How To Install libxml2 on Rocky Linux 8
Introduction
In this tutorial we learn how to install libxml2
on Rocky Linux 8.
What is libxml2
This library allows to manipulate XML files. It includes support to read, modify and write XML and HTML files. There is DTDs support this includes parsing and validation even with complex DtDs, either at parse time or later once the document has been modified. The output can be a simple SAX stream or and in-memory DOM like representations. In this case one can use the built-in XPath and XPointer implementation to select sub nodes or ranges. A flexible Input/Output mechanism is available, with existing HTTP and FTP modules and combined to an URI library.
We can use yum
or dnf
to install libxml2
on Rocky Linux 8. In this tutorial we discuss both methods but you only need to choose one of method to install libxml2.
Install libxml2 on Rocky Linux 8 Using dnf
Update yum database with dnf
using the following command.
sudo dnf makecache --refresh
After updating yum database, We can install libxml2
using dnf
by running the following command:
sudo dnf -y install libxml2
Install libxml2 on Rocky Linux 8 Using yum
Update yum database with yum
using the following command.
sudo yum makecache --refresh
After updating yum database, We can install libxml2
using yum
by running the following command:
sudo yum -y install libxml2
How To Uninstall libxml2 on Rocky Linux 8
To uninstall only the libxml2
package we can use the following command:
sudo dnf remove libxml2
libxml2 Package Contents on Rocky Linux 8
/usr/bin/xmlcatalog
/usr/bin/xmllint
/usr/lib/.build-id
/usr/lib/.build-id/07
/usr/lib/.build-id/07/6c5c7aa9d4182666b640de9d185068167be80c
/usr/lib/.build-id/91
/usr/lib/.build-id/91/9f079a77caf076535e1e107a066936a23819ad
/usr/lib/.build-id/ca
/usr/lib/.build-id/ca/2b66f87ae5af68a980fb1addf41d48d9eb588b
/usr/lib64/libxml2.so.2
/usr/lib64/libxml2.so.2.9.7
/usr/share/doc/libxml2
/usr/share/doc/libxml2/AUTHORS
/usr/share/doc/libxml2/NEWS
/usr/share/doc/libxml2/README
/usr/share/doc/libxml2/TODO
/usr/share/licenses/libxml2
/usr/share/licenses/libxml2/Copyright
/usr/share/man/man1/xmlcatalog.1.gz
/usr/share/man/man1/xmllint.1.gz
/usr/share/man/man3/libxml.3.gz
/usr/bin/xmlcatalog
/usr/bin/xmllint
/usr/lib/.build-id
/usr/lib/.build-id/0e
/usr/lib/.build-id/0e/9a5c3f2fe082ec86476ea980bf80e23b898f6f
/usr/lib/.build-id/83
/usr/lib/.build-id/83/b7a949c59104dc039a9a0da81455d1061e9e2a
/usr/lib/.build-id/af
/usr/lib/.build-id/af/4502c2618f7d0ae50edd21c0ebf8ba8bf38b73
/usr/lib64/libxml2.so.2
/usr/lib64/libxml2.so.2.9.7
/usr/share/doc/libxml2
/usr/share/doc/libxml2/AUTHORS
/usr/share/doc/libxml2/NEWS
/usr/share/doc/libxml2/README
/usr/share/doc/libxml2/TODO
/usr/share/licenses/libxml2
/usr/share/licenses/libxml2/Copyright
/usr/share/man/man1/xmlcatalog.1.gz
/usr/share/man/man1/xmllint.1.gz
/usr/share/man/man3/libxml.3.gz
/usr/bin/xmlcatalog
/usr/bin/xmllint
/usr/lib/.build-id
/usr/lib/.build-id/59
/usr/lib/.build-id/59/be5a4cef8881c30846d3eba19f469f92ba3097
/usr/lib/.build-id/97
/usr/lib/.build-id/97/a619df83df44c24ebf69644c41de4b4a8d0fdd
/usr/lib/.build-id/d8
/usr/lib/.build-id/d8/8ec22d71278de10ee82b8271a3c616ede4ecec
/usr/lib/libxml2.so.2
/usr/lib/libxml2.so.2.9.7
/usr/share/doc/libxml2
/usr/share/doc/libxml2/AUTHORS
/usr/share/doc/libxml2/NEWS
/usr/share/doc/libxml2/README
/usr/share/doc/libxml2/TODO
/usr/share/licenses/libxml2
/usr/share/licenses/libxml2/Copyright
/usr/share/man/man1/xmlcatalog.1.gz
/usr/share/man/man1/xmllint.1.gz
/usr/share/man/man3/libxml.3.gz
/usr/bin/xmlcatalog
/usr/bin/xmllint
/usr/lib/.build-id
/usr/lib/.build-id/73
/usr/lib/.build-id/73/588fa95bab9641eb2dc1fe5d3b87cf2f4cbb69
/usr/lib/.build-id/e3
/usr/lib/.build-id/e3/77fb2c96461ca1c8272c3ed358afdd6d51a39b
/usr/lib/.build-id/ed
/usr/lib/.build-id/ed/2595e7f0ce3fbb5a4cbf1b4e68c947e90ab284
/usr/lib/libxml2.so.2
/usr/lib/libxml2.so.2.9.7
/usr/share/doc/libxml2
/usr/share/doc/libxml2/AUTHORS
/usr/share/doc/libxml2/NEWS
/usr/share/doc/libxml2/README
/usr/share/doc/libxml2/TODO
/usr/share/licenses/libxml2
/usr/share/licenses/libxml2/Copyright
/usr/share/man/man1/xmlcatalog.1.gz
/usr/share/man/man1/xmllint.1.gz
/usr/share/man/man3/libxml.3.gz
References
Summary
In this tutorial we learn how to install libxml2
on Rocky Linux 8 using yum and dnf.