Questions tagged [archive]

Use this tag for questions about files containing other files and/or folders, that are not covered by a more specific tag like tar, cpio, zip, rar, ar, 7z (in that case only use the specific tags). For generic questions about making security backups and rsync's archive mode, use backup.

235 questions
134
votes
10 answers

How to unzip a multipart (spanned) ZIP on Linux?

I need to upload a 400mb file to my web server, but I'm limited to 200mb uploads. My host suggested I use a spanned archive, which I've never done on Linux. I created a test in its own folder, zipping up a PDF into test.zip.001, .002, and .003. How…
Tim
  • 1,443
  • 2
  • 10
  • 5
115
votes
5 answers

How to add/update a file to an existing tar.gz archive?

Is there a way to add/update a file in a tar.gz archive? Basically, I have an archive which contains a file at /data/data/com.myapp.backup/./files/settings.txt and I'd like to pull that file from the archive (already done) and push it back into the…
Naftuli Kay
  • 38,686
  • 85
  • 220
  • 311
105
votes
8 answers

Why would I tar a single file?

At my company, we download a local development database snapshot as a db.dump.tar.gz file. The compression makes sense, but the tarball only contains a single file (db.dump). Is there any point to archiving a single file, or is .tar.gz just such a…
gardenhead
  • 1,997
  • 2
  • 12
  • 12
51
votes
8 answers

Is there a parallel file archiver (like tar)?

Is there something out there for parallel archiving of files? Tar is great, but I don't use tape archives, and it's more important to me that the archiving happens quickly (with compression like bzip2) since I have smp.
supercheetah
  • 864
  • 2
  • 8
  • 13
40
votes
4 answers

Fastest way combine many files into one (tar czf is too slow)

Currently I'm running tar czf to combine backup files. The files are in a specific directory. But the number of files is growing. Using tzr czf takes too much time (more than 20 minutes and counting). I need to combine the files more quickly and in…
Najib-botak Chin
  • 493
  • 2
  • 5
  • 7
34
votes
5 answers

View a file in a tar archive without extracting it

I want to view the content of the tarred file without extracting it, Scenario: I have a.tar and inside there is a file called ./x/y.txt. I want to view the content of y.txt without actually extracting the a.tar.
Ramji
  • 341
  • 1
  • 3
  • 3
21
votes
1 answer

tar - How to preserve timestamps down to more than a second of precision?

I am using tar to package a number of files. Modify timestamps on the files are critical, and must be of high accuracy. Using tar -cvf, timestamps are preserved but rounded to the nearest second, i.e. running stat on the files displays only…
brendon-ai
  • 321
  • 1
  • 2
  • 6
20
votes
3 answers

why should I use tar.xz instead of tar.gz? xz is a lossless data compression program and file format

Today first time in my life I saw tar.xz download. I searched the internet and found Wikipedia articles (xz and XZ Utils) Interesting quote about the users of xz xz has gained notability for compressing packages in the GNU coreutils project,[7]…
Sybil
  • 1,653
  • 5
  • 19
  • 37
19
votes
2 answers

7zip, xz, gzip, tar, etc -- what are the differences?

what factors should be considered when choosing among 7zip, xz, gzip, tar, etc. for compressing and archiving files?
Jio
  • 327
  • 1
  • 2
  • 3
19
votes
9 answers

How do I recursively grep through compressed archives?

I'm trying to find out what modules use Test::Version in cpan. So I've used minicpan to mirror it. My problem is that I need to iterate through the archives that are downloaded, and grep the files that are in the archives. Can anyone tell me how I…
xenoterracide
  • 57,918
  • 74
  • 184
  • 250
17
votes
3 answers

Create an archive with command "gzip"

I have to create an archive with the command gzip (not tar - it's necessary) and the archive should contain files from another directory - for example, /etc. I tried to use command gzip myetc.gz /etc But it didn't work.
Elisia Light
  • 401
  • 2
  • 4
  • 7
16
votes
2 answers

Remove accidentally extracted files

Possible Duplicate: How to de-unzip, de-tar -xvf — de-unarchive in a messy folder? This is a pretty annoying occurrence. Sometimes, I download an archive (tar.gz, tar.bz2, zip, rar, etc) and run tar xf [file] (or similar) in the file's directory.…
n0pe
  • 9,411
  • 13
  • 60
  • 108
15
votes
6 answers

How to de-unzip, de-tar -xvf -- de-unarchive in a messy folder?

Usually, I unarchive things by $ mkdir newFolder; $ mv *.zip newFolder; $ cd newFolder; $unzip *.zip but sometimes I get lazy and just do in an arbitrary folder $ unzip *.zip so time-to-time messing up with other content. I will list here some…
user2362
14
votes
8 answers

Is there any program to provide a consistent interface across multiple archive types?

At the moment, if I download a compressed file, it could be any of a .tar.gz archive, a tar.bz2 arhive, a .zip archive or a .gz archive. And each time I do so, I have to remember what the command line options for that program are. Is there any CLI…
Macha
  • 3,760
  • 7
  • 30
  • 35
13
votes
2 answers

Print archive file list instantly (without decompressing entire archive)

A problem with .tar.gz archives is that, when I try to just list an archive's content, the computer actually decompresses it, which would take a very long time if the file is large. Other file formats like .7z, .rar,.zip don't have this problem.…
SparedWhisle
  • 3,588
  • 4
  • 22
  • 35
1
2 3
15 16