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

HTML Publisher failure: Failed to extract directory from slave

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • htmlpublisher-plugin
    • Slave:
      - HP ProLiant DL380 G5
      - uname -r: 2.6.32-5-amd64
      - java -version: java version "1.6.0_18", OpenJDK Runtime Environment (IcedTea6 1.8.13) (6b18-1.8.13-0+squeeze2), OpenJDK 64-Bit Server VM (build 14.0-b16, mixed mode)

      Hi,

      in my jenkins-setup i am using a master/slave system. When a Job is executed, everything works fine until htmlpublisher is supposed to archive one HTML report. Usually the execution hangs, sometimes an exception is reported[1]

      As you can see, htmlpublisher tries to extract /home/jenkins-slave9/.../code-browser from slave, this fails.

      Problem occurred in Jenkins v. 1.456, I tried some versions in between, also the current v. 1.483 is affected.

      [1]

      [htmlpublisher] Archiving HTML reports...
      [htmlpublisher] Archiving at BUILD level /home/jenkins-slave9/workspace/wkw_cssjs/unitTesting/build/code-browser to /var/wkw/jenkins/jobs/wkw_cssjs/builds/2012-09-25_10-30-44/htmlreports/Code_Browser
      FATAL: HTML Publisher failure
      hudson.util.IOException2: hudson.util.IOException2: Failed to extract /home/jenkins-slave9/workspace/wkw_cssjs/unitTesting/build/code-browser/**/*
      	at hudson.FilePath.readFromTar(FilePath.java:1936)
      	at hudson.FilePath.copyRecursiveTo(FilePath.java:1848)
      	at hudson.FilePath.copyRecursiveTo(FilePath.java:1756)
      	at htmlpublisher.HtmlPublisher.perform(HtmlPublisher.java:212)
      	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:717)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:692)
      	at hudson.model.Build$BuildExecution.post2(Build.java:183)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:639)
      	at hudson.model.Run.execute(Run.java:1527)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
      	at hudson.model.ResourceController.execute(ResourceController.java:88)
      	at hudson.model.Executor.run(Executor.java:236)
      Caused by: java.io.IOException
      	at hudson.remoting.FastPipedInputStream.read(FastPipedInputStream.java:175)
      	at hudson.util.HeadBufferingStream.read(HeadBufferingStream.java:61)
      	at java.util.zip.InflaterInputStream.fill(InflaterInputStream.java:221)
      	at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:141)
      	at java.util.zip.GZIPInputStream.read(GZIPInputStream.java:92)
      	at org.apache.tools.tar.TarBuffer.readBlock(TarBuffer.java:257)
      	at org.apache.tools.tar.TarBuffer.readRecord(TarBuffer.java:223)
      	at hudson.org.apache.tools.tar.TarInputStream.read(TarInputStream.java:345)
      	at java.io.FilterInputStream.read(FilterInputStream.java:90)
      	at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:1025)
      	at org.apache.commons.io.IOUtils.copy(IOUtils.java:999)
      	at hudson.util.IOUtils.copy(IOUtils.java:37)
      	at hudson.FilePath.readFromTar(FilePath.java:1926)
      	... 12 more
      
      	at hudson.FilePath.copyRecursiveTo(FilePath.java:1855)
      	at hudson.FilePath.copyRecursiveTo(FilePath.java:1756)
      	at htmlpublisher.HtmlPublisher.perform(HtmlPublisher.java:212)
      	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:717)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:692)
      	at hudson.model.Build$BuildExecution.post2(Build.java:183)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:639)
      	at hudson.model.Run.execute(Run.java:1527)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
      	at hudson.model.ResourceController.execute(ResourceController.java:88)
      	at hudson.model.Executor.run(Executor.java:236)
      Caused by: java.util.concurrent.ExecutionException: hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel
      	at hudson.remoting.Request$1.get(Request.java:278)
      	at hudson.remoting.Request$1.get(Request.java:210)
      	at hudson.remoting.FutureAdapter.get(FutureAdapter.java:59)
      	at hudson.FilePath.copyRecursiveTo(FilePath.java:1851)
      	... 11 more
      Caused by: hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel
      	at hudson.remoting.Request.abort(Request.java:299)
      	at hudson.remoting.Channel.terminate(Channel.java:724)
      	at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:69)
      Caused by: java.io.IOException: Unexpected termination of the channel
      	at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:50)
      Caused by: java.io.EOFException
      	at java.io.ObjectInputStream$BlockDataInputStream.peekByte(ObjectInputStream.java:2553)
      	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1296)
      	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:350)
      	at hudson.remoting.Command.readFrom(Command.java:90)
      	at hudson.remoting.ClassicCommandTransport.read(ClassicCommandTransport.java:59)
      	at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:48)
      

          [JENKINS-15301] HTML Publisher failure: Failed to extract directory from slave

          Jesse Glick added a comment -

          Not clearly related to JENKINS-13614.

          Jesse Glick added a comment - Not clearly related to JENKINS-13614 .

          Problem still exists in Jenkins 1.492

          Markus Schulte added a comment - Problem still exists in Jenkins 1.492

          John Armenia added a comment -

          Problem still exists in 1.544

          John Armenia added a comment - Problem still exists in 1.544

          I have this problem on version 1.532.3. Its happening on remote suse slaves.. Same behaviour, it gets to last step; htmlpublisher hangs; when i kill job it throws the above exception. Odd thing is its only happening to about half the suse boxes.. the others are fine and they have the same setup.

          Anyone know when this will be fixed?

          Wesley Archbell added a comment - I have this problem on version 1.532.3. Its happening on remote suse slaves.. Same behaviour, it gets to last step; htmlpublisher hangs; when i kill job it throws the above exception. Odd thing is its only happening to about half the suse boxes.. the others are fine and they have the same setup. Anyone know when this will be fixed?

          mcrooney added a comment -

          Unfortunately, while I wrote this plugin, I'm not familiar with remote slaves or what is causing this. If anyone is able to take a look it at and submit a pull request at https://github.com/jenkinsci/htmlpublisher-plugin, it would be greatly appreciated!

          mcrooney added a comment - Unfortunately, while I wrote this plugin, I'm not familiar with remote slaves or what is causing this. If anyone is able to take a look it at and submit a pull request at https://github.com/jenkinsci/htmlpublisher-plugin , it would be greatly appreciated!

          Hi - this issue has been around and not touched for a year or more. In an effort to try and focus on issues which are still present, I am resolving these issues for now.

          If you feel that the issue is still present, please feel free to re-open / comment. I'll be closing off any issues that haven't had any re-opening or comments by the end of the month.

          Thanks for reporting these issues - hopefully you are still using HTML Publisher and its working for you but, if not, let me know so that I can focus on issues that are causing you problems today

          Richard Bywater added a comment - Hi - this issue has been around and not touched for a year or more. In an effort to try and focus on issues which are still present, I am resolving these issues for now. If you feel that the issue is still present, please feel free to re-open / comment. I'll be closing off any issues that haven't had any re-opening or comments by the end of the month. Thanks for reporting these issues - hopefully you are still using HTML Publisher and its working for you but, if not, let me know so that I can focus on issues that are causing you problems today

          Anh Phan added a comment - - edited

          Right now, I am facing this problem:

          05:32:46 [htmlpublisher] Archiving HTML reports...
          05:32:46 [htmlpublisher] Archiving at PROJECT level /home/vncuser/JENKINS/workspace/Abcdefgh-Project/Abcdefgh-all-master-MACOS-Safari-Auto-merge-triggering/target/site/serenity to /var/lib/jenkins/jobs/Abcdefgh-Project/jobs/Abcdefgh-all-master-MACOS-Safari-Auto-merge-triggering/htmlreports/MacOS-Safari_20Report
          05:33:34 FATAL: HTML Publisher failure
          05:33:34 java.io.IOException: Failed to extract /home/vncuser/JENKINS/workspace/Abcdefgh-Project/Abcdefgh-all-master-MACOS-Safari-Auto-merge-triggering/target/site/serenity/**/*
          05:33:34 	at hudson.FilePath.readFromTar(FilePath.java:2608)
          05:33:34 	at hudson.FilePath.copyRecursiveTo(FilePath.java:2386)
          05:33:34 	at hudson.FilePath.copyRecursiveTo(FilePath.java:2350)
          05:33:34 	at hudson.FilePath.copyRecursiveTo(FilePath.java:2338)
          05:33:34 	at hudson.FilePath.copyRecursiveTo(FilePath.java:2321)
          05:33:34 	at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242)
          05:33:34 	at htmlpublisher.HtmlPublisher.perform(HtmlPublisher.java:186)
          05:33:34 	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
          05:33:34 	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
          05:33:34 	at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
          05:33:34 	at hudson.model.Build$BuildExecution.post2(Build.java:186)
          05:33:34 	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
          05:33:34 	at hudson.model.Run.execute(Run.java:1881)
          05:33:34 	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
          05:33:34 	at hudson.model.ResourceController.execute(ResourceController.java:97)
          05:33:34 	at hudson.model.Executor.run(Executor.java:428)
          05:33:34 	Suppressed: java.util.concurrent.ExecutionException: java.io.IOException: This archive contains unclosed entries.
          05:33:34 		at hudson.remoting.Channel$2.adapt(Channel.java:1035)
          05:33:34 		at hudson.remoting.Channel$2.adapt(Channel.java:1029)
          05:33:34 		at hudson.remoting.FutureAdapter.get(FutureAdapter.java:59)
          05:33:34 		at hudson.FilePath.copyRecursiveTo(FilePath.java:2389)
          05:33:34 		... 14 more
          05:33:34 	Caused by: java.io.IOException: This archive contains unclosed entries.
          05:33:34 		at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.finish(TarArchiveOutputStream.java:289)
          05:33:34 		at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.close(TarArchiveOutputStream.java:307)
          05:33:34 		at hudson.util.io.TarArchiver.close(TarArchiver.java:126)
          05:33:34 		at hudson.FilePath.writeToTar(FilePath.java:2568)
          05:33:34 		at hudson.FilePath.access$4000(FilePath.java:211)
          05:33:34 		at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2531)
          05:33:34 		at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2518)
          05:33:34 		at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3069)
          05:33:34 		at hudson.remoting.UserRequest.perform(UserRequest.java:211)
          05:33:34 		at hudson.remoting.UserRequest.perform(UserRequest.java:54)
          05:33:34 		at hudson.remoting.Request$2.run(Request.java:369)
          05:33:34 		at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
          05:33:34 		at java.util.concurrent.FutureTask.run(FutureTask.java:266)
          05:33:34 		at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
          05:33:34 		at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
          05:33:34 		at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:117)
          05:33:34 		at java.lang.Thread.run(Thread.java:748)
          05:33:34 		Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from 11.111.111.111/11.111.111.111:11111
          05:33:34 			at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)
          05:33:34 			at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356)
          05:33:34 			at hudson.remoting.Channel$2.adapt(Channel.java:1033)
          05:33:34 			at hudson.remoting.Channel$2.adapt(Channel.java:1029)
          05:33:34 			at hudson.remoting.FutureAdapter.get(FutureAdapter.java:59)
          05:33:34 			at hudson.FilePath.copyRecursiveTo(FilePath.java:2389)
          05:33:34 			at hudson.FilePath.copyRecursiveTo(FilePath.java:2350)
          05:33:34 			at hudson.FilePath.copyRecursiveTo(FilePath.java:2338)
          05:33:34 			at hudson.FilePath.copyRecursiveTo(FilePath.java:2321)
          05:33:34 			at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242)
          05:33:34 			at htmlpublisher.HtmlPublisher.perform(HtmlPublisher.java:186)
          05:33:34 			at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
          05:33:34 			at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
          05:33:34 			at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
          05:33:34 			at hudson.model.Build$BuildExecution.post2(Build.java:186)
          05:33:34 			at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
          05:33:34 			at hudson.model.Run.execute(Run.java:1881)
          05:33:34 			at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
          05:33:34 			at hudson.model.ResourceController.execute(ResourceController.java:97)
          05:33:34 			at hudson.model.Executor.run(Executor.java:428)
          05:33:34 Caused by: java.io.IOException: Truncated TAR archive
          05:33:34 	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.read(TarArchiveInputStream.java:643)
          05:33:34 	at java.io.InputStream.read(InputStream.java:101)
          05:33:34 	at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:2314)
          05:33:34 	at org.apache.commons.io.IOUtils.copy(IOUtils.java:2270)
          05:33:34 	at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:2291)
          05:33:34 	at org.apache.commons.io.IOUtils.copy(IOUtils.java:2246)
          05:33:34 	at hudson.util.IOUtils.copy(IOUtils.java:43)
          05:33:34 	at hudson.FilePath.readFromTar(FilePath.java:2598)
          05:33:34 	... 15 more
          05:33:34 Build step 'Publish HTML reports' changed build result to FAILURE
          05:33:34 Finished: FAILURE

          My slave node information:

          • Mac mini 2012 late
          • MacOS v10.15
          • Core i7, 8Gb RAM
          • JDK8

          However, in this slave node, I executed another Job then it's OK
           
           
           

          Anh Phan added a comment - - edited Right now, I am facing this problem: 05:32:46 [htmlpublisher] Archiving HTML reports... 05:32:46 [htmlpublisher] Archiving at PROJECT level /home/vncuser/JENKINS/workspace/Abcdefgh-Project/Abcdefgh-all-master-MACOS-Safari-Auto-merge-triggering/target/site/serenity to / var /lib/jenkins/jobs/Abcdefgh-Project/jobs/Abcdefgh-all-master-MACOS-Safari-Auto-merge-triggering/htmlreports/MacOS-Safari_20Report 05:33:34 FATAL: HTML Publisher failure 05:33:34 java.io.IOException: Failed to extract /home/vncuser/JENKINS/workspace/Abcdefgh-Project/Abcdefgh-all-master-MACOS-Safari-Auto-merge-triggering/target/site/serenity /**/ * 05:33:34 at hudson.FilePath.readFromTar(FilePath.java:2608) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2386) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2350) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2338) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2321) 05:33:34 at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242) 05:33:34 at htmlpublisher.HtmlPublisher.perform(HtmlPublisher.java:186) 05:33:34 at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) 05:33:34 at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) 05:33:34 at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) 05:33:34 at hudson.model.Build$BuildExecution.post2(Build.java:186) 05:33:34 at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) 05:33:34 at hudson.model.Run.execute(Run.java:1881) 05:33:34 at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) 05:33:34 at hudson.model.ResourceController.execute(ResourceController.java:97) 05:33:34 at hudson.model.Executor.run(Executor.java:428) 05:33:34 Suppressed: java.util.concurrent.ExecutionException: java.io.IOException: This archive contains unclosed entries. 05:33:34 at hudson.remoting.Channel$2.adapt(Channel.java:1035) 05:33:34 at hudson.remoting.Channel$2.adapt(Channel.java:1029) 05:33:34 at hudson.remoting.FutureAdapter.get(FutureAdapter.java:59) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2389) 05:33:34 ... 14 more 05:33:34 Caused by: java.io.IOException: This archive contains unclosed entries. 05:33:34 at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.finish(TarArchiveOutputStream.java:289) 05:33:34 at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.close(TarArchiveOutputStream.java:307) 05:33:34 at hudson.util.io.TarArchiver.close(TarArchiver.java:126) 05:33:34 at hudson.FilePath.writeToTar(FilePath.java:2568) 05:33:34 at hudson.FilePath.access$4000(FilePath.java:211) 05:33:34 at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2531) 05:33:34 at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2518) 05:33:34 at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3069) 05:33:34 at hudson.remoting.UserRequest.perform(UserRequest.java:211) 05:33:34 at hudson.remoting.UserRequest.perform(UserRequest.java:54) 05:33:34 at hudson.remoting.Request$2.run(Request.java:369) 05:33:34 at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) 05:33:34 at java.util.concurrent.FutureTask.run(FutureTask.java:266) 05:33:34 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) 05:33:34 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) 05:33:34 at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:117) 05:33:34 at java.lang. Thread .run( Thread .java:748) 05:33:34 Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from 11.111.111.111/11.111.111.111:11111 05:33:34 at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788) 05:33:34 at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356) 05:33:34 at hudson.remoting.Channel$2.adapt(Channel.java:1033) 05:33:34 at hudson.remoting.Channel$2.adapt(Channel.java:1029) 05:33:34 at hudson.remoting.FutureAdapter.get(FutureAdapter.java:59) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2389) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2350) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2338) 05:33:34 at hudson.FilePath.copyRecursiveTo(FilePath.java:2321) 05:33:34 at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242) 05:33:34 at htmlpublisher.HtmlPublisher.perform(HtmlPublisher.java:186) 05:33:34 at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) 05:33:34 at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) 05:33:34 at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) 05:33:34 at hudson.model.Build$BuildExecution.post2(Build.java:186) 05:33:34 at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) 05:33:34 at hudson.model.Run.execute(Run.java:1881) 05:33:34 at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) 05:33:34 at hudson.model.ResourceController.execute(ResourceController.java:97) 05:33:34 at hudson.model.Executor.run(Executor.java:428) 05:33:34 Caused by: java.io.IOException: Truncated TAR archive 05:33:34 at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.read(TarArchiveInputStream.java:643) 05:33:34 at java.io.InputStream.read(InputStream.java:101) 05:33:34 at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:2314) 05:33:34 at org.apache.commons.io.IOUtils.copy(IOUtils.java:2270) 05:33:34 at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:2291) 05:33:34 at org.apache.commons.io.IOUtils.copy(IOUtils.java:2246) 05:33:34 at hudson.util.IOUtils.copy(IOUtils.java:43) 05:33:34 at hudson.FilePath.readFromTar(FilePath.java:2598) 05:33:34 ... 15 more 05:33:34 Build step 'Publish HTML reports' changed build result to FAILURE 05:33:34 Finished: FAILURE My slave node information: Mac mini 2012 late MacOS v10.15 Core i7, 8Gb RAM JDK8 However, in this slave node, I executed another Job then it's OK      

          Anh Phan added a comment -

          I am still facing this problem then I added new log in 2020-08-21

          Anh Phan added a comment - I am still facing this problem then I added new log in 2020-08-21

          Rémy Guillo du Bodan added a comment - - edited

           Same problem with Jenkins LTS 2.303.2 and HTMLPublisher v1.26 running * with a *Windows10 agent.

          Downgrade HTMLPublisher to v1.25 solved my problem 

          Error log :

          [htmlpublisher] Archiving HTML reports...
          [htmlpublisher] Archiving at PROJECT level C:\jenkins\workspace\de-matlab-du-tuv-en-matlab-coder to /var/jenkins_home/jobs/Pilotage_TUV/branches/CSI-322-p.cdvqom5vp0t2.lab-coder/htmlreports/Code_20Documentation
          FATAL: HTML Publisher failure
          java.io.IOException: Failed to extract C:\jenkins\workspace\de-matlab-du-tuv-en-matlab-coder/**/*
          	at hudson.FilePath.readFromTar(FilePath.java:2866)
          	at hudson.FilePath.copyRecursiveTo(FilePath.java:2644)
          	at hudson.FilePath.copyRecursiveTo(FilePath.java:2608)
          	at hudson.FilePath.copyRecursiveTo(FilePath.java:2596)
          	at hudson.FilePath.copyRecursiveTo(FilePath.java:2579)
          	at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242)
          	at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:70)
          	at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:45)
          	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
          	at hudson.security.ACL.impersonate2(ACL.java:449)
          	at hudson.security.ACL.impersonate(ACL.java:461)
          	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
          	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
          	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
          	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
          	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
          	at java.base/java.lang.Thread.run(Thread.java:829)
          	Suppressed: java.util.concurrent.ExecutionException: java.io.IOException: This archive contains unclosed entries.
          		at hudson.remoting.Channel$2.adapt(Channel.java:1037)
          		at hudson.remoting.Channel$2.adapt(Channel.java:1031)
          		at hudson.remoting.FutureAdapter.get(FutureAdapter.java:65)
          		at hudson.FilePath.copyRecursiveTo(FilePath.java:2647)
          		... 15 more
          	Caused by: java.io.IOException: This archive contains unclosed entries.
          		at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.finish(TarArchiveOutputStream.java:291)
          		at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.close(TarArchiveOutputStream.java:309)
          		at hudson.util.io.TarArchiver.close(TarArchiver.java:128)
          		at hudson.FilePath.writeToTar(FilePath.java:2826)
          		at hudson.FilePath.access$4300(FilePath.java:216)
          		at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2789)
          		at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2776)
          		at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3331)
          		at hudson.remoting.UserRequest.perform(UserRequest.java:211)
          		at hudson.remoting.UserRequest.perform(UserRequest.java:54)
          		at hudson.remoting.Request$2.run(Request.java:376)
          		at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:78)
          		at java.util.concurrent.FutureTask.run(Unknown Source)
          		at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
          		at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
          		at java.lang.Thread.run(Unknown Source)
          		Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to Windows 10 x64
          			at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1795)
          			at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356)
          			at hudson.remoting.Channel$2.adapt(Channel.java:1035)
          			at hudson.remoting.Channel$2.adapt(Channel.java:1031)
          			at hudson.remoting.FutureAdapter.get(FutureAdapter.java:65)
          			at hudson.FilePath.copyRecursiveTo(FilePath.java:2647)
          			at hudson.FilePath.copyRecursiveTo(FilePath.java:2608)
          			at hudson.FilePath.copyRecursiveTo(FilePath.java:2596)
          			at hudson.FilePath.copyRecursiveTo(FilePath.java:2579)
          			at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242)
          			at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:70)
          			at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:45)
          			at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
          			at hudson.security.ACL.impersonate2(ACL.java:449)
          			at hudson.security.ACL.impersonate(ACL.java:461)
          			at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
          			at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
          			at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
          			at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
          			at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
          			at java.base/java.lang.Thread.run(Thread.java:829)
          Caused by: java.nio.charset.MalformedInputException: Input length = 1
          	at java.base/java.nio.charset.CoderResult.throwException(CoderResult.java:274)
          	at java.base/java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:813)
          	at org.apache.commons.compress.archivers.zip.NioZipEncoding.decode(NioZipEncoding.java:136)
          	at org.apache.commons.compress.archivers.tar.TarUtils.parseName(TarUtils.java:311)
          	at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeaderUnwrapped(TarArchiveEntry.java:1607)
          	at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:1595)
          	at org.apache.commons.compress.archivers.tar.TarArchiveEntry.<init>(TarArchiveEntry.java:556)
          	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:379)
          	at hudson.FilePath.readFromTar(FilePath.java:2840)
          	... 16 more
          

           

          Rémy Guillo du Bodan added a comment - - edited  Same problem with Jenkins LTS 2.303.2 and HTMLPublisher v1.26 running *  with a *Windows10 agent . Downgrade HTMLPublisher to v1.25 solved my problem  Error log : [htmlpublisher] Archiving HTML reports... [htmlpublisher] Archiving at PROJECT level C:\jenkins\workspace\de-matlab-du-tuv-en-matlab-coder to / var /jenkins_home/jobs/Pilotage_TUV/branches/CSI-322-p.cdvqom5vp0t2.lab-coder/htmlreports/Code_20Documentation FATAL: HTML Publisher failure java.io.IOException: Failed to extract C:\jenkins\workspace\de-matlab-du-tuv-en-matlab-coder /**/ * at hudson.FilePath.readFromTar(FilePath.java:2866) at hudson.FilePath.copyRecursiveTo(FilePath.java:2644) at hudson.FilePath.copyRecursiveTo(FilePath.java:2608) at hudson.FilePath.copyRecursiveTo(FilePath.java:2596) at hudson.FilePath.copyRecursiveTo(FilePath.java:2579) at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242) at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:70) at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:45) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47) at hudson.security.ACL.impersonate2(ACL.java:449) at hudson.security.ACL.impersonate(ACL.java:461) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang. Thread .run( Thread .java:829) Suppressed: java.util.concurrent.ExecutionException: java.io.IOException: This archive contains unclosed entries. at hudson.remoting.Channel$2.adapt(Channel.java:1037) at hudson.remoting.Channel$2.adapt(Channel.java:1031) at hudson.remoting.FutureAdapter.get(FutureAdapter.java:65) at hudson.FilePath.copyRecursiveTo(FilePath.java:2647) ... 15 more Caused by: java.io.IOException: This archive contains unclosed entries. at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.finish(TarArchiveOutputStream.java:291) at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.close(TarArchiveOutputStream.java:309) at hudson.util.io.TarArchiver.close(TarArchiver.java:128) at hudson.FilePath.writeToTar(FilePath.java:2826) at hudson.FilePath.access$4300(FilePath.java:216) at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2789) at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2776) at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3331) at hudson.remoting.UserRequest.perform(UserRequest.java:211) at hudson.remoting.UserRequest.perform(UserRequest.java:54) at hudson.remoting.Request$2.run(Request.java:376) at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:78) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang. Thread .run(Unknown Source) Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to Windows 10 x64 at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1795) at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356) at hudson.remoting.Channel$2.adapt(Channel.java:1035) at hudson.remoting.Channel$2.adapt(Channel.java:1031) at hudson.remoting.FutureAdapter.get(FutureAdapter.java:65) at hudson.FilePath.copyRecursiveTo(FilePath.java:2647) at hudson.FilePath.copyRecursiveTo(FilePath.java:2608) at hudson.FilePath.copyRecursiveTo(FilePath.java:2596) at hudson.FilePath.copyRecursiveTo(FilePath.java:2579) at htmlpublisher.HtmlPublisher.publishReports(HtmlPublisher.java:242) at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:70) at htmlpublisher.workflow.PublishHTMLStepExecution.run(PublishHTMLStepExecution.java:45) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47) at hudson.security.ACL.impersonate2(ACL.java:449) at hudson.security.ACL.impersonate(ACL.java:461) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang. Thread .run( Thread .java:829) Caused by: java.nio.charset.MalformedInputException: Input length = 1 at java.base/java.nio.charset.CoderResult.throwException(CoderResult.java:274) at java.base/java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:813) at org.apache.commons.compress.archivers.zip.NioZipEncoding.decode(NioZipEncoding.java:136) at org.apache.commons.compress.archivers.tar.TarUtils.parseName(TarUtils.java:311) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeaderUnwrapped(TarArchiveEntry.java:1607) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:1595) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.<init>(TarArchiveEntry.java:556) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:379) at hudson.FilePath.readFromTar(FilePath.java:2840) ... 16 more  

          Susanta added a comment -

          The serenity report failure issue was figured out.

          For some reason the serenity report files are having different permission and hence the archive issue.

          Below is the pseudo code:

          1. I have put the ` clean test aggregate` command inside a `catcherror` block so that it continues to execute other commands.
          2. I have given full permission to the `target/site/serenity` folder to everyone.
          stages {
            stage('Run Test Cases') {
              steps {
                container('myproject') {
                    catchError(buildResult: 'SUCCESS', stageResult: 'UNSTABLE') {
                        sh """
                    pwd
                    ls
                    echo ${WORKSPACE}
                    gradle --info clean test aggregate -Denvironment=${params.APP_ENV} -Dtags='envr:'${params.APP_ENV} -Dcucumber.options='--tags @envr='${params.APP_ENV}
                   """
                    }
                    sh """
                    echo 'Allowing Full permission to target File'
                    chmod -R 777 target/site/serenity
                    """
                }
              }
            }
          post {
            always {
              publishHTML (target : [allowMissing: false,
                alwaysLinkToLastBuild: false,
                keepAll: true,
                reportDir: 'target/site/serenity',
                reportFiles: 'index.html',
                reportName: 'qa-my-project-bdd-reports',
                reportTitles: 'The Serenity Report'])
            }
          } 

          Susanta added a comment - The serenity report failure issue was figured out. For some reason the serenity report files are having different permission and hence the archive issue. Below is the pseudo code: I have put the ` clean test aggregate` command inside a `catcherror` block so that it continues to execute other commands. I have given full permission to the `target/site/serenity` folder to everyone. stages { stage( 'Run Test Cases' ) { steps { container( 'myproject' ) { catchError(buildResult: 'SUCCESS' , stageResult: 'UNSTABLE' ) { sh """ pwd ls echo ${WORKSPACE} gradle --info clean test aggregate -Denvironment=${params.APP_ENV} -Dtags= 'envr:' ${params.APP_ENV} -Dcucumber.options= '--tags @envr=' ${params.APP_ENV} """ } sh """ echo 'Allowing Full permission to target File' chmod -R 777 target/site/serenity """ } } } post { always { publishHTML (target : [allowMissing: false , alwaysLinkToLastBuild: false , keepAll: true , reportDir: 'target/site/serenity' , reportFiles: 'index.html' , reportName: 'qa-my-project-bdd-reports' , reportTitles: 'The Serenity Report' ]) } }

            r2b2_nz Richard Bywater
            schultemarkus Markus Schulte
            Votes:
            6 Vote for this issue
            Watchers:
            12 Start watching this issue

              Created:
              Updated: