First of all you must know which file you want to extract. That you can know by # tar -ztvf <tar name> or # tar -jtvf <tar name>. It will list you all the file name and there entire path. Suppose you want to extract /etc/httpd/httpd.conf, then go to any temp folder and give the command # tar -zxvf <sample.tar.gz> etc/httpd/httpd.conf. or # tar -jxvf <sample.tar.bz2> etc/httpd/httpd.conf. Imp Note:- Dont give "/" in front of etc while extracting file, otherwise it will overwrite your existing /etc/httpd/httpd.conf. Mubeen Nakade.
--- On Sat, 6/12/08, Neelesh Raje <[EMAIL PROTECTED]> wrote: From: Neelesh Raje <[EMAIL PROTECTED]> Subject: [LinuxVadaPav] TAR To: [EMAIL PROTECTED], [EMAIL PROTECTED], [EMAIL PROTECTED], [EMAIL PROTECTED], [EMAIL PROTECTED], "linux_ipsr" <[EMAIL PROTECTED]>, "linuxvadapav" <linuxvadapav@yahoogroups.com>, [EMAIL PROTECTED] Date: Saturday, 6 December, 2008, 2:53 PM Dear all, 1How to extract only one folder and file from tar.gz and tar.bz2 file. regards neelesh Connect with friends all over the world. Get Yahoo! India Messenger at http://in.messenger .yahoo.com/ ?wm=n/ [Non-text portions of this message have been removed] Add more friends to your messenger and enjoy! Go to http://messenger.yahoo.com/invite/ [Non-text portions of this message have been removed]