ISO image is an archive file generally used for optical disks. ISO image uses file system ISO 9660 and has extension .iso or .image. ISO images can be written into CD, DVD, Blu-ray. ISO file is a very popular way to distribute files, Linux distributions, media files, etc.
Install iso-info
We may want to list the content of ISO image and check if the content we are looking for exists. Libcdio-utils is a package that provides a tool named iso-info where we will use to list ISO image content. We can install libcdio-utils like below.
$ sudo apt-get install libcdio-utils -y

Syntax
The syntax of the isoinfo command is like below.
$ isoinfo [OPTIOMS] -i FILENAME
- `OPTIONS` are an option and used to enable/disable some features
- `-i FILENAME` is used to specify the ISO file name and path accordingly.
List Content Of The ISO File
At this stage, we will use memtest86+.iso file which is by default provided from Ubuntu, Debian to use boot operations.
$ isoinfo -l -i /usr/lib/memtest86+/memtest86+.iso

isoinfo list files and directories like ls -Rl command. Say we want to get /README.TXT file.
Mount ISO Image
We will mount the iso image with the mount command. Mount command automatically detects the file system of the ISO image and provides related options implicitly. We first install isoinfo like below. We will create a new directory to mount our ISO image. We can prefer to use existing directories like /cdrom or /mnt too.
$ mkdir iso
Now we can mount the iso file. We need root privileges to mount the iso file. And mounted iso file directory will be read-only by default because the aim is to read files.
$ sudo mount /usr/lib/memtest86+/memtest86+.iso iso

Unmount Mounted ISO
We need to unmount after we completed our work with ISO file. Actually we have no obligation but the neat way is unmounting ISO file from a mounted path. We can use umount
command by providing the path we all ready mount. We also generally need the root privileges with sudo
command. In this example, we will unmount path /mnt
.
$ sudo umount /mnt