Having trouble starting Jenkins: “java.io.FileNotFoundException: /usr/share/java/jenkins/war/META-INF/MANIFEST.MF (No such file or directory)”

前端 未结 8 1010
栀梦
栀梦 2021-01-14 08:01

I just downloaded the Jenkins WAR, version 1.651.1. I’m trying to set it up on my Amazon Linux box. I’m running Java 1.7. I moved the WAR into its own directory, /usr/sha

相关标签:
8条回答
  • 2021-01-14 08:40

    My two cents: not only must be jenkins user be the owner of $JENKINS_HOME, it looks like it also has to be the owner of jenkins.war (not just have access to it). Found out the hard way while configuring sytemd unit file for Jenkins.

    0 讨论(0)
  • 2021-01-14 08:44

    I think it is a permission related issue.

    I guess the user and group owner isset to a different user than what jenkins was trying to run as. Try to set it correctly with:

    $sudo chown -R <jenkins_user><jenkins_group> /usr/share/java/jenkins/
    
    0 讨论(0)
  • 2021-01-14 08:48

    “java.io.FileNotFoundException: /usr/share/java/jenkins/war/META-INF/MANIFEST.MF (No such file or directory)”

    Guys be chill.

    Just run below command.

    mkdir /var/cache/jenkins;chown jenkins:jenkins /var/cache/jenkins;

    and the start the app.

    0 讨论(0)
  • 2021-01-14 08:50

    In my case, I had this problem because a user named "jenkins" was already created on my Mac.

    After:

    1. uninstalling the broken Jenkins with '/Library/Application Support/Jenkins/Uninstall.command',
    2. removing the "jenkins" user,
    3. and re-installing from https://jenkins.io/download

    --> everything worked smoothly.

    0 讨论(0)
  • 2021-01-14 08:57

    I had exactly the same issue. Unable to change the user, I changed the hosted port by appending --httpPort=9090 to my java run command.

    $ java -jar /usr/share/java/jenkins/jenkins.war --httpPort=9090

    0 讨论(0)
  • 2021-01-14 08:58

    Probably the userid that you are using is not the owner of JENKINS_HOME.

    This has happened to me on Vagrant, when trying to use the jenkins user on a JENKINS_HOME owned by vagrant. jenkins did have write permissions to on JENKINS_HOME, but it is not enough: it has to be the owner.

    I learned this because when I tried sudo -u jenkins touch file-in-jenkins-home I got touch: setting times (...): Operation not permitted. And then I found https://unix.stackexchange.com/questions/64848/cannot-touch-m-a-writable-file

    0 讨论(0)
提交回复
热议问题