关闭

启动nacos出现错误Unable to start web server; nested exception is org.springframework.boot.web

别叨叨 1年前 ⋅ 401 阅读

启动nacos报错

org. springframework.context.ApplicationContextException:Unable to start web server; nested exception is org.springframework.boot. web.server.WebServerException: Unable to start embedded Tom
cat
at org.springframework.boot.web. servlet.context.ServletWebServerApplicationContext.onRefresh(ServletWebServerApplicationContext. java:156) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:544)
at org.springframework.boot.web. servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext. java:141) at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:744)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:391) at orgspringframework.boot.SpringApplication.run(SpringApplication.java:312) at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215) at orgspringframeworkboot.SpringApplication.run(SpringApplication.java:1204) at com.alibaba.nacos.Nacos.main(Nacos.java:35)
at sun.reflect.NativeMethodAccessorImpl.invokeO(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke Method.java:498)
at org.springframework.boot.loader.MainMethodRunner. run (MainMethodRunner. java:49) at org.springframework.boot.loader.Launcher. launch (Launcher. java:108) at org.springframework.boot.loader.Launcher. launch (Launcher. java:58)
at org springframework.boot.loader.PropertiesLauncher.main (PropertiesLauncher. java:467)
Caused by:org.springframework.boot.web.server.WebServerException: Unable to start embedded Tomcat
at org.springframework.boot.web.embedded.tomcat.TomcatWebServer.initialize(TomcatWebServer. java:124) at org.springframework.boot.web.embedded.tomcat.TomcatWebServer.<init>(TomcatWebServer. java:86)
at org.springframework.boot.web. embedded. tomcat.TomcatServletWebServerFactory.getTomcatWebServer(TomcatServletWebServerFactory. java:416) at org.springframework.boot.web. embedded.tomcat.TomcatServletWebServerFactory.getWebServer(TomcatServletWebServerFactory. java:180)
at org.springframework.boot. web. servlet. context.ServletWebServerApplicationContext.createWebServer(ServletWebServerApplicationContext. java:180) at org.springframework.boot.web. servlet. context.ServletWebServerApplicationContext. onRefresh(ServletWebServerApplicationContext. java:153)
16 common frames omitted
Caused by: org. springframework.beans.factory.BeanCreationException: Error creating bean with name"distrofilterRegistration’defined in class path resource lcom/alibaba/nacos/naming/web/Nam ingConfig.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate lorg. springframework boot. web.servlet.FilterReeistrationBeanl: Factorv method’distrofilterReaistration’threw exception: nested exception is ore.sorineframework.beans. factorv.UnsatisfiedDependencvException: Error crea ting bean with name'distroFilter’: Unsatisfied dependency expressed through field'distroMapper'':nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Erro ie creatine bean with name ’distrollapper’defined in URLTiar:file:/D:/nacos/tarset/nacos-server.far!/B00T-INP/1ib/nacos-namine-2.0.3.ar!/com/alibaba/nacos/namine/core/Distrollapoer.class1: nsatisfied dependencv expressed throuch constructor parameter 0: nested exception is oresprineframework.beans.factorv.BeanCreationExcetion: Error creatine bean with name"serveremberan aper defined in urL Tiar:file:/D:/nacos/target/nacos-server.jar!/B00T-INF/1ib/nacos-core-20.3.jar!/com/alibaba/nacos/core/cluster/ServerMemberlanager.class]: Bean instantiation via constr uctor failed: nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [comalibaba.nacos.core.cluster.ServerMemberanager]: Constructor threw excepti on: nested exception is ErrCode:500,ErrMsg:jmenv.tbsite.net
at orz.springframework.beans.factorv.support.ConstructorResolver.instantiate(ConstructorResolver. iava:627)
at org.springframework. beans.factory. support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver. java:456)
at org.springframework. beans.factory. support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1318) at org.springframework. beans. factory. support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1158) at ore.sorineframework. beans.factorv.support.AbstractAutowireCanableBeanFactorv. doCreateBean(AbstractAutowireCanableBeanFactorv. iava:554) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory. java:514) at org.springframework.beans.factory.support.AbstractBeanFactory. lambda$doGetBean$0(AbstractBeanFactory. java:321)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean (AbstractBeanFactory. java:319) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:204)
at org.springframework.boot.web.servlet.ServletContextInitializerBeans.getOrderedBeansOfType(ServletContextInitializerBeans. java:211)
at org.springframework.boot.web.servlet.ServletContextInitializerBeans.getOrderedBeansOfType(ServletContextInitializerBeans. java:202) at org.springframework.boot.web.servlet.ServletContextInitializerBeans.addServletContextInitializerBeans(ServletContextInitializerBeans. java:96) https/iblog.csdn.net/qq_40711705

解决办法:将nacos\bin\startup.sh中的set MODE="cluster" 改为"standalone"


全部评论: 0

    我有话说: