06-19-2008
Some tools such as less will allow you to inspect the contents of some compressed files without explicitly decompressing them. Of course, behind the scenes, it is extracting the compressed data to a temporary location.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
HI
I need to import data from a file which is in comressed format
but system doesn't have enough space to uncompress file
Is there any way so that i can do import from compressed file. (4 Replies)
Discussion started by: ap_gore79
4 Replies
2. Shell Programming and Scripting
Is there a way I can check if a file is comppressed or not? (Be it tar/gzip or compress). trying to write a generic housekeeping scrit that will delete files over 6 months old and compress any uncompressed files if less than 6 months old. But not sure if there is a clever way to check except for... (4 Replies)
Discussion started by: badg3r
4 Replies
3. UNIX for Dummies Questions & Answers
I compressed a file by using gzip command
gzip <<xx>>
filename changed to xx.gz
How to view this xx.gz file. Any idea.
Thanks in advance. (7 Replies)
Discussion started by: venkatesht
7 Replies
4. Shell Programming and Scripting
Hi,
I'm trying to find all tar and compressed files (say gzip). I'm having to assume that the tar and gzip files may or may not have the correct extension (.tar .gz .tgz etc).
Any help appreciated (2 Replies)
Discussion started by: andyatit
2 Replies
5. Shell Programming and Scripting
Hi
i have a filename.tar.bz2 and i have to parse it with a tool that doesn't support compressed files.
I have to do it for many big files, so i can't decompress and then process. I'd like to do something like:
tar -jxvf namefile.tar.bz2 | parsing_tool
i mean analyze it directly,... (4 Replies)
Discussion started by: Dedalus
4 Replies
6. Shell Programming and Scripting
i have a file 4d7a94d0.bbb.1292
when i do
file 4d7a94d0.bbb.1292
the ouput is below
4d7a94d0.bbb.1292: gzip compressed data - deflate method
and i run this command
gunzip -c 4d7a94d0.bbb.1292 | awk '{gsub("\"","")}/I_ACCOUNT_ID/{print $2}' RS=":|;" FS=","
i get... (3 Replies)
Discussion started by: blackzinga80
3 Replies
7. Shell Programming and Scripting
Hi ,
I have a .gz file whose contents look like below.
data1^filename1
data2^filename2.
..
.
.
Is it possible to find out the byte offset of each record from the .gz file.
Like in an uncompressed file.
grep -nb "Filename" give the byte offset of the record in this case.
... (4 Replies)
Discussion started by: chetan.c
4 Replies
8. UNIX for Dummies Questions & Answers
Hi All,
Is there is any way to find the size of compressed file without doing decompression. The size should give the original uncompressed data size
Thanks
Arun (3 Replies)
Discussion started by: arunkumar_mca
3 Replies
9. UNIX for Dummies Questions & Answers
Hi,
I have a big (~15G) compressed file having around 170M records and I need to exclude around 4k bad records (\n in the string) .
The typical steps would have been
1. zgrep required records into new file
zgrep big15GFile.dat.gz > newBig64GFile.dat
2. zip back new file
gzip... (1 Reply)
Discussion started by: iamwha1am
1 Replies
10. Shell Programming and Scripting
Hello all,
I would like to add a file to a compressed (gzip) tarfile. Normally it won't be a Problem, if I would do it in several steps. But I do not want to have unnecessary files.
So, in words:
unzip the tarfile
add a new file
zip the tarfile
What I tried:
... (3 Replies)
Discussion started by: API
3 Replies
LEARN ABOUT LINUX
cms_uncompress
CMS_uncompress(3SSL) OpenSSL CMS_uncompress(3SSL)
NAME
CMS_uncompress - uncompress a CMS CompressedData structure
SYNOPSIS
#include <openssl/cms.h>
int CMS_uncompress(CMS_ContentInfo *cms, BIO *dcont, BIO *out, unsigned int flags);
DESCRIPTION
CMS_uncompress() extracts and uncompresses the content from a CMS CompressedData structure cms. data is a BIO to write the content to and
flags is an optional set of flags.
The dcont parameter is used in the rare case where the compressed content is detached. It will normally be set to NULL.
NOTES
The only currently supported compression algorithm is zlib: if the structure indicates the use of any other algorithm an error is returned.
If zlib support is not compiled into OpenSSL then CMS_uncompress() will always return an error.
The following flags can be passed in the flags parameter.
If the CMS_TEXT flag is set MIME headers for type text/plain are deleted from the content. If the content is not of type text/plain then an
error is returned.
RETURN VALUES
CMS_uncompress() returns either 1 for success or 0 for failure. The error can be obtained from ERR_get_error(3)
BUGS
The lack of single pass processing and the need to hold all data in memory as mentioned in CMS_verify() also applies to CMS_decompress().
SEE ALSO
ERR_get_error(3), CMS_compress(3)
HISTORY
CMS_uncompress() was added to OpenSSL 0.9.8
1.0.0e 2008-04-11 CMS_uncompress(3SSL)