Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Loopback mount in OSX

I am trying to mount an .img file (rootfs.img) so I can modify the features of the firmware for a derivitive of the 4fff N618 (Pandigital Novel).

I have flashed it with the firmware of the bqAvant and it is fully operational, but I cannot find a way to do a loopback mount with OSX 10.5, neither do I have a cd with a linux distro. The efi won't even let me boot from a usb device using rEFIt.

Using:

mount -o loop rootfs.img /mnt/rootfs

replies that loop is not supported.

like image 898
spaghettiCode Avatar asked Dec 28 '10 20:12

spaghettiCode


People also ask

What is a loopback mount?

You can mount a CD image without having to burn an actual CD or manipulate a floppy boot image. Of course, different platforms call it different things and use different tools. Mounting file images on Linux uses the loop device and is called a loop mount or a loopback mount.

What is an ISO loopback device?

A loopback device is a device that can be used as a block device to access files. The loopback file can contain an ISO image, a disk image, a file system, or a logical volume image.


1 Answers

Look here https://serverfault.com/questions/174909/mount-block-file-on-osx. Here are the correct parameters for hdiutil:

$ hdiutil attach -imagekey diskimage-class=CRawDiskImage -nomount <filename>

Example:

$ hdiutil attach -imagekey diskimage-class=CRawDiskImage -nomount /Users/me/backup.rdisk4s2.dd

Example Output:

/dev/disk6
like image 95
S. T. Lee Avatar answered Oct 16 '22 23:10

S. T. Lee