# Day 7 - 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 center or a command lines tool like apt-get or Pacman.

You’ll often find me using the term ‘package’ in tutorials and articles, To understand package manager, you must understand what a package is.

### **💡**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.

## **🔨**Tasks

1. You have to install docker and check the status of the docker service in your system
    

* ◼️Installation of Docker on Ubuntu
    
    ![](https://cdn.hashnode.com/res/hashnode/image/upload/v1707981026685/344972ab-160c-41f5-9a03-bc46230d5e9d.png align="center")
    
    * ◼️Check the status of docker service in your system
        
    
    ![](https://cdn.hashnode.com/res/hashnode/image/upload/v1707981302368/1ec5c28e-fe9e-4fed-af88-196e9517e304.png align="center")
    
    * ◼️Check the version of the docker
        
    
    ![](https://cdn.hashnode.com/res/hashnode/image/upload/v1707981433807/6cc330e4-fe0c-43c6-bb56-89eed7008431.png align="center")
    

1. You have to install Jenkins in your system from your terminal using package managers stop the service Jenkins and post before and after screenshots
    

* ◼️Update Package List
    
    ```plaintext
       sudo apt update #Update Package List
    ```
    
* ◼️Install Java Development Kit (JDK): Jenkins requires Java to run.
    
    ```plaintext
      sudo apt install -y openjdk-11-jdk #Install Java 11
    ```
    
* ◼️For Installing the Jenkins.
    
    ```plaintext
      sudo wget -O /usr/share/keyrings/jenkins-keyring.asc \
        https://pkg.jenkins.io/debian-stable/jenkins.io-2023.key
      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
    ```
    
* ◼️Check the status of Jenkins
    
    ```plaintext
      sudo systemctl status jenkins
    ```
    
    ![](https://cdn.hashnode.com/res/hashnode/image/upload/v1707982189950/6281cd41-e4dc-4d32-b5bc-ba0b212c5388.png align="center")
    
* ◼️Stop the Jenkins service
    
    ![](https://cdn.hashnode.com/res/hashnode/image/upload/v1707982429629/6b70ec99-3bb9-440b-b287-09e6aa50211b.png align="center")
    

### **💡systemctl and systemd**

systemctl is used to examine and control the state of “systemd” system and service manager. systemd is a system and service manager for Unix-like operating systems(most of the distributions, not all).

***📚 Happy Learning :)😊***
