#90DaysOfDevops | Day 7
📍What is a package manager in Linux?
In simpler words, a package manager is a tool that allows users to install, remove, upgrade, configure and manage software packages on an operating system. The package manager can be a graphical application like a software center or a command line tool like apt-get or pacman.
📍What is a package?
A package is usually referred to an application but it could be a GUI application, command line tool or a software library (required by other software programs). A package is essentially an archive file containing the binary executable, configuration file and sometimes information about the dependencies.
📍Different kinds of package managers
Package Managers differ based on packaging system but same packaging system may have more than one package manager.
For example, RPM has Yum and DNF package managers. For DEB, you have apt-get, aptitude command line based package managers.
📍Installing Docker and Jenkins Using Package Managers
On Ubuntu:
1. Install Docker: Open your terminal and run the following commands-
sudo apt-get update
sudo apt-get install docker.io
2. Install Jenkins: To install Jenkins on Ubuntu, use the following commands:
sudo apt update
sudo apt install openjdk-17-jre
curl -fsSL https://pkg.jenkins.io/debian-stable/jenkins.io-2023.key | sudo tee \
/usr/share/keyrings/jenkins-keyring.asc > /dev/null
echo deb [signed-by=/usr/share/keyrings/jenkins-keyring.asc] \
https://pkg.jenkins.io/debian-stable binary/ | sudo tee \
/etc/apt/sources.list.d/jenkins.list > /dev/null
sudo apt-get update
sudo apt-get install jenkins
📍Exploring systemctl and systemd
As you delve into Linux system management, you might encounter terms like systemctl and systemd. These are essential tools and concepts for controlling and monitoring system services. Here's a brief overview:
systemctl: This command is used to examine and control the state of the "systemd" system and service manager. It allows you to start, stop, restart, enable, and disable services on your Linux system.
systemd: systemd is a system and service manager that has become the standard for Unix-like operating systems, with widespread adoption across various Linux distributions. It provides a robust and efficient way to manage services, logging, and system initialization.
📍System Service Management
To check the status of the service in your system, use the following command:
sudo systemctl status docker
sudo systemctl status jenkins
To start and stop services, use the following commands:
# Start services
sudo systemctl start docker
sudo systemctl start jenkins.service
# Stop services
sudo systemctl start docker
sudo systemctl start jenkins.service
In summary, package managers are the lifeblood of the Linux ecosystem, simplifying the installation, configuration, and management of software packages. They ensure that your Linux system remains organized, efficient, and up to date. Moreover, understanding the basics of systemctl and systemd is essential for managing system services effectively. With these tools at your disposal, you're well-equipped to navigate the Linux landscape with confidence.
I hope you like this blog, If yes ? feel free to share your thoughts.
Happy Learning ✨🚀
Subscribe to my newsletter
Read articles from Rajendra Patil directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by