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

safeRestart fails with Authentication exception

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Component/s: safe-restart
    • Labels:
      None
    • Environment:
    • Similar Issues:

      Description

      Jenkins hangs with "Please wait while Jenkins is restarting..." after a restart from the GUI.

      This seems to occur with any restart from the Jenkins GUI. I experienced the same issue when disabling plugins and selecting "Restart Once No Jobs are Running" or selecting the "Restart Safely" plugin.

      The following error shows in the log:

      SEVERE: Failed to stop filters
      java.lang.UnsupportedOperationException
      	at java.util.concurrent.CopyOnWriteArrayList$COWIterator.remove(CopyOnWriteArrayList.java:1040)
      	at hudson.util.PluginServletFilter.cleanUp(PluginServletFilter.java:162)
      	at jenkins.model.Jenkins._cleanUpPluginServletFilters(Jenkins.java:3237)
      	at jenkins.model.Jenkins.cleanUp(Jenkins.java:2890)
      	at hudson.lifecycle.UnixLifecycle.restart(UnixLifecycle.java:70)
      	at jenkins.model.Jenkins$27.run(Jenkins.java:3846)
      
      Mar 21, 2016 1:28:41 PM jenkins.model.Jenkins cleanUp
      INFO: Jenkins stopped
      Mar 21, 2016 1:28:41 PM jenkins.model.Jenkins$27 run
      WARNING: Failed to restart Jenkins
      java.lang.RuntimeException: Unexpected issues encountered during cleanUp: null
      	at jenkins.model.Jenkins.cleanUp(Jenkins.java:2905)
      	at hudson.lifecycle.UnixLifecycle.restart(UnixLifecycle.java:70)
      	at jenkins.model.Jenkins$27.run(Jenkins.java:3846)
      Caused by: java.lang.UnsupportedOperationException
      	at java.util.concurrent.CopyOnWriteArrayList$COWIterator.remove(CopyOnWriteArrayList.java:1040)
      	at hudson.util.PluginServletFilter.cleanUp(PluginServletFilter.java:162)
      	at jenkins.model.Jenkins._cleanUpPluginServletFilters(Jenkins.java:3237)
      	at jenkins.model.Jenkins.cleanUp(Jenkins.java:2890)
      	... 2 more
      
      

      This occurred after an upgrade to Jenkins 1.653.

      I have also experienced this after running a safeRestart, executed using the following command:

      curl -u ${key} -X POST -w "%{http_code}" --connect-time 5 --max-time 10 https://ci.gfs.com/scmProductAcquisition/safeRestart
      

      where $

      {key}

      is the username:apikey. I have verified the login and API with successful logins. The command executes and the server does not shutdown or restart. The process ID remains the same and active. Killing and restarting works fine. Thread dumps produce no logging at all, as if the process did not actually exist.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              danielmish Daniel Mish
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: