Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Not A Defect
    • Component/s: active-choices-plugin
    • Labels:
    • Environment:
      - Jenkins Server: 2.194 (latest at 15/9/2019)
      - Installed as System Service (init.d) on Ubuntu 14.04 LTS
      - Java: OpenJDK build 1.8.0_141-8u141
    • Similar Issues:

      Description

      Upgrade to latest release of OWASP HTML Formatter plugin crashed Jenkins server totally.

      Jenkins crashes with all other plugins
      when upgraded to version 1.6

      Errors:

      File: /var/log/jenkins/jenkins.log

      root@jenkins:/home/ubuntu# tail -f /var/log/jenkins/jenkins.log|grep -A2 SEVERE
      --2019-09-15 19:37:10.079+0000 [id=28] SEVERE h.ExtensionFinder$GuiceFinder#<init>: Failed to create Guice container from all the pluginsjava.lang.ClassNotFoundException: org.jenkinsci.plugins.scriptler.ScriptlerManagement at jenkins.util.AntClassLoader.findClassInComponents(AntClassLoader.java:1383)
      --2019-09-15 19:37:11.479+0000 [id=28] SEVERE h.ExtensionFinder$GuiceFinder#<init>: Failed to create Guice container from all the pluginsjava.lang.ClassNotFoundException: org.jenkinsci.plugins.scriptler.ScriptlerManagement at jenkins.util.AntClassLoader.findClassInComponents(AntClassLoader.java:1383)
      --2019-09-15 19:37:12.761+0000 [id=28] SEVERE h.ExtensionFinder$GuiceFinder#<init>: Failed to create Guice container from all the pluginsjava.lang.ClassNotFoundException: org.jenkinsci.plugins.scriptler.ScriptlerManagement at jenkins.util.AntClassLoader.findClassInComponents(AntClassLoader.java:1383)
      --2019-09-15 19:37:12.816+0000 [id=32] SEVERE jenkins.InitReactorRunner$1#onTaskFailed: Failed Contributed.loadjava.lang.NullPointerException at jenkins.security.CustomClassFilter$Contributed.load(CustomClassFilter.java:155)
      --2019-09-15 19:37:12.818+0000 [id=37] SEVERE jenkins.InitReactorRunner$1#onTaskFailed: Failed PluginImpl.initjava.lang.IllegalStateException: Expected 1 instance of hudson.PluginManager$PluginUpdateMonitor but got 0 at hudson.ExtensionList.lookupSingleton(ExtensionList.java:451)
      --2019-09-15 19:37:12.818+0000 [id=36] SEVERE jenkins.InitReactorRunner$1#onTaskFailed: Failed RekeySecretAdminMonitor.scanOnRebootjava.lang.IllegalArgumentException: Unable to inject class jenkins.security.RekeySecretAdminMonitor at hudson.init.TaskMethodFinder.lookUp(TaskMethodFinder.java:125)--2019-09-15 19:37:12.818+0000 [id=29] SEVERE jenkins.InitReactorRunner$1#onTaskFailed: Failed GitSCM.onLoadedjava.lang.NullPointerException at hudson.plugins.git.GitSCM.onLoaded(GitSCM.java:1895)
      --2019-09-15 19:37:12.818+0000 [id=31] SEVERE jenkins.InitReactorRunner$1#onTaskFailed: Failed UserIdMapper.initjava.lang.IllegalArgumentException: Unable to inject class hudson.model.UserIdMapper at hudson.init.TaskMethodFinder.lookUp(TaskMethodFinder.java:125)
      --2019-09-15 19:37:12.822+0000 [id=21] SEVERE hudson.util.BootFailure#publish: Failed to initialize Jenkinsjava.lang.NullPointerException at hudson.plugins.git.GitSCM.onLoaded(GitSCM.java:1895)
      --2019-09-15 19:37:13.189+0000 [id=21] SEVERE jenkins.model.Jenkins$18#onTaskFailed: Failed NioChannelSelector.cleanUpjava.lang.IllegalArgumentException: Unable to inject class jenkins.slaves.NioChannelSelector at hudson.init.TaskMethodFinder.lookUp(TaskMethodFinder.java:125)
      --2019-09-15 19:37:13.202+0000 [id=21] SEVERE jenkins.model.Jenkins$18#onTaskFailed: Failed IOHubProvider.cleanUpjava.lang.IllegalArgumentException: Unable to inject class jenkins.slaves.IOHubProvider at hudson.init.TaskMethodFinder.lookUp(TaskMethodFinder.java:125)
      

       

      Did not work:

      1. Deleting anitsamy-markup-formatter manually from Plugins directory.

        This only caused v1.1 to get installed after server restart (expected?)

        Then many other plugins are not compatible with the old version, see screenshot:

       


      Also tried
      2. Upgrading the Plugin after previous step from v1.1 to to v1.5 via  manual upload of the .hpi file in the "Advanced" tab.

      However this version also crashed Jenkins.

      Server does not start AT ALL with same errors as before.

       

      Additional issue is that after crash, Jenkins UI shows this error

      java.lang.NullPointerException
      	at hudson.plugins.git.GitSCM.onLoaded(GitSCM.java:1895)
      Caused: java.lang.reflect.InvocationTargetException
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:498)
      	at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:104)
      Caused: java.lang.Error
      	at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:110)
      	at hudson.init.TaskMethodFinder$TaskImpl.run(TaskMethodFinder.java:175)
      	at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:296)
      	at jenkins.model.Jenkins$5.runTask(Jenkins.java:1118)
      	at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:214)
      	at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      	at java.lang.Thread.run(Thread.java:748)
      Caused: org.jvnet.hudson.reactor.ReactorException
      	at org.jvnet.hudson.reactor.Reactor.execute(Reactor.java:282)
      	at jenkins.InitReactorRunner.run(InitReactorRunner.java:48)
      	at jenkins.model.Jenkins.executeReactor(Jenkins.java:1152)
      	at jenkins.model.Jenkins.<init>(Jenkins.java:959)
      	at hudson.model.Hudson.<init>(Hudson.java:85)
      	at hudson.model.Hudson.<init>(Hudson.java:81)
      	at hudson.WebAppMain$3.run(WebAppMain.java:233)
      Caused: hudson.util.HudsonFailedToLoad
      	at hudson.WebAppMain$3.run(WebAppMain.java:250)
      

      Error and "resolution" is reproducible on this environment and has been reproduced in both states multiple times.

        Attachments

          Issue Links

            Activity

            Hide
            danielbeck Daniel Beck added a comment -

            Failed to create Guice container from all the pluginsjava.lang.ClassNotFoundException: org.jenkinsci.plugins.scriptler.ScriptlerManagement

            My guess is that you (also) updated uno-choice ("Active Choices") plugin, and that messed this up, claiming to have an optional dependency that is, in fact, mandatory.

            Show
            danielbeck Daniel Beck added a comment - Failed to create Guice container from all the pluginsjava.lang.ClassNotFoundException: org.jenkinsci.plugins.scriptler.ScriptlerManagement My guess is that you (also) updated uno-choice ("Active Choices") plugin, and that messed this up, claiming to have an optional dependency that is, in fact, mandatory.
            Hide
            j00mz Joe Tavin added a comment -

            Daniel Beck, so you suggest downgrading Active Choices?

            To which version?

            Show
            j00mz Joe Tavin added a comment - Daniel Beck , so you suggest downgrading Active Choices? To which version?
            Hide
            j00mz Joe Tavin added a comment - - edited

            Seems the Scriptler Plugin was required as opposed to Optional as it appears in ActiveState plugin [site|https://plugins.jenkins.io/uno-choice]

            We installed the latest Scriptler version 3.0 and this resolved the issue.

            Show
            j00mz Joe Tavin added a comment - - edited Seems the Scriptler Plugin was required as opposed to Optional as it appears in ActiveState plugin [site| https://plugins.jenkins.io/uno-choice ] We installed the latest Scriptler version 3.0 and this resolved the issue.
            Hide
            sturman Roman Isko added a comment -

            Joe Tavin, I've just fixed Jenkins by downgrading Active Choice plugin to version 2.1. In plugins directory I've restored the backup version of the plugin and restarted jenkins with these commands:

            cd /var/lib/jenkins/plugins/

            sudo mv uno-choice.jpi uno-choice.jpi.bak

            sudo mv uno-choice.bak uno-choice.jpi

            sudo systemctl restart jenkins.service

             

            Show
            sturman Roman Isko added a comment - Joe Tavin , I've just fixed Jenkins by downgrading Active Choice plugin to version 2.1. In plugins directory I've restored the backup version of the plugin and restarted jenkins with these commands: cd /var/lib/jenkins/plugins/ sudo mv uno-choice.jpi uno-choice.jpi.bak sudo mv uno-choice.bak uno-choice.jpi sudo systemctl restart jenkins.service  
            Hide
            j00mz Joe Tavin added a comment - - edited

            Thanks.

            It actually works with uno-choice ("Active Choices") plugin v2.2 after upgrading Scriptler.

            Seems RC was an optional requirement of Scriptler that should have been mandatory as Daniel Beck suggested before.

            Show
            j00mz Joe Tavin added a comment - - edited Thanks. It actually works with uno-choice ("Active Choices") plugin v2.2 after upgrading Scriptler. Seems RC was an optional requirement of Scriptler that should have been mandatory as Daniel Beck suggested before.
            Hide
            kinow Bruno P. Kinoshita added a comment -

            Hi, sorry for the update that broke it. It appears we made scriptler a non-optional dependency. Will try to get a fix in this week and cut a new release.

            Show
            kinow Bruno P. Kinoshita added a comment - Hi, sorry for the update that broke it. It appears we made scriptler a non-optional dependency. Will try to get a fix in this week and cut a new release.
            Hide
            j00mz Joe Tavin added a comment - - edited

            Thanks Bruno P. Kinoshita Is this related, no?

            Show
            j00mz Joe Tavin added a comment - - edited Thanks Bruno P. Kinoshita  Is this related, no?
            Hide
            kinow Bruno P. Kinoshita added a comment -

            I haven't tested with the scenario described here. The exception looks the same users got in active choices when upgrading to 2.2.

            Released 2.2.1 last night (New Zealand time) with a tentative fix. One user reported it worked so far.

            Show
            kinow Bruno P. Kinoshita added a comment - I haven't tested with the scenario described here. The exception looks the same users got in active choices when upgrading to 2.2. Released 2.2.1 last night (New Zealand time) with a tentative fix. One user reported it worked so far.

              People

              • Assignee:
                Unassigned
                Reporter:
                j00mz Joe Tavin
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: