Configuration-as-code-plugin: Jenkins failed to start after Upgrade

Created on 8 Jan 2020  Â·  5Comments  Â·  Source: jenkinsci/configuration-as-code-plugin

After Upgrading Jenkins, jenkins is throughing below message . Please note I'm upgrading Jenkins from way too older version .

com.thoughtworks.xstream.mapper.CannotResolveClassException: hudson.security.ProjectMatrixAuthorizationStrategy
    at com.thoughtworks.xstream.mapper.DefaultMapper.realClass(DefaultMapper.java:79)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.DynamicProxyMapper.realClass(DynamicProxyMapper.java:55)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.PackageAliasingMapper.realClass(PackageAliasingMapper.java:88)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.ClassAliasingMapper.realClass(ClassAliasingMapper.java:79)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.ArrayMapper.realClass(ArrayMapper.java:74)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.SecurityMapper.realClass(SecurityMapper.java:71)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at hudson.util.XStream2$CompatibilityMapper.realClass(XStream2.java:380)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at hudson.util.xstream.MapperDelegate.realClass(MapperDelegate.java:43)
    at com.thoughtworks.xstream.mapper.MapperWrapper.realClass(MapperWrapper.java:30)
    at com.thoughtworks.xstream.mapper.CachingMapper.realClass(CachingMapper.java:48)
    at hudson.util.RobustReflectionConverter.determineType(RobustReflectionConverter.java:458)
    at hudson.util.RobustReflectionConverter.doUnmarshal(RobustReflectionConverter.java:324)
Caused: jenkins.util.xstream.CriticalXStreamException: hudson.security.ProjectMatrixAuthorizationStrategy : hudson.security.ProjectMatrixAuthorizationStrategy
---- Debugging information ----
message             : hudson.security.ProjectMatrixAuthorizationStrategy
cause-exception     : com.thoughtworks.xstream.mapper.CannotResolveClassException
cause-message       : hudson.security.ProjectMatrixAuthorizationStrategy
class               : hudson.model.Hudson
required-type       : hudson.model.Hudson
converter-type      : hudson.util.RobustReflectionConverter
path                : /hudson/authorizationStrategy
line number         : 11
version             : not available
-------------------------------
    at hudson.util.RobustReflectionConverter.doUnmarshal(RobustReflectionConverter.java:353)
    at hudson.util.RobustReflectionConverter.unmarshal(RobustReflectionConverter.java:267)
    at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:72)
    at com.thoughtworks.xstream.core.AbstractReferenceUnmarshaller.convert(AbstractReferenceUnmarshaller.java:65)
    at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:66)
    at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller.java:50)
    at com.thoughtworks.xstream.core.TreeUnmarshaller.start(TreeUnmarshaller.java:134)
    at com.thoughtworks.xstream.core.AbstractTreeMarshallingStrategy.unmarshal(AbstractTreeMarshallingStrategy.java:32)
    at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:1189)
    at hudson.util.XStream2.unmarshal(XStream2.java:162)
    at hudson.util.XStream2.unmarshal(XStream2.java:133)
    at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:1173)
    at hudson.XmlFile.unmarshal(XmlFile.java:180)
Caused: java.io.IOException: Unable to read E:\Jenkins\config.xml
    at hudson.XmlFile.unmarshal(XmlFile.java:183)
    at hudson.XmlFile.unmarshal(XmlFile.java:163)
    at jenkins.model.Jenkins.loadConfig(Jenkins.java:3081)
    at jenkins.model.Jenkins.access$1200(Jenkins.java:315)
    at jenkins.model.Jenkins$13.run(Jenkins.java:3182)
    at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:169)
    at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:296)
    at jenkins.model.Jenkins$5.runTask(Jenkins.java:1121)
    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(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
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:1154)
    at jenkins.model.Jenkins.<init>(Jenkins.java:965)
    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)
question

All 5 comments

Would you mind actually filling out the checklist?

  • [ ] Jenkins version
  • [ ] Plugin version
  • [ ] OS

Not sure how this is related to JCasC.

As this seems to be an issue with either ProjectMatrixAuthorizationStrategy or Jenkins Core as it is an issue inside the xstream.

What version of Jenkins are you coming from and upgrading to?

Thank you for your reply. I will send the version number soon .

I deleted existing jenkins.war and renamed jenkins.war.bak to jenkins.war
and restarted jenkins which made jenkins to be back online with all agents
as well .

But I cant open any jobs. When I open any jobs its throughing the same
error message . I bieleve issue is with the plugins . I'll also include
plugins.txt in my next email.

Many thanks for your response.

On Wed, Jan 8, 2020, 12:13 PM Joseph Petersen notifications@github.com
wrote:

Would you mind actually filling on the checklist?

  • Jenkins version
  • Plugin version
  • OS

Not sure how this is related to JCasC.

As this seems to be an issue with either
ProjectMatrixAuthorizationStrategy or Jenkins Core as it is an issue
inside the xstream.

What version of Jenkins are you coming from and upgrading to?

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/jenkinsci/configuration-as-code-plugin/issues/1244?email_source=notifications&email_token=AE3DC3YTOOEHDJ3KQD7BXVLQ4YCU3A5CNFSM4KELSC5KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEINJKWY#issuecomment-572167515,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AE3DC3ZZRBSCCUDIIXDKQNTQ4YCU3ANCNFSM4KELSC5A
.

Still not sure how this is related to configuration as code plugin?

Once I'm logged in if I click on any job I'm getting below message .

Version Number : 2.7.2
OS : WIndows 2012 R2

[image: image.png]

On Wed, Jan 8, 2020 at 11:28 PM Joseph Petersen notifications@github.com
wrote:

Still not sure how this is related to configuration as code plugin?

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/jenkinsci/configuration-as-code-plugin/issues/1244?email_source=notifications&email_token=AE3DC3ZFXA6M3HOESXX5Y7TQ42RVZA5CNFSM4KELSC5KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEIO5FNY#issuecomment-572379831,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AE3DC35WK3SYLVCCBJU2EXLQ42RVZANCNFSM4KELSC5A
.

Jenkins configuration as code plugin only supports Jenkins v2.60.3 and beyond.

I believe your issue is not related to Jenkins configuration as code plugin and suggest you file your issue in the proper channel.

https://issues.jenkins-ci.org/

Was this page helpful?
0 / 5 - 0 ratings

Related issues

darkn3rd picture darkn3rd  Â·  3Comments

aheritier picture aheritier  Â·  3Comments

timblaktu picture timblaktu  Â·  4Comments

sshepel picture sshepel  Â·  6Comments

oleg-nenashev picture oleg-nenashev  Â·  3Comments