Tuesday, April 6, 2010

RPM: Verifying packages

Click Here For Free Windows Downloads
mywindowsdownloads.blogspot.com

Click here for all Free Linux Downloads



Blog address for Linux in Hindi


Verifying packages


During verification of package compares the information in files installed from the original package. In this process it compares the permissions, owner and group, size, type and MD5 of every file. Command rpm -V verifies the package. Few of the options are described hereunder.


To verify all installed packages:

# rpm -Va


To verify the installed package against an RPM package:


# rpm -Vp gcc-4.1.5-3.i386.rpm


The output of verification will not be displayed, if everything is properly verified. But if some discrepancies are found then they will be displayed. Format of the output is string of eight characters, including ‘c’ which denotes a configuration file, and then the file name. A single dot () will mean the test has passed. Following characters denote failure of a test:


M mode

5 MD5 checksum

L symbolic link

D device

S file size

U user

G group

T file modification time

? unreadable file


In few cases, a failure is not a big problem. For example, if we have revised our /etc/inittab file, we will see something like verification failure:


# rpm -Vf /etc/inittab

5T c /etc/inittab


Here, the checksum (error 5) changed because we changed the contents of file, and file modification (error T) changed because it was modified on time other than the installation time.


If any of the output like above is seen to us, the best judgment will be to determine that whether the package should be removed or reinstalled.

No comments:

Post a Comment