]> wimlib.net Git - wimlib/blob - doc/imagex-optimize.1.in
f0ecc549fa129d79371cfadf83d23f04551c5843
[wimlib] / doc / imagex-optimize.1.in
1 .TH WIMLIB-IMAGEX "1" "November 2013" "@IMAGEX_PROGNAME@ @VERSION@" "User Commands"
2 .SH NAME
3 @IMAGEX_PROGNAME@-optimize \- Optimize a WIM archive
4 .SH SYNOPSIS
5 \fB@IMAGEX_PROGNAME@ optimize\fR \fIWIMFILE\fR [\fIOPTION\fR...]
6 .SH DESCRIPTION
7 \fB@IMAGEX_PROGNAME@ optimize\fR will rebuild the stand-alone WIM \fIWIMFILE\fR.  The new
8 WIM is written to a temporary file, and it is renamed to the original file when
9 it's ready.  This action will remove any holes that have been left as a result
10 of appending images, so the new WIM may be slightly smaller than the old WIM.
11 In addition, some errors in the original WIM may be fixed by re-writing it
12 (although most cannot).
13 This command is also available as simply \fBwimoptimize\fR if the appropriate
14 hard link or batch file has been installed.
15 .SH OPTIONS
16 .TP 6
17 \fB--check\fR
18 When reading \fIWIMFILE\fR, verify its integrity if an integrity table is
19 present.  In addition, include an integrity table in the optimized WIM.  If this
20 option is not specified, by default the integrity table (if present) is not
21 checked, and an integrity table is included in the rebuilt WIM if and only if
22 one was present in the original WIM.
23 .TP
24 \fB--nocheck\fR
25 Neither verify the integrity of \fIWIMFILE\fR using the integrity table, nor
26 include an integrity table in the rebuilt WIM file.
27 .TP
28 \fB--recompress\fR
29 Recompress all compressed streams in \fIWIMFILE\fR when rebuilding it.  This
30 will increase the time needed to rebuild the WIM, unless the WIM is
31 uncompressed, but it may result in a better compression ratio if wimlib can do a
32 better job than the program that wrote the original file.  A side effect of this
33 is that every stream in the original WIM will be checksummed, so this can help
34 verify that the WIM is intact (equivalent to applying all the images from it).
35 .IP ""
36 Note: as mentioned in the README, wimlib generally provides a slightly better
37 XPRESS compression ratio than Microsoft's software, while it generally provides
38 a slightly worse LZX compression ratio than Microsoft's software.  So, you may
39 not want to specify \fB--recompress\fR when optimizing a LZX-compressed WIM
40 created on Windows with Microsoft's ImageX.
41 .TP
42 \fB--compress-slow\fR
43 With \fB--recompress\fR: Spend even more time compressing the data in order to
44 achieve a higher compression ratio.  Currently, this only has an effect with LZX
45 ("maximum") compression.  Depending on the data, compressing with this option
46 will take around 10 to 15 times longer and produce a LZX-compressed WIM about 1%
47 to 5% smaller than one produced with the default LZX compressor.  Depending on
48 the data, the resulting WIM may be approximately the same size (typically no
49 more than 0.4% different) as a LZX-compressed WIM produced by WIMGAPI.
50 .TP
51 \fB--threads\fR=\fINUM_THREADS\fR
52 Number of threads to use for compressing data.  Default: autodetect (number of
53 processors).  This parameter is only meaningful when \fB--recompress\fR is also
54 specified.
55 .TP
56 \fB--pipable\fR
57 Rebuild the WIM so that it can be applied fully sequentially, including from a
58 pipe.  See \fB@IMAGEX_PROGNAME@ capture\fR(1) for more details about creating
59 pipable WIMs.  By default, when neither \fB--pipable\fR or \fB--not-pipable\fR
60 is specified, the rebuilt WIM will be pipable if and only if it was already
61 pipable.
62 .TP
63 \fB--not-pipable\fR
64 Rebuild the WIM in the non-pipable format.  (This is the default if
65 \fIWIMFILE\fR is not pipable.)
66 .SH NOTES
67 \fB@IMAGEX_PROGNAME@ optimize\fR does not support split WIMs.
68 .PP
69 \fB@IMAGEX_PROGNAME@ optimize\fR is roughly equivalent to:
70 .RS
71 .PP
72 \fB@IMAGEX_PROGNAME@ export\fR \fIWIMFILE\fR all tmp.wim && mv tmp.wim \fIWIMFILE\fR
73 .RE
74 .PP
75 .SH SEE ALSO
76 .BR @IMAGEX_PROGNAME@ (1)
77 .BR @IMAGEX_PROGNAME@-export (1)