How To Install python3-libvirt on Fedora 36

In this tutorial we learn how to install python3-libvirt in Fedora 36. python3-libvirt is The libvirt virtualization API python3 binding

Introduction

In this tutorial we learn how to install python3-libvirt on Fedora 36.

What is python3-libvirt

The python3-libvirt package contains a module that permits applications written in the Python 3.x programming language to use the interface supplied by the libvirt library to use the virtualization capabilities of recent versions of Linux (and other OSes).

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

Install python3-libvirt on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

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

sudo dnf -y install python3-libvirt

Install python3-libvirt on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

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

sudo yum -y install python3-libvirt

How To Uninstall python3-libvirt on Fedora 36

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

sudo dnf remove python3-libvirt

python3-libvirt Package Contents on Fedora 36

/usr/lib/.build-id
/usr/lib/.build-id/01
/usr/lib/.build-id/01/a2fdfea52ae8d921b2870231fc0a0c20c74c06
/usr/lib/.build-id/4c
/usr/lib/.build-id/4c/49fcfa639078e130bad082b56c79edf4b035d6
/usr/lib/.build-id/75
/usr/lib/.build-id/75/433cd4c1da03d5fe504851514876a4561e0a57
/usr/lib64/python3.10/site-packages/__pycache__/libvirt.cpython-310.opt-1.pyc
/usr/lib64/python3.10/site-packages/__pycache__/libvirt.cpython-310.pyc
/usr/lib64/python3.10/site-packages/__pycache__/libvirt_lxc.cpython-310.opt-1.pyc
/usr/lib64/python3.10/site-packages/__pycache__/libvirt_lxc.cpython-310.pyc
/usr/lib64/python3.10/site-packages/__pycache__/libvirt_qemu.cpython-310.opt-1.pyc
/usr/lib64/python3.10/site-packages/__pycache__/libvirt_qemu.cpython-310.pyc
/usr/lib64/python3.10/site-packages/__pycache__/libvirtaio.cpython-310.opt-1.pyc
/usr/lib64/python3.10/site-packages/__pycache__/libvirtaio.cpython-310.pyc
/usr/lib64/python3.10/site-packages/libvirt.py
/usr/lib64/python3.10/site-packages/libvirt_lxc.py
/usr/lib64/python3.10/site-packages/libvirt_python-8.0.0-py3.10.egg-info
/usr/lib64/python3.10/site-packages/libvirt_qemu.py
/usr/lib64/python3.10/site-packages/libvirtaio.py
/usr/lib64/python3.10/site-packages/libvirtmod.cpython-310-x86_64-linux-gnu.so
/usr/lib64/python3.10/site-packages/libvirtmod_lxc.cpython-310-x86_64-linux-gnu.so
/usr/lib64/python3.10/site-packages/libvirtmod_qemu.cpython-310-x86_64-linux-gnu.so
/usr/share/doc/python3-libvirt
/usr/share/doc/python3-libvirt/AUTHORS
/usr/share/doc/python3-libvirt/COPYING
/usr/share/doc/python3-libvirt/COPYING.LESSER
/usr/share/doc/python3-libvirt/ChangeLog
/usr/share/doc/python3-libvirt/README
/usr/share/doc/python3-libvirt/examples
/usr/share/doc/python3-libvirt/examples/consolecallback.py
/usr/share/doc/python3-libvirt/examples/dominfo.py
/usr/share/doc/python3-libvirt/examples/domipaddrs.py
/usr/share/doc/python3-libvirt/examples/domrestore.py
/usr/share/doc/python3-libvirt/examples/domsave.py
/usr/share/doc/python3-libvirt/examples/domstart.py
/usr/share/doc/python3-libvirt/examples/esxlist.py
/usr/share/doc/python3-libvirt/examples/event-test.py
/usr/share/doc/python3-libvirt/examples/guest-vcpus
/usr/share/doc/python3-libvirt/examples/guest-vcpus/guest-vcpu-daemon.py
/usr/share/doc/python3-libvirt/examples/guest-vcpus/guest-vcpu.py
/usr/share/doc/python3-libvirt/examples/nodestats.py
/usr/share/doc/python3-libvirt/examples/sparsestream.py
/usr/share/doc/python3-libvirt/examples/topology.py

References

Summary

In this tutorial we learn how to install python3-libvirt on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).