Questions tagged [bzip2]
40 questions
238
votes
4 answers
Why are tar archive formats switching to xz compression to replace bzip2 and what about gzip?
More and more tar archives use the xz format based on LZMA2 for compression instead of the traditional bzip2(bz2) compression. In fact kernel.org made a late "Good-bye bzip2" announcement, 27th Dec. 2013, indicating kernel sources would from this…
user44370
40
votes
1 answer
What happened to bzip1?
bzip2 had been a de facto standard for quite strong compression throughout many years already. I myself had typed the bzip2 command thousands of times so far, which makes me wonder - what happened to bzip, or bzip1? Google doesn't seem to tell me…
d33tah
- 1,361
- 14
- 28
19
votes
5 answers
Compress a large number of large files fast
I have about 200 GB of log data generated daily, distributed among about 150 different log files.
I have a script that moves the files to a temporary location and does a tar-bz2 on the temporary directory.
I get good results as 200 GB logs are…
anu
- 332
- 1
- 2
- 8
13
votes
2 answers
How to check/test .tar.bz archives?
I've been using tar with its "--use-compress-prog=pbzip2" function to archive my files then compress them with pbzip2 to get an "*.tar.bz" archive.
Afterwards I checked the resulting file with pbzip2's "-t" switch, and it passed the test. However,…
hpy
- 4,517
- 8
- 53
- 73
12
votes
3 answers
bunzip2 to a different directory
Say I have a file foo.tbz2 in a directory. I want to extract the tar file from the archive, but to a different directory. It seems like bunzip2 will only extract the archive to the same directory as the archive.
This works, but I'm wondering if…
longneck
- 410
- 2
- 4
- 11
7
votes
2 answers
How to bzip a file with minimum cpu percentage?
I am using bzip2 to compress a file,the process takes more that 100% cpu.Is there any way to run bzip2 with minimum CPU precentage.
dddddd
7
votes
1 answer
Is there a compression tool with an arbitrarily large dictionary?
I am looking for a compression tool with an arbitrarily large dictionary (and "block size"). Let me explain by way of examples.
First let us create 32MB random data and then concatenate it to itself to make a file of twice the length of length…
Simd
- 325
- 1
- 2
- 11
7
votes
2 answers
bzip2: Check file's decompressed size without actually decompressing it
I have a big bzip2 compressed file and I need to check it's decompressed size without actually decompressing it (similar to gzip -l file.gz or xz -l file.xz). How can this be done using bzip2?
manifestor
- 2,423
- 6
- 22
- 47
7
votes
1 answer
Can files compressed with bzip2 be relied upon to be deterministic (reproducible)?
I am trying to determine if there are any potential issues using bzip2 to compress files that need to be 100% reproducible. Specifically: can metadata (name / inode, lastmod date, etc) or anything else cause identical file contents to produce a…
Jonathan Cross
- 248
- 1
- 10
7
votes
2 answers
How to extract a single file from tbz
I have the following archived directory:
itunes20140618.tbz
I want to extract single file from it called:
itunes20140618/video
How would I do this?
So far, I am doing
$ bzip2 -d /tmp/itunes20140618.tbz
But it seems to create a tar directory of…
David542
- 333
- 2
- 3
- 11
6
votes
1 answer
Why bzip2 --version behaves strange?
So if I enter the command
$ gzip --version | head -n1
everything goes as expected. But if I try the same with bzip2:
$ bzip2 --version | head -n1
I get a lot of lines and I have to press Ctrl-C to terminate.
What is happening here?
EDIT:
The lines…
Msegade
- 572
- 1
- 4
- 13
4
votes
8 answers
Triple compression and I only save 1% in space?
I've been trying to save space on my linux server, and I had a folder containting, in subfolders, 22GB of images.
So I decided to compress them.
First I used tar:
tar -zcf folder.tar folder
Then gzip
gzip folder
And finally, for good measure,…
ACarter
- 389
- 1
- 4
- 11
4
votes
1 answer
Can I somehow update compressed archives?
I'm trying to find all files with given extension but I'm getting this error:
tar: Cannot update compressed archives
Try 'tar --help' or 'tar --usage' for more information.
tar: Cannot update compressed archives
Try 'tar --help' or 'tar --usage' for…
pnom
- 297
- 1
- 3
- 8
4
votes
1 answer
Is it possible to get file list, byte range from the head of a tar+bzip2 file?
Essentially, I'm hoping someone with an advanced knowledge of tar/bz2 can answer whether this is possible.
The situation is that we have a periodic 24GB feed of data from a vendor, as a .tbz file. (tar+bzip2). This is downloaded from the vendor via…
Excalibur
- 255
- 2
- 7
3
votes
2 answers
tar exits with bzip2: (stdin): trailing garbage after EOF ignored after extract
I have extracted a large (3.9GB) tar.bz2 file using the following command:
tar -xjvf archive.tar.bz2
The extract proceeds fines but exits printing:
bzip2: (stdin): trailing garbage after EOF ignored
Is there a problem with the archive/extract? Has…
avanwyk
- 133
- 1
- 4