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] setting-up lvm-based VMs on a non-LVM Lenny setup

Darko Petroviç wrote:
You can still change it if you have enough free space. Boot a Linux distro from Live CD (Ubuntu or Knoppix for instance) and start the partition editor. You will be able to shrink your system so as to leave room for LVM volumes.

But be careful, in the *general* case, modifying partitions is usually a destructive thing - ie it will destroy whatever is in the partition. Unless the editor explicitly supports resizing a partition (and the filesystem within it) then you'll need to do some manual work - it's something I've done a few times.


Assuming EXT2 or EXT3, you can do it by :

Make sure you have a backup/means of recovery if it goes wrong.
Check (fsck -f) the filesystem (resize2fs will refuse to work unless you do).
Resize (shrink) the filesystem with resize2fs.
Delete the partition.
Re-create the partition making sure that it starts in the same place and is equal or larger in size than the filesystem size. If you didn't make the partition exactly the same size as the filesystem, resize the filesystem again to fill the partition.

You now have a smaller partition with the same files in it - just less free space.

--
Simon Hobson

WANTED: "Software CD ROM Kit" for Canon CLBP 360-PS printer (Canon part no RH6-3612, or possibly RH6-3810, or RH6-3610 might do). I've a dead HD and need this CD so I can replace the disk and re-install the printer OS on it. If anyone knows where I might get hold of one I'd be grateful - requests to Canon drew a blank, it's been out of support for years. Alternatively, if anyone has one of these and would let me image their hard disk ...

Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.

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