genisoimage and xorrisofs
The classical command line interface for production of ISO 9660 filesystem images is the option set established by program mkisofs. For reasons of licensing and other problems with its author, Debian ships a fork of mkisofs, called genisoimage, which was split off in 2006 and then developed independently.
Meanwhile, genisoimage gets no new features and not even bug fixes. It is first choice only if its options -udf or -hfs are needed.
Replacement in most cases, especially for bootable ISO 9660 filesystems, is xorrisofs which starts the -as mkisofs emulation mode of program xorriso.
Creating an ISO 9660 CD-ROM filesystem image
The options of the first example
genisoimage -v -J -r -V MY_DISK_LABEL -o /home/user/file.iso /home/user/for_iso xorrisofs -v -J -r -V MY_DISK_LABEL -o /home/user/file.iso /home/user/for_iso
mean in particular:
-v lets the program be verbose about minor problems or noteworthy facts
-J enables the production of a second superblock and directory tree which is suitable for reading by MS-Windows. The Joliet filenames are specified in 16-bit Unicode and each path component can be up to 64 Unicode characters long. Linux will use this tree if no Rock Ridge information is added to the main directory tree.
-r enables production of Rock Ridge information which records typical POSIX file properties like ownership, permissions, timestamps, file type, symbolic link target. Different from option -R it does not preserve the ownership as on hard disk, but rather sets owner UID to 0 and permissions to read-only and inspect-only for everybody. If Rock Ridge is present, then Linux will mount the main directory tree and use Rock Ridge to show long names with original characters.
-V sets the name of the ISO 9660 filesystem. It will be used as link name in directory /dev/disk/by-label when the written optical medium is inserted into a reader drive that is watched by udev. Use your own unique name instead of MY_DISK_LABEL.
-o sets the name of the resulting ISO 9660 image file. Use any suitable path instead of /home/user/file.iso.
The argument /home/user/for_iso is not part of any option. Thus it is used as path of an input file or directory which shall be copied into the ISO 9660 filesystem. If it is a directory then all files and directories underneath are copied, too.
More than one input path may be given. In this case it is best to use option -graft-points and pathspecs of the form target=source.