How To Install python2-ipaddress on CentOS 8
Introduction
In this tutorial we learn how to install python2-ipaddress on CentOS 8.
What is python2-ipaddress
ipaddress provides the capabilities to create, manipulate and operate on IPv4 and IPv6 addresses and networks. The functions and classes in this module make it straightforward to handle various tasks related to IP addresses, including checking whether or not two hosts are on the same subnet, iterating over all hosts in a particular subnet, checking whether or not a string represents a valid IP address or network definition, and so on.
We can use yum or dnf to install python2-ipaddress on CentOS 8. In this tutorial we discuss both methods but you only need to choose one of method to install python2-ipaddress.
Install python2-ipaddress on CentOS 8 Using yum
Update yum database with yum using the following command.
sudo yum makecache
After updating yum database, We can install python2-ipaddress using yum by running the following command:
sudo yum -y install python2-ipaddress
Install python2-ipaddress on CentOS 8 Using dnf
If you don’t have dnf installed you can install DNF on CentOS 7 first.
Update yum database with dnf using the following command.
sudo dnf makecache
After updating yum database, We can install python2-ipaddress using dnf by running the following command:
sudo dnf -y install python2-ipaddress
How To Uninstall python2-ipaddress on CentOS 8
To uninstall only the python2-ipaddress package we can use the following command:
sudo dnf remove python2-ipaddress
References
Summary
In this tutorial we learn how to install python2-ipaddress on CentOS 8 using yum and dnf.