Use lofiadm to mount an ISO in Solaris 10
published on Wed, 05/06/2009 - 11:04
As a Linux user, I've used
mount -o loop -t iso9660 /path/to/file.iso /mnt/tmp
more times than I can count. Not suprisingly, you can do it in Solaris 10 as well, there's just another step involved:
# lofiadm -a /path/to/file.iso /dev/lofi/1 # mount -o ro -F hsfs /dev/lofi/1 /mnt/tmp
The first command, lofiadm, associates the iso file to a block device managed by the kernel LOopback FIle driver. The second command is the same old mount command you're used to, you just point it to the lofi device.
To unmount:
# umount /mnt/tmp # lofiadm -d /dev/lofi/1
Comments
One-line version
mount -o ro -F hsfs `lofiadm -a /path/to/file.iso` /mnt/tmp
Add new comment