詹金斯关机后无法启动

时间:2019-06-27 07:15:31

标签: ubuntu jenkins

我从控制台关闭了Jenkins,然后尝试使用以下命令启动它:

sudo /etc/init.d/jenkins start

,但是出现了以下异常。如何再次还原?

P.S。我正在Ubuntu 16.04上运行詹金斯

     com.thoughtworks.xstream.mapper.CannotResolveClassException: 

    at hudson.util.RobustReflectionConverter.doUnmarshal(RobustReflectionConverter.java:325)
    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         : 12
    version             : not available
-------------------------------
    at hudson.util.RobustReflectionConverter.doUnmarshal(RobustReflectionConverter.java:354)
    at hudson.util.RobustReflectionConverter.unmarshal(RobustReflectionConverter.java:268)
    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:161)
    at hudson.util.XStream2.unmarshal(XStream2.java:132)
    at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:1173)
    at hudson.XmlFile.unmarshal(XmlFile.java:178)
Caused: java.io.IOException: Unable to read /var/lib/jenkins/config.xml
    at hudson.XmlFile.unmarshal(XmlFile.java:181)
    at hudson.XmlFile.unmarshal(XmlFile.java:161)
    at jenkins.model.Jenkins.loadConfig(Jenkins.java:3039)
    at jenkins.model.Jenkins.access$1200(Jenkins.java:309)
    at jenkins.model.Jenkins$13.run(Jenkins.java:3141)
Caused: hudson.util.HudsonFailedToLoad
    at hudson.WebAppMain$3.run(WebAppMain.java:250)

1 个答案:

答案 0 :(得分:0)

请切换到su - jenkins用户,然后启动jenkins。