I have recently installed a iSCSI environment on a Ubuntu Server. In this system i have used images created with the following command:
dd if=/dev/zero of=/storage/lun1.img bs=1024k count=20000
They have then been partitioned and formated via the iSCSI initiator.
The problem i have now is that i would like to mount these images, if the iSCSI server goes down to get the data.
How do I mount these image files?
Disk lun4.img: 0 MB, 0 byte 33 heads, 61 sectors/track, 0 cylinders Units = sectors of 2013 · 512 = 1030656 byte Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Device Boot Start End Blocks Id System lun4.img1 1 1017 1023580 83 Linux
mount -o loop,offset=512 -t ext4 lun4.img /mnt
mount: wrong fs type, bad option, bad superblock on /dev/loop0, missing codepage or other error In some cases useful info is found in syslog - try dmesg | tail or so