GDAL-VSI-SOZIP(1)
π gdal-vsi-sozip β the GDAL manual, bestie edition π
okay so this is gdal-vsi-sozip, part of the GDAL family of manual pages, and it's the one that handles all your SOZIP (Seek-Optimized ZIP) business. no cap, it's a glow-up for your zip files. β¨
πΈ NAME πΈ
gdal-vsi-sozip β SOZIP (Seek-Optimized ZIP) related commands.
Added in version 3.11. π
π DESCRIPTION π
The gdal vsi sozip utility can be used to:
- create a SOZip (Seek-Optimized ZIP) file π
- append files to an existing ZIP/SOZip file
- list the contents of a ZIP/SOZip file
- validate a SOZip file
- convert an existing Zip file into a SOZip optimized one
like... five whole jobs?? she does it all, main character energy fr fr. π
β¨ SYNOPSIS β¨
Usage: gdal vsi sozip <SUBCOMMAND> [OPTIONS]
where <SUBCOMMAND> is one of:
- create: Create Seek-optimized ZIP (SOZIP) file.
- list: List content of a ZIP file, with SOZIP related information.
- optimize: Create a Seek-optimized ZIP (SOZIP) file from a regular ZIP file.
- validate: Validate a ZIP file, possibly using SOZIP optimization.
Common Options:
-h, --help Display help message and exit
--json-usage Display usage as JSON document and exit
--config <KEY>=<VALUE> Configuration option [may be repeated]
The shared Common Options, so you don't have to scroll back and forth (you're welcome π«Ά):
-h,--helpβ show the help message and bounce. iconic behavior.--json-usageβ print the usage as a JSON document and exit. for the machine girlies π€--config <KEY>=<VALUE>β set a configuration option. it may be repeated (go off, stack them π ).
π¦ GDAL VSI SOZIP CREATE π¦
π Description
Adds one or several files to a new or existing zip file.
π Synopsis
Usage: gdal vsi sozip create [OPTIONS] <INPUT> <OUTPUT>
Create a Seek-optimized ZIP (SOZIP) file.
Positional arguments:
-i, --input <INPUT> Input filenames [may be repeated] [required]
-o, --output <OUTPUT> Output ZIP filename [required]
Common Options:
-h, --help Display help message and exit
--json-usage Display usage as JSON document and exit
--config <KEY>=<VALUE> Configuration option [may be repeated]
-q, --quiet Quiet mode (no progress bar or warning message) [not available in pipelines]
Options:
--overwrite Whether overwriting existing output dataset is allowed
-r, --recursive Travels the directory structure of the specified directories recursively
-j, --junk-paths, --no-paths Store just the name of a saved file, and do not store directory names
--enable-sozip <ENABLE-SOZIP> Whether to automatically/systematically/never apply the SOZIP optimization. ENABLE-SOZIP=auto|yes|no (default: auto)
--sozip-chunk-size <value in bytes or with K/M suffix> Chunk size for a seek-optimized file (default: 32768)
--sozip-min-file-size <value in bytes or with K/M/G suffix> Minimum file size to decide if a file should be seek-optimized (default: 1 MB)
--content-type <CONTENT-TYPE> Store the Content-Type of the file being added.
π Options
-i,--input <INPUT>β the input filenames. Required. several file names or directory names are accepted, so bring a whole crew.-o,--output <OUTPUT>β the output ZIP filename. Required. it must have a.zipextension, no exceptions bestie π€--overwriteβ whether overwriting existing output is allowed. (default: no ruining your old files without permission π«)-r,--recursiveβ travels the directory structure of the specified directories recursively. she goes deep. π³οΈ-j,--junk-paths,--no-pathsβ store just the name of a saved file (junk the path), and do not store directory names. by default,sozipwill store the full path (relative to the current directory).--enable-sozip auto|yes|noβ inautomode, a file is seek-optimized only if its size is above the value of--sozip-min-file-size. inyesmode, all input files will be seek-optimized. innomode, no input files will be seek-optimized. (default:auto, our little negotiator π )--sozip-chunk-size <value>β chunk size for a seek-optimized file. defaults to32768bytes. the value is specified in bytes, orKandMsuffix (optionally preceded by a space) can be respectively used to specify a value in kilo-bytes or mega-bytes.--sozip-min-file-size <value>β minimum file size to decide if a file should be seek-optimized, in--enable-sozip=automode. defaults to1 MBbyte. the value is specified in bytes, orK,MorGsuffix (optionally preceded by a space) can be respectively used to specify a value in kilo-bytes, mega-bytes or giga-bytes.--content-type <value>β store the Content-Type for the file being added as a key-value pair in the extra field extension'KV'(0x564b) dedicated to storing key-value pair metadata. metadata girlies rise π-q,--quietβ do not output any informative message (only errors). shhh. π€«
β Multithreading
The GDAL_NUM_THREADS configuration option can be set to ALL_CPUS or a integer value to specify the number of threads to use for SOZip-compressed files. Defaults to ALL_CPUS. literally working all her cores, we stan a try-hard π₯
π Examples
Example 1: Create a, potentially seek-optimized, ZIP file with the content of my.gpkg
gdal vsi sozip create my.gpkg my.gpkg.zip
Example 2: Create a, potentially seek-optimized, ZIP file from the content of a source directory:
gdal vsi sozip create -r source_dir/ my.gpkg.zip
π§ GDAL VSI SOZIP OPTIMIZE π§
π Description
Create a new zip file from the content of an existing one, possibly applying SOZip optimization when relevant.
π Synopsis
Usage: gdal vsi sozip optimize [OPTIONS] <INPUT> <OUTPUT>
Create a Seek-optimized ZIP (SOZIP) file from a regular ZIP file.
Positional arguments:
-i, --input <INPUT> Input ZIP filename [required]
-o, --output <OUTPUT> Output ZIP filename [required]
Common Options:
-h, --help Display help message and exit
--json-usage Display usage as JSON document and exit
--config <KEY>=<VALUE> Configuration option [may be repeated]
-q, --quiet Quiet mode (no progress bar or warning message) [not available in pipelines]
Options:
--overwrite Whether overwriting existing output dataset is allowed
--enable-sozip <ENABLE-SOZIP> Whether to automatically/systematically/never apply the SOZIP optimization. ENABLE-SOZIP=auto|yes|no (default: auto)
--sozip-chunk-size <value in bytes or with K/M suffix> Chunk size for a seek-optimized file (default: 32768)
--sozip-min-file-size <value in bytes or with K/M/G suffix> Minimum file size to decide if a file should be seek-optimized (default: 1 MB)
π Options
-i,--input <INPUT>β Input ZIP filename. Required.-o,--output <OUTPUT>β Output ZIP filename. Required. Must have a.zipextension β οΈ--overwriteβ Whether overwriting existing output is allowed.--enable-sozip auto|yes|noβ inautomode, a file is seek-optimized only if its size is above the value of--sozip-chunk-size. inyesmode, all input files will be seek-optimized. innomode, no input files will be seek-optimized. (default:auto)--sozip-chunk-size <value>β Chunk size for a seek-optimized file. Defaults to32768bytes. The value is specified in bytes, orKandMsuffix can be respectively used to specify a value in kilo-bytes or mega-bytes.--sozip-min-file-size <value>β Minimum file size to decide if a file should be seek-optimized, in--enable-sozip=automode. Defaults to1 MBbyte. The value is specified in bytes, orK,MorGsuffix can be respectively used to specify a value in kilo-bytes, mega-bytes or giga-bytes.-q,--quietβ Do not output any informative message (only errors).
β Multithreading
The GDAL_NUM_THREADS configuration option can be set to ALL_CPUS or a integer value to specify the number of threads to use for SOZip-compressed files. Defaults to ALL_CPUS. yes she threads, she's that girl π
π Examples
Example 3: Create a, potentially seek-optimized, ZIP file sozip_optimized.zip from an existing ZIP file in.zip.
gdal vsi sozip optimize in.zip sozip_optimized.zip
π«Ά GDAL VSI SOZIP LIST π«Ά
π Description
List the files contained in the zip file in an output similar to Info-ZIP unzip utility, but with the addition of a column indicating whether each file is seek-optimized.
π Synopsis
Usage: gdal vsi sozip list [OPTIONS] <INPUT>
List content of a ZIP file, with SOZIP related information.
Positional arguments:
-i, --input <INPUT> Input ZIP filename [required]
Common Options:
-h, --help Display help message and exit
--json-usage Display usage as JSON document and exit
--config <KEY>=<VALUE> Configuration option [may be repeated]
π Options
-i,--input <INPUT>β Input ZIP filename. Required.
π Examples
Example 4: List contents of my.zip.
gdal vsi sozip list my.zip
π GDAL VSI SOZIP VALIDATE π
π Description
Validates a SOZip file. Baseline ZIP validation is done in a light way, limited to being able to browse through ZIP records with the InfoZIP-based ZIP reader used by GDAL. But validation of the SOZip-specific aspects is done more thoroughly. so the normal stuff gets a casual vibe check and the SOZip stuff gets the full interrogation π
π Synopsis
ngl bestie, the page literally prints the list usage here β that's exactly what it says, so here it is, unchanged:
Usage: gdal vsi sozip list [OPTIONS] <INPUT>
List content of a ZIP file, with SOZIP related information.
Positional arguments:
-i, --input <INPUT> Input ZIP filename [required]
Common Options:
-h, --help Display help message and exit
--json-usage Display usage as JSON document and exit
--config <KEY>=<VALUE> Configuration option [may be repeated]
π Options
-i,--input <INPUT>β Input ZIP filename. Required.-q,--quietβ Do not output any informative message (only errors).-v,--verboseβ Turn on verbose mode. tell me everything, I'm listening π
π RETURN STATUS CODE π
The program returns status code 0 in case of success, and non-zero in case of error (non-blocking errors emitted as warnings are considered as a successful execution). so a lil warning is not a fail, don't spiral π
π Examples
Example 5: Validate my.zip.
gdal vsi sozip validate my.zip
π AUTHOR π
Even Rouault <even.rouault@spatialys.com> β legend behavior, honestly π
π COPYRIGHT π
1998-2026
and that's the whole page, bestie!! you ate that π½οΈβ¨ this one's straight from the GDAL manual (that's the source, fr fr) and it's dated Aug 18, 2026 β so go forth, seek-optimize your zips, and remember: the vibe changes, the facts do not. periodt. ππΈπ¦
π¦ where this page comes from
- alpine 3.24: gdal-doc 3.13.3-r0 Β· MIT
- arch rolling: gdal 3.13.3-6 Β· MIT
- ubuntu stonking: gdal-bin 3.13.3+dfsg-1ubuntu4 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms