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

Failed to update permalink: unable to delete

    Details

    • Similar Issues:

      Description

      Sometimes users report seeing exceptions such as

      ... jenkins.model.PeepholePermalink updateCache
      WARNING: Failed to update ... lastSuccessfulBuild permalink for ...
      java.io.IOException: Unable to delete /jenkins/jobs/.../builds/lastSuccessfulBuild
      	at hudson.util.AtomicFileWriter.commit(AtomicFileWriter.java:112)
      	at jenkins.model.PeepholePermalink.writeSymlink(PeepholePermalink.java:200)
      	at jenkins.model.PeepholePermalink.updateCache(PeepholePermalink.java:150)
      	at jenkins.model.PeepholePermalink.resolve(PeepholePermalink.java:122)
      	at hudson.model.Job.getLastSuccessfulBuild(Job.java:857)
      

      In one case this was discovered to be due to lastSuccessfulBuild being an actual directory rather than a symlink, due to an incorrect restoration from backup. But AtomicFileWriter should use Util.deleteFile or similar to make sure that Java 7 methods are first used to perform the deletion, which provide better diagnostics.

        Attachments

          Issue Links

            Activity

            Hide
            jglick Jesse Glick added a comment -

            Steven Christou had a proposed patch to core to stop using symlinks for build directories. What happened to it? I cannot find such a PR.

            Show
            jglick Jesse Glick added a comment - Steven Christou had a proposed patch to core to stop using symlinks for build directories. What happened to it? I cannot find such a PR.

              People

              • Assignee:
                Unassigned
                Reporter:
                jglick Jesse Glick
              • Votes:
                1 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated: