Tag Info

New answers tagged

2

Both traditional archiving tools tar and cpio preserve ownership and Unix permissions (user/group/other) as well as timestamps (with cpio, be sure to pass -m when extracting). If you don't like their arcane syntax┬╣, you can use their POSIX replacement pax (pax -w -pe) All of these output an uncompressed archive; pipe the archive into a tool like gzip or xz ...


2

If you're talking about linux systems then another option for you is squashfs. It can often achieve very high compression ratios - and the compression process itself is multi-threaded - which means that you can apply all processor cores to the compression task. A squashfs archive differs from most other kinds in that it is a file-system. If you've ever ...


4

Yes. tar retains the owner and permissions. Wikipedia: tar The archive data sets created by tar contain various file system parameters, such as time stamps, ownership, file access permissions, and directory organization.


2

The -C flag enables a gzip compression of an SSH stream. It's an equivalent of Accept-Encoding: gzip in HTTP. How the flag that performs depends on a kind of data you transfer: When transferring a single large file, the performance would be near the same to zipping the file before the transfer (neglecting efficiency of zip vs. gzip algorithm). But using ...


6

It enables the gzip compression in ssh (under the scp). On slow connections this will speed things up, on any reasonably fast connection ( 100Mbit or faster) the compression is very likely to slow things down. It will be more or less efficient than zip based on whether gzip (specifically gzip -6) would be more or less efficient than your chosen zip ...


7

It's never really going to make any big difference, but zipping the file before copying it ought to be a little bit less efficient since using a container format such as zip that can encapsulate multiple files (like tar) is unnecessary and it is not possible to stream zip input and output (so you need a temporary file). Using gzip on the other hand, instead ...


2

I cobbled together some python to do what you want. It uses python's tarfile library to append stdin to a tar file, and then simply seeks back in the tar to rewrite the header with the right size at eof. The usage would be: rm -f mytar for db in $dbs do mysqldump ... $db | gzip -c | tarappend -t mytar -f mysql-backup-$db.gz done tar tvf mytar Here's ...


1

No, and I miss that feature so much: my question on Ask Ubuntu. If the file to be archived is a raw file with no filesystem metadata associated to it, tar doesn't have neither a filename nor a path necessary to build the internal directories / files tree (to say the least). I think that something can be done in Perl, which has some library dedicated to ...


0

You could consider using the tardy tar post-processor. However, you might question the use of tar and consider some other ways to archive your things. In particular consider rsync and afio Notice that mysqldump understands the --export-all option (see this). You might pipe that into some script understanding the boundaries, etc...


4

Not easily. tar records not only file contents, but also file metadata (name, timestamps, permissions, owner and such). That information has to come from somewhere, and it won't be there in a pipe. You could gzip your database dumps to a file (probably named for the database in question), append the file to a tar archive and then delete the file before ...


3

You can encode flac to flac. Not sure how much the compression level will help, though. I tested with a voice message recorded by my IP phone. for level in {0..8} do flac --verify -$level -o tam818.$level.flac tam818.flac done Result: $ stat -c '%s %n' *.flac | sort 232049 tam818.8.flac 232406 tam818.7.flac 232845 tam818.6.flac 233596 tam818.5.flac ...


0

File Roller (the GNOME application whose variant/fork/whatever-you-call-it you use) depends on zip. That should not be the case - according to the fileroller news page, p7zip is used to create zip archives since version 2.23.4 - see this somewhat outdated fileroller news page. It's also stated on 7-Zip's Wiki page: 7-Zip supports: The 256-bit ...



Top 50 recent answers are included