To prevent uncomfortable surprises, xz has a built-in memory usage limiter, which is disabled by default. xz files that require several gigabytes of memory to decompress.Įspecially users of older systems may find the possibility of very large memory usage annoying. For example, decompressing a file created with xz -9 currently requires 65 MiB of memory. Typically the decompressor needs 5 % to 20 % of the amount of memory that the compressor needed when creating the file. The settings used when compressing a file determine the memory requirements of the decompressor. The memory usage of xz varies from a few hundred kilobytes to several gigabytes depending on the compression settings. This has only limited use since when standard error is a terminal, using -verbose will display an automatically updating progress indicator. Sending SIGINFO or SIGUSR1 to the xz process makes it print progress information to standard error. The source file is never removed if the output is written to standard output or if an error occurs. Once the target file has been successfully closed, the source file is removed unless -keep was specified. xz doesn't support copying other metadata like access control lists or extended attributes yet. If copying the group fails, the permissions are modified so that the target file doesn't become accessible to users who didn't have permission to access the source file. lz).Īfter successfully compressing or decompressing the file, xz copies the owner, group, permissions, access time, and modification time from the source file to the target file. The operation mode is set to decompress and the file doesn't have a suffix of any of the supported file formats (.The operation mode is set to compress and the file already has a suffix of the target file format (.File has setuid, setgid, or sticky bit set.Symbolic links are not followed, and thus they are not considered to be regular files. Unless writing to standard output, xz will display a warning and skip the file if any of the following applies: If the target file already exists, an error is displayed and the file is skipped. lz suffix is removed from the filename to get the target filename. lzma) is appended to the source filename to get the target filename. When compressing, the suffix of the target file format (.Unless -stdout is specified, files other than - are written to a new file whose name is derived from the source file name: Similarly, xz will refuse to read compressed data from standard input if it is a terminal. xz will refuse (display an error and skip the file) to write compressed data to standard output if it is a terminal. If no files are given or file is -, xz reads from standard input and writes the processed data to standard output. Xz compresses or decompresses each file according to the selected operation mode. lzma format used by LZMA Utils and raw compressed streams with no container format headers are also supported. Xz is a general-purpose data compression tool with command line syntax similar to gzip(1) and bzip2(1). When writing scripts that need to decompress files, it is recommended to always use the name xz with appropriate arguments ( xz -d or xz - d c) instead of the names unxz and xzcat. Lzcat is equivalent to xz -format=lzma -decompress -stdout. Unlzma is equivalent to xz -format=lzma -decompress. Xzcat is equivalent to xz -decompress -stdout. Compress a file using the best compression: xz -9 path/to/file.Compress a file using the fastest compression: xz -0 path/to/file.Compress a file, but don't delete the original: xz -k path/to/file.Decompress a file and write to stdout: xz - d c file.xz.Decompress an LZMA file: xz -d -format= lzma file.lzma.Compress a file to the LZMA file format: xz -format= lzma path/to/file.Compress a file to the xz file format: xz path/to/file.Basic file format and compression optionsĬompress or decompress.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |