PIP is primarily utilized for installing new Python packages, libraries, and modules from the official Python PyPi package repository on your computer.
In this guide, we will demonstrate how to install PIP on the Rocky Linux 9 operating system. Additionally, we will provide instructions on upgrading PIP to the latest version of Rocky Linux 9.
Table of Contents:
– Updating the Package Repository Cache for Rocky Linux 9
– Installing PIP on Rocky Linux 9
– Verifying the Functionality of PIP on Rocky Linux 9
– Upgrading PIP to the Latest Version in Rocky Linux 9
– Utilizing PIP to Manage Python Packages and Modules
Updating the Package Repository Cache for Rocky Linux 9
Firstly, you need to update the package repository cache for Rocky Linux 9. Execute the following command in order to accomplish this task:
$ sudo dnf makecache
The package repository cache for Rocky Linux 9 will now be updated.
Installing PIP on Rocky Linux 9
Python PIP is readily available in the official package repository for Rocky Linux 9, making the installation process straightforward.
To install Python PIP on Rocky Linux 9, run the following command:
$ sudo dnf install python3-pip
Confirm the installation by pressing ‘Y’ and then ‘Enter’.
Python PIP will be downloaded from the official package repository of Rocky Linux 9. Please allow a few moments for the process to complete.
If you encounter the prompt below, press ‘Y’ and then ‘Enter’ to accept the GPG key associated with the Rocky Linux 9 package repository.
The installation of Python PIP should now be complete.
Verifying the Functionality of PIP on Rocky Linux 9
To confirm that PIP is accessible and functioning correctly on Rocky Linux 9, execute the following command:
$ pip –version
If PIP is accessible and operational, the installed version of PIP will be displayed. At the time of writing, Rocky Linux 9 includes PIP version 21.2.3 in its package repository. However, newer versions may be available. If desired, you can proceed to upgrade PIP to the latest version, which will be explained in the next section.
Upgrading PIP to the Latest Version in Rocky Linux 9
To check for the availability of a newer version of PIP and upgrade to the latest version in Rocky Linux 9, execute the following command:
$ pip install –upgrade pip
PIP will be upgraded to the latest version if newer versions are accessible in the PyPi package repository.
To verify the version number of PIP after the upgrade, run the following command. As seen in the example, PIP was upgraded from version 21.2.3 to 23.1.2. Please note that a newer version may be available when you read this article.
$ pip –version
Utilizing PIP to Manage Python Packages and Modules
For further information on PIP and its usage, we suggest reading the article on “How to Manage Python Packages with PIP”. This article provides guidance on various tasks such as installing new Python packages, listing installed packages, uninstalling packages using PIP, and more.
In conclusion, we have demonstrated how to install Python PIP on Rocky Linux 9 and how to upgrade it to the latest version.