<br><br><div class="gmail_quote">On Fri, May 8, 2009 at 2:30 PM, Rudi Ahlers <span dir="ltr"><<a href="mailto:rudiahlers@gmail.com">rudiahlers@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi all, <br><br>One of our Dell servers has failed badly, and one of
the domU's has been corrupted in the process. It boots up to a point
and then gives me a kernel panic:<br><br>Loading dm-zero.ko module<br>Loading dm-snapshot.ko module<br>Scanning and configuring dmraid supported devices<br>Scanning logical volumes<br>  Reading all physical volumes.  This may take a while...<br>

  No volume groups found<br>Activating logical volumes<br>  Volume group "VolGroup00" not found<br>Creating root device.<br>Mounting root filesystem.<br>mount: could not find filesystem '/dev/root'<br>Setting up other filesystems.<br>

Setting up new root fs<br>setuproot: moving /dev failed: No such file or directory<br>no fstab.sys, mounting internal defaults<br>setuproot: error mounting /proc: No such file or directory<br>setuproot: error mounting /sys: No such file or directory<br>

Switching to new root and running init.<br>unmounting old /dev<br>unmounting old /proc<br>unmounting old /sys<br>switchroot: mount failed: No such file or directory<br>Kernel panic - not syncing: Attempted to kill init!<br>

<br><br>It shows up as a Zombie:<br><br>[root@xen ~]# xm list<br>Name                                      ID Mem(MiB) VCPUs State   Time(s)<br>Domain-0                                   0     1439     1 r-----    329.0<br>

Zombie-hfserver2                          15     1024     1 ----c-      0.5<br>hfdns02                                   10      519     2 r-----   1552.8<br><br><br>I can't mount either:<br><br>root@xen ~]# mount /dev/data/hf<br>


hfdns02    hfserver2<br>
[root@xen ~]# mount /dev/data/hfserver2 /mnt/cpanel/<br>
mount: you must specify the filesystem type<br>
[root@xen ~]# mount -o loop /dev/data/hfserver2 /mnt/cpanel/<br>
mount: you must specify the filesystem type<br>
<br>
Here's the output of the LVM partitions:<br>
<br>
[root@xen ~]# lvscan<br>
  ACTIVE            '/dev/data/cpanel002' [100.00 GB] inherit<br>
  ACTIVE            '/dev/data/windows2003_web' [30.00 GB] inherit<br>
  ACTIVE            '/dev/data/storage' [50.00 GB] inherit<br>
  ACTIVE   Original '/dev/data/hfserver2' [30.00 GB] inherit<br>
  ACTIVE            '/dev/data/hfdns02' [30.00 GB] inherit<br>
  ACTIVE            '/dev/data/pluto' [30.00 GB] inherit<br>
  ACTIVE   Snapshot '/dev/data/pluto_s' [30.00 GB] inherit<br>
  ACTIVE            '/dev/system/root' [39.06 GB] inherit<br>
  ACTIVE            '/dev/system/swap' [9.75 GB] inherit<br>
[root@xen ~]# vgscan<br>
  Reading all physical volumes.  This may take a while...<br>
  Found volume group "data" using metadata type lvm2<br>
  Found volume group "system" using metadata type lvm2<br>
[root@xen ~]#            <br>
<br>
<br>
Does anyone know how to fix a LVM like this?<br clear="all"><font color="#888888"><br>-- <br></font></blockquote><div><br></div><div> Here's what I've done so far:<br></div><br>[root@xen ~]# losetup /dev/loop4  /dev/data/hfserver2<br>
<div><div><div><br></div><div># This mounts the LVM partition as imaginary physical to /dev/loop4</div><div># data is the virtual group (VG) name<br><br><div>[root@xen ~]#  kpartx -va /dev/loop4</div><div>add map loop4p1 : 0 208782 linear /dev/loop4 63</div>
<div>add map loop4p2 : 0 62701695 linear /dev/loop4 208845</div><div><br></div># This creates a device map with partitions in /dev/data/hfserver in /dev/mapper <br><br><div>[root@xen ~]# vgscan</div><div>  Reading all physical volumes.  This may take a while...</div>
<div>  Found volume group "VolGroup00" using metadata type lvm2</div><div>  Found volume group "data" using metadata type lvm2</div><div>  Found volume group "system" using metadata type lvm2</div>
<div><br></div><br><div>[root@xen ~]# lvscan</div><div>  inactive          '/dev/VolGroup00/LogVol00' [27.94 GB] inherit</div><div>  inactive          '/dev/VolGroup00/LogVol01' [1.94 GB] inherit</div><div>
  ACTIVE            '/dev/data/cpanel002' [100.00 GB] inherit</div><div>  ACTIVE            '/dev/data/windows2003_web' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/storage' [50.00 GB] inherit</div>
<div>  ACTIVE   Original '/dev/data/hfserver2' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/hfdns02' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/pluto' [30.00 GB] inherit</div>
<div>  ACTIVE   Snapshot '/dev/data/pluto_s' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/system/root' [39.06 GB] inherit</div><div>  ACTIVE            '/dev/system/swap' [9.75 GB] inherit</div>
<div><br></div><div><div>[root@xen ~]# lvchange -ay VolGroup00</div><div>[root@xen ~]# lvscan</div><div>  ACTIVE            '/dev/VolGroup00/LogVol00' [27.94 GB] inherit</div><div>  ACTIVE            '/dev/VolGroup00/LogVol01' [1.94 GB] inherit</div>
<div>  ACTIVE            '/dev/data/cpanel002' [100.00 GB] inherit</div><div>  ACTIVE            '/dev/data/windows2003_web' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/storage' [50.00 GB] inherit</div>
<div>  ACTIVE   Original '/dev/data/hfserver2' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/hfdns02' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/pluto' [30.00 GB] inherit</div>
<div>  ACTIVE   Snapshot '/dev/data/pluto_s' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/system/root' [39.06 GB] inherit</div><div>  ACTIVE            '/dev/system/swap' [9.75 GB] inherit</div>
<div><br></div><div><div>[root@xen ~]# e2fsck /dev/VolGroup00/LogVol00</div><div>e2fsck 1.39 (29-May-2006)</div><div>/dev/VolGroup00/LogVol00: clean, 631982/7325696 files, 4512772/7323648 blocks</div><div><br></div><div><br>
</div><div>At first it found a whole lot of damages inodes which I repaired.</div><div><br></div><div>Then, I reversed the process:</div><div><br></div><div><div>[root@xen ~]# lvchange -an VolGroup00</div><div>[root@xen ~]# lvscan</div>
<div>  inactive          '/dev/VolGroup00/LogVol00' [27.94 GB] inherit</div><div>  inactive          '/dev/VolGroup00/LogVol01' [1.94 GB] inherit</div><div>  ACTIVE            '/dev/data/cpanel002' [100.00 GB] inherit</div>
<div>  ACTIVE            '/dev/data/windows2003_web' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/storage' [50.00 GB] inherit</div><div>  ACTIVE   Original '/dev/data/hfserver2' [30.00 GB] inherit</div>
<div>  ACTIVE            '/dev/data/hfdns02' [30.00 GB] inherit</div><div>  ACTIVE            '/dev/data/pluto' [30.00 GB] inherit</div><div>  ACTIVE   Snapshot '/dev/data/pluto_s' [30.00 GB] inherit</div>
<div>  ACTIVE            '/dev/system/root' [39.06 GB] inherit</div><div>  ACTIVE            '/dev/system/swap' [9.75 GB] inherit</div><div><br></div><div><br></div><div><div><br></div><div>[root@xen ~]# vgchange -an VolGroup00</div>
<div>  0 logical volume(s) in volume group "VolGroup00" now active</div><div>[root@xen ~]# kpartx -d /dev/loop4</div><div>[root@xen ~]# losetup -d /dev/loop4</div><div>[root@xen ~]#</div><div><br></div><div><div>
[root@xen ~]# xm create -c /etc/xen/hfserver2</div><div><br></div><div><br></div><div>And then it dies:</div><div><br></div><div><br></div><div><div> Reading all physical volumes.  This may take a while...</div><div>  Found volume group "VolGroup00" using metadata type lvm2</div>
<div>Activating logical volumes</div><div>  2 logical volume(s) in volume group "VolGroup00" now active</div><div>Creating root device.</div><div>Mounting root filesystem.</div><div>kjournald starting.  Commit interval 5 seconds</div>
<div>EXT3-fs: mounted filesystem with ordered data mode.</div><div>Setting up other filesystems.</div><div>Setting up new root fs</div><div>no fstab.sys, mounting internal defaults</div><div>Switching to new root and running init.</div>
<div>unmounting old /dev</div><div>unmounting old /proc</div><div>unmounting old /sys</div><div>exec of init (/sbin/init) failed!!!: No such file or directory</div><div>Kernel panic - not syncing: Attempted to kill init!</div>
</div></div></div></div></div></div></div></div></div><div> [root@xen ~]#  </div></div><br clear="all"><br>-- <br>Kind Regards<br>Rudi Ahlers<br>CEO, SoftDux Hosting<br>Web: <a href="http://www.SoftDux.com">http://www.SoftDux.com</a><br>
Office: 087 805 9573<br>Cell: 082 554 7532<br>