WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] how to run fsck for a crashed domU?

To: Rudi Ahlers <Rudi@xxxxxxxxxxx>, xen-users@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-users] how to run fsck for a crashed domU?
From: Alexander Hoßdorf <xen-users@xxxxxxxxxxx>
Date: Fri, 01 Aug 2008 17:58:21 +0200
Cc:
Delivery-date: Fri, 01 Aug 2008 09:00:14 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <48933178.7080808@xxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <20080801135141.mrkyj00vi8888888@localhost> <90eb1dc70808010648i74f99ac1s5cfa37fd4ad66c80@xxxxxxxxxxxxxx> <48931993.7050809@xxxxxxxxxxx> <489326F2.9090101@xxxxxxxxxxx> <48933178.7080808@xxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.16 (Windows/20080708)
Sorry, I read to fast ;-)

/dev/sysvg/root is your real root partition?!



inactive          '/dev/VolGroup00/LogVol00' [9.34 GB] inherit

This seems to be your root lvm partition from the Image, am I right?

have you tried:

e2fsck /dev/VolGroup00/LogVol00

?

Cheers,
Alex


Alexander Hoßdorf schrieb:
ACTIVE            '/dev/sysvg/root' [2.00 GB] inherit

I guess this is your root lvm partition from the Image?

try: e2fsck /dev/sysvg/root

Cheers,
Alex



Rudi Ahlers schrieb:
Alexander Hoßdorf wrote:
okay, I got it now...

step by step...

1. losetup /dev/loop4  /home/vm/vm01.img
# This mounts the image file as imaginary physical to /dev/loop4

2. kpartx -va /dev/loop4
# This creates a device map with partitions in vm01.img in /dev/mapper

3. vgscan
# This should discover your lvm VGs from Image.

4. lvscan
# Should list the ACTIVE  volumes.

5. Now you can do e2fsck to the volumes listet by lvscan.
But be sure to e2fsck only the LVs from yout Image if you're using lvm in Dom0, too.

Please give feedback if this worked for you.


Cheers,
Alex ______________________________________________
Awesome, thanx!!!

I got as far as seeing the partitions, but can only run e2fsck on one of them:

lvscan
 ACTIVE            '/dev/backup/pluto' [20.00 GB] inherit
 ACTIVE            '/dev/backup/bck' [40.00 GB] inherit
 ACTIVE            '/dev/backup/anya_zanet' [7.00 GB] inherit
 inactive          '/dev/VolGroup00/LogVol00' [9.34 GB] inherit
 inactive          '/dev/VolGroup00/LogVol01' [544.00 MB] inherit
 ACTIVE            '/dev/sysvg/root' [2.00 GB] inherit
 ACTIVE            '/dev/sysvg/usr' [8.00 GB] inherit
 ACTIVE            '/dev/sysvg/var' [8.00 GB] inherit
 ACTIVE            '/dev/sysvg/home' [53.38 GB] inherit
 ACTIVE            '/dev/sysvg/tmp' [1.00 GB] inherit

There's no VolGroup00 in /dev/ - but I do see /dev/mapper/loop4p1 & /dev/mapper/loop4p2

Running e2fsck on it seems ok,

# e2fsck /dev/mapper/loop4p1
e2fsck 1.39 (29-May-2006)
/boot: clean, 45/26104 files, 22630/104388 blocks



Yet, when booting up, I still get the error :(

[/sbin/fsck.ext3 (1) -- /] fsck.ext3 -a /dev/VolGroup00/LogVol00
/dev/VolGroup00/LogVol00 contains a file system with errors, check forced.
/dev/VolGroup00/LogVol00: Inode 67830 has illegal block(s).

/dev/VolGroup00/LogVol00: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.
       (i.e., without -a or -p options)
[FAILED]

*** An error occurred during the file system check.
*** Dropping you to a shell; the system will reboot
*** when you leave the shell.




_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

__________ Hinweis von ESET NOD32 Antivirus, Signaturdatenbank-Version 3317 (20080801) __________

E-Mail wurde geprüft mit ESET NOD32 Antivirus.

http://www.eset.com





_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

<Prev in Thread] Current Thread [Next in Thread>