On Sat, Nov 03, 2007 at 05:16:54PM +0000, Chris G wrote:
OK, so I have cleared everything off my /dev/sda (except, presumably, the MBR) and all is well still, Fedora still boots and my Windows guest virtual machine is still working.
How do I now set up /dev/sda using LVM? As I understand it the sequence is to create a Physical Volume using pvcreate, then a Logical Group that uses the Physical Volumes I have created and then I create a logical volume in the Logical Group.
The problem is that I don't understand how you tell pvcreate what disk it is to use. The 'synopsis' on the pvcreate man page says:-
SYNOPSIS pvcreate [-d|--debug] [-f[f]|--force [--force]] [-y|--yes] [-h|--help] [-t|--test] [-v|--verbose] [--labelsector] [-M|--metadatatypetype] [--metadatacopies#copies] [--meta- datasizesize] [--restorefilefile] [--setphysicalvolumesizesize] [--version] [-Z|--zeroy/n] PhysicalVolume [PhysicalVolume...]
Which doesn't seem to give much clue as to what disk it uses, PhysicalVolume is (as I understand it) the name that pvcreate gives to the chunk of disk you want to use, so what disk does it use?
It's OK, although the man page wasn't very clear the example was, a PhysicalVolume is simply the same name as the device, so I just say:-
pvcreate /dev/sda2
So now I have created my PhysicalVolume and I have created a Logical Group that is just that PhysicalVolume I'm now stuck trying to set the size of a VolumeGroup to use all of the space.
If I just say:-
lvcreate VolGroupA2
I get an error saying "Please specify either size or extents (not both)", there seems no way to specify 'all' and I can't find anything that tells me what the parameters to --size mean.
Help!? :-)