Please Note This forum exists for community support for the Mango product family and the Radix IoT Platform. Although Radix IoT employees participate in this forum from time to time, there is no guarantee of a response to anything posted here, nor can Radix IoT, LLC guarantee the accuracy of any information expressed or conveyed. Specific project questions from customers with active support contracts are asked to send requests to support@radixiot.com.
SSL Certification Error
-
Dear All,
We would like to run Mango with https instead of http. We have tried steps on the Mango Documentation ( https://docs-v3.mango-os.com/installation-configuration/#ssl-properties ) and restart Mango then get an error as below.
What should we do to run Mango with https?
WARN 2020-09-16T09:19:45,659 (com.serotonin.m2m2.Lifecycle.webServerInitialize:975) - ALPN is enabled in env.properties but couldn't be loaded: No Server ALPNProcessors! java.lang.IllegalStateException: No Server ALPNProcessors! at org.eclipse.jetty.alpn.server.ALPNServerConnectionFactory.<init>(ALPNServerConnectionFactory.java:52) ~[jetty-alpn-server-9.4.23.v20191118.jar:9.4.23.v20191118] at com.serotonin.m2m2.Lifecycle.webServerInitialize(Lifecycle.java:973) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Lifecycle.initialize(Lifecycle.java:221) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Main.main(Main.java:159) ~[ma-priv-3.7.7.jar:?] Suppressed: java.lang.UnsupportedClassVersionError: org/eclipse/jetty/alpn/java/server/JDK9ServerALPNProcessor has been compiled by a more recent version of the Java Runtime (class file version 53.0), this version of the Java Runtime only recognizes class file versions up to 52.0 at java.lang.ClassLoader.defineClass1(Native Method) ~[?:1.8.0_252] at java.lang.ClassLoader.defineClass(ClassLoader.java:756) ~[?:1.8.0_252] at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) ~[?:1.8.0_252] at java.net.URLClassLoader.defineClass(URLClassLoader.java:468) ~[?:1.8.0_252] at java.net.URLClassLoader.access$100(URLClassLoader.java:74) ~[?:1.8.0_252] at java.net.URLClassLoader$1.run(URLClassLoader.java:369) ~[?:1.8.0_252] at java.net.URLClassLoader$1.run(URLClassLoader.java:363) ~[?:1.8.0_252] at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_252] at java.net.URLClassLoader.findClass(URLClassLoader.java:362) ~[?:1.8.0_252] at java.lang.ClassLoader.loadClass(ClassLoader.java:418) ~[?:1.8.0_252] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:352) ~[?:1.8.0_252] at java.lang.ClassLoader.loadClass(ClassLoader.java:405) ~[?:1.8.0_252] at java.lang.ClassLoader.loadClass(ClassLoader.java:351) ~[?:1.8.0_252] at java.lang.Class.forName0(Native Method) ~[?:1.8.0_252] at java.lang.Class.forName(Class.java:348) ~[?:1.8.0_252] at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:370) ~[?:1.8.0_252] at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404) ~[?:1.8.0_252] at java.util.ServiceLoader$1.next(ServiceLoader.java:480) ~[?:1.8.0_252] at org.eclipse.jetty.alpn.server.ALPNServerConnectionFactory.<init>(ALPNServerConnectionFactory.java:59) ~[jetty-alpn-server-9.4.23.v20191118.jar:9.4.23.v20191118] at com.serotonin.m2m2.Lifecycle.webServerInitialize(Lifecycle.java:973) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Lifecycle.initialize(Lifecycle.java:221) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Main.main(Main.java:159) ~[ma-priv-3.7.7.jar:?] Suppressed: java.lang.IllegalStateException: org.eclipse.jetty.alpn.ALPN must be on JVM boot classpath at org.eclipse.jetty.alpn.openjdk8.server.OpenJDK8ServerALPNProcessor.init(OpenJDK8ServerALPNProcessor.java:44) ~[jetty-alpn-openjdk8-server-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.alpn.server.ALPNServerConnectionFactory.<init>(ALPNServerConnectionFactory.java:72) ~[jetty-alpn-server-9.4.23.v20191118.jar:9.4.23.v20191118] at com.serotonin.m2m2.Lifecycle.webServerInitialize(Lifecycle.java:973) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Lifecycle.initialize(Lifecycle.java:221) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Main.main(Main.java:159) ~[ma-priv-3.7.7.jar:?] ERROR 2020-09-16T09:19:45,902 (com.serotonin.m2m2.Main.main:162) - Error during initialization java.lang.IllegalStateException: no valid keystore at org.eclipse.jetty.util.security.CertificateUtils.getKeyStore(CertificateUtils.java:50) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.ssl.SslContextFactory.loadKeyStore(SslContextFactory.java:1188) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.ssl.SslContextFactory.load(SslContextFactory.java:323) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.ssl.SslContextFactory.doStart(SslContextFactory.java:245) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:117) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.server.SslConnectionFactory.doStart(SslConnectionFactory.java:92) ~[jetty-server-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:117) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.server.AbstractConnector.doStart(AbstractConnector.java:320) ~[jetty-server-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.server.AbstractNetworkConnector.doStart(AbstractNetworkConnector.java:81) ~[jetty-server-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.server.ServerConnector.doStart(ServerConnector.java:231) ~[jetty-server-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.server.Server.doStart(Server.java:385) ~[jetty-server-9.4.23.v20191118.jar:9.4.23.v20191118] at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:72) ~[jetty-util-9.4.23.v20191118.jar:9.4.23.v20191118] at com.serotonin.m2m2.Lifecycle.webServerInitialize(Lifecycle.java:1042) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Lifecycle.initialize(Lifecycle.java:221) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Main.main(Main.java:159) ~[ma-priv-3.7.7.jar:?] INFO 2020-09-16T09:19:45,902 (com.serotonin.m2m2.Lifecycle.terminate:400) - Mango Lifecycle terminating... ERROR 2020-09-16T09:19:45,922 (com.serotonin.m2m2.Lifecycle.terminate:478) - com.serotonin.provider.InputStreamEPollProvider com.serotonin.provider.ProviderNotFoundException: com.serotonin.provider.InputStreamEPollProvider at com.serotonin.provider.Providers.get(Providers.java:30) ~[mango-3.7.7.jar:?] at com.serotonin.provider.Providers.get(Providers.java:20) ~[mango-3.7.7.jar:?] at com.serotonin.m2m2.Lifecycle.terminate(Lifecycle.java:473) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Main.main(Main.java:163) ~[ma-priv-3.7.7.jar:?] ERROR 2020-09-16T09:19:45,922 (com.serotonin.m2m2.Lifecycle.terminate:486) - com.serotonin.provider.ProcessEPollProvider com.serotonin.provider.ProviderNotFoundException: com.serotonin.provider.ProcessEPollProvider at com.serotonin.provider.Providers.get(Providers.java:30) ~[mango-3.7.7.jar:?] at com.serotonin.provider.Providers.get(Providers.java:20) ~[mango-3.7.7.jar:?] at com.serotonin.m2m2.Lifecycle.terminate(Lifecycle.java:481) ~[ma-priv-3.7.7.jar:?] at com.serotonin.m2m2.Main.main(Main.java:163) ~[ma-priv-3.7.7.jar:?]
Thanks in advance!
-
Hi @Nurr
What version of Java are you using and have you put the enable-alpn.sh script to the /mango/bin/ext-enabled/ directory?
If you are using java 8 you need the script. If you are using Java 9+ the script will cause errors.
-
I see enable-alpn.sh script on the /mango/bin/ext-enabled/ directory. We use java version 1.8.0.
What is your suggestion? Should we upgrade java version or use the script?
openjdk version "1.8.0_252"
OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_252-b09)
OpenJDK 64-Bit Server VM (AdoptOpenJDK)(build 25.252-b09, mixed mode)Thanks!
-
@nurr said in SSL Certification Error:
openjdk version "1.8.0_252"
We recommend using AdoptOpenJDK 13 HotSpot. upgrade to that version and then remove the enable-alpn.sh script.