Closed TheQue42 closed 10 months ago
I've now tried the next version of 7.4, as well as the -beta, and neither works. Can someone please confirm which version of separate mongo container they run with successfully, aginst 7.4?
Log from -beta:
[2023-06-29 19:58:49,174] <launcher> INFO tomcat - Adding basic REST API support during the startup
[2023-06-29 19:58:52,995] <launcher> INFO db - Starting database service initialization...
[2023-06-29 19:58:52,995] <launcher> INFO db - waiting for db connection...
[2023-06-29 19:58:53,496] <launcher> INFO db - Connecting to mongodb://mongodb:27017/unifi
[2023-06-29 19:58:53,575] <launcher> INFO db - db connection established...
[2023-06-29 19:58:53,635] <launcher> INFO db - db connected (v5.0.18@mongodb://mongodb:27017/unifi)
[2023-06-29 19:58:53,637] <launcher> INFO db - setting mongodb features compatibility version to 3.6
[2023-06-29 19:58:53,640] <launcher> WARN db - Unable to ensure mongodb features version to 3.6: Command failed with error 4926900 (Location4926900): 'Invalid value for featureCompatibilityVersiondocument in admin.system.version, found 3.6, expected '4.4' or '4.9' or '5.0. See https://docs.mongodb.com/master/release-notes/4.4-compatibility/#feature-compatibility.' on server mongodb:27017. The full response is {"ok": 0.0, "errmsg": "Invalid value for featureCompatibilityVersiondocument in admin.system.version, found 3.6, expected '4.4' or '4.9' or '5.0. See https://docs.mongodb.com/master/release-notes/4.4-compatibility/#feature-compatibility.", "code": 4926900, "codeName": "Location4926900"}
[2023-06-29 19:58:53,708] <launcher> INFO db - Database service initialized...
[2023-06-29 19:58:53,714] <launcher> INFO system - ======================================================================
[2023-06-29 19:58:53,714] <launcher> INFO system - UniFi 7.4.162 (build atag_7.4.162_21057 - release/release) is started
[2023-06-29 19:58:53,714] <launcher> INFO system - Environment: UniFi-OS[false], UniFi-Cloud[false], UniFi-MongoService[false]
[2023-06-29 19:58:53,714] <launcher> INFO system - ======================================================================
[2023-06-29 19:58:53,714] <launcher> INFO system - BASE dir:/usr/lib/unifi
[2023-06-29 19:58:53,715] <launcher> INFO system - Current System IP: 172.18.0.3
[2023-06-29 19:58:53,715] <launcher> INFO system - Hostname: e7740cacab32
[2023-06-29 19:58:53,715] <launcher> INFO system - ubic.env: stage
[2023-06-29 19:58:54,837] <launcher> WARN AnnotationConfigWebApplicationContext - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [com.ubnt.net.SpringConfig]; nested exception is java.lang.IllegalStateException: Failed to introspect annotated methods on class com.ubnt.net.null
[2023-06-29 19:58:54,839] <launcher> ERROR ContextLoader - Context initialization failed
org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [com.ubnt.net.SpringConfig]; nested exception is java.lang.IllegalStateException: Failed to introspect annotated methods on class com.ubnt.net.null
at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:610)
at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:311)
at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:250)
at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:207)
at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:175)
at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:331)
at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:247)
at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:112)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:401)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:292)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:103)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4766)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5230)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at com.ubnt.net.OoOO.returnsuper(Unknown Source)
at com.ubnt.net.OoOO.Òo0000(Unknown Source)
at com.ubnt.service.D.StringObject(Unknown Source)
at com.ubnt.ace.Launcher.class(Unknown Source)
at com.ubnt.ace.Launcher.main(Unknown Source)
Caused by: java.lang.IllegalStateException: Failed to introspect annotated methods on class com.ubnt.net.null
at org.springframework.core.type.StandardAnnotationMetadata.getAnnotatedMethods(StandardAnnotationMetadata.java:162)
at org.springframework.context.annotation.ConfigurationClassParser.retrieveBeanMethodMetadata(ConfigurationClassParser.java:403)
at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:326)
at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:250)
at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:600)
... 21 common frames omitted
Caused by: java.lang.IllegalStateException: Failed to introspect Class [com.ubnt.net.null] from ClassLoader [jdk.internal.loader.ClassLoaders$AppClassLoader@277050dc]
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:485)
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:459)
at org.springframework.core.type.StandardAnnotationMetadata.getAnnotatedMethods(StandardAnnotationMetadata.java:151)
... 25 common frames omitted
Caused by: java.lang.NoClassDefFoundError: springfox/documentation/spring/web/plugins/Docket
at java.base/java.lang.Class.getDeclaredMethods0(Native Method)
at java.base/java.lang.Class.privateGetDeclaredMethods(Class.java:3166)
at java.base/java.lang.Class.getDeclaredMethods(Class.java:2309)
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:467)
... 27 common frames omitted
Caused by: java.lang.ClassNotFoundException: springfox.documentation.spring.web.plugins.Docket
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
... 31 common frames omitted
[2023-06-29 19:58:54,841] <launcher> ERROR [/] - Exception sending context initialized event to listener instance of class [org.springframework.web.context.ContextLoaderListener]
org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [com.ubnt.net.SpringConfig]; nested exception is java.lang.IllegalStateException: Failed to introspect annotated methods on class com.ubnt.net.null
at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:610)
at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:311)
at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:250)
at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:207)
at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:175)
at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:331)
at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:247)
at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:112)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:401)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:292)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:103)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4766)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5230)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at com.ubnt.net.OoOO.returnsuper(Unknown Source)
at com.ubnt.net.OoOO.Òo0000(Unknown Source)
at com.ubnt.service.D.StringObject(Unknown Source)
at com.ubnt.ace.Launcher.class(Unknown Source)
at com.ubnt.ace.Launcher.main(Unknown Source)
Caused by: java.lang.IllegalStateException: Failed to introspect annotated methods on class com.ubnt.net.null
at org.springframework.core.type.StandardAnnotationMetadata.getAnnotatedMethods(StandardAnnotationMetadata.java:162)
at org.springframework.context.annotation.ConfigurationClassParser.retrieveBeanMethodMetadata(ConfigurationClassParser.java:403)
at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:326)
at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:250)
at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:600)
... 21 common frames omitted
Caused by: java.lang.IllegalStateException: Failed to introspect Class [com.ubnt.net.null] from ClassLoader [jdk.internal.loader.ClassLoaders$AppClassLoader@277050dc]
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:485)
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:459)
at org.springframework.core.type.StandardAnnotationMetadata.getAnnotatedMethods(StandardAnnotationMetadata.java:151)
... 25 common frames omitted
Caused by: java.lang.NoClassDefFoundError: springfox/documentation/spring/web/plugins/Docket
at java.base/java.lang.Class.getDeclaredMethods0(Native Method)
at java.base/java.lang.Class.privateGetDeclaredMethods(Class.java:3166)
at java.base/java.lang.Class.getDeclaredMethods(Class.java:2309)
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:467)
... 27 common frames omitted
Caused by: java.lang.ClassNotFoundException: springfox.documentation.spring.web.plugins.Docket
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
... 31 common frames omitted
[2023-06-29 19:58:54,842] <launcher> ERROR StandardContext - One or more listeners failed to start. Full details will be found in the appropriate container log file
[2023-06-29 19:58:54,842] <launcher> ERROR StandardContext - Context [] startup failed due to previous errors
Exception in thread "launcher" java.lang.NullPointerException: Web context failed to initialize
at java.base/java.util.Objects.requireNonNull(Objects.java:246)
at com.ubnt.net.OoOO.ØÒ0000(Unknown Source)
at com.ubnt.net.OoOO.Òo0000(Unknown Source)
at com.ubnt.service.D.StringObject(Unknown Source)
at com.ubnt.ace.Launcher.class(Unknown Source)
at com.ubnt.ace.Launcher.main(Unknown Source)
I'm using mongodb v5.0.19, and v5.0.18 prior to that without issue.
One thing I see different between your setup and mine is:
unifi | [2023-07-18 01:11:47,449] <launcher> INFO system - ubic.env: prod
Are you running the Debian, Ubuntu, or Alpine version of the container?
I'm using mongodb v5.0.19, and v5.0.18 prior to that without issue.
One thing I see different between your setup and mine is:
unifi | [2023-07-18 01:11:47,449] <launcher> INFO system - ubic.env: prod
Are you running the Debian, Ubuntu, or Alpine version of the container?
I tried all three with what I could see, similar results. Finally, I tried a version without the separate mongo-db, and then it worked. Havent had time to go back since then :-/
This issue has had no activity for the last 90 days. Do you still see this issue with the latest release? Please add a reply within 14 days or this issue will be automatically closed. To keep a confirmed issue open we can also add a "bug confirmed" tag.
Disclaimer: This is an open community project with limited resources. Any skilled member of the community may jump in at any time to fix this issue. That can take a while depending on our busy lives so please be patient, and take advantage of other resources to help solve the issue.
Reporting bugs/issues
Been running with a separate mongo db (:5) and 7.3 without issues for a long time. Upgrading to 7.4 fails, and all attempts to change external mongodb to either 3.6, 4, 6, 7 fails, even with a fresh install (of any container)
On OpenSuse 15.4, Docker version 20.10.23-ce, build 6051f1429
Log from the start of unifi:
Since the example for using docker-compose still doesnt indicate that I need to restrict the mongdo db-version to a specific version, I'm still not clear on which version I am supposed to use, but :5 has been working fine for 7.3 and it feels strange that a newer version would need an OLDER version??