BIP KB Tag: Extract

How To Extract The Contents Of An RPM File

Sometimes it can be useful to extract the contents of an RPM file without actually installing it. In order to do so, use the following command: rpm2cpio file.rpm | cpio -idmv Please Note: This will extract the rpm into whatever directory you are in, including all of it's sub-directories. So for example, if you change directory into / and run the command above the rpm will be extracted and files/directories placed just...
By tasia, January 24, 2015


How To Extract A User List From Your Linux System

Here is a simple way to extract the User Name and full name for all the users on your Linux system. Both methods divide the /etc/passwd file into columns and print column 1 and 5 where ":" is used as a common delimiter. Column 1 contains the username and column 5 contains the full name. Using awk: BEGIN { FS=":" } { print $1 "\t" $5 } save this as extractnames.awk . Now execute awk and include this file: $ awk ...
By kevin, June 26, 2015