1bzip3(1) General Commands Manual bzip3(1)
2
3
4
6 bzip3 - an efficient statistical file compressor and spiritual succes‐
7 sor to bzip2
8
9
11 bzip3 [ -BbcdehftV ] [ filenames ... ]
12
13 bz3cat is equivalent to bzip3 -dc
14
15 bunzip3 is equivalent to bzip3 -d
16
18 Compress or decompress a file using run length encoding and Lempel Ziv
19 prediction, followed by the Burrows-Wheeler transform and arithmetic
20 coding. bzip3, like its ancestor bzip2, excels at compressing text or
21 source code.
22
23 The command-line options are deliberately very similar to those of
24 bzip2, but they are not identical.
25
26 bzip3 expects at most two filenames intertwined with flags. bzip3 will
27 by default not overwrite existing files. If this behaviour is in‐
28 tended, use the -f flag.
29
30 If no file names are specified, bzip3 will compress from standard input
31 to standard output, refusing to output binary data to a terminal. The
32 -e flag (encode) is implied.
33
34 bunzip3 (or, bzip3 -d equivalently) decompresses data from standard in‐
35 put to the standard output, refusing to read from a terminal.
36
37 If two files are specified, the first one is used in place of standard
38 input, and the second one is used in place of standard output.
39
40 If the -c flag is present, bzip3 will read from the specified file and
41 output data to standard output instead. Otherwise, if decoding, bzip3
42 will try to guess the decompressed filename by removing the .bz3 exten‐
43 sion. If not present, an error will be reported. If encoding, the out‐
44 put filename will be generated by appending the .bz3 extension to the
45 input filename.
46
47
49 -B --batch
50 Enable batch mode. By default, bzip3 will error if more than two
51 files are passed, and the two files specified are always treated
52 as input and output. The batch mode makes bzip3 treat every file
53 as input, so for example bzip3 -Bd *.bz3 will decompress all
54 .bz3 files in the current directory.
55
56 -b --block N
57 Set the block size to N mebibytes. The minimum is 1MiB, the max‐
58 imum is 511MiB.
59
60 -c --stdout
61 Force writing output data to the standard output if one file is
62 specified.
63
64 -d --decode
65 Force decompression.
66
67 -e/-z --encode
68 Force compression (default behaviour).
69
70 -f --force
71 Overwrite existing files.
72
73 -h --help
74 Display a help message and exit.
75
76 -j --jobs N
77 Set the amount of parallel worker threads that process one block
78 each.
79
80 -k --keep
81 Keep (don't delete) the input files. Set by default, provided
82 only for compatibility with other compressors.
83
84 -v --verbose
85 Set verbose output mode to see compression statistics.
86
87 -V --version
88 Display version information and exit.
89
90 -t --test
91 Verify the validity of compressed blocks.
92
93 -- Treat all subsequent arguments as file names, even if they start
94 with a dash. This is so you can handle files with names begin‐
95 ning with a dash.
96
98 Compression is performed as long as the input block is longer than 64
99 bytes. Otherwise, it's coded as a literal block. In all other cases,
100 the compressed data is written to the file. The file format has con‐
101 stant overhead of 9 bytes per file and from 9 to 17 bytes per block.
102 Random data is coded so that expansion is generally under 0.8%.
103
104 bzip3 uses 32-bit CRC to ensure that the decompressed version of a file
105 is identical to the original. This guards against corruption of the
106 compressed data.
107
108
110 The -b flag sets the block size in mebibytes (MiB). The default is 16
111 MiB. Compression and decompression memory usage can be estimated as:
112
113 6 x block size
114
115 Larger block sizes usually give rapidly diminishing returns. It is
116 also important to appreciate that the decompression memory requirement
117 is set at compression time by the choice of block size. In general,
118 try and use the largest block size memory constraints allow, since that
119 maximises the compression achieved. Compression and decompression
120 speed are virtually unaffected by block size.
121
122
124 Kamila Szewczyk, kspalaiologos@gmail.com.
125
126 https://github.com/kspalaiologos/bzip3
127
128 Thanks to: Ilya Grebnov, Benjamin Strachan, Caleb Maclennan, Ilya Mu‐
129 ravyov, package maintainers - Leah Neukirchen, Grigory Kirillov, Maciej
130 Barc, Robert Schutz, Petr Pisar, and others. Also everyone who sent
131 patches, helped with portability problems, encouraged me to work on
132 bzip3 and lent me machines for performance tests.
133
134
136 bzip2(1), bz3less(1), bz3more(1), bz3grep(1), bunzip3(1)
137
138
139
140version v1.3.2 07 August 2023 bzip3(1)