java.io.FileNotFoundException: C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process)

Jenkins JIRA | boris ivan | 3 years ago
  1. 0

    Occasionally, remote windows slaves die with the following trace spit to the screen on the remote slave (I am running via command line, not as a service): {noformat} Nov 20, 2013 4:16:10 PM org.jvnet.winp.Native load WARNING: Failed to write winp.x64.dll java.io.FileNotFoundException: C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process) at java.io.FileOutputStream.open(Native Method) at java.io.FileOutputStream.<init>(FileOutputStream.java:212) at java.io.FileOutputStream.<init>(FileOutputStream.java:165) at org.jvnet.winp.Native.load(Native.java:81) at org.jvnet.winp.Native.<clinit>(Native.java:52) at org.jvnet.winp.WinProcess.enableDebugPrivilege(WinProcess.java:200) at hudson.util.ProcessTree$Windows.<clinit>(ProcessTree.java:477) at hudson.util.ProcessTree.get(ProcessTree.java:336) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:899) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:890) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Thread.java:724) # # A fatal error has been detected by the Java Runtime Environment: # # EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000000c8b3a90, pid=7136, tid=2024 # # JRE version: 7.0_25-b17 # Java VM: Java HotSpot(TM) 64-Bit Server VM (23.25-b01 mixed mode windows-amd64 compressed oops) # Problematic frame: # C 0x000000000c8b3a90 # # Core dump written. Default location: C:\\hs_err_pid7136.mdmp # # An error report file with more information is saved as: # C:\\hs_err_pid7136.log {noformat} When this occurs, here's the trailing end of the build console for this build: {noformat} ... ... ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1:33.420s [INFO] Finished at: Wed Nov 20 16:16:09 EST 2013 [INFO] Final Memory: 42M/272M [INFO] ------------------------------------------------------------------------ [JENKINS] Archiving C:\jenkins\workspace\<redacted>\pom.xml to <redacted>SNAPSHOT.pom [JENKINS] Archiving C:\jenkins\workspace\<redacted>-SNAPSHOT.jar to <redacted>jar channel stopped FATAL: hudson.remoting.RequestAbortedException: java.net.SocketException: Connection reset hudson.remoting.RequestAbortedException: hudson.remoting.RequestAbortedException: java.net.SocketException: Connection reset at hudson.remoting.RequestAbortedException.wrapForRethrow(RequestAbortedException.java:41) at hudson.remoting.RequestAbortedException.wrapForRethrow(RequestAbortedException.java:34) at hudson.remoting.Request.call(Request.java:174) at hudson.remoting.Channel.call(Channel.java:714) at hudson.Launcher$RemoteLauncher.kill(Launcher.java:887) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:585) at hudson.model.Run.execute(Run.java:1679) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:509) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:230) Caused by: hudson.remoting.RequestAbortedException: java.net.SocketException: Connection reset at hudson.remoting.Request.abort(Request.java:299) at hudson.remoting.Channel.terminate(Channel.java:774) at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:69) Caused by: java.net.SocketException: Connection reset at java.net.SocketInputStream.read(Unknown Source) at java.net.SocketInputStream.read(Unknown Source) at java.io.BufferedInputStream.fill(Unknown Source) at java.io.BufferedInputStream.read(Unknown Source) at hudson.remoting.FlightRecorderInputStream.read(FlightRecorderInputStream.java:77) at java.io.ObjectInputStream$PeekInputStream.peek(Unknown Source) at java.io.ObjectInputStream$BlockDataInputStream.peek(Unknown Source) at java.io.ObjectInputStream$BlockDataInputStream.peekByte(Unknown Source) at java.io.ObjectInputStream.readObject0(Unknown Source) at java.io.ObjectInputStream.readObject(Unknown Source) at hudson.remoting.Command.readFrom(Command.java:92) at hudson.remoting.ClassicCommandTransport.read(ClassicCommandTransport.java:71) at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:48) {noformat} The post build action that should have occurred at this point was the "Editable Email Notification" plugin. Not sure if it got that far or if the crash is immediately prior to that. This happens about 4-5 times out of every 100 builds. All of my build configs (for different projects, all maven builds, all executing the email-ext plugin afterwards...) do this. Occasionally, it will show the same stacktrace on the remote slave.. WARNING: Failed to write winp.x64.dll java.io.FileNotFoundException: C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process) .. but not crash. According to my google searches, a couple of people have been hitting this, though I couldn't find a JIRA issue logged against it. Not sure if anyone has determined root cause yet. I'll attach what information I can, though my company will frown upon me attaching the core dump, so I might not be able to do that.

    Jenkins JIRA | 3 years ago | boris ivan
    java.io.FileNotFoundException: C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process)
  2. 0

    Occasionally, remote windows slaves die with the following trace spit to the screen on the remote slave (I am running via command line, not as a service): {noformat} Nov 20, 2013 4:16:10 PM org.jvnet.winp.Native load WARNING: Failed to write winp.x64.dll java.io.FileNotFoundException: C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process) at java.io.FileOutputStream.open(Native Method) at java.io.FileOutputStream.<init>(FileOutputStream.java:212) at java.io.FileOutputStream.<init>(FileOutputStream.java:165) at org.jvnet.winp.Native.load(Native.java:81) at org.jvnet.winp.Native.<clinit>(Native.java:52) at org.jvnet.winp.WinProcess.enableDebugPrivilege(WinProcess.java:200) at hudson.util.ProcessTree$Windows.<clinit>(ProcessTree.java:477) at hudson.util.ProcessTree.get(ProcessTree.java:336) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:899) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:890) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Thread.java:724) # # A fatal error has been detected by the Java Runtime Environment: # # EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000000c8b3a90, pid=7136, tid=2024 # # JRE version: 7.0_25-b17 # Java VM: Java HotSpot(TM) 64-Bit Server VM (23.25-b01 mixed mode windows-amd64 compressed oops) # Problematic frame: # C 0x000000000c8b3a90 # # Core dump written. Default location: C:\\hs_err_pid7136.mdmp # # An error report file with more information is saved as: # C:\\hs_err_pid7136.log {noformat} When this occurs, here's the trailing end of the build console for this build: {noformat} ... ... ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1:33.420s [INFO] Finished at: Wed Nov 20 16:16:09 EST 2013 [INFO] Final Memory: 42M/272M [INFO] ------------------------------------------------------------------------ [JENKINS] Archiving C:\jenkins\workspace\<redacted>\pom.xml to <redacted>SNAPSHOT.pom [JENKINS] Archiving C:\jenkins\workspace\<redacted>-SNAPSHOT.jar to <redacted>jar channel stopped FATAL: hudson.remoting.RequestAbortedException: java.net.SocketException: Connection reset hudson.remoting.RequestAbortedException: hudson.remoting.RequestAbortedException: java.net.SocketException: Connection reset at hudson.remoting.RequestAbortedException.wrapForRethrow(RequestAbortedException.java:41) at hudson.remoting.RequestAbortedException.wrapForRethrow(RequestAbortedException.java:34) at hudson.remoting.Request.call(Request.java:174) at hudson.remoting.Channel.call(Channel.java:714) at hudson.Launcher$RemoteLauncher.kill(Launcher.java:887) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:585) at hudson.model.Run.execute(Run.java:1679) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:509) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:230) Caused by: hudson.remoting.RequestAbortedException: java.net.SocketException: Connection reset at hudson.remoting.Request.abort(Request.java:299) at hudson.remoting.Channel.terminate(Channel.java:774) at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:69) Caused by: java.net.SocketException: Connection reset at java.net.SocketInputStream.read(Unknown Source) at java.net.SocketInputStream.read(Unknown Source) at java.io.BufferedInputStream.fill(Unknown Source) at java.io.BufferedInputStream.read(Unknown Source) at hudson.remoting.FlightRecorderInputStream.read(FlightRecorderInputStream.java:77) at java.io.ObjectInputStream$PeekInputStream.peek(Unknown Source) at java.io.ObjectInputStream$BlockDataInputStream.peek(Unknown Source) at java.io.ObjectInputStream$BlockDataInputStream.peekByte(Unknown Source) at java.io.ObjectInputStream.readObject0(Unknown Source) at java.io.ObjectInputStream.readObject(Unknown Source) at hudson.remoting.Command.readFrom(Command.java:92) at hudson.remoting.ClassicCommandTransport.read(ClassicCommandTransport.java:71) at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:48) {noformat} The post build action that should have occurred at this point was the "Editable Email Notification" plugin. Not sure if it got that far or if the crash is immediately prior to that. This happens about 4-5 times out of every 100 builds. All of my build configs (for different projects, all maven builds, all executing the email-ext plugin afterwards...) do this. Occasionally, it will show the same stacktrace on the remote slave.. WARNING: Failed to write winp.x64.dll java.io.FileNotFoundException: C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process) .. but not crash. According to my google searches, a couple of people have been hitting this, though I couldn't find a JIRA issue logged against it. Not sure if anyone has determined root cause yet. I'll attach what information I can, though my company will frown upon me attaching the core dump, so I might not be able to do that.

    Jenkins JIRA | 3 years ago | boris ivan
    java.io.FileNotFoundException: C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process)
  3. 0

    JNLP Slave on WinXP 64 bit gives error

    Google Groups | 3 years ago | Gaurang shah
    java.io.FileNotFoundException: C:\Users\gaurang_shah\.jenkins\cache\jars\01\winp.x64.dll (The process cannot access the f ile because it is being used by another process)
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Seems that JAR caching also takes DLL files on Windows. Thanks to Windows architecture (:(), it leads to access conflicts, because DDLs may be locked by other process. The issue is being heavily reproduced during the process. After several hours, any process termination fails with the FileNotFoundException exception (see the log below). Probably, the high frequency of the issue is somehow related to "Cygwin Process Killer" plugin. On my installation it calls additional remote call on the node before any process termination (it is an interim workaround for JENKINS-19156 and JENKINS-20289 in the custom 1.509.4 core build). {quote} Dec 07, 2013 7:02:28 AM org.jvnet.winp.Native load WARNING: Failed to write winp.x64.dll java.io.FileNotFoundException: C:\Users\XXX\.jenkins\cache\jars\01\winp.x64.dll (The process cannot access the file because it is being used by another process) at java.io.FileOutputStream.open(Native Method) at java.io.FileOutputStream.<init>(Unknown Source) at java.io.FileOutputStream.<init>(Unknown Source) at org.jvnet.winp.Native.load(Native.java:81) at org.jvnet.winp.Native.<clinit>(Native.java:52) at org.jvnet.winp.WinProcess.enableDebugPrivilege(WinProcess.java:200) at hudson.util.ProcessTree$Windows.<clinit>(ProcessTree.java:470) at hudson.util.ProcessTree.get(ProcessTree.java:335) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:899) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:890) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) 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 hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Unknown Source) Dec 07, 2013 7:02:35 AM hudson.util.ProcessTree get WARNING: Failed to load winp. Reverting to the default java.lang.UnsatisfiedLinkError: Native Library C:\Users\XXX\.jenkins\cache\jars\01\winp.x64.dll already loaded in another classloader at java.lang.ClassLoader.loadLibrary1(Unknown Source) at java.lang.ClassLoader.loadLibrary0(Unknown Source) at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.load0(Unknown Source) at java.lang.System.load(Unknown Source) at org.jvnet.winp.Native.loadDll(Native.java:158) at org.jvnet.winp.Native.load(Native.java:90) at org.jvnet.winp.Native.<clinit>(Native.java:52) at org.jvnet.winp.WinProcess.enableDebugPrivilege(WinProcess.java:200) at hudson.util.ProcessTree$Windows.<clinit>(ProcessTree.java:470) at hudson.util.ProcessTree.get(ProcessTree.java:335) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:899) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:890) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) 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 hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Unknown Source) {quote}

    Jenkins JIRA | 3 years ago | Oleg Nenashev
    java.io.FileNotFoundException: C:\Users\XXX\.jenkins\cache\jars\01\winp.x64.dll (The process cannot access the file because it is being used by another process)
  6. 0

    Seems that JAR caching also takes DLL files on Windows. Thanks to Windows architecture (:(), it leads to access conflicts, because DDLs may be locked by other process. The issue is being heavily reproduced during the process. After several hours, any process termination fails with the FileNotFoundException exception (see the log below). Probably, the high frequency of the issue is somehow related to "Cygwin Process Killer" plugin. On my installation it calls additional remote call on the node before any process termination (it is an interim workaround for JENKINS-19156 and JENKINS-20289 in the custom 1.509.4 core build). {quote} Dec 07, 2013 7:02:28 AM org.jvnet.winp.Native load WARNING: Failed to write winp.x64.dll java.io.FileNotFoundException: C:\Users\XXX\.jenkins\cache\jars\01\winp.x64.dll (The process cannot access the file because it is being used by another process) at java.io.FileOutputStream.open(Native Method) at java.io.FileOutputStream.<init>(Unknown Source) at java.io.FileOutputStream.<init>(Unknown Source) at org.jvnet.winp.Native.load(Native.java:81) at org.jvnet.winp.Native.<clinit>(Native.java:52) at org.jvnet.winp.WinProcess.enableDebugPrivilege(WinProcess.java:200) at hudson.util.ProcessTree$Windows.<clinit>(ProcessTree.java:470) at hudson.util.ProcessTree.get(ProcessTree.java:335) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:899) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:890) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) 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 hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Unknown Source) Dec 07, 2013 7:02:35 AM hudson.util.ProcessTree get WARNING: Failed to load winp. Reverting to the default java.lang.UnsatisfiedLinkError: Native Library C:\Users\XXX\.jenkins\cache\jars\01\winp.x64.dll already loaded in another classloader at java.lang.ClassLoader.loadLibrary1(Unknown Source) at java.lang.ClassLoader.loadLibrary0(Unknown Source) at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.load0(Unknown Source) at java.lang.System.load(Unknown Source) at org.jvnet.winp.Native.loadDll(Native.java:158) at org.jvnet.winp.Native.load(Native.java:90) at org.jvnet.winp.Native.<clinit>(Native.java:52) at org.jvnet.winp.WinProcess.enableDebugPrivilege(WinProcess.java:200) at hudson.util.ProcessTree$Windows.<clinit>(ProcessTree.java:470) at hudson.util.ProcessTree.get(ProcessTree.java:335) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:899) at hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:890) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) 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 hudson.remoting.Engine$1$1.run(Engine.java:63) at java.lang.Thread.run(Unknown Source) {quote}

    Jenkins JIRA | 3 years ago | Oleg Nenashev
    java.io.FileNotFoundException: C:\Users\XXX\.jenkins\cache\jars\01\winp.x64.dll (The process cannot access the file because it is being used by another process)

  1. eti22 3 times, last 2 weeks ago
  2. tyson925 49 times, last 1 week ago
  3. MoYapro 1 times, last 1 month ago
  4. musketyr 3 times, last 1 month ago
  5. iridic 12 times, last 1 month ago
23 more registered users
72 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.io.FileNotFoundException

    C:\Users\<redacted>\.jenkins\cache\jars\01\winp.x64.dll (The process can not access the file because it is being used by another process)

    at java.io.FileOutputStream.open()
  2. Java RT
    FileOutputStream.<init>
    1. java.io.FileOutputStream.open(Native Method)
    2. java.io.FileOutputStream.<init>(FileOutputStream.java:212)
    3. java.io.FileOutputStream.<init>(FileOutputStream.java:165)
    3 frames
  3. org.jvnet.winp
    WinProcess.enableDebugPrivilege
    1. org.jvnet.winp.Native.load(Native.java:81)
    2. org.jvnet.winp.Native.<clinit>(Native.java:52)
    3. org.jvnet.winp.WinProcess.enableDebugPrivilege(WinProcess.java:200)
    3 frames
  4. Hudson
    Launcher$RemoteLauncher$KillTask.call
    1. hudson.util.ProcessTree$Windows.<clinit>(ProcessTree.java:477)
    2. hudson.util.ProcessTree.get(ProcessTree.java:336)
    3. hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:899)
    4. hudson.Launcher$RemoteLauncher$KillTask.call(Launcher.java:890)
    4 frames
  5. Hudson :: Remoting Layer
    InterceptingExecutorService$1.call
    1. hudson.remoting.UserRequest.perform(UserRequest.java:118)
    2. hudson.remoting.UserRequest.perform(UserRequest.java:48)
    3. hudson.remoting.Request$2.run(Request.java:326)
    4. hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
    4 frames
  6. Java RT
    ThreadPoolExecutor$Worker.run
    1. java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    2. java.util.concurrent.FutureTask.run(FutureTask.java:166)
    3. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    4. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    4 frames
  7. Hudson :: Remoting Layer
    Engine$1$1.run
    1. hudson.remoting.Engine$1$1.run(Engine.java:63)
    1 frame
  8. Java RT
    Thread.run
    1. java.lang.Thread.run(Thread.java:724)
    1 frame