[sclug] Mount whole-disk image?

John Stumbles john at stumbles.org.uk
Sun Jan 27 12:54:13 UTC 2008


Alex Butcher wrote:

> Yup, but it's a bit of a pain. IIRC, you need to manually set up the loop
> device, using losetup and its -o (offset) parameter. If you run 'sfdisk -d
> /path/to/dd_file', the start parameter should give you the appropriate
> offset.

Thanks Alex (and everyone else).

FWIW 'file' seems to give the same info (though less neatly formatted)

$ file jmelaptop
jmelaptop: x86 boot sector; partition 1: ID=0x7, active, starthead 1, 
startsector 63, 137199553 sectors; partition 2: ID=0x7, starthead 254, 
startsector 137199616, 15837184 sectors; partition 3: ID=0x7, starthead 
254, startsector 153044992, 3254272 sectors

# sfdisk -d /media/sdg1/jmelaptop
# partition table of /media/sdg1/jmelaptop
unit: sectors

/media/sdg1/jmelaptop1 : start=       63, size=137199553, Id= 7, bootable
/media/sdg1/jmelaptop2 : start=137199616, size= 15837184, Id= 7
/media/sdg1/jmelaptop3 : start=153044992, size=  3254272, Id= 7
/media/sdg1/jmelaptop4 : start=        0, size=        0, Id= 0


-- 
John Stumbles



More information about the Sclug mailing list