Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-58687

Tomcat deployment fails when using deploy plugin

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Component/s: deploy-plugin
    • Labels:
      None
    • Environment:
      ubuntu 16.04
    • Similar Issues:

      Description

      getting below errors when using deploy to container plugin to tomcat 8

       
      ERROR: Build step failed with exception
      org.codehaus.cargo.container.ContainerException: Failed to redeploy [/var/lib/jenkins/workspace/divya_deploy/sample.war]
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:192)
      at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:77)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:147)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:117)
      at hudson.FilePath.act(FilePath.java:1075)
      at hudson.FilePath.act(FilePath.java:1058)
      at hudson.plugins.deploy.CargoContainerAdapter.redeploy(CargoContainerAdapter.java:114)
      at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeploy(PasswordProtectedAdapterCargo.java:93)
      at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:64)
      at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:744)
      at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
      at hudson.model.Build$BuildExecution.post2(Build.java:186)
      at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
      at hudson.model.Run.execute(Run.java:1841)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      at hudson.model.ResourceController.execute(ResourceController.java:97)
      at hudson.model.Executor.run(Executor.java:429)
      Caused by: java.io.FileNotFoundException:
      http://192.168.0.102:8080/manager/text/list
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1890)
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:571)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:876)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:889)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:173)
      ... 17 more
      java.io.FileNotFoundException:
      http://192.168.0.102:8080/manager/text/list
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1890)
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:571)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:876)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:889)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:173)
      at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:77)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:147)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:117)
      at hudson.FilePath.act(FilePath.java:1075)
      at hudson.FilePath.act(FilePath.java:1058)
      at hudson.plugins.deploy.CargoContainerAdapter.redeploy(CargoContainerAdapter.java:114)
      at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeploy(PasswordProtectedAdapterCargo.java:93)
      at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:64)
      at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:744)
      at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
      at hudson.model.Build$BuildExecution.post2(Build.java:186)
      at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
      at hudson.model.Run.execute(Run.java:1841)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      at hudson.model.ResourceController.execute(ResourceController.java:97)
      at hudson.model.Executor.run(Executor.java:429)
      Build step 'Deploy war/ear to a container' marked build as failure
      Finished: FAILURE

        Attachments

          Issue Links

            Activity

            Hide
            jansohn Robin Jansohn added a comment -

            The error message is quite clear. There is no Tomcat manager running at the specified location.

            Show
            jansohn Robin Jansohn added a comment - The error message is quite clear. There is no Tomcat manager running at the specified location.
            Hide
            msollanych_dwave Mike Sollanych added a comment -

            I can duplicate the problem with my Jenkins instance, running 2.176.2 with the Deploy To Container plugin 1.14; downgrading to 1.13 solves the issue for me. I am certain that my Tomcat manager is running and functional; no config for the working job had changed except for upgrading this plugin.

            Relevant logs with 1.14:

            [DeployPublisher][INFO] Attempting to deploy 1 war file(s)
            [DeployPublisher][INFO] Deploying /var/lib/jenkins/workspace/Processor Development (PD)/config-database/Testing Test and Deploy (from Master)/Lab/build/install/Lab.war to container Tomcat 7.x Remote with context lab
            ERROR: Build step failed with exception
            org.codehaus.cargo.container.ContainerException: Failed to redeploy [/var/lib/jenkins/workspace/Processor Development (PD)/config-database/Testing Test and Deploy (from Master)/Lab/build/install/Lab.war]
            {{ at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:188)}}
            {{ at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)}}
            {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)}}
            {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)}}
            {{ at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3050)}}
            {{ at hudson.remoting.UserRequest.perform(UserRequest.java:212)}}
            {{ at hudson.remoting.UserRequest.perform(UserRequest.java:54)}}
            {{ at hudson.remoting.Request$2.run(Request.java:369)}}
            {{ at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)}}
            {{ 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)}}
            {{ Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to pd-jenkins-ls1}}
            {{ at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1743)}}
            {{ at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:357)}}
            {{ at hudson.remoting.Channel.call(Channel.java:957)}}
            {{ at hudson.FilePath.act(FilePath.java:1070)}}
            {{ at hudson.FilePath.act(FilePath.java:1059)}}
            {{ at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)}}
            {{ at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)}}
            {{ at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)}}
            {{ at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)}}
            {{ at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)}}
            {{ at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)}}
            {{ at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)}}
            {{ at hudson.model.Build$BuildExecution.post2(Build.java:186)}}
            {{ at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)}}
            {{ at hudson.model.Run.execute(Run.java:1843)}}
            {{ at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)}}
            {{ at hudson.model.ResourceController.execute(ResourceController.java:97)}}
            {{ at hudson.model.Executor.run(Executor.java:429)}}
            Caused by: java.io.FileNotFoundException: http://REDACTED:8080/null/list
            {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1890)}}
            {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)}}
            {{ ... 12 more}}
            java.io.FileNotFoundException: http://REDACTED:8080/null/list
            {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1890)}}
            {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)}}
            {{ at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)}}
            {{ at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)}}
            {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)}}
            {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)}}
            {{ at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3050)}}
            {{ at hudson.remoting.UserRequest.perform(UserRequest.java:212)}}
            {{ at hudson.remoting.UserRequest.perform(UserRequest.java:54)}}
            {{ at hudson.remoting.Request$2.run(Request.java:369)}}
            {{ at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)}}
            {{ 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)}}
            Build step 'Deploy war/ear to a container' marked build as failure
            [Slack Notifications] found #203 as previous completed, non-aborted build
            Finished: FAILURE

            I have to figure the null/list bit has something to do with it. When I put "/manager/" at the end of the Tomcat deploy URL in the job configuration, I saw instead

            http://REDACTED:8080/manager//manager/text/list

            Something in the newer version of the plugin that constructs the URLs is broken, I suspect.

            Show
            msollanych_dwave Mike Sollanych added a comment - I can duplicate the problem with my Jenkins instance, running 2.176.2 with the Deploy To Container plugin 1.14; downgrading to 1.13 solves the issue for me. I am certain that my Tomcat manager is running and functional; no config for the working job had changed except for upgrading this plugin. Relevant logs with 1.14: [DeployPublisher] [INFO] Attempting to deploy 1 war file(s) [DeployPublisher] [INFO] Deploying /var/lib/jenkins/workspace/Processor Development (PD)/config-database/Testing Test and Deploy (from Master)/Lab/build/install/Lab.war to container Tomcat 7.x Remote with context lab ERROR: Build step failed with exception org.codehaus.cargo.container.ContainerException: Failed to redeploy [/var/lib/jenkins/workspace/Processor Development (PD)/config-database/Testing Test and Deploy (from Master)/Lab/build/install/Lab.war] {{ at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:188)}} {{ at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)}} {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)}} {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)}} {{ at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3050)}} {{ at hudson.remoting.UserRequest.perform(UserRequest.java:212)}} {{ at hudson.remoting.UserRequest.perform(UserRequest.java:54)}} {{ at hudson.remoting.Request$2.run(Request.java:369)}} {{ at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)}} {{ 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)}} {{ Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to pd-jenkins-ls1}} {{ at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1743)}} {{ at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:357)}} {{ at hudson.remoting.Channel.call(Channel.java:957)}} {{ at hudson.FilePath.act(FilePath.java:1070)}} {{ at hudson.FilePath.act(FilePath.java:1059)}} {{ at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)}} {{ at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)}} {{ at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)}} {{ at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)}} {{ at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)}} {{ at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)}} {{ at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)}} {{ at hudson.model.Build$BuildExecution.post2(Build.java:186)}} {{ at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)}} {{ at hudson.model.Run.execute(Run.java:1843)}} {{ at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)}} {{ at hudson.model.ResourceController.execute(ResourceController.java:97)}} {{ at hudson.model.Executor.run(Executor.java:429)}} Caused by: java.io.FileNotFoundException: http://REDACTED:8080/null/list {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1890)}} {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)}} {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)}} {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)}} {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)}} {{ at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)}} {{ ... 12 more}} java.io.FileNotFoundException: http://REDACTED:8080/null/list {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1890)}} {{ at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)}} {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)}} {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)}} {{ at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)}} {{ at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)}} {{ at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)}} {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)}} {{ at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)}} {{ at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3050)}} {{ at hudson.remoting.UserRequest.perform(UserRequest.java:212)}} {{ at hudson.remoting.UserRequest.perform(UserRequest.java:54)}} {{ at hudson.remoting.Request$2.run(Request.java:369)}} {{ at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)}} {{ 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)}} Build step 'Deploy war/ear to a container' marked build as failure [Slack Notifications] found #203 as previous completed, non-aborted build Finished: FAILURE I have to figure the null/list bit has something to do with it. When I put "/manager/" at the end of the Tomcat deploy URL in the job configuration, I saw instead http://REDACTED:8080/manager//manager/text/list Something in the newer version of the plugin that constructs the URLs is broken, I suspect.
            Hide
            jansohn Robin Jansohn added a comment -

            Mike Sollanych your problem is different (I'm guessing the same as JENKINS-58667). For the Tomcat URL please don't add a trailing slash (and don't add the /manager part), e.g. in your case http://REDACTED:8080. It should be enough to simply re-save the job configuration with 1.14 to get it working again.

            Show
            jansohn Robin Jansohn added a comment - Mike Sollanych your problem is different (I'm guessing the same as JENKINS-58667 ). For the Tomcat URL please don't add a trailing slash (and don't add the /manager part), e.g. in your case http://REDACTED:8080 . It should be enough to simply re-save the job configuration with 1.14 to get it working again.
            Hide
            msollanych_dwave Mike Sollanych added a comment -

            That worked fine, thank you.

             

            Show
            msollanych_dwave Mike Sollanych added a comment - That worked fine, thank you.  
            Hide
            divyap divya P added a comment -

            i re-installed Tomcat.

             

            Again getting below error even though my credentails are correct

             

            tomcat roles :

            <role rolename="manager-script"/>
            <role rolename="manager-jmx"/>
            <role rolename="manager-gui"/>
            <role rolename="admin-gui"/>
            <role rolename="admin"/>
            <role rolename="manager-status"/>
            <user username="admin" password="admin" roles="admin,manager-gui"/>

             

             

            =======================

            my tomcat is running on 8080

            in webbrowser i get If you're seeing this page via a web browser, it means you've setup Tomcat successfully. Congratulations!

             

            ===========
            Building in workspace /root/.jenkins/workspace/auto
            [auto] $ /bin/sh -xe /tmp/jenkins7274486585926992312.sh
            + date
            Fri Aug 16 16:26:31 IST 2019
            [DeployPublisher][INFO] Attempting to deploy 1 war file(s)
            [DeployPublisher][INFO] Deploying /root/.jenkins/workspace/auto/sample.war to container Tomcat 7.x Remote with context sample.war
            ERROR: Build step failed with exception
            org.codehaus.cargo.container.ContainerException: Failed to redeploy [/root/.jenkins/workspace/auto/sample.war]
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:184)
            at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
            at hudson.FilePath.act(FilePath.java:1076)
            at hudson.FilePath.act(FilePath.java:1059)
            at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
            at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
            at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
            at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)
            at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
            at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
            at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
            at hudson.model.Build$BuildExecution.post2(Build.java:186)
            at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
            at hudson.model.Run.execute(Run.java:1843)
            at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
            at hudson.model.ResourceController.execute(ResourceController.java:97)
            at hudson.model.Executor.run(Executor.java:429)
            Caused by: org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)
            ... 18 more
            Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL:
            http://localhost:8080/manager/text/list
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894)
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)
            ... 21 more
            org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)
            at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
            at hudson.FilePath.act(FilePath.java:1076)
            at hudson.FilePath.act(FilePath.java:1059)
            at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
            at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
            at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
            at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)
            at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
            at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
            at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
            at hudson.model.Build$BuildExecution.post2(Build.java:186)
            at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
            at hudson.model.Run.execute(Run.java:1843)
            at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
            at hudson.model.ResourceController.execute(ResourceController.java:97)
            at hudson.model.Executor.run(Executor.java:429)
            Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL:
            http://localhost:8080/manager/text/list
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894)
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)
            ... 21 more
            Build step 'Deploy war/ear to a container' marked build as failure
            Finished: FAILURE
             

            through jenkins i get

             

             

             

             

             

             

             

             

             

            Show
            divyap divya P added a comment - i re-installed Tomcat.   Again getting below error even though my credentails are correct   tomcat roles : <role rolename="manager-script"/> <role rolename="manager-jmx"/> <role rolename="manager-gui"/> <role rolename="admin-gui"/> <role rolename="admin"/> <role rolename="manager-status"/> <user username="admin" password="admin" roles="admin,manager-gui"/>     ======================= my tomcat is running on 8080 in webbrowser i get If you're seeing this page via a web browser, it means you've setup Tomcat successfully. Congratulations!   =========== Building in workspace /root/.jenkins/workspace/auto [auto] $ /bin/sh -xe /tmp/jenkins7274486585926992312.sh + date Fri Aug 16 16:26:31 IST 2019 [DeployPublisher] [INFO] Attempting to deploy 1 war file(s) [DeployPublisher] [INFO] Deploying /root/.jenkins/workspace/auto/sample.war to container Tomcat 7.x Remote with context sample.war ERROR: Build step failed with exception org.codehaus.cargo.container.ContainerException: Failed to redeploy [/root/.jenkins/workspace/auto/sample.war] at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:184) at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136) at hudson.FilePath.act(FilePath.java:1076) at hudson.FilePath.act(FilePath.java:1059) at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133) at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95) at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.model.Build$BuildExecution.post2(Build.java:186) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Caused by: org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895) at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169) ... 18 more Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL: http://localhost:8080/manager/text/list at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577) ... 21 more org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895) at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169) at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136) at hudson.FilePath.act(FilePath.java:1076) at hudson.FilePath.act(FilePath.java:1059) at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133) at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95) at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.model.Build$BuildExecution.post2(Build.java:186) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL: http://localhost:8080/manager/text/list at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577) ... 21 more Build step 'Deploy war/ear to a container' marked build as failure Finished: FAILURE   through jenkins i get                  
            Hide
            divyap divya P added a comment -

            now user credential is not there.

            but getting below

            ======

             

            Started by user unknown or anonymous
            Running as SYSTEM
            Building in workspace /root/.jenkins/workspace/auto
            [auto] $ /bin/sh -xe /tmp/jenkins693768182065739185.sh
            + date
            Fri Aug 16 16:32:35 IST 2019
            [DeployPublisher][INFO] Attempting to deploy 1 war file(s)
            [DeployPublisher][INFO] Deploying /root/.jenkins/workspace/auto/sample.war to container Tomcat 7.x Remote with context sample.war
            ERROR: Build step failed with exception
            org.codehaus.cargo.container.ContainerException: Failed to redeploy [/root/.jenkins/workspace/auto/sample.war]
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:188)
            at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
            at hudson.FilePath.act(FilePath.java:1076)
            at hudson.FilePath.act(FilePath.java:1059)
            at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
            at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
            at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
            at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)
            at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
            at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
            at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
            at hudson.model.Build$BuildExecution.post2(Build.java:186)
            at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
            at hudson.model.Run.execute(Run.java:1843)
            at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
            at hudson.model.ResourceController.execute(ResourceController.java:97)
            at hudson.model.Executor.run(Executor.java:429)
            Caused by: java.net.UnknownHostException: http
            at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184)
            at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
            at java.net.Socket.connect(Socket.java:589)
            at java.net.Socket.connect(Socket.java:538)
            at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
            at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
            at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
            at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
            at sun.net.www.http.HttpClient.New(HttpClient.java:339)
            at sun.net.www.http.HttpClient.New(HttpClient.java:357)
            at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1220)
            at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1156)
            at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1050)
            at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:984)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:567)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)
            ... 18 more
            java.net.UnknownHostException: http
            at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184)
            at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
            at java.net.Socket.connect(Socket.java:589)
            at java.net.Socket.connect(Socket.java:538)
            at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
            at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
            at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
            at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
            at sun.net.www.http.HttpClient.New(HttpClient.java:339)
            at sun.net.www.http.HttpClient.New(HttpClient.java:357)
            at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1220)
            at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1156)
            at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1050)
            at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:984)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:567)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)
            at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
            at hudson.FilePath.act(FilePath.java:1076)
            at hudson.FilePath.act(FilePath.java:1059)
            at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
            at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
            at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
            at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)
            at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
            at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
            at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
            at hudson.model.Build$BuildExecution.post2(Build.java:186)
            at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
            at hudson.model.Run.execute(Run.java:1843)
            at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
            at hudson.model.ResourceController.execute(ResourceController.java:97)
            at hudson.model.Executor.run(Executor.java:429)
            Build step 'Deploy war/ear to a container' marked build as failure
            Finished: FAILURE

             

            Show
            divyap divya P added a comment - now user credential is not there. but getting below ======   Started by user unknown or anonymous Running as SYSTEM Building in workspace /root/.jenkins/workspace/auto [auto] $ /bin/sh -xe /tmp/jenkins693768182065739185.sh + date Fri Aug 16 16:32:35 IST 2019 [DeployPublisher] [INFO] Attempting to deploy 1 war file(s) [DeployPublisher] [INFO] Deploying /root/.jenkins/workspace/auto/sample.war to container Tomcat 7.x Remote with context sample.war ERROR: Build step failed with exception org.codehaus.cargo.container.ContainerException: Failed to redeploy [/root/.jenkins/workspace/auto/sample.war] at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:188) at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136) at hudson.FilePath.act(FilePath.java:1076) at hudson.FilePath.act(FilePath.java:1059) at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133) at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95) at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.model.Build$BuildExecution.post2(Build.java:186) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Caused by: java.net.UnknownHostException: http at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:589) at java.net.Socket.connect(Socket.java:538) at sun.net.NetworkClient.doConnect(NetworkClient.java:180) at sun.net.www.http.HttpClient.openServer(HttpClient.java:463) at sun.net.www.http.HttpClient.openServer(HttpClient.java:558) at sun.net.www.http.HttpClient.<init>(HttpClient.java:242) at sun.net.www.http.HttpClient.New(HttpClient.java:339) at sun.net.www.http.HttpClient.New(HttpClient.java:357) at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1220) at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1156) at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1050) at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:984) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:567) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895) at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169) ... 18 more java.net.UnknownHostException: http at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:589) at java.net.Socket.connect(Socket.java:538) at sun.net.NetworkClient.doConnect(NetworkClient.java:180) at sun.net.www.http.HttpClient.openServer(HttpClient.java:463) at sun.net.www.http.HttpClient.openServer(HttpClient.java:558) at sun.net.www.http.HttpClient.<init>(HttpClient.java:242) at sun.net.www.http.HttpClient.New(HttpClient.java:339) at sun.net.www.http.HttpClient.New(HttpClient.java:357) at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1220) at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1156) at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1050) at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:984) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:567) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895) at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169) at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136) at hudson.FilePath.act(FilePath.java:1076) at hudson.FilePath.act(FilePath.java:1059) at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133) at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95) at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.model.Build$BuildExecution.post2(Build.java:186) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Build step 'Deploy war/ear to a container' marked build as failure Finished: FAILURE  
            Hide
            divyap divya P added a comment -

            again i am getting same credentials error
            Started by user unknown or anonymous
            Running as SYSTEM
            Building in workspace /root/.jenkins/workspace/auto
            [auto] $ /bin/sh -xe /tmp/jenkins2468471969922371506.sh
            + date
            Fri Aug 16 16:43:20 IST 2019
            [DeployPublisher][INFO] Attempting to deploy 1 war file(s)
            [DeployPublisher][INFO] Deploying /root/.jenkins/workspace/auto/sample.war to container Tomcat 8.x Remote with context sample.war
            ERROR: Build step failed with exception
            org.codehaus.cargo.container.ContainerException: Failed to redeploy [/root/.jenkins/workspace/auto/sample.war]
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:184)
            at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
            at hudson.FilePath.act(FilePath.java:1076)
            at hudson.FilePath.act(FilePath.java:1059)
            at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
            at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
            at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
            at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)
            at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
            at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
            at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
            at hudson.model.Build$BuildExecution.post2(Build.java:186)
            at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
            at hudson.model.Run.execute(Run.java:1843)
            at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
            at hudson.model.ResourceController.execute(ResourceController.java:97)
            at hudson.model.Executor.run(Executor.java:429)
            Caused by: org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)
            ... 18 more
            Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL:
            http://192.168.0.102:8080/manager/text/list
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894)
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)
            ... 21 more
            org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895)
            at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169)
            at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167)
            at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136)
            at hudson.FilePath.act(FilePath.java:1076)
            at hudson.FilePath.act(FilePath.java:1059)
            at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133)
            at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95)
            at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113)
            at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79)
            at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
            at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
            at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
            at hudson.model.Build$BuildExecution.post2(Build.java:186)
            at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
            at hudson.model.Run.execute(Run.java:1843)
            at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
            at hudson.model.ResourceController.execute(ResourceController.java:97)
            at hudson.model.Executor.run(Executor.java:429)
            Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL:
            http://192.168.0.102:8080/manager/text/list
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894)
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
            at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577)
            ... 21 more
            Build step 'Deploy war/ear to a container' marked build as failure
            Finished: FAILURE
             

            Show
            divyap divya P added a comment - again i am getting same credentials error Started by user unknown or anonymous Running as SYSTEM Building in workspace /root/.jenkins/workspace/auto [auto] $ /bin/sh -xe /tmp/jenkins2468471969922371506.sh + date Fri Aug 16 16:43:20 IST 2019 [DeployPublisher] [INFO] Attempting to deploy 1 war file(s) [DeployPublisher] [INFO] Deploying /root/.jenkins/workspace/auto/sample.war to container Tomcat 8.x Remote with context sample.war ERROR: Build step failed with exception org.codehaus.cargo.container.ContainerException: Failed to redeploy [/root/.jenkins/workspace/auto/sample.war] at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:184) at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136) at hudson.FilePath.act(FilePath.java:1076) at hudson.FilePath.act(FilePath.java:1059) at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133) at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95) at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.model.Build$BuildExecution.post2(Build.java:186) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Caused by: org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895) at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169) ... 18 more Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL: http://192.168.0.102:8080/manager/text/list at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577) ... 21 more org.codehaus.cargo.container.tomcat.internal.TomcatManagerException: The username and password you provided are not correct (error 401) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:704) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.list(TomcatManager.java:882) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.getStatus(TomcatManager.java:895) at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:169) at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:81) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:167) at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:136) at hudson.FilePath.act(FilePath.java:1076) at hudson.FilePath.act(FilePath.java:1059) at hudson.plugins.deploy.CargoContainerAdapter.redeployFile(CargoContainerAdapter.java:133) at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeployFile(PasswordProtectedAdapterCargo.java:95) at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:113) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.model.Build$BuildExecution.post2(Build.java:186) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL: http://192.168.0.102:8080/manager/text/list at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492) at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:577) ... 21 more Build step 'Deploy war/ear to a container' marked build as failure Finished: FAILURE  

              People

              • Assignee:
                Unassigned
                Reporter:
                divyap divya P
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated: