<br><br><div class="gmail_quote">On Sat, Jan 14, 2012 at 12:47 PM, Sam Varshavchik <span dir="ltr">&lt;<a href="mailto:mrsam@courier-mta.com">mrsam@courier-mta.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
JD writes:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
« HTML content follows »<br>
Dear all,<br>
I have a dd image of a windows disk.<br>
<br>
I run<br>
<br>
losetup /dev/loop0 winDrive.dd<br>
<br>
Then<br>
<br>
fdisk -l /dev/loop0<br>
<br>
and it shows there is 1 partition:<br>
<br>
/dev/loop0p1 ....etc ..... etc.<br>
<br>
However, I seem to have no way of mounting the partition, because<br>
device loop0p1 does not exist in /dev directory.<br>
<br>
Short of dumping the dd image onto another hard drive, is there<br>
a way to mount the ntfs partition  in the dd image?<br>
</blockquote>
<br>
Figure out the starting position of each partition in the image, and its size, in bytes, then use the --offset and --sizelimit parameters to losetup, accordingly.<br>
<br>
<br></blockquote><div><br>The losetup command does accept an offset value. However, these values<br>have to be expressed as integers of KiB or MiB or GiB ...etc.<br>The NTFS partition starts at sector 63, which is not a multiple of 1KiB (1024 Bytes).<br>

If the losetup command could accept an offset stated in sectors or in an arbitrary<br>integer number of bytes, the losetup could be used to access the partition within<br>the image and mount it.<br>Interestingly enough, the kernel loop driver looks at the offset as a number of sectors!<br>

<br>Cheers,<br><font color="#888888"><br>JD<br></font><br></div></div>