`gzip` (or GNU zip) is a file format and corresponding utility for compressing files using the DEFLATE algorithm. The usual extension is `.gz`.

learn more… | top users | synonyms

0
votes
1answer
29 views

Cannot unzip xymon-4.3.18.tar.gz; “No such file or directory” error

I have a problem unzipping an archive. ubuntu:~% sudo gzip -dc xymon-4.3.18.tar.gz | tar xf - gzip: xymon-4.3.18.tar.gz: No such file or directory tar: This does not look like a tar archive tar: ...
0
votes
0answers
6 views

How to disable mod_deflate in a subdirectoy using htaccess

I have a site that mod_deflate and gzip breaks a script in a subdirectoy. I am on a shared host. Is it possible to use compression on the root level and disable it on a specific subdirectory using ...
0
votes
1answer
27 views

dd , pv , gzip and exclude directory, possible?

Is it possible to do the following: dd if=/dev/hdx | pv | gzip > /path/to/image.img\ --exclude=/temp --exclude=/lost+found --exclude=/proc --exclude=/path/to/image.img So I want to make a backup ...
3
votes
2answers
30 views

How to tell of a GZip file is still being written while being copied

I am getting a gzip file in a path. Input Folder Path: <server>/input_gate I want to check whether the GZIP file I am getting in this folder are valid? I have used the following command. It ...
3
votes
2answers
67 views

Is Gzip supposed to honor original filename during decompress?

This question stems from a Crypto++ library question on Stack Overflow: How to add filename to archive if compressing using Gzip class?. Gzip, as specified in RFC 1952 has an optional field for the ...
1
vote
1answer
47 views

How to extract single file from large tar/tar.gz file

What I want to do is to extract a single file from a huge tar file, instead of extracting the whole tar. I am using RHEL 6.4 I Googled it and tried the following: tar --extract --file=some.tar ...
1
vote
0answers
12 views

canot restore disk image with dd (target part filled with zero)

I have a RAID0 disk before, now I want change the size of it. From the manual, the only way is backup data, delete RAID, re-create with new size, and restore data. now I have many old 2.5" hdd, each ...
3
votes
1answer
195 views

Not sure gzip has decompressed the whole file

I am decompressing a list of files using gzip: At any time it skips from one file to the next, I read (I am using the verbose option): star_60out.txt.gz: 91.0% -- replaced with star_60out.txt or ...
0
votes
1answer
65 views

extracting multiple .gz files, and printing the name of the extracted file

I would think this is easy but I'm blocking… I have a directory with a series of log files (from minecraft server…): 2014-09-28-1.log.gz 2014-09-29-1.log.gz 2014-09-30-1.log.gz 2014-10-01-1.log.gz ...
1
vote
2answers
88 views

Gzip thousands of files efficiently in a single pass

I want to gzip the contents of a couple of thousand of tiny files into a single file. While I could do it with something like for file in $(find . -iname 'pattern'); do; cat $file | gzip - >> ...
0
votes
1answer
28 views

can't open .gzip archives retrieved with wget

I'm trying to download the content of a directory hosted on a server using wget in a cygwin terminal. I have no problem getting the files but they are all .gz archive and once downloaded they are ...
0
votes
1answer
43 views

how to extract lots of gz files in windows

I have 36,348 .gz files. I need to extract them all the same directory. In unix I would use gunzip and so forth from the shell. How would I do it on my windows 7 machine? I can't even get winrar to ...
0
votes
0answers
24 views

Is there any way to have the `split` utility gzip its output by default?

I'd like to be able to do something like, my_long_running_process_producing_lots_of_output | split --gzip --lines 1000000 - part_ and have this produce things like part_aa.gz part_ab.gz instead ...
1
vote
1answer
131 views

Running find…exec tar czvf only archives one file…need all files

When attempting to run find . -iname "*.gz" -mtime +7 -exec tar czvf all_gizip_$(date +%Y-%m-%d).tar.gz {} \; I get the list of files ./corosync.log-20140620.gz ./corosync.log-20140618.gz ...
0
votes
0answers
47 views

List contents of zip archive via stdin

Is there a "magic" way to list the contents of a Zip archive piped in via stdin? For instance: $ some_process_sending_files_in_one_zip_stream_to_stdout | gunzip -l - ... listing of files ... When ...
1
vote
1answer
35 views

How to revert a “gzip -r folder/” command?

I accidentally compressed all the files using the Gzip method which compresses all the files (not directories) individually, replacing the uncompressed files with the .gz compressed files. How can I ...
54
votes
2answers
4k views

Why is piping 'dd' through gzip so much faster than a direct copy?

I wanted to backup a path from a computer in my network to another computer in the same network over a 100 Mbit/s line. For this I did dd if=/local/path ...
0
votes
1answer
764 views

How to compress a large file to many smaller zip files with defined size?

I have a very large file, e.g. 100GB, and I want to compress it to many smaller zip file, with each file cannot larger than 1GB, what would be the most suitable commands to do it? remark: I want to ...
0
votes
0answers
78 views

GZIP corruption with big files?

I came across a weird behavior: gzip v1.5 - Fedora r18 A file -rwxrwxrwx. 1 root root 3892576256 Apr 28 11:29 vm.qcow2 Initial checksum: md5sum vm.qow2 954c5461468d68daed3cef6a7b66bd8f vm.qcow2 ...
1
vote
1answer
72 views

Need help in the shell script - gunzip and file command

This is on Ubuntu 12.04. I have a custom webkit based application where "browser" saves bunch of cache files. When triaging the problems, I have to inspect the cache. The cache directory holds many ...
3
votes
1answer
92 views

Why does tar with -z option create archive with different hash everytime

Can you tell me why tar czf archive.tar dir creates archive with different hash everytime (I check with 'md5sum') Without compression parameter -z or with parameter -j instead all works fine. ...
0
votes
1answer
84 views

Concatenate header of one file with tail of another

I have a large gzipped mysqldump file which contains some table definitions and then many insert statements. I'd like to edit the table definitions but leave the insert statements alone. The file is ...
0
votes
0answers
114 views

Error uncompressing file when piping curl to gunzip

I need to download a gzipped xml feed to parse in my Ruby app. It may well be quite large, 30Mb compressed, 300Mb uncompressed. So I do this: curl -s http://example.com/file.xml.gz | gunzip and read ...
0
votes
1answer
20 views

Copying Jar files into single zip file

I am trying to compress the hundreds of jar files into a single zip file that can be transferred to a different location. Please help.
0
votes
1answer
81 views

Tar up only 3 specific files in command line with linux

Is it possible with one command to tar up 3 files into one tar archive? For example, tar up: public_html.tar.gz dbapp.sql dbwp.sql into a tar file called bak.tar.gz
1
vote
2answers
89 views

Search zipped *and* non-zipped files in one hit

I have a folder with a mix of zipped and unzipped log files which i want to search. I can search the non-zipped with grep -r "my-search-string" /path/to/folder and search the zipped files with ...
0
votes
1answer
53 views

dd a partition and keep device structure

How can I dd a partition while keeping its device structure? Source device: [root@cal-7-3 ~]# lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 37.3G 0 disk └─sda1 8:1 0 ...
2
votes
2answers
213 views

Compressing compressed .tar.gz files deterministically

I want to perform a series of recompressions of compressed files to study their properties. At first, I tried simply recompressing .zip files in a loop: for f in $(seq 1 100) do zip $f.zip -9 -v ...
1
vote
1answer
194 views

How to convert a file of format tar.gz to tar.bz2?

Like the title says, how do I do this conversion from the Linux console?
0
votes
2answers
91 views

rsync: gzip on source tolerant

I need to transfer a couple of log-files each hour to a logstorage which all users can reach, and I use rsync for do that, but the problem comes when the log-file is rotated and automatically zipped, ...
0
votes
0answers
400 views

Caveats with gzip --rsyncable - no speedup

I am using (trying) gzip to compress an SQL file in an rsyncable way in order to transfer the backup with minimal delay. However it appears that this is not working, since the speedup is always 1.00. ...
0
votes
3answers
211 views

What are good compression algorithms for delta synchronization?

When syncing large files over a slow link, it is often useful to use delta compression in order to reduce the bandwidth used. It is also useful to compress files as they take up much less space. ...
0
votes
0answers
41 views

Gzip, firmware problems

I am trying to unpackage firmware. The file command gives me this. gzip compressed data, ASCII, has CRC, extra field gzip -d gzip.gz gives this. gzip: gzip.gz has flags 0xcf -- not supported Any ...
3
votes
2answers
2k views

How can I get the uncompressed size of gzip file without actually decompressing it?

Please find my OS details: $ uname -a AIX xxyy 1 6 000145364C00 I've tried the following command to get size of a file in gzip archive: $ gzip -l mycontent.DAT.Gz compressed uncompr. ratio ...
10
votes
3answers
2k views

Files with same content but with different md5sums when gzip'd?

I don't know why this is happening, but I upload some files to Amazon S3 then delete the sent files checking their md5sum both in Amazon and locally. But recently I found this issue about the same ...
1
vote
2answers
112 views

How to extract such a compressed file?

I have been asked to extract a ZIP file having in it 3 tar files and each tar file contains around 3000 gz files. I had to extract the main ZIP file first then extract the tar files second then ...
2
votes
1answer
446 views

Do curl and wget open gzipped files automatically?

I made two http calls to the same gzipped resource from two different machines - RHEL and OSX. curl http://example.com/file.gz The first call returned an expected binary output: /�IQ���} The ...
-2
votes
4answers
107 views

“.gz” extension somehow appended itself to EVERY FILE on my site… how do I undo it?

Somehow I accidentally appended the extension .gz to ALL files in my entire website directory. How do I undo this? I need them to retain their original file extensions (EG: picture.jpg.gz -> ...
4
votes
3answers
2k views

Why is gzip slow despite CPU and hard drive performance not being maxed out?

I have some JSON files, 20 GB each, that I want to compress with gzip: gzip file1.json This takes up one full CPU core, all fine. It processes around 25 MB/s (checked in atop), my hard drive can ...
6
votes
2answers
6k views

Time to zip very large (100G) files

I find myself having to compress a number of very large files (80-ish GB), and I am surprised at the (lack of) speed my system is exhibiting. I get about 500 MB / min conversion speed; using top, I ...
0
votes
2answers
558 views

What is the difference in various commands for compressing files in linux?

What are the commands for compressing files in linux and what are the difference between them? (for example: tar, gzip, rar). I'm working on Linux Mint 11 and doing a script for compressing files. I ...
5
votes
2answers
5k views

Is there a way to force gzip not to overwrite files on conflict?

I'm writing a script in which I'm gzipping files. There's a possibility that I might zip a file, create a file of the same name, and try to gzip this as well, e.g. $ ls -l archive/ total 4 ...
1
vote
3answers
4k views

Between xz, gzip, and bzip2, which compression algorithim is the most efficient?

Between xz, gzip, and bzip2, which compression algorithm gives the smallest file size and fastest speed when compressing fairly large tarballs?
2
votes
2answers
3k views

gzip several files in different directories and copy to new directory

I'm working with several files that are located in different directories that I need to compress into individual .gz files. I also need to move the compressed files to a single directory while leaving ...
1
vote
3answers
548 views

What is the equivalent unix command to a Mac OSX “Compress” menu action?

When I right-click a file in Mac OSX and select "Compress 'File Name'", what is the equivalent bash or terminal command to get the same result? Is it just gzip -9 /path/to/filename?
3
votes
2answers
6k views

.tgz file- tar: Unrecognized archive format

I'm trying to install a 10gen build of mongodb on my local mac running Mountain Lion (10.8.3): I fetch it with curl at: curl http://downloads.mongodb.org/osx/mongodb-osx-x86_64-2.4.tgz > ...
2
votes
1answer
651 views

Why is ZFS gzip-9 compression so much worse than actually using zip files?

I am working with some very large packet capture files (~150GB across 30 files) but because of how highly redundant packet captures are, these compress to ~7% (14.29x) of their originally file size ...
0
votes
1answer
38 views

Removind same *.tar.gz archives

I have crontab event archives to .tar.gz some folder every N hours. Finally I have collection of .tar.gz files. Now I want remove duplicating archives (created while target files stays unchanged) How ...
0
votes
0answers
34 views

Is there an older version of gzip that returns different/larger outputs?

I don't know how else to phrase this question, but I stumbled upon a file which I know from the header is gzipped (1F8B0800) but I am unable to recreate the file no matter what I try (including gzip ...
0
votes
1answer
776 views

One-click to create and extract .tar.gz files in Windows?

I'm using 7-zip latest alpha version (9.30) and I find it really inconvenient that, if I want to create a .tar.gz archive, I have to create a .tar archive first then add it to a .gz archive later. So ...