9

I am trying to install Jenkins in my mac and i have followed this below steps:

  1. Downloaded the Jenkins war file for OS-X

  2. After cd , Ran this:

    java -jar jenkins.war

  3. getting this error in my terminal:

    Error: Unable to access jarfile jenkins.war

Any idea what i am doing wrong??? FYI, I was successful in windows by following those steps.

ASM
  • 709
  • 2
  • 8
  • 27
  • I have just now figured out and resolved the issue. Earlier I downloaded the wrong file. :) – ASM Feb 26 '16 at 01:23
  • You could elaborate on how you got it working and post it as an answer to yourself - I'm sure it will help someone down the track! – schweerelos Feb 26 '16 at 01:29
  • Don't forget to include some specs of your system and I think the most important will be to include `java` version too! (will help others) – enkicoma Feb 02 '20 at 20:53

4 Answers4

3

Here how the issue got resolved. If you got mac or windows regardless,

  1. go to jenkins-ci.org
  2. Select long term support release which is a stable build.
  3. Click on the link .war
  4. Then in Terminal cd to that path where you downloaded
  5. Run this command: java -jar jenkins.war

You are good to go!!!

ASM
  • 709
  • 2
  • 8
  • 27
0

I got the same error with java -jar jenkins.war but when I changed it to java -jar .\jenkins.war it worked for me.

Paul Spencer
  • 860
  • 5
  • 14
0

The following is running in terminal.

  1. $: jenkins (You will see the "Running from: ".../jenkins/2.265/libexec/jenkins.war")
  2. $: cd .../jenkins/2.265/libexec
  3. $: java -jar jenkins.war
-2

Try to run: java -jar jenkins.war.jar. It helped me on Windows 10.