02-12-2009
tar extract to new path
I need to extract a file,which contains the path to a new path.
sample tar file
tar -tfv class.tar | grep client
-rw------- 0/1 99 Jan 22 12:46 2004 /usr/openv/netbackup/db/class/mariner/clients
-rw------- 0/1 102 Sep 25 11:33 2007 /usr/openv/netbackup/db/class/my-prmtrc01/clients
-rw------- 0/1 101 Oct 30 13:35 2003 /usr/openv/netbackup/db/class/pmdus2/clients
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Dear All , :D
I have a question ... I need to exclude the absolute path in the TAR process.
For example :
system("tar cvf /root/BACKUPS_$fecha.tar /root/BKP/");
system("gzip /root/BACKUPS_$fecha.tar");
I need to exclude de path " /root/BKP/ " in the file.tar.gz
What is the parameter to... (1 Reply)
Discussion started by: telco
1 Replies
2. Shell Programming and Scripting
hi all,
kindly help me how to extract one file form .tar.gz without uncompressing .tar.gz file.
thanks in advance
bali (2 Replies)
Discussion started by: balireddy_77
2 Replies
3. Linux
Hi,
how can I extract glibc-2.3.2.tar.tar file ?
I used tar -xf but does not work.
Thank you. (4 Replies)
Discussion started by: big123456
4 Replies
4. Shell Programming and Scripting
Hi,
I have a environmental variables,
ORACLE_HOME=/u01/oracle/ORCL/db/tech/10.2.0
ORACLE_SID=ORCL
Now I need to create a variable and need to extract some part from ORACLE_HOME. I need to get the path from ORACLE_HOME till ORACLE_SID as /u01/oracle/ORCL. I may need to check also... (6 Replies)
Discussion started by: sreejitnair123
6 Replies
5. Shell Programming and Scripting
Hi,
Could anyone help me in writing a single line code by either using (sed, awk, perl or whatever) to extract a specific path from the PATH environment variable?
for eg: suppose the PATH is being set as follows
PATH=/usr/bin/:/usr/local/bin:/bin:/usr/sbin:/usr/bin/java:/usr/bin/perl3.4
... (2 Replies)
Discussion started by: royalibrahim
2 Replies
6. Shell Programming and Scripting
/Path/snowbird9/nrfCompMgrRave1230100920.log.gz:09/20/2010 06:14:51 ERROR Error Message.
/Path/snowbird6/nrfCompMgrRave1220100920.log.gz:09/20/2010 06:14:51 ERROR Error Message.
/Path/snowbird14/nrfCompMgrRave920100920.log.gz:09/20/2010 06:14:51 ERROR Error Message.... (0 Replies)
Discussion started by: Shirisha
0 Replies
7. UNIX for Dummies Questions & Answers
Hi
Is there any way to exclude the absolute path while using Tar , like am using the command
# tar cvf mytar.tar /home/rakesh/myback/
when i extract the mytar.tar then it shows as
/home
/rakesh
... (1 Reply)
Discussion started by: rakeshkumar
1 Replies
8. UNIX for Dummies Questions & Answers
I would like to confirm my file.tar is been tar-ed correctly before I remove them. But I have very limited disc space to untar it.
Can I just do the listing instead of actual extract it? Can I say confirm folder integrity if the listing is sucessful without problem?
tar tvf file1.tar
... (1 Reply)
Discussion started by: vivien_chu
1 Replies
9. Shell Programming and Scripting
Hi everyone;
I need to create a shell script for full and incremental backup purposes. for incremental backup only for one folder (test1) located in /home/test1 syntax below works fine and have no problem: tar -cvf /home/backup/backup-0.tar.gz -g /home/test1/test.snar /home/test Problem is here... (5 Replies)
Discussion started by: momed131
5 Replies
10. Shell Programming and Scripting
Hi All,
I am trying to create a tar from absolute path then transfer that file to another machine.
But tar is not taking the absolute (full) path.
Could you please help. I tried tar -cvf option at source and tar -xvf option at destination
My variable has 3 files with full path... (2 Replies)
Discussion started by: sdosanjh
2 Replies
BF_TAR(1) BF_TAR(1)
NAME
bf_tar - shell script to write a tar file of a bogofilter directory to stdout
SYNOPSIS
bf_tar [-r] [-R] bogofilter_directory
DESCRIPTION
bf_tar bundles a bogofilter working directory in tar format and copies it to standard output (your console, or where you redirect it, see
EXAMPLES below).
OPTIONS
The -r option causes bf_tar to remove inactive log files after the archive has been written successfully. The default is to leave log
files.
The -R option causes bf_tar to remove inactive log files before the archive is written. This may reduce chances that the resulting archive
is recoverable should it become damaged. The archive may be smaller though. The default is to leave log files.
EXIT STATUS
The script exits with status code 0 if everything went well, and nonzero if it encountered trouble.
EXAMPLES
o bf_tar ~/.bogofilter > outfile.tar
Writes a standard .tar file containing the essential files from ~/.bogofilter to outfile.tar.
o bf_tar ~/.bogofilter | gzip -9 -c > outfile.tar.gz
Writes a gzipped .tar.gz file containing the essential files from ~/.bogofilter to outfile.tar.gz.
o bf_tar `pwd`/mydirectory > outfile.tar
Prepend $(pwd)/ or `pwd`/ if you want to specify an absolute path instead of a relative path.
NOTES
This script is meant for use with Berkeley DB based bogofilter versions.
This script requires a SUSv2 compliant pax utility.
This script expects a SUSv2 compliant shell. Solaris systems should have the SUNWxcu4 package installed (when bogofilter is configured) so
that /usr/xpg4/bin/sh can be used.
07/23/2007 BF_TAR(1)