连接被拒绝:如何为localhost配置apache james

时间:2012-08-16 06:36:25

标签: linux apache email telnet james

我不清楚如何配置Apache James。 quick start guide说:

Step 4: Configure
#################

  * All configuration files are embedded in jars.
  * We ship in the conf foler template configuration files.
  * You can override the default configuration : 
      Copy the conf folder any ...-template... you need and update according to your needs.

配置文件嵌入jar中意味着什么?我应该解压缩所有这些jar来配置文件吗?

目录结构:

thufir@dur:~/apache-james-3.0-beta4$ 
thufir@dur:~/apache-james-3.0-beta4$ tree -L 1
.
├── bin
├── conf
├── lib
├── LICENSE
├── log
├── NOTICE
├── README.crypto
├── README.txt
└── var

5 directories, 4 files
thufir@dur:~/apache-james-3.0-beta4$ 
thufir@dur:~/apache-james-3.0-beta4$ ll conf/
total 272
drwxr-xr-x 4 thufir thufir  4096 Aug 14 06:26 ./
drwxrwxr-x 7 thufir thufir  4096 Aug 14 06:26 ../
-rw------- 1 thufir thufir  2939 Mar 21 03:33 dnsservice-template.conf
-rw------- 1 thufir thufir  2903 Mar 21 03:33 domainlist-template.conf
-rw------- 1 thufir thufir 18715 Mar 21 03:33 fetchmail-template.conf
-rw------- 1 thufir thufir  1197 Mar 21 03:33 hbase-site-template.xml
-rw------- 1 thufir thufir  3466 Mar 21 03:33 imapserver-template.conf
-rw------- 1 thufir thufir  1645 Mar 21 03:33 james-database-template.properties
-rw------- 1 thufir thufir  3510 Mar 21 03:33 jcr-repository-template.xml
-rw------- 1 thufir thufir  1158 Mar 21 03:33 jmx-template.properties
drwxr-xr-x 2 thufir thufir  4096 Aug 14 06:26 lib/
-rw------- 1 thufir thufir  3325 Mar 21 03:33 lmtpserver-template.conf
-rw------- 1 thufir thufir  6944 Mar 21 03:33 log4j.properties
-rw------- 1 thufir thufir  7073 Mar 21 03:33 log4j-template.properties
-rw------- 1 thufir thufir  2885 Mar 21 03:33 mailbox-jcr-template.cnd
-rw------- 1 thufir thufir  1043 Mar 21 03:33 mailbox-maildir-template.properties
-rw------- 1 thufir thufir  1492 Mar 21 03:33 mailbox-template.conf
-rw------- 1 thufir thufir 30474 Mar 21 03:33 mailetcontainer-template.conf
-rw------- 1 thufir thufir  4172 Mar 21 03:33 mailrepositorystore-template.conf
drwxr-xr-x 3 thufir thufir  4096 Aug 14 06:26 META-INF/
-rw------- 1 thufir thufir  3528 Mar 21 03:33 pop3server-template.conf
-rw------- 1 thufir thufir  2497 Mar 21 03:33 recipientrewritetable-template.conf
-rw------- 1 thufir thufir 16011 Mar 21 03:33 smtpserver-template.conf
-rw------- 1 thufir thufir 43220 Mar 21 03:33 sqlResources-template.xml
-rw------- 1 thufir thufir 43220 Mar 21 03:33 sqlResources.xml
-rw------- 1 thufir thufir  1606 Mar 21 03:33 usersrepository23-template.conf
-rw------- 1 thufir thufir  3715 Mar 21 03:33 usersrepository-template.conf
-rw------- 1 thufir thufir 12596 Mar 21 03:33 wrapper.conf
thufir@dur:~/apache-james-3.0-beta4$ 

虽然我看到配置文件,但是哪个配置文件可以让我telnet到James?

尝试连接:

thufir@dur:~/apache-james-3.0-beta4$ 
thufir@dur:~/apache-james-3.0-beta4$ bin/james console
Running Apache James Server App...
wrapper  | --> Wrapper Started as Console
wrapper  | Launching a JVM...
jvm 1    | Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org
jvm 1    |   Copyright 1999-2006 Tanuki Software, Inc.  All Rights Reserved.
jvm 1    | 
jvm 1    | log4j:ERROR setFile(null,true) call failed.
jvm 1    | java.io.FileNotFoundException: ../log/james-server.log (Permission denied)
jvm 1    |  at java.io.FileOutputStream.openAppend(Native Method)
jvm 1    |  at java.io.FileOutputStream.<init>(FileOutputStream.java:207)
jvm 1    |  at java.io.FileOutputStream.<init>(FileOutputStream.java:131)
jvm 1    |  at org.apache.log4j.FileAppender.setFile(FileAppender.java:294)
jvm 1    |  at org.apache.log4j.FileAppender.activateOptions(FileAppender.java:165)
jvm 1    |  at org.apache.log4j.DailyRollingFileAppender.activateOptions(DailyRollingFileAppender.java:223)
jvm 1    |  at org.apache.log4j.config.PropertySetter.activate(PropertySetter.java:307)
jvm 1    |  at org.apache.log4j.config.PropertySetter.setProperties(PropertySetter.java:172)
jvm 1    |  at org.apache.log4j.config.PropertySetter.setProperties(PropertySetter.java:104)
jvm 1    |  at org.apache.log4j.PropertyConfigurator.parseAppender(PropertyConfigurator.java:809)
jvm 1    |  at org.apache.log4j.PropertyConfigurator.parseCategory(PropertyConfigurator.java:735)
jvm 1    |  at org.apache.log4j.PropertyConfigurator.parseCatsAndRenderers(PropertyConfigurator.java:639)
jvm 1    |  at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:504)
jvm 1    |  at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:547)
jvm 1    |  at org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:483)
jvm 1    |  at org.apache.log4j.LogManager.<clinit>(LogManager.java:127)
jvm 1    |  at org.slf4j.impl.Log4jLoggerFactory.getLogger(Log4jLoggerFactory.java:73)
jvm 1    |  at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:242)
jvm 1    |  at org.apache.james.app.spring.JamesAppSpringMain.<clinit>(JamesAppSpringMain.java:34)
jvm 1    |  at java.lang.Class.forName0(Native Method)
jvm 1    |  at java.lang.Class.forName(Class.java:186)
jvm 1    |  at org.tanukisoftware.wrapper.WrapperSimpleApp.<init>(WrapperSimpleApp.java:147)
jvm 1    |  at org.tanukisoftware.wrapper.WrapperSimpleApp.main(WrapperSimpleApp.java:485)
jvm 1    | log4j:ERROR Either File or DatePattern options are not set for appender [FILE].
jvm 1    | INFO  01:04:33,381 | org.apache.james.container.spring.context.JamesServerApplicationContext | Refreshing org.apache.james.container.spring.context.JamesServerApplicationContext@1f5d386: startup date [Thu Aug 16 01:04:33 PDT 2012]; root of context hierarchy
jvm 1    | log4j:WARN No appenders could be found for logger (org.apache.commons.configuration.ConfigurationUtils).
jvm 1    | log4j:WARN Please initialize the log4j system properly.
jvm 1    | log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
jvm 1    | INFO  01:04:38,359 | org.apache.james.container.spring.context.JamesServerApplicationContext | Bean 'logprovider' of type [class org.apache.james.container.spring.lifecycle.LogProviderImpl] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
jvm 1    | INFO  01:04:39,987 | james.mailrepositorystore | JamesMailStore init...
jvm 1    | INFO  01:04:40,026 | james.mailrepositorystore | Registering Repository instance of class org.apache.james.mailrepository.file.FileMailRepository to handle file protocol requests for repositories with key file
jvm 1    | INFO  01:04:40,026 | james.mailrepositorystore | Registering Repository instance of class org.apache.james.mailrepository.jdbc.JDBCMailRepository to handle db protocol requests for repositories with key db
jvm 1    | INFO  01:04:40,027 | james.mailrepositorystore | Registering Repository instance of class org.apache.james.mailrepository.jdbc.JDBCMailRepository to handle dbfile protocol requests for repositories with key dbfile
jvm 1    | INFO  01:04:40,027 | james.mailrepositorystore | Registering Repository instance of class org.apache.james.mailrepository.file.MBoxMailRepository to handle mbox protocol requests for repositories with key mbox
jvm 1    | INFO  01:04:41,791 | james.dnsservice | Autodiscovery is enabled - trying to discover your system's DNS Servers
jvm 1    | INFO  01:04:41,821 | james.dnsservice | Adding autodiscovered server 127.0.0.1
jvm 1    | INFO  01:04:41,822 | james.dnsservice | Adding autodiscovered search path bounceme.net.
jvm 1    | INFO  01:04:41,833 | james.dnsservice | DNS Server is: 127.0.0.1
jvm 1    | INFO  01:04:41,870 | james.dnsservice | Registered cache, resolver and search paths as DNSJava defaults
jvm 1    | 54  James  WARN   [WrapperSimpleAppMain] openjpa.Runtime - An error occurred while registering a ClassTransformer with PersistenceUnitInfo: name 'James', root URL [file:/home/thufir/apache-james-3.0-beta4/conf/]. The error has been consumed. To see it, set your openjpa.Runtime log level to TRACE. Load-time class transformation will not be available.
jvm 1    | INFO  01:04:43,208 | james.domainlist | Set autodetect to: true
jvm 1    | INFO  01:04:43,216 | james.domainlist | Set autodetectIP to: true
jvm 1    | 156  James  INFO   [WrapperSimpleAppMain] openjpa.Runtime - Starting OpenJPA 2.1.0
jvm 1    | 368  James  INFO   [WrapperSimpleAppMain] openjpa.jdbc.JDBC - Using dictionary class "org.apache.openjpa.jdbc.sql.DerbyDictionary".
jvm 1    | 7087  James  INFO   [WrapperSimpleAppMain] openjpa.Runtime - The Entity "org.apache.james.domainlist.jpa.model.JPADomain" was enhanced at level "2", but the current level of enhancement is "1,055,128". 
jvm 1    | 7094  James  INFO   [WrapperSimpleAppMain] openjpa.Runtime - A down level Entity was detected and logged. Please enable RUNTIME trace to see all down level Entities.
jvm 1    | WARN  01:04:51,660 | james.mailetcontext | The specified postmaster address ( postmaster@localhost ) is not a local address.  This is not necessarily a problem, but it does mean that emails addressed to the postmaster will be routed to another server.  For some configurations this may cause problems.
jvm 1    | INFO  01:04:52,153 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:52,214 | james.mailprocessor | Mailet PostmasterAlias instantiated.
jvm 1    | INFO  01:04:52,238 | james.mailprocessor | Matcher RelayLimit=30 instantiated.
jvm 1    | INFO  01:04:52,262 | james.mailprocessor | Mailet Null instantiated.
jvm 1    | INFO  01:04:52,284 | james.mailprocessor | Matcher SMTPAuthSuccessful instantiated.
jvm 1    | INFO  01:04:52,301 | james.mailprocessor | Mailet ToProcessor instantiated.
jvm 1    | INFO  01:04:52,302 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:52,314 | james.mailprocessor | Mailet ToProcessor instantiated.
jvm 1    | INFO  01:04:54,075 | james.mailprocessor | Matcher SMTPAuthSuccessful instantiated.
jvm 1    | INFO  01:04:54,085 | james.mailprocessor | Mailet SetMimeHeader instantiated.
jvm 1    | INFO  01:04:54,094 | james.mailprocessor | Matcher RecipientIsLocal instantiated.
jvm 1    | INFO  01:04:54,103 | james.mailprocessor | Mailet RecipientToLowerCase instantiated.
jvm 1    | INFO  01:04:54,104 | james.mailprocessor | Matcher RecipientIsLocal instantiated.
jvm 1    | INFO  01:04:54,547 | james.mailprocessor | Mailet LocalDelivery instantiated.
jvm 1    | INFO  01:04:54,556 | james.mailprocessor | Matcher HostIsLocal instantiated.
jvm 1    | INFO  01:04:54,558 | james.mailprocessor | Mailet ToProcessor instantiated.
jvm 1    | INFO  01:04:54,558 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:54,621 | james.mailetcontext | maxRetries is larger than total number of attempts specified.  Increasing last delayTime with 19 attempts 
jvm 1    | INFO  01:04:54,621 | james.mailetcontext | Delay of 21600000 msecs is now attempted: 20 times
jvm 1    | INFO  01:04:54,696 | james.mailprocessor | Mailet RemoteDelivery instantiated.
jvm 1    | INFO  01:04:56,336 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:56,387 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentObjectRepository Store
jvm 1    | INFO  01:04:56,390 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentObjectRepository opened in ../var/mail/error
jvm 1    | INFO  01:04:56,392 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentStreamRepository Store
jvm 1    | INFO  01:04:56,393 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentStreamRepository opened in ../var/mail/error
jvm 1    | INFO  01:04:56,395 | james.mailrepositorystore | added repository: file://var/mail/error/->org.apache.james.mailrepository.file.FileMailRepository
jvm 1    | INFO  01:04:56,395 | james.mailprocessor | Mailet ToRepository instantiated.
jvm 1    | INFO  01:04:56,801 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:56,806 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentObjectRepository Store
jvm 1    | INFO  01:04:56,807 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentObjectRepository opened in ../var/mail/spam
jvm 1    | INFO  01:04:56,808 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentStreamRepository Store
jvm 1    | INFO  01:04:56,808 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentStreamRepository opened in ../var/mail/spam
jvm 1    | INFO  01:04:56,809 | james.mailrepositorystore | added repository: file://var/mail/spam/->org.apache.james.mailrepository.file.FileMailRepository
jvm 1    | INFO  01:04:56,809 | james.mailprocessor | Mailet ToRepository instantiated.
jvm 1    | INFO  01:04:57,180 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:57,183 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentObjectRepository Store
jvm 1    | INFO  01:04:57,183 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentObjectRepository opened in ../var/mail/address-error
jvm 1    | INFO  01:04:57,184 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentStreamRepository Store
jvm 1    | INFO  01:04:57,184 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentStreamRepository opened in ../var/mail/address-error
jvm 1    | INFO  01:04:57,185 | james.mailrepositorystore | added repository: file://var/mail/address-error/->org.apache.james.mailrepository.file.FileMailRepository
jvm 1    | INFO  01:04:57,185 | james.mailprocessor | Mailet ToRepository instantiated.
jvm 1    | INFO  01:04:57,633 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:57,636 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentObjectRepository Store
jvm 1    | INFO  01:04:57,636 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentObjectRepository opened in ../var/mail/relay-denied
jvm 1    | INFO  01:04:57,637 | james.mailrepositorystore | Init org.apache.james.repository.file.FilePersistentStreamRepository Store
jvm 1    | INFO  01:04:57,637 | james.mailrepositorystore | org.apache.james.repository.file.FilePersistentStreamRepository opened in ../var/mail/relay-denied
jvm 1    | INFO  01:04:57,637 | james.mailrepositorystore | added repository: file://var/mail/relay-denied/->org.apache.james.mailrepository.file.FileMailRepository
jvm 1    | INFO  01:04:57,638 | james.mailprocessor | Mailet ToRepository instantiated.
jvm 1    | INFO  01:04:57,996 | james.mailprocessor | Matcher All instantiated.
jvm 1    | INFO  01:04:58,043 | james.mailprocessor | Mailet DSNBounce instantiated.
jvm 1    | INFO  01:04:58,398 | james.mailspooler | org.apache.james.mailetcontainer.impl.JamesMailSpooler init...
jvm 1    | INFO  01:04:58,400 | james.mailspooler | org.apache.james.mailetcontainer.impl.JamesMailSpooler uses 20 Thread(s)
jvm 1    | INFO  01:04:58,407 | james.mailspooler | Run org.apache.james.mailetcontainer.impl.JamesMailSpooler: dequeuer-1
jvm 1    | INFO  01:04:58,407 | james.mailspooler | Queue=MailQueue:spool
jvm 1    | INFO  01:04:58,423 | james.mailspooler | Run org.apache.james.mailetcontainer.impl.JamesMailSpooler: dequeuer-2
jvm 1    | INFO  01:04:58,423 | james.mailspooler | Queue=MailQueue:spool
jvm 1    | INFO  01:04:58,577 | james.fetchmail | FetchMail Disabled
jvm 1    | INFO  01:04:58,807 | james.smtpserver | SMTP Service bound to: 0.0.0.0:25
jvm 1    | INFO  01:04:58,808 | james.smtpserver | SMTP Service is running on: dur.bounceme.net
jvm 1    | INFO  01:04:58,808 | james.smtpserver | SMTP Service handler hello name is: dur.bounceme.net
jvm 1    | INFO  01:04:58,809 | james.smtpserver | SMTP Service handler connection timeout is: 360
jvm 1    | INFO  01:04:58,809 | james.smtpserver | SMTP Service connection backlog is: 200
jvm 1    | INFO  01:04:58,810 | james.smtpserver | This SMTP server requires authentication.
jvm 1    | INFO  01:04:58,810 | james.smtpserver | No maximum message size is enforced for this server.
jvm 1    | INFO  01:05:00,105 | james.mailspooler | org.apache.james.mailetcontainer.impl.JamesMailSpooler dispose...
jvm 1    | INFO  01:05:00,110 | james.mailspooler | Stop org.apache.james.mailetcontainer.impl.JamesMailSpooler: dequeuer-2
jvm 1    | INFO  01:05:00,113 | james.mailspooler | org.apache.james.mailetcontainer.impl.JamesMailSpooler thread shutdown completed.
jvm 1    | INFO  01:05:00,112 | james.mailspooler | Stop org.apache.james.mailetcontainer.impl.JamesMailSpooler: dequeuer-1
jvm 1    | 
jvm 1    | WrapperSimpleApp: Encountered an error running main: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'smtpserver': Invocation of init method failed; nested exception is org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:25
jvm 1    | org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'smtpserver': Invocation of init method failed; nested exception is org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:25
jvm 1    |  at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:135)
jvm 1    |  at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:394)
jvm 1    |  at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1448)
jvm 1    |  at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
jvm 1    |  at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
jvm 1    |  at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
jvm 1    |  at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
jvm 1    |  at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)
jvm 1    |  at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
jvm 1    |  at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:585)
jvm 1    |  at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913)
jvm 1    |  at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464)
jvm 1    |  at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)
jvm 1    |  at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)
jvm 1    |  at org.apache.james.container.spring.context.JamesServerApplicationContext.<init>(JamesServerApplicationContext.java:39)
jvm 1    |  at org.apache.james.app.spring.JamesAppSpringMain.init(JamesAppSpringMain.java:61)
jvm 1    |  at org.apache.james.app.spring.JamesAppSpringMain.main(JamesAppSpringMain.java:42)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
jvm 1    |  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1    |  at java.lang.reflect.Method.invoke(Method.java:616)
jvm 1    |  at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
jvm 1    |  at java.lang.Thread.run(Thread.java:679)
jvm 1    | Caused by: org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:25
jvm 1    |  at org.jboss.netty.bootstrap.ServerBootstrap.bind(ServerBootstrap.java:298)
jvm 1    |  at org.apache.james.protocols.netty.AbstractAsyncServer.bind(AbstractAsyncServer.java:101)
jvm 1    |  at org.apache.james.protocols.lib.netty.AbstractConfigurableAsyncServer.init(AbstractConfigurableAsyncServer.java:274)
jvm 1    |  at org.apache.james.protocols.lib.netty.AbstractServerFactory.init(AbstractServerFactory.java:75)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
jvm 1    |  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1    |  at java.lang.reflect.Method.invoke(Method.java:616)
jvm 1    |  at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleElement.invoke(InitDestroyAnnotationBeanPostProcessor.java:346)
jvm 1    |  at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleMetadata.invokeInitMethods(InitDestroyAnnotationBeanPostProcessor.java:299)
jvm 1    |  at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:132)
jvm 1    |  ... 22 more
jvm 1    | Caused by: java.net.SocketException: Permission denied
jvm 1    |  at sun.nio.ch.Net.bind(Native Method)
jvm 1    |  at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:137)
jvm 1    |  at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:77)
jvm 1    |  at org.jboss.netty.channel.socket.nio.NioServerSocketPipelineSink.bind(NioServerSocketPipelineSink.java:140)
jvm 1    |  at org.jboss.netty.channel.socket.nio.NioServerSocketPipelineSink.handleServerSocket(NioServerSocketPipelineSink.java:92)
jvm 1    |  at org.jboss.netty.channel.socket.nio.NioServerSocketPipelineSink.eventSunk(NioServerSocketPipelineSink.java:66)
jvm 1    |  at org.jboss.netty.channel.Channels.bind(Channels.java:462)
jvm 1    |  at org.jboss.netty.channel.AbstractChannel.bind(AbstractChannel.java:186)
jvm 1    |  at org.jboss.netty.bootstrap.ServerBootstrap$Binder.channelOpen(ServerBootstrap.java:343)
jvm 1    |  at org.jboss.netty.channel.Channels.fireChannelOpen(Channels.java:170)
jvm 1    |  at org.jboss.netty.channel.socket.nio.NioServerSocketChannel.<init>(NioServerSocketChannel.java:77)
jvm 1    |  at org.jboss.netty.channel.socket.nio.NioServerSocketChannelFactory.newChannel(NioServerSocketChannelFactory.java:137)
jvm 1    |  at org.jboss.netty.channel.socket.nio.NioServerSocketChannelFactory.newChannel(NioServerSocketChannelFactory.java:85)
jvm 1    |  at org.jboss.netty.bootstrap.ServerBootstrap.bind(ServerBootstrap.java:277)
jvm 1    |  ... 32 more
wrapper  | <-- Wrapper Stopped
thufir@dur:~/apache-james-3.0-beta4$ 

配置文件(不适合):

https://gist.github.com/3368324

1 个答案:

答案 0 :(得分:1)

  

大多数UNIX系统都需要超级用户权限才能打开下面的套接字   1024,包括IANA标准SMTP(在端口25上),POP3(在   端口110)和IMAP4(在端口143上)。可以更改这些默认端口   在conf文件中(读取pop3,smtp和imap4。显然,你会的   然后需要重新配置您的客户。如果这可能不是一个选项   您希望从外部邮件服务器接收邮件。

此文本来自here找到的james安装指南。您是否尝试以root用户身份运行james以尝试绑定到端口25?试试这个:sudo ./james start。如果这似乎不起作用,您可以在各自的配置文件中更改相应服务的端口: smtp的smtpserver.conf ,您可能会感兴趣,看到您正在尝试使用smtp服务器。

[编辑]:您可以在任何标准文本编辑器中打开配置文件,,如nano,vi,emacs,gedit等...

[编辑#2]:您是否拥有运行james所需的正确java实现?从安装指南:

  

James需要Java Runtime Environment。 Java 1.5或更高版本   需要运行James应用程序。确切的JRE可用   取决于平台。另外,环境变量   在运行之前,应将JAVA_HOME设置为JRE主目录   詹姆斯。

     

如果你运行JDK7,由于JAXB中的错误,James将无法启动。如   临时解决方法,您可以下载最新的2.1版本的JAXB   来自http://jaxb.java.net/2.1.13/JAXB2_20100510.jar并复制   将jaxb-impl.jar解压缩到conf / lib。

     

James 3.0已在OpenJDK,Sun JDK和IBM JDK上成功测试

如果我是你,我会选择下载OpenJDK 1.6版并查看它的去向。作为旁注,您是否尝试使用./james help,并查看是否有任何有用的内容?此外,尝试附加詹姆斯可能在您的问题中产生的任何日志文件,以帮助我们进一步检查问题。