Re: losetup behavior

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 6/28/06, Joshua Hudson <[email protected]> wrote:
On 6/28/06, Hareesh Nagarajan <[email protected]> wrote:
> In my example below I have an image of an entire disk /dev/sda created
> using the dd command. The name of the file is foo.img. There are
> (internally) 3 partitions. ext2 (root), swap, ext2 (data). I will
> extract the third partition, first with dd and show that it works and
> then with losetup and show that it doesn't work.
>
> With dd:
> root: / # dd if=foo.img of=part3 bs=512 skip=12402180 count=21141540
> (Partition 3 begins at: 12402180 * 512 = 6349916160 bytes from start)
>
> root: / # mount -o loop=/dev/loop0 part3 mypart3/
> root: microv3/ # cd mypart3/; ls
> blah/ blah-blah/
>
> *works*
>
> With losetup:
> root: # losetup -o6349916160 /dev/loop0 foo.img
> root: # mount /dev/loop0 mypart3/
> mount: you must specify the filesystem type
> root: / # mount -t ext2 /dev/loop0 mypart3
> mount: wrong fs type, bad option, bad superblock on /dev/loop5,
> or too many mounted file systems
>
> *doesn't work*
>
If I had to guess, I would say you have an old version of losetup and
this is an integer overflow problem. Maybe post an strace of the
losetup command that doesn't work. Probably it won't help.

[ CCing: linux-kernel ]

Yeah, upgrading losetup fixed it. apt-get install loop-aes-utils

Thanks,
--
./hareesh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux