Port-xen archive

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

Re: Mount Linux image file



Are you sure it isn't ext4?  The partition IDs still say ext2, but it
introduces extents, which the ext2 code can't read.

There was a pygrub patch to allow it to extract the kernel/initrd from ext4...

-Dustin

On Fri, Mar 5, 2010 at 9:55 AM, Victor Dorneanu <victor%dornea.nu@localhost> 
wrote:
> Hi port-xen!
>
> I have finally managed it to install Debian (over network) into a
> image/container file.
>
> $ file root.img
> root.img: x86 boot sector; partition 1: ID=0x83, active, starthead 1,
> startsector 63, 1445787 sectors; partition 2: ID=0x5, starthead 0,
> startsector 1445850, 208845 sectors
>
> I was told I should use "vnconfig" in order to mount the partitions:
>
> $ vnconfig vnd0 root.img
> $ disklabel /dev/vnd0
> # /dev/vnd0d:
> type: vnd
> disk: vnd
> label: fictitious
> flags:
> bytes/sector: 512
> sectors/track: 32
> tracks/cylinder: 64
> sectors/cylinder: 2048
> cylinders: 812
> total sectors: 1664000
> rpm: 3600
> interleave: 1
> trackskew: 0
> cylinderskew: 0
> headswitch: 0           # microseconds
> track-to-track seek: 0  # microseconds
> drivedata: 0
>
> 9 partitions:
> #        size    offset     fstype [fsize bsize cpg/sgs]
>  d:   1664000         0     unused      0     0        # (Cyl.      0
> -    812*)
>  e:   1445787        63 Linux Ext2      0     0        # (Cyl.
> 0*-    705*)
>  i:    208782   1445913       swap                     # (Cyl.
> 706*-    807*)
> disklabel: boot block size 0
> disklabel: super block size 0
>
>
> Everything looks fine by now. However I can't mount the ext2-partition
> to extract the kernel.
>
> $ mount -t ext2fs /dev/vnd0e /mnt
> mount_ext2fs: /dev/vnd0e on /mnt: incorrect super block
>
>
> Any ideas?!
>
> --
> Victor Dorneanu
>
> Contact
> - Web/Blog: http://dornea.nu
>
> GnuPG information
> - KeyID = 0xD20870F4 (pgp.mit.edu)
> - Key fingerprint = DD6B 5E09 242F 7410 3F90 492A 4CBA FD13 D208 70F4
>
>
>
>


Home | Main Index | Thread Index | Old Index