Day:07 Understanding package manager and systemctl

Day:07 Understanding package manager and systemctl

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 centre or a command lines tool like apt-get or pacman.

What is a package?
A package is usually referred to as 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 the packaging system but the 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.

Debian and ubuntu =>

> apt

*CentOs and RHEL => *

> yum, dnf
have to install docker and Jenkins in your system from your terminal using package managers
I)To install Docker on Ubuntu, follow these steps:

1.Install & Update the package index:

sudo apt install

sudo apt update

2.Install Docker:

sudo apt install docker.io

once installation starts; it asks if we want to continue; type ‘y’ and enter. Once the installation is done we can check by command;

docker --version.

II) To install Jenkins on Ubuntu, follow these steps:

Since Jenkins is written in Java, the first step is to install Java.

Update the package index:

sudo apt update

Install Jenkins:

sudo apt install jenkins

Start the Jenkins daemon:

sudo systemctl start jenkins

To enable the Jenkins daemon to start on boot:

sudo systemctl enable jenkins

5)Difference in systemctl and systemd

systemd is a system and service manager for Linux systems that provides many powerful features for managing processes and system resources. systemctl is a command-line utility that is used to control and manage the systemd system and service manager.

With systemctl, you can start, stop, and restart services, enable and disable them to start at boot, and check the status of services. You can also use systemctl to view and manage system logs, configure system startup and shutdown, and set system-wide environment variables.

systemd gives us the systemctl commands suite which is mostly used to enable services to start at boot time. We can also start, stop, reload, restart and check status of services with the help of systemctl ; Whileas service command is a wrapper script that allows system administrators to start, stop, and check the status of services without worrying too much about the actual init system being used.

Thank you for reading this article…!!


Discover more from Coursity

Subscribe to get the latest posts to your email.

Comments

No comments yet. Why don’t you start the discussion?

Leave a Reply

Your email address will not be published. Required fields are marked *