title: springboot get error when server starting in linux
body: <p>First, there are two <code>Linux</code> servers.
  I want to build a redundant <code>web server</code> on two servers.</p>
  
  <p>I installed jre1.8.0 on two servers equally.
  And I installed the same spring boot war file on two servers equally.</p>
  
  <p>By the way ....
  Server 1 normally goes up and works normally.
  Error on server # 2 ....</p>
  
  <p>I've copied war and tomcat on server # 1 to server # 2.
  I still get an error on server # 2.</p>
  
  <p>The duplication structure is almost the same as all the settings ...</p>
  
  <p>jre path I checked .. 1.8.0 I checked and ..... ha ...... what is the problem?</p>
  
  <p>I can not figure out why the error is only on server 2, because it is the same file with the same settings.</p>
  
  <p>This is the error log.</p>
  
  <hr>
  
  <p>:: Spring Boot ::  (v2.1.0.BUILD-SNAPSHOT)</p>
  
  <blockquote>
    <p>2018-09-17 16:31:35 [DEBUG] [StartupInfoLogger.java]logStarting(53) :
    Running with Spring Boot v2.1.0.BUILD-SNAPSHOT, Spring
    v5.1.0.BUILD-SNAPSHOT</p>
    
    <p>2018-09-17 16:31:35 [INFO ]
    [SpringApplication.java]logStartupProfileInfo(701) : The following
    profiles are active: dev</p>
    
    <p>2018-09-17 16:31:35 [ERROR]
    [LoggingFailureAnalysisReporter.java]report(42) :</p>
  </blockquote>
  
  <hr>
  
  <p>APPLICATION FAILED TO START</p>
  
  <hr>
  
  <p>Description:</p>
  
  <p>An attempt was made to call the method org.springframework.beans.factory.annotation.AnnotatedBeanDefinition.setRole(I)V but it does not exist. Its class, org.springframework.beans.factory.annotation.AnnotatedBeanDefinition, is available from the following locations:</p>
  
  <pre><code>jar:file:{path}/WEB-INF/lib/spring-beans-5.1.0.RC3.jar!/org/springframework/beans/factory/annotation/AnnotatedBeanDefinition.class
  
  jar:file:{path}/WEB-INF/lib/spring-beans-5.1.0.BUILD-SNAPSHOT.jar!/org/springframework/beans/factory/annotation/AnnotatedBeanDefinition.class
  </code></pre>
  
  <p>It was loaded from the following location:</p>
  
  <pre><code>file:{path}/WEB-INF/lib/spring-beans-5.1.0.RC3.jar
  </code></pre>
  
  <p>Action:</p>
  
  <p>Correct the classpath of your application so that it contains a single, compatible version of </p>
  
  <pre><code>org.springframework.beans.factory.annotation.AnnotatedBeanDefinition
  
  
  
  17-Sep-2018 16:31:35.890 ½É°¢ [localhost-startStop-1] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild:
  </code></pre>
  
  <p>start:</p>
  
  <pre><code> org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/url]]
  
      at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:162)
  
      at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:753)
  
      at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:729)
  
      at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717)
  
      at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:940)
  
      at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1816)
  
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
  
      at java.util.concurrent.FutureTask.run(FutureTask.java:266)
  
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
  
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
  
      at java.lang.Thread.run(Thread.java:748)
  </code></pre>
  
  <blockquote>
    <p>Caused by: java.lang.NoSuchMethodError:
    org.springframework.beans.factory.annotation.AnnotatedBeanDefinition.setRole(I)V</p>
    
    <p>at
    org.springframework.context.annotation.AnnotationConfigUtils.processCommonDefinitionAnnotations(AnnotationConfigUtils.java:259)
            at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForBeanMethod(ConfigurationClassBeanDefinitionReader.java:228)
            at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForConfigurationClass(ConfigurationClassBeanDefinitionReader.java:140)
            at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitions(ConfigurationClassBeanDefinitionReader.java:116)
            at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:327)
            at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:232)
            at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:275)
            at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:95)
            at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:693)
            at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:530)
            at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:140)
            at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:797)
            at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:421)
            at org.springframework.boot.SpringApplication.run(SpringApplication.java:340)
            at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.run(SpringBootServletInitializer.java:157)
            at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.createRootApplicationContext(SpringBootServletInitializer.java:137)
            at org.springframework.boot.web.servlet.support.SpringBootServletInitializer.onStartup(SpringBootServletInitializer.java:91)
            at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:171)
            at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5303)
            at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
            ... 10 more</p>
    
    <p>17-Sep-2018 16:31:35.892 ½É°¢ [localhost-startStop-1]
    org.apache.catalina.startup.HostConfig.deployWAR Error deploying web
    application archive {Path}.War  java.lang.IllegalStateException:
    ContainerBase.addChild: start: org.apache.catalina.LifecycleException:
    Failed to start component
    [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/url]]
            at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:757)
            at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:729)
            at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717)
            at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:940)
            at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1816)
            at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
            at java.util.concurrent.FutureTask.run(FutureTask.java:266)
            at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
            at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
            at java.lang.Thread.run(Thread.java:748)</p>
    
    <p>17-Sep-2018 16:31:35.893 Á¤º¸ [localhost-startStop-1]
    org.apache.catalina.startup.HostConfig.deployWAR Deployment of web
    application archive {path}.war has finished in 3,617 ms 17-Sep-2018
    16:31:35.894 Á¤º¸ [localhost-startStop-1]
    org.apache.catalina.startup.HostConfig.deployDirectory Deploying web
    application directory {path}/ROOT 17-Sep-2018 16:31:35.924 Á¤º¸
    [localhost-startStop-1]
    org.apache.catalina.startup.HostConfig.deployDirectory Deployment of
    web application directory {path}/ROOT has finished in 30 ms
    17-Sep-2018 16:31:35.926 Á¤º¸ [main]
    org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler
    ["http-nio-5555"] 17-Sep-2018 16:31:35.932 Á¤º¸ [main]
    org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler
    ["ajp-nio-4444"] 17-Sep-2018 16:31:35.934 Á¤º¸ [main]
    org.apache.catalina.startup.Catalina.start Server startup in 3701 ms</p>
  </blockquote>