10 More Discussions You Might Find Interesting
1. AIX
Quick question,
is it possible to make a Tar of completely directory and placing the tar file in it (will this cause even the tar file to tarred ?)
sample:
/opt/freeware/bin/tar -cvf - /oracle | gzip > /oracle/backup.tgz
will the tar file backup.tgz also include backup.tgz ?
i tried... (5 Replies)
Discussion started by: filosophizer
5 Replies
2. UNIX for Dummies Questions & Answers
Hi Folks,
I have a directory in unix that is /usr/local/pos contain the folowing directoreis ..that is
dir1
dir2
dir3
now I want to delete only dir2 please advise how to remove the directory dir 2 ..that is rm command and how to use it , and second if I want to zip the dir3 please... (1 Reply)
Discussion started by: punpun66
1 Replies
3. Shell Programming and Scripting
Hi all,
I here have an index file ($index) which lists the full paths of some files, and am tying to use "tar" to zip all of them.
I ran a command like below,
cat $index | xargs tar -rcf $archived_file
Strangely I noticed only part of files in that index were zipped in my... (4 Replies)
Discussion started by: isaacniu
4 Replies
4. UNIX for Dummies Questions & Answers
can someone give me a script to tar files that is older than 5 days in a directory that is not something like this:
fileArray=($(find -mtime +5 asdfasdf))
tar -cvf asfadfasdfa ${fileArray}
as the Unix I'm using has some problem with ($( )), I need another way to tar files in the folder.... (1 Reply)
Discussion started by: s3270226
1 Replies
5. UNIX for Advanced & Expert Users
I want to backup all the directory tress, including hidden directories, without copying any files.
find . -type d gives the perfect list.
When I tried tar, it won't work for me because it tars all the files.
find . -type d | xargs tar -cvf a.tar
So i tried rsync.
On my own test box, the... (4 Replies)
Discussion started by: fld2007
4 Replies
6. Shell Programming and Scripting
Hi,
I am having some problem with a shell script which zip some files. For zipping I have used the following command:
find . -name "Test_*" -mtime 0 | zip Test_$(date +"%Y%m%d") -@
I have kept the script in /home/abc directory. It is creating the zip file within the same directory where i... (2 Replies)
Discussion started by: abhishek_510
2 Replies
7. Shell Programming and Scripting
Hiya,
I've been plugging away at this script and I cant get it to behave as I need.
first off it fails to adhere to the conditions of the file limit, and zips the directory regardless of the file count and secondly, but less important it zips up the entire path not just the directory I'm... (2 Replies)
Discussion started by: orionrush
2 Replies
8. Shell Programming and Scripting
Hi,
What I'm trying to do is rather easy to explain, but I don't know if it's possible.
The main idea is that I have directories which I want to add to a TAR file, but for some of them I don't want to include the files in the directory. I just want to add the path to the TAR file as if the... (5 Replies)
Discussion started by: wisobe
5 Replies
9. UNIX for Dummies Questions & Answers
I received a tar file of a directory with 50,000 files in it. Is it possible to extract the files in the tar file without first creating the directory?
ie. Doing tar -xvf filename.tar extracts as follows:
x directory/file1.txt
x directory/file2.txt
.
.
.
I would like to avoid... (4 Replies)
Discussion started by: here2learn
4 Replies
10. UNIX for Dummies Questions & Answers
If I have a directory /directory1 and want to tar and zip everything in it into a file new_tar.tar.gz on disk (not tape)
How can I do it?
I tried tar -cv /new_tar.tar /directory1/*
But I got an error: tar: /dev/rmt/0: No such device or address (4 Replies)
Discussion started by: FredSmith
4 Replies