lunes, 20 de febrero de 2012

How to mount ISO images in Linux

Back in my Windows days, I was very happy to work with virtual CD drives thanks to Daemon tools. The ability to play games and watch videos without having to place the actual CD on the drive tray was like magic to me.

Once I migrated to Linux, since the games I used to play were not supported, I forgot about mounting virtual drives.

Today, I learned how to mount ISO files in KDE: it's a real simply process that can be performed with the terminal or with a graphical tool.

Mounting an ISO file with Konsole

The first step is to create a directory which is going to be used to mount the ISO to. This is achieved by opening Konsole and, after typing SU and your root password, you type:

mkdir /media/any_name (any_name will be the directory).

Close the terminal and use Dolphin to find the directory where the ISO file you want to mount is. Let's suppose it is called "your-file.iso". Once in the appropriate directory, go to the menu in Dolphin and click on "tools". Then select "Open terminal". Once again, type SU and your password. Then type:

mount -t iso9660 -o loop your-file.iso /media/any_directory

And there you have it, Linux beginners! Your ISO will be mounted.

So you want to unmount the ISO? Well, in the terminal, as root, type:
umount /media/your-file.iso and then:
rd /media/any_directory (to erase the directory we created).

Notice that the command is umount, not uNmount.

Mounting an ISO file with Acetoneiso

If you think that the terminal is too much of a hassle, then you can use acetoneiso. Find it in your distribution repository and install it. Then, launch it from the menu and the first thing the program will do is ask you to select whether you use KDE, Gnome, or any other environment. After that, you yous have to select the file and click in mount or unmount. This program creates a folder called "virtual-drives", in which it makes numbered directories where your ISOs will be mounted to.

A notorious difference is that they are created in your home folder, not in root.

2 comentarios: