LinuxCommandLibrary

xorriso

SYNOPSIS

xorriso [ options ] [ commands ]
xorriso -outdev device|image [ -indev device|image ] commands...
xorriso -dev device|image [ commands... ]

PARAMETERS

-help
    Displays a summary of common options and commands.

-version
    Prints the program version information.

-outdev path
    Specifies the output device or image file for writing operations.

-indev path
    Specifies the input device or image file for reading an existing session or content.

-dev path
    Sets both the input and output device/image to the same path for read/write operations.

-eject on|off
    Controls automatic disc ejection after operations complete.

-volid ID
    Sets the volume ID (label) for the ISO 9660 filesystem.

-joliet on|off
    Enables or disables Joliet extensions for long filenames and Unicode character support.

-rockridge on|off
    Enables or disables Rock Ridge extensions for Unix-like permissions, symbolic links, and device nodes.

-add source_path iso_path
    Adds a file or directory from the host filesystem at source_path to the ISO image at iso_path.

-map source_path iso_path
    Adds a file or directory, mapping source_path to iso_path in the image. If iso_path is omitted, it defaults to the basename of source_path.

-rm iso_path
    Removes a file or directory at iso_path from the ISO image.

-extract iso_path dest_path
    Extracts a file or directory from the ISO image at iso_path to the host filesystem at dest_path.

-boot_image type settings
    Configures parameters for creating a bootable image (e.g., El Torito, GRUB).

-commit
    Writes all pending filesystem changes to the output device or image file.

-abort
    Discards all pending filesystem changes, reverting to the state before the last commit or input device read.

-iso_level num
    Sets the ISO 9660 conformance level (1-4). Level 3 supports files larger than 4GB.

-speed num
    Sets the writing speed for optical media (e.g., '4x', 'max', '10000').

-read_only on|off
    Prevents any writing operations when set to on.

-hardlinks on|off
    Enables or disables the creation of hardlinks on the ISO filesystem.

-acl on|off
    Enables or disables the recording of Access Control Lists (ACLs).

-xattr on|off
    Enables or disables the recording of Extended Attributes (xattrs).

-hfsplus on|off
    Enables or disables the generation of an HFS+ filesystem alongside ISO 9660, for Apple Macintosh compatibility.

-zisofs on|off
    Enables or disables zisofs compression for files within the ISO image.

-multi_session mode
    Controls multi-session behavior, allowing appending data to existing optical discs (e.g., 'on', 'off', 'append').

DESCRIPTION

xorriso is a versatile command-line utility for creating, modifying, and burning ISO 9660 Rock Ridge filesystems, primarily for optical media like CD, DVD, and BD. It combines the functionalities of traditional tools like mkisofs and growisofs into a single, powerful application. Beyond simple ISO creation, xorriso supports multi-session recording, incremental backups, and file extraction from existing images or discs. It can manage various advanced filesystem features such as Joliet, HFS+, ACLs, and extended attributes. Its robust design allows for flexible manipulation of disc content, making it an indispensable tool for archival, data distribution, and system recovery tasks.

CAVEATS

xorriso has a very comprehensive set of options and can be complex to use for intricate tasks. Misconfiguration of options, especially related to -boot_image, filesystem extensions (-acl, -xattr, -hfsplus), or multi-session parameters, can lead to unbootable or unreadable media.
Direct device access requires appropriate user permissions, often root privileges. Care must be taken when using -outdev with a physical drive, as it can overwrite existing data. The command-line interface, with its distinction between options and commands, requires careful attention to syntax.

UNIFIED WORKFLOW

xorriso unifies the entire workflow of ISO image and optical disc management. Users can create a new ISO, add files, modify its structure, append data in a new session, and even extract specific files, all within a single invocation or interactive session, unlike older approaches that often required piping between multiple commands.

FILESYSTEM AGNOSTIC DESIGN

While primarily focused on ISO 9660, xorriso can generate compatible filesystems like Joliet, Rock Ridge, and HFS+, allowing for broad compatibility across different operating systems while retaining POSIX-like attributes. It also supports advanced features like 'zisofs' compression and extended attributes which can be vital for backup and archival purposes.

INTERACTIVE MODE

xorriso can be run in an interactive mode, allowing users to issue commands sequentially, inspect the current state of the filesystem, and commit changes only when satisfied, providing a more controlled environment for complex operations.

HISTORY

xorriso was developed as a modern, unified tool to overcome the limitations and complexities of using separate programs like mkisofs and growisofs in conjunction. It was designed to support modern optical media (DVD, Blu-ray) and advanced filesystem features (like ACLs, xattr, HFS+), which were either lacking or poorly implemented in older tools. Its development aimed to provide a single, consistent interface for all stages of ISO image and optical disc manipulation, from creation to multi-session appending and data extraction. It has become a standard component in many Linux distributions for optical media handling.

SEE ALSO

mkisofs(8), growisofs(1), isoinfo(1), wodim(1), dd(1), mount(8)

Copied to clipboard