5/5 - (1 vote)

Last Updated on May 15, 2021 by Vikash Ekka

Linux repository and package
Linux repository and package


Linux repository:

A software repository contains software packages
When you search via the inbuilt Linux Software Center or use a Linux tools, you are shown a list of all the packages within the repositories available to your system.
A software repository can store its files on one server or across many different servers known as mirrors
 

Linux package

In Linux distributions, a “package” refers to a compressed file archive containing executable and data files that come with a particular application

The files are usually stored in the package according to their relative installation paths on your desktop system.


The contents of control file inside a Package are:

  • Package Name and version Number

  • Architecture support like 1386 (32-bit) or i686 (64bit)

  • Installed Size and location

  • Dependencies, Homepage and Description.


There are 2 types of Packages, they are:

1.    Source code package is a suite of files related to one program, it contains source code, documentation and configuration files.

2.    If a source code package is configured for a particular Unix or Linux distribution it is a Binary package

 

Linux Package Manager:

Installing software on Linux involves package managers and software repositories, Unlike Windows where you visit a website to download and run a dot exe files:
Linux Package Manager is designed to install and update the corresponding software.
A Linux Package Manager is similar to a mobile app store example Google Play store. Take a look at the adjoining diagram, it shows the Ubuntu Software center that contains the software repositories required for the Debian based Ubuntu system.
Package Manage is used to install, Upgrade, configure and remove software programs in the computer.
Package manager contains software in archive files, and the information about the necessary dependencies required for the software.

 

Ubuntu Software center

Different Package managers:

It is important for Linux administrators to know about the various supported package managers in various Linux Distributions.
Package Managers help in downloading and installing software from repositories, also it is used for handling dependencies, update and removal of software.

 

The various package managers are:

Dpkg (Debian package Management System) is a base package management system for the Debian Linux family, it is used to install, remove, store and provide information about .deb packages.

APT (Aptitude Package Manager) is a popular command line package management tool for Debian Linux Family.

RPM (Red Hat Package manager), is the standard package manager for Red hat Linux, CentOS and Fedora.

YUM (Yellowdog Updater, Modified) is an open source and popular command line package manager.

Pacman package manager is a simple but powerful package manager for Arch Linux. It provides the fundamental functionalities for automatic dependency resolution, installing, upgrading, uninstalling and downgrading software.

 

RPM- Red Hat linux Package Manager:

 

RPM stands for Red Hat Package Manager.

RPM command is used for installing, uninstalling, upgrading, querying, listing. and checking RPM packages on your Linux system.

RPM deals with dot rpm files, which contains the actual information about the packages such as: what it is, from where it comes, dependencies info. version info etc.

There are four basic modes in RPM command, they are:

1.    Install (i)-is used to install any RPM package

2.    Remove (e)- is used to erase or remove any RPM package

3.    Upgrade (U) is used to update existing RPM package

4.    Verify (q)-is used to query and verify about different RPM packages.

The table above lists some of the commands and their corresponding description.

Command Description
# rpm ivh <package_name> Install a rpm software package
# rpm -qpR <package_name> Check dependencies of RPM Package before installation
# rpm -ivh –nodeps <package_name> Install RPM package without dependencies
# rpm -qa –last To list recently installed RPM packages
# rpm -Uvh <package_name> To upgrade a RPM package
# rpm -evv <package_name> To remove a RPM package

YUM (Yellowdog Updater Modified) Package Manager

YUM (Yellowdog Updater Modified) is an open source command-line as well as graphical based package management tool for RPM (RedHat Package Manager) based Linux systems.

It allows users and system administrators to easily install, update, remove or search software packages on a system.

YUM uses numerous third party repositories to install packages automatically by resolving their dependencies issues.

Take a look at the table showing commands and description for YUM

Command Description
# yum install <package_name> Install a package by using YUM, this command asks for confirmation
# yum-install <package name> Install a package automatically without asking confirmation
# yum remove <package_name> Remove package with all its dependencies
# yum update <package_name> Update a package using YUM
# yum repolist all To display all enabled and disabled yum repositories
# yum history To view history of YUM

By Vikash Ekka

Hi All, My name is Vikash Ekka from India. I’m the founder and tech editor of https://www.vetechno.in. I have completed my Graduation in BCA. I love to write technical articles like Windows, Linux & MAC Tutorials, Tips, Tricks, How To fix, Tutorials About Ethical Hacking & Cyber Security Guide, and Software Review. Currently, I have been working as an IT professional since 2018.

Leave a Reply

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