-v (Create Volumes) switch
Specifies volume sizes.
Syntax
-v{Size}[b | k | m | g]
{Size}[b | k | m | g]
Specifies volume size in Bytes, Kilobytes (1 Kilobyte = 1024 bytes),
Megabytes (1 Megabyte = 1024 Kilobytes) or Gigabytes (1 Gigabyte = 1024 Megabytes).
if you specify only {Size}, 7-zip will treat it as bytes.
It's possible to specify several -v switches.
NOTE: Please don't use volumes (and don't copy volumes) before finishing archiving.
7-Zip can change any volume (including first volume) at the end of archiving operation.
Examples
7z a a.7z *.txt -v10k -v15k -v2m
creates multivolume a.7z archive.
First volume will be 10 KB, second will be 15 KB, and all others will be 2 MB.
Commands that can be used with this switch
a (Add) ,
Notes from this site
Not part of the 7-Zip manual. Written by this site; examples checked with 7-Zip 26.04.
How do I split an archive and extract the parts?
On Linux and macOS the official console binary is 7zz; on Windows it is 7z, and the same switch works with backslash paths: 7z a backup.7z folder\ -v100m.
7zz a backup.7z folder/ -v100m # split into 100 MiB parts
7zz x backup.7z.001 # extract: name the FIRST part
7zz t backup.7z.001 # test all parts
7zz a backup.7z folder/ -v100m -mx=9 -psecret # other switches combine freely
7zz a -tzip z.zip folder/ -v100k # zip volumes work too: z.zip.001 ...
7zz a -tgzip big.tar.gz big.tar -v100m # a tar as gzip volumes: big.tar.gz.001 ...
Parts are named by appending a three-digit number to the archive name: backup.7z.001, backup.7z.002, and so on. The last part is usually smaller. All parts must sit in one folder. 7-Zip reads the parts directly, so joining is optional; to get one file anyway, use cat backup.7z.00* > joined.7z on Linux and macOS or copy /b backup.7z.* joined.7z in Windows cmd.
In the 7-Zip File Manager, the Add to Archive dialog has a "Split to volumes" field that takes the same sizes. With gzip the volumes are pieces of the compressed file; the tar inside is not split separately.
What do the size units mean (and FAT32)?
Units are binary and case-insensitive: -v1m makes parts of exactly 1,048,576 bytes. Decimals are rejected: -v1.5k fails with "Incorrect volume size" (exit code 7), so use -v1536. For a FAT32 drive (files must be smaller than 4 GiB) use -v4092m, not -v4g.
Common mistakes
Omitting the unit: -v100 means 100 bytes, so 3 KB of data became 32 parts in a test.
Extracting from .002 or a later part: 7-Zip prints "Cannot open the file as archive" and exits with code 2. Start from .001.
Uploading or copying parts from a script before 7zz exits: the vendor text warns that 7-Zip can change any part, including the first, at the end.
Deleting or renaming a part: extraction stops with "Unexpected end of archive".
Running u on an existing volume set: it fails with "Updating for multivolume archives is not implemented" (exit code 2). Create the set again.
Related pages