Jenkins Installtion Guide: Step by Step Instruction For Linux
- Last Updated on: December 27, 2018
- By: scriptcrunch
This guide will help in Jenkins installation using step by step instructions. It explains the different methods to setup jenkins on a Linux server.
Hardware Requirements
Jenkins server should meet the following minimum hardware requirements to run smoothly.
- 2GB RAM
- 30GB Hard disk (Better to have a additional disk for storing Jenkins data)
Note: This tutorila will work only on Redhat based Linux systems (Redhat & centos)
Prerequisites
Following are the two mimimim requirements for Jenkins setup.
- Java
- Git (Not mandatory)
Java Installation
Java is a primary requirement for Jenkins as it is a java based application.
Step 1: Install java jdk
sudo yum install -y java-1.8.0-openjdk-devel
Step 2: Verify java installation
java -version
Git Installation
git is not a mandatory requirement. However, most of your Jenkins operations will be based on git. So it is better to have it installed on the Jenkins server.
Step 1: Install git
sudo yum install -y git
Step 2: Verify git installation
git --version
Jenkins Installation Methods
Jenkins can be installed in the following ways
- Using yum repository
- Using jenkins war file
Jenkins Installation Using yum Repo
Step 1: Add the Jenkins repo to the server
sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
Step 2: Using the following command, find the specific version of Jenkins that you need.
sudo yum --showduplicates list jenkins | expand
Step 3: Install jenkins by following the below syntax.
sudo yum install -y jenkins-(package-info)
For example,
sudo yum install -y jenkins-2.156-1.1
Step 4: Start and enable jenkins service
sudo chkconfig jenkins on sudo systemctl start jenkins
Step 4: check the jenkins service status
sudo systemctl status jenkins
You will be able to access Jenkins on port 8080.
Jenkins Installation Using Jenkins war File
Step 1: Download the latest jenkins war file from here
wget http://mirrors.jenkins.io/war-stable/latest/jenkins.war
Step 2: Run the jar
java -jar jenkins.war
If you want to run
java -jar jenkins.war --httpPort=9090
Other Jenkins Resources:
Other Interesting Blogs

CKA Exam Study Guide: Certified Kubernetes Administrator
Passing the cloud-native Certified Kubernetes Administrator (CKA) exam is not a cakewalk. To pass the CKA exam, you should have enough hands-on

Linux Foundation Coupon for 2023
Hi Techies, I wanted to let you know about a pretty sweet deal with the Linux Foundation Coupon that is running now.

[35% OFF] Linux Foundation LFCA, LFCS & LFCT Exam Voucher Codes
Linux Foundation has announced up to a $284 discount on its Linux certification programs Linux Foundation Certified IT Associate (LFCA) and Linux