Install Java 8 on MAC OS


Step 1: Check if JDK has been Pre-Installed

In some Mac systems (earlier than Mac OS X 10.7), JDK has been pre-installed. To check if JDK has been installed, open a "Terminal" (Search "Terminal"; or Finder ⇒ Go ⇒ Utilities ⇒ Terminal) and issue this command:

javac -version


Step 2: Download JDK

  1. Goto Java SE download site @ http://www.oracle.com/technetwork/java/javase/downloads/index.html. Under "Java Platform, Standard Edition" ⇒ "Java SE 10.0.{x}" ⇒ Click the JDK's "Download" button.

  2. Check "Accept License Agreement".

  3. Choose your operating platform, i.e., MacOS. Download the installer (e.g, jdk-1.8.0.{x}_osx-x64_bin.dmg - 395MB).


Step 3: Install JDK/JRE

  1. Double-click the downloaded Disk Image (DMG) file. Follow the screen instructions to install JDK/JRE.

  2. Eject the DMG file.

  3. To verify your installation, open a "Terminal" and issue these commands.

    // Display the JDK versionjavac -versionjavac 10.0.{x} // Display the JRE versionjava -versionjava version "10.0.{x}"...... // Display the location of Java Compilerwhich javac/usr/bin/javac // Display the location of Java Runtimewhich java/usr/bin/java


Start Jenkins on Mac OS

1. Open terminal and execute command

java -jar ~/path-to-jenkins-war/jenkins.war -httpPort={Port_Num}