Questions tagged [tar]

GNU tar creates and manipulates archives which are actually collections of many other files; the program provides users with an organized and systematic method for controlling a large amount of data.

GNU tar creates and manipulates archives which are actually collections of many other files; the program provides users with an organized and systematic method for controlling a large amount of data. The name “tar” originally came from the phrase “Tape ARchive”, but archives need not (and these days, typically do not) reside on tapes.

347 questions
2
votes
2 answers

Segmenting mysql backups using tar

In addition to using mysqldump, I've been backing up my mysql server by tarring up /var/lib/mysql for redundancy and convenience. This directory includes ibdata, ib_logfile0, and ib_logfile1 as well as some other files and a subdirectory for each of…
user1389890
  • 181
  • 2
2
votes
3 answers

UNIX ctime : how to keep this precious information in backups (tar)?

I have three questions related to the "ctime" information of a file. They are in bold (if you don't have time you can jump directly to them). A website on my dedicated server has been hacked. Lots of files have been edited. I noticed that some…
Fox
  • 992
  • 2
  • 14
  • 23
2
votes
1 answer

tar operation taking extremely long time

Wonder if anyone can help with this issue, we running RHL 5 on HP Proliant DL580 G7 it has 2xCPU @1.87GHz 6XCORES each & 64GB RAM. lately backing up a directory (62GB) with tar (tar -czvf filename.tgz /directory/to/backup) is taking up to 3…
Vladimir
  • 33
  • 1
  • 1
  • 5
2
votes
3 answers

Linux backup using tar

Im new to linux backup. Im thinking of full system backup of my linux server using tar. I came up with the following code: tar -zcvpf /archive/fullbackup.tar.gz --exclude=/archive --exclude=/mnt --exclude=/proc --exclude=/lost+found…
misamisa
  • 49
  • 1
  • 4
  • 5
2
votes
0 answers

Accident from tar -cvf, recover original file?

Possible Duplicate: Is it possible to recover filed removed by rm in linux? I'm using a RHEL6 server RAID10 with a ext4 fs, with a volumeGroup (lvm2) VolGroup00 created on a PV /dev/sda5 [831Go]. The logical volume concerned is…
Doog
  • 21
  • 2
2
votes
1 answer

Gzip command to produce exact same output than tar -cvzf?

I did thought the following commands where equivalent, but they produce different checksums: tar -cvzf ... and tar -cvf ...; gzip ... does not produce the same output. sha1sumdiffers. What would be the gzip command that would perfectly match the tar…
Olivier
  • 415
  • 3
  • 5
  • 15
2
votes
1 answer

create log for an encrypted tar

I want to create an encrypted tar but also I want to have a log of what tar has compressed, I'm using the following command: tar -cvvf - --files-from=/root/backup.cfg | openssl des3 -salt -k backuppass | dd of=/root/tmp/back.encrypted But I need to…
magiza83
  • 83
  • 2
  • 10
2
votes
1 answer

resumable tar over ssh

I'd like to use tar cf - | ssh user@hostname tar xf - to copy a very large set of files. The only problem is that it will be over a very flakey VPN link. Is it possible to somehow set up a resumable transfer like this? I would use rsync, but I'm not…
sirlark
  • 211
  • 2
  • 12
2
votes
1 answer

linux/solaris when to use tar or gtar

is it possible to know when need to use tar or gtar according to tar file for example I have some tar file as sometarfile.tar how to know if need to use tar or gtar command ? is it possible to check the tar file and according this to understand…
yael
  • 2,433
  • 5
  • 31
  • 43
2
votes
1 answer

sudoers not working for tar command

I want to disable the requirement of sudo or running as root for a bash script that does backups with tar. I added this line to my sudoers file username ALL=NOPASSWD: /bin/tar However after I added that it still shows permissions denied when I run…
bash-
  • 797
  • 2
  • 6
  • 10
2
votes
1 answer

Linux - Splitting a backup into two steps

I create a tarball using tar zcf arhive.tar.gz dir/ and this works ok. Now I wanted to split this into two simple archives, one only for images, the other -- for everything else. It seems that there's not a trivial and clean way to do this. For tar…
Mikhail
  • 160
  • 8
2
votes
1 answer

How to remove a certain folder when tar zipping?

I want to remove a folder when I'm creating a tar.gz file as it's for a backup and it takes too much space and is not required I am using the following command; tar -cvzf /home/backups/$STAMP-Earth.tar.gz /home/bukkit/ I do not want to include…
2
votes
8 answers

Deleting all executables in a directory in Linux

Before I recursively tar a directory i want to be able to delete all of the executables. In windows I would have simply deleted all of the files with .exe extensions. And I cannot simply delete all files with the executable mode since that would…
DHamrick
  • 825
  • 2
  • 9
  • 8
2
votes
4 answers

encrypt tape files with openssl and tar

I am trying to add encryption to my current tape backup scripts by piping the output through openssl, at the moment I have : tar -czpvf /dev/nst0 /home /otherdir so adding openssl gives this : tar czpvf - /home /otherdir | openssl aes-256-cbc -e…
Tim the Enchanter
  • 347
  • 2
  • 6
  • 21
2
votes
3 answers

Bandwidth-friendly backup strategy using tar?

We've used tar to backup and compress (gzip) selected directories on our file server with very good results until recently. Each and every one of our backups are stored on mirrored (RAID) harddrives and simultaneously uploaded to a Amazon S3 bucket…
Industrial
  • 1,579
  • 6
  • 24
  • 37