Day 13 – RPM, YUM, and Installing Jenkins on CentOS

📦 Today on Day 13, I dove into package management on CentOS using RPM, YUM, and manual repo setup. I installed tools like tree, httpd, and Jenkins, gaining a solid understanding of low-level and high-level package operations.

🧪 Activities Breakdown

🌲 1. Installing Tree with RPM

# Download and install tree manually
curl -O https://rpmfind.net/linux/centos/7.9.2009/os/x86_64/Packages/tree-1.6.0-10.el7.x86_64.rpm
rpm -ivh tree-1.6.0-10.el7.x86_64.rpm

✅ Explored /var/log directory structure using tree
✅ Removed the package later using:

rpm -e tree-1.6.0-10.el7.x86_64

🌐 2. Installing Apache (httpd) via RPM

curl -O https://rpmfind.net/linux/centos/7.9.2009/os/x86_64/Packages/httpd-2.4.6-95.el7.centos.x86_64.rpm
rpm -ivh httpd-2.4.6-95.el7.centos.x86_64.rpm

💡 Later explored how yum simplifies this:

yum install httpd
yum remove httpd

🕵️ 3. Exploring Installed Packages

rpm -qa              # List all RPM packages
rpm -qa | grep tree  # Search for specific package

🍽️ 4. Installing Jenkins the Right Way (via Repo)

yum install wget -y

# Add Jenkins repo
sudo wget -O /etc/yum.repos.d/jenkins.repo \
  https://pkg.jenkins.io/redhat-stable/jenkins.repo

# Import Jenkins GPG key
rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io.key

# Install Jenkins + Java
yum install jenkins java-1.8.0-openjdk-devel -y

📌 Key Learnings

rpm is low-level and fast but lacks dependency resolution
yum is high-level, resolving dependencies and handling repos
✅ Repositories live in /etc/yum.repos.d/
✅ You can install packages by URL or by enabling a repo
✅ Jenkins requires its repo and GPG key for secure installation


🛠️ Real-World Application

In production, you often configure repos (like Jenkins, Docker, GitLab) manually for the latest stable releases. Understanding how to install and manage packages manually is crucial for hardened and minimal systems.


🚀 Next Step – Day 14

Tomorrow, I’ll explore systemd, service management, and how to control services like Jenkins and Apache!

0
Subscribe to my newsletter

Read articles from Shaharyar Shakir directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Shaharyar Shakir
Shaharyar Shakir