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

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



> I have a Windows 2003 domU in an LVM partition.
> I want to enlarge this partition in order to have more space for windows
> 2003.
>
> So in your post you say:
> > 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
>
> but for me the problem is that fdisk can't enlarge a partition! It
> says you must delete it and then recreate it, but if I do this I lose
> all my 2003 system.

Well, in principle I guess that ought to work, right?  I mean the data will 
still be there, and once you've recreated the partition table it should be 
possible to find the filesystem again.  Mmm?  Maybe try it on a copy for 
safety's sake?

Doesn't Windows have any facility for expanding filesystems?  Worst case, you 
could just export another drive to Windows (and, if you want, mount it 
somewhere in the filesystem hierarchy - 2k3 can do that).

Cheers,
Mark

> How can I enlarge my 2003 partition (and update the MBR for windows to
> recognize it)?
>
> ntfsresize tells me:
>
> Current volume size: 10470748672 bytes (10471 MB)
> Current device size: 10470749184 bytes (10471 MB)
> New volume size    : 10470744576 bytes (10471 MB)
> Nothing to do: NTFS volume size is already OK.
>
> So my LVM partition have been enlarged, but ntfsresize don't see it.
> You solved it with fdisk? and how?
>
> Windows 2003 is in one big partition, so it will need to boot after
> the resize :)
>
> Thanks for your help!
>
> Jordi.S
>
> On 1/31/07, Derek <xen@xxxxxxxxxxxxxxxx> wrote:
> > 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
>
> _______________________________________________
> Xen-users mailing list
> Xen-users@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-users

-- 
Dave: Just a question. What use is a unicyle with no seat?  And no pedals!
Mark: To answer a question with a question: What use is a skateboard?
Dave: Skateboards have wheels.
Mark: My wheel has a wheel!

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.