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

[Xen-users] Managing DomU partitions in XEN+LVM systems?

To: "xen ml" <xen-users@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-users] Managing DomU partitions in XEN+LVM systems?
From: Derek <xen@xxxxxxxxxxxxxxxx>
Date: Wed, 31 Jan 2007 09:05:17 -0700
Delivery-date: Wed, 31 Jan 2007 08:05:57 -0800
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:sender:to:subject:mime-version:content-type:x-google-sender-auth; b=S1eHjeWlwvaJSFsjv+1E/1f7DjF/b03L5UR9RFNIXTZe4g1RWTK2ezjCK7pv0TJLre4GnFviv7ffQzsfi0M/e+lC1XtzHtTPwswNnTNMEDWFF/wW3K3c9R71t6VMaapx23ntgMzH5oEXr5BM6ZexKMAi6oG6fFFQmphYo3X0us4=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
Hi all,

This is more an LVM question than a XEN one.   But hopefully not too far off topic for the Xen list...

I am running an HVM domU partitions (WinXP).  I assigned a root drive that is an LVM logical volume as seen by the Dom0, in other words:

  disk = [ 'phy:/dev/mapper/main-root_disk_winxp,hda,w' , ... others ... ]

WinXP's installer sees the logical volume as a whole disk, and promptly partitions it.  So, it ends up with a partition table and one large NTFS filesystem partition.

Now later, I decided to enlarge the logical volume, it's associated partition, and it's associated NTFS filesystem.

That would seem trivial to do, from within dom0 (while the domU is not running of course.)  Just use:
  - lvextend to enlarge the volume
  - fdisk (or parted) to enlarge the partition
 - ntfsresize to enlarge the filesystem

The first two steps work flawlessly.  The third step is problematic, because ntfsresize wants to be told the device path to the _partition_, not to the _whole_disk_.  Well, /dev/mapper/main-root_disk_winxp is the whole disk, but there's no corresponding /dev/mapper/main-root_disk_winxp1 for the paritition on it.  LVM+UDEV+DM don't give you one.

I'm not stuck, I have a workaround yet to try:   linux in a domU, and run fdisk+ntfsresize there.  The linux DomU will presumably contain a device nodes for the partition, and I can run ntfsresize within it.  But I'm asking this because I'm sure there's  a more elegant solution, and someone on this list probably knows it.  Surely there's a way to persuade LVM+UDEV+DM to produce device nodes for each partition within each logical volume?  (I know roughly how to write UDEV rules, but this problem goes beyond that, and I definitely don't understand the device mapper).

Thanks,
Derek.
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
<Prev in Thread] Current Thread [Next in Thread>