How To Install python3-netaddr on AlmaLinux 8

In this tutorial we learn how to install python3-netaddr in AlmaLinux 8. python3-netaddr is A pure Python network address representation and manipulation library

Introduction

In this tutorial we learn how to install python3-netaddr on AlmaLinux 8.

What is python3-netaddr

A network address manipulation library for Python Provides support for Layer 3 addresses * IPv4 and IPv6 addresses, subnets, masks, prefixes * iterating, slicing, sorting, summarizing and classifying IP networks * dealing with various ranges formats (CIDR, arbitrary ranges and globs, nmap) * set based operations (unions, intersections etc) over IP addresses and subnets * parsing a large variety of different formats and notations * looking up IANA IP block information * generating DNS reverse lookups * supernetting and subnetting Layer 2 addresses * representation and manipulation MAC addresses and EUI-64 identifiers * looking up IEEE organisational information (OUI, IAB) * generating derived IPv6 addresses

We can use yum or dnf to install python3-netaddr on AlmaLinux 8. In this tutorial we discuss both methods but you only need to choose one of method to install python3-netaddr.

Install python3-netaddr on AlmaLinux 8 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install python3-netaddr using dnf by running the following command:

sudo dnf -y install python3-netaddr

Install python3-netaddr on AlmaLinux 8 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install python3-netaddr using yum by running the following command:

sudo yum -y install python3-netaddr

How To Uninstall python3-netaddr on AlmaLinux 8

To uninstall only the python3-netaddr package we can use the following command:

sudo dnf remove python3-netaddr

References

Summary

In this tutorial we learn how to install python3-netaddr on AlmaLinux 8 using yum and dnf.