New answers tagged compression
The most straightforward way is: tar cfz bigtar.tar.gz /path/to/file1 /path/to/file2 ... /path/to/file20 If there are matchable similarities between the target files, you could use find to create the files list and GNU tar's -T (--files-from). e.g. if they're all .mp4 files: find /path -type -f -iname '*.mp4' | tar cf bigtar.tar -T - Otherwise, if ...
If they are on the same filesystem, you could hard-link those to a common directory and tar that directory. Alternatively, if you are using GNU tar, you could (with a little more flexibility) soft-link those to a common directory and using its -h option, tar the files which the soft-links point to. The manual page for the latter shows: -h, ...
The correct syntax is: 7z a isos.7z *.iso or 7z a isos.7z chakra-2015.11-fermi-x86_64.iso openSUSE-Leap-42.1-DVD-x86_64.iso PCBSD10.2-RELEASE-08-19-2015-x64-DVD-USB.iso Sabayon_Linux_15.11_amd64_MATE.iso
gzip already checks it. if ! gunzip FILENAME echo "crc error" fi
Yes, you can do that in the pipeline, without having to read the whole file. This first script fragment illustrates the mechanism by which we will intercept and inspect the header and pass it on. Notice that we print the header to stderr (>&2), yet it continues to appear in the output: $ echo 0123456789ABCDEF | ( HEADER=$(dd bs=1 count=4); ...
Use file on the sending machine and use that info to decide which decompression command to run on the remote host. e.g. #! /bin/sh filetype=$(file misteryCompressedFile) case "$filetype" in *gzip*) CMD='gzip' ; ARGS='-d -fc' ;; *bzip2*) CMD='bzip2' ; ARGS='-d -fc' ;; *) echo "error: unknown compression type" ; exit 1 ;; esac cat ...
tar is like a zip file that stores a bunch of other files, but doesn't compress them. bzip2 compresses a file, but only one at a time. A .tar.bz2 file likely indicates a bunch of files were put in a tar and subsequently zipped. You can't zip them together without tarring them, first. Your error is because your .tar.bz2 file is corrupt. See an example of ...
User @tino commented below the openssl answer but I think this should be separate: zlib-flate -uncompress < FILE I tried this and it worked for me. zlib-flate can be found in the qpdf package (in Debian Squeeze and Fedora 23, according to comments in other answers)
It seems that only approach left is stacking a compressing filesystem on top of encrypting filesystem. Here are few options, but I do not have hands on experience with them: FuseCompress hosted on GitHub SquashFS, JFFS2, or some combination described on LWN I doubt that you can select compression or encryption per file. Btrfs is supposed to offer that ...
Top 50 recent answers are included