How To Install lockdev on Rocky Linux 8

In this tutorial we learn how to install lockdev on Rocky Linux 8. lockdev is A library for locking devices

Introduction

In this tutorial we learn how to install lockdev on Rocky Linux 8.

What is lockdev

Lockdev provides a reliable way to put an exclusive lock to devices using both FSSTND and SVr4 methods.

We can use yum or dnf to install lockdev on Rocky Linux 8. In this tutorial we discuss both methods but you only need to choose one of method to install lockdev.

Install lockdev 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 lockdev using dnf by running the following command:

sudo dnf -y install lockdev

Install lockdev 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 lockdev using yum by running the following command:

sudo yum -y install lockdev

How To Uninstall lockdev on Rocky Linux 8

To uninstall only the lockdev package we can use the following command:

sudo dnf remove lockdev

lockdev Package Contents on Rocky Linux 8

/run/lock/lockdev
/usr/lib/.build-id
/usr/lib/.build-id/00
/usr/lib/.build-id/00/54302bc072ce4047e274fcff46604495b0cbbf
/usr/lib/.build-id/b1
/usr/lib/.build-id/b1/3259133e31a823c691af772cab1429fe143af8
/usr/lib/tmpfiles.d/lockdev.conf
/usr/lib64/liblockdev.so.1
/usr/lib64/liblockdev.so.1.0.0
/usr/sbin/lockdev
/usr/share/doc/lockdev
/usr/share/doc/lockdev/AUTHORS
/usr/share/licenses/lockdev
/usr/share/licenses/lockdev/COPYING
/usr/share/man/man8/lockdev.8.gz
/run/lock/lockdev
/usr/lib/.build-id
/usr/lib/.build-id/01
/usr/lib/.build-id/01/9b463da9fa0df241584bda83e5d4d04fc4f0b6
/usr/lib/.build-id/75
/usr/lib/.build-id/75/9e00f02793ecf941514177ccaa7bcf608a8ff9
/usr/lib/liblockdev.so.1
/usr/lib/liblockdev.so.1.0.0
/usr/lib/tmpfiles.d/lockdev.conf
/usr/sbin/lockdev
/usr/share/doc/lockdev
/usr/share/doc/lockdev/AUTHORS
/usr/share/licenses/lockdev
/usr/share/licenses/lockdev/COPYING
/usr/share/man/man8/lockdev.8.gz

References

Summary

In this tutorial we learn how to install lockdev on Rocky Linux 8 using yum and dnf.