LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

xorriso

Create, load, change, and write ISO 9660 images

TLDR

Create an image from a directory
$ xorriso -outdev [path/to/image.iso] -map [path/to/directory] /
copy
Create an image with mkisofs-compatible options
$ xorriso -as mkisofs -o [path/to/image.iso] -V [label] -J -R [path/to/directory]
copy
List the root of an image
$ xorriso -indev [path/to/image.iso] -ls /
copy
Find files by name
$ xorriso -indev [path/to/image.iso] -find / -name '[*.txt]'
copy
Extract a whole image
$ xorriso -osirrox on -indev [path/to/image.iso] -extract / [path/to/output_directory]
copy
Extract one file
$ xorriso -osirrox on -indev [path/to/image.iso] -extract [/path/in/image] [path/to/output_file]
copy
Add a file to an existing image
$ xorriso -dev [path/to/image.iso] -map [path/to/file] [/path/in/image]
copy
Show sessions and size (table of contents)
$ xorriso -indev [path/to/image.iso] -toc
copy

SYNOPSIS

xorriso [commands]...xorriso -as mkisofs [mkisofs-options]...

DESCRIPTION

xorriso is the GNU libburnia program for ISO 9660 filesystems. It can build an image, load one, change files inside it, and write it. Commands are options that run in order: -outdev names a new image, -indev opens one for reading, -dev opens one for update, -map copies a disk path into the image, -ls lists a directory, -find searches, and -toc prints sessions.-osirrox on allows extraction back to the disk. -extract then copies an image path to a local path.-as mkisofs accepts a subset of mkisofs options, including -o for the output file, -V for the volume label, and -J and -R for Joliet and Rock Ridge. On some distributions the mkisofs command itself is this compatibility mode.The program also drives optical drives. -indev accepts a device such as /dev/sr0 as well as a file.

INSTALL

sudo apt install xorriso
copy
sudo dnf install xorriso
copy
sudo apk add xorriso
copy
sudo zypper install xorriso
copy
brew install xorriso
copy
nix profile install nixpkgs#xorriso
copy

CAVEATS

Writing with -dev or -outdev pointed at a real drive records a disc. Point those options at a file path unless a disc is intended.The option set is large. The examples above are the common ones. The GNU manual is the full command list. The separate programs xorrecord and osirrox are front ends of the same project and are not documented here.

SEE ALSO

RESOURCES

Copied to clipboard
Kai