java.nio.file.FileSystemException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • *Configuration:* Jenkins 1.625, job-dsl-plugin 1.37, OS Windows 2012R2 I have a job containing: 1. Clean SVN checkout 2. Gradle step that obtains some dependency libraries. 3. "Process Job DSLs" step that uses these libraries in Groovy script. The job was created basing on this example: https://github.com/jenkinsci/job-dsl-plugin/wiki/User-Power-Moves#using-libraries Running this job twice, returns an error on second run. The checkout fails since Java still locks the JAR files: {noformat} Cleaning local Directory . java.nio.file.FileSystemException: d:\workspace\m\.\lib\antlr-runtime-3.4.jar: The process cannot access the file because it is being used by another process. at sun.nio.fs.WindowsException.translateToIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source) at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source) at java.nio.file.Files.delete(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at hudson.Util.deleteFile(Util.java:247) at hudson.Util.deleteRecursive(Util.java:310) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.scm.subversion.CheckoutUpdater$1.perform(CheckoutUpdater.java:81) at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:162) at hudson.scm.SubversionSCM$CheckOutTask.perform(SubversionSCM.java:992) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:973) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:949) at hudson.FilePath.act(FilePath.java:991) at hudson.FilePath.act(FilePath.java:969) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:898) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:834) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1277) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1741) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:408) Finished: FAILURE {noformat} I found someone already reported similar problem few months ago, but no issue was opened: https://groups.google.com/forum/#!topic/job-dsl-plugin/zwSgrtJhOLc
    via by Vasili Galka,
  • *Configuration:* Jenkins 1.625, job-dsl-plugin 1.37, OS Windows 2012R2 I have a job containing: 1. Clean SVN checkout 2. Gradle step that obtains some dependency libraries. 3. "Process Job DSLs" step that uses these libraries in Groovy script. The job was created basing on this example: https://github.com/jenkinsci/job-dsl-plugin/wiki/User-Power-Moves#using-libraries Running this job twice, returns an error on second run. The checkout fails since Java still locks the JAR files: {noformat} Cleaning local Directory . java.nio.file.FileSystemException: d:\workspace\m\.\lib\antlr-runtime-3.4.jar: The process cannot access the file because it is being used by another process. at sun.nio.fs.WindowsException.translateToIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source) at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source) at java.nio.file.Files.delete(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at hudson.Util.deleteFile(Util.java:247) at hudson.Util.deleteRecursive(Util.java:310) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.scm.subversion.CheckoutUpdater$1.perform(CheckoutUpdater.java:81) at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:162) at hudson.scm.SubversionSCM$CheckOutTask.perform(SubversionSCM.java:992) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:973) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:949) at hudson.FilePath.act(FilePath.java:991) at hudson.FilePath.act(FilePath.java:969) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:898) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:834) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1277) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1741) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:408) Finished: FAILURE {noformat} I found someone already reported similar problem few months ago, but no issue was opened: https://groups.google.com/forum/#!topic/job-dsl-plugin/zwSgrtJhOLc
    via by Vasili Galka,
  • We run Jenkins on a NAS/NFS share and have repeatedly had issues where builds will fail due to the following error: Started by an SCM change Building in workspace <http://lxe0038:8080/job/Ruff/ws/> Cleaning local Directory . java.nio.file.FileSystemException: <http://lxe0038:8080/job/Ruff/ws/./python/.nfs0000000001b52d730000361a>: Device or resource busy at sun.nio.fs.UnixException.translateToIOException(UnixException.java:91) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107) at sun.nio.fs.UnixFileSystemProvider.implDelete(UnixFileSystemProvider.java:244) at sun.nio.fs.AbstractFileSystemProvider.delete(AbstractFileSystemProvider.java:103) at java.nio.file.Files.delete(Files.java:1079) at sun.reflect.GeneratedMethodAccessor607.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at hudson.Util.deleteFile(Util.java:247) at hudson.Util.deleteRecursive(Util.java:310) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.scm.subversion.CheckoutUpdater$1.perform(CheckoutUpdater.java:80) at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:162) at hudson.scm.SubversionSCM$CheckOutTask.perform(SubversionSCM.java:991) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:972) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:948) at hudson.FilePath.act(FilePath.java:991) at hudson.FilePath.act(FilePath.java:969) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:897) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:833) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1282) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1744) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:374) Skipping Cobertura coverage report as build was not UNSTABLE or better ... Recording test results When I go in my jenkins/jobs/Ruff/workspace/python directory, I see the .nfs000xxx file and the contents appear to be the output of the SLOCCount logs (Creating filelist for .., Adding .., Categorizing file. Computing results, etc.) The actual sloccount process that generates the results is finished executing. I cannot seem to delete the .nfs manually as I get the Device or Resource busy. As soon as I kill my jenkins process, the file disappears. I'm running SLOCCount plugin v1.20 and Jenkins 1.618 (latest version of both). This is happening multiple times per day and requires manual intervention. Any ideas or workarounds?
    via by Don Drake,
  • Jenkins Build Failure with Workspace
    via Stack Overflow by Ruben Redman
    ,
  • We run Jenkins on a NAS/NFS share and have repeatedly had issues where builds will fail due to the following error: Started by an SCM change Building in workspace <http://lxe0038:8080/job/Ruff/ws/> Cleaning local Directory . java.nio.file.FileSystemException: <http://lxe0038:8080/job/Ruff/ws/./python/.nfs0000000001b52d730000361a>: Device or resource busy at sun.nio.fs.UnixException.translateToIOException(UnixException.java:91) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107) at sun.nio.fs.UnixFileSystemProvider.implDelete(UnixFileSystemProvider.java:244) at sun.nio.fs.AbstractFileSystemProvider.delete(AbstractFileSystemProvider.java:103) at java.nio.file.Files.delete(Files.java:1079) at sun.reflect.GeneratedMethodAccessor607.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at hudson.Util.deleteFile(Util.java:247) at hudson.Util.deleteRecursive(Util.java:310) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.scm.subversion.CheckoutUpdater$1.perform(CheckoutUpdater.java:80) at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:162) at hudson.scm.SubversionSCM$CheckOutTask.perform(SubversionSCM.java:991) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:972) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:948) at hudson.FilePath.act(FilePath.java:991) at hudson.FilePath.act(FilePath.java:969) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:897) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:833) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1282) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1744) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:374) Skipping Cobertura coverage report as build was not UNSTABLE or better ... Recording test results When I go in my jenkins/jobs/Ruff/workspace/python directory, I see the .nfs000xxx file and the contents appear to be the output of the SLOCCount logs (Creating filelist for .., Adding .., Categorizing file. Computing results, etc.) The actual sloccount process that generates the results is finished executing. I cannot seem to delete the .nfs manually as I get the Device or Resource busy. As soon as I kill my jenkins process, the file disappears. I'm running SLOCCount plugin v1.20 and Jenkins 1.618 (latest version of both). This is happening multiple times per day and requires manual intervention. Any ideas or workarounds?
    via by Don Drake,
  • Build failed in Jenkins: Stan Unit Tests #1023
    via by Unknown author,
    • java.nio.file.FileSystemException: d:\workspace\m\.\lib\antlr-runtime-3.4.jar: The process cannot access the file because it is being used by another process. at sun.nio.fs.WindowsException.translateToIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source) at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source) at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source) at java.nio.file.Files.delete(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at hudson.Util.deleteFile(Util.java:247) at hudson.Util.deleteRecursive(Util.java:310) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.Util.deleteRecursive(Util.java:301) at hudson.Util.deleteContentsRecursive(Util.java:212) at hudson.scm.subversion.CheckoutUpdater$1.perform(CheckoutUpdater.java:81) at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:162) at hudson.scm.SubversionSCM$CheckOutTask.perform(SubversionSCM.java:992) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:973) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:949) at hudson.FilePath.act(FilePath.java:991) at hudson.FilePath.act(FilePath.java:969) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:898) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:834) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1277) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1741) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:408)

    Users with the same issue

    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    ivanszkypeterivanszkypeter
    53 times, last one,
    10 more bugmates