Thanks Craig, no I have never set up SElinux. quasar:/mail/apache-james-3.4/james-server-app-3.4.0/conf # getenforce Disabled
On 12/28/19 10:14 AM, Craig Cudmore wrote: > Is SElinux enabled? Perhaps disable it and see if that has any impact. > > Craig Cudmore > 613-868-7316 > >> On Dec 28, 2019, at 1:09 PM, Marc Chamberlin >> <m...@marcchamberlin.com.invalid> wrote: >> >> Hello - I am in the process of installing the new release of James >> 3.4.0 and am encountering an error that doesn't make sense to me, >> involving the startup of the smtp service. As shown below in the >> exception traceback I am getting a complaint about the keystore file >> either not being found or getting some sort of permission denied error. >> The keystore file does indeed exist and there is really nothing wrong >> with the path or file that this error is reporting. In this particular >> example the keystore is a symlink to the actual keystore file. I created >> from LetsEncrypt wildcard certificates, and I have tried configuring the >> path directly to the actual keystore file with no symlinks involved and >> still no joy. So I suspect the "FileNotFoundException" error is misleading. >> >> quasar:/mail/apache-james-3.4/james-server-app-3.4.0/conf # ll keystore >> lrwxrwxrwx 1 james mail 34 Dec 23 18:47 keystore -> >> keystore.privateFiles/keystore.jks >> >> quasar:/mail/apache-james-3.4/james-server-app-3.4.0/conf # ll -d >> keystore.privateFiles >> drw-rw-r-- 2 james mail 4096 Dec 27 22:11 keystore.privateFiles >> >> quasar:/mail/apache-james-3.4/james-server-app-3.4.0/conf # ll >> keystore.privateFiles/ >> total 12 >> -rw-rw-r-- 1 james mail 4637 Dec 27 22:13 keystore.jks >> >> As for the "Permission denied" comment in the error message this is what >> I can report. All of the files for James, including the keystore file >> have their owner and group set to james:mail. Both the user james and >> root are part of the mail group. The file permissions are set to >> -rw-rw-r--. I have also experimented with other file permissions such as >> -rw-rw---- and -rw-r----- with no joy. As for the password to use for >> accessing the keystore itself again I know that what I am specifying in >> the smtpserver.xml file is correct and I can test it by using the >> following command which will ask for the keystore password. >> >> keytool -list -v -keystore >> /mail/apache-james-3.4/james-server-app-3.4.0/conf/keystore >> >> So I am at a loss trying to figure out what is going wrong. I set the >> debug levels in the logj4.properties file to debug to see if that would >> produce any further helpful info, but it didn't. >> >> What follows is the exception walkback, anyone got any ideas that I can >> try? Thanks in advance... Marc >> >> ---- >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | WARN 08:36:27,067 | >> org.apache.james.container.spring.context.JamesServerApplicationContext | >> Exception encountered during context initialization - cancelling refresh >> attempt: org.springframework.beans.factory.BeanCreationException: Error >> creating bean with name 'smtpserver': Invocation of init method failed; >> nested exception is java.io.FileNotFoundException: >> /mail/apache-james-3.4/james-server-app-3.4.0/conf/keystore (Permission >> denied) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | INFO 08:36:27,068 | >> org.apache.james.mailetcontainer.impl.JamesMailSpooler | start dispose() ... >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | INFO 08:36:27,068 | >> org.apache.james.mailetcontainer.impl.JamesMailSpooler | thread shutdown >> completed. >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | 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 java.io.FileNotFoundException: >> /mail/apache-james-3.4/james-server-app-3.4.0/conf/keystore (Permission >> denied) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | >> org.springframework.beans.factory.BeanCreationException: Error creating bean >> with name 'smtpserver': Invocation of init method failed; nested exception >> is java.io.FileNotFoundException: >> /mail/apache-james-3.4/james-server-app-3.4.0/conf/keystore (Permission >> denied) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:133) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:396) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1507) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:191) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:638) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:942) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:482) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.apache.james.container.spring.context.JamesServerApplicationContext.<init>(JamesServerApplicationContext.java:40) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.apache.james.app.spring.JamesAppSpringMain.init(JamesAppSpringMain.java:56) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.apache.james.app.spring.JamesAppSpringMain.main(JamesAppSpringMain.java:42) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> java.lang.reflect.Method.invoke(Method.java:498) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> java.lang.Thread.run(Thread.java:748) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | Caused by: >> java.io.FileNotFoundException: >> /mail/apache-james-3.4/james-server-app-3.4.0/conf/keystore (Permission >> denied) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> java.io.FileInputStream.open0(Native Method) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> java.io.FileInputStream.open(FileInputStream.java:195) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> java.io.FileInputStream.<init>(FileInputStream.java:138) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.apache.james.protocols.lib.netty.AbstractConfigurableAsyncServer.buildSSLContext(AbstractConfigurableAsyncServer.java:404) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.apache.james.protocols.lib.netty.AbstractConfigurableAsyncServer.init(AbstractConfigurableAsyncServer.java:263) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.apache.james.protocols.lib.netty.AbstractServerFactory.init(AbstractServerFactory.java:57) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> java.lang.reflect.Method.invoke(Method.java:498) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleElement.invoke(InitDestroyAnnotationBeanPostProcessor.java:344) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleMetadata.invokeInitMethods(InitDestroyAnnotationBeanPostProcessor.java:295) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | at >> org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:130) >> >> INFO | jvm 1 | 2019/12/28 08:36:27 | ... 22 more >> >> STATUS | wrapper | 2019/12/28 08:36:29 | <-- Wrapper Stopped >> >> >> -- >> >> --... ...-- .----. ... -.. . .-- .- --... .--. -..- .-- >> -- .- .-. -.-. >> >> >> *Computers: the final frontier. These are the voyages of the user Marc. >> His mission: to explore strange new hardware. To seek out new software >> and new applications. >> To boldly go where no Marc has gone before! >> * > --------------------------------------------------------------------- > To unsubscribe, e-mail: server-user-unsubscr...@james.apache.org > For additional commands, e-mail: server-user-h...@james.apache.org > -- --... ...-- .----. ... -.. . .-- .- --... .--. -..- .-- -- .- .-. -.-. *Computers: the final frontier. These are the voyages of the user Marc. His mission: to explore strange new hardware. To seek out new software and new applications. To boldly go where no Marc has gone before! *