Tuesday, August 26, 2008

How to unzip a RPM file and a bz2 file on unix/linux

You may use
1. Unzip RPM file
$ rpm2cpio myrpmfile.rpm | cpio -idmv

for detailed explaination look at
http://www.cyberciti.biz/tips/how-to-extract-an-rpm-package-without-installing-it.html

2. for a bz2 file

$ bunzip2 filename.txt.bz2

To compress a file using bzip2, execute the following command:

$ bzip2 filename.txt

for more details you may visit
http://www.debianadmin.com/create-and-extract-bz2-and-gz-files.html

cheers
Vaibhav

No comments: