I installed XenServer 6.0 on a machine with 2 drives (80GB SSD and 1TB SATA). My goal is to have some space for local storage where I can put ISO (since it will be very difficult to access the box physically, and I would prefer to install VMs from ISOs and not from CDs).
However, no matter what I specify for LVM, the only filesystem on sda is 4G (and only 2GB is available). XenCenter shows me plenty of disk space available for VMs; but that doesn't help me with ISOs.
Is it possible to increase local storage? I haven't started building VMs yet – so now is ideal time to partition the disk the way it should be. But parted is not installed – and I suspect for a reason.
Here is the output from pvdisplay:
[root@xenserver ~]# pvdisplay
--- Physical volume ---
PV Name /dev/sdb
VG Name VG_XenStorage-a7bbe7ea-f205-5f25-4ef8-daec4e08bcb2
PV Size 931.51 GB / not usable 6.41 MB
Allocatable yes
PE Size (KByte) 4096
Total PE 238464
Free PE 238463
Allocated PE 1
PV UUID yqrKQi-l8mD-k3mo-PxEs-M0bK-7xx3-17nnzE
"/dev/sda3" is a new physical volume of "66.53 GB"
--- NEW Physical volume ---
PV Name /dev/sda3
VG Name
PV Size 66.53 GB
Allocatable NO
PE Size (KByte) 0
Total PE 0
Free PE 0
Allocated PE 0
PV UUID HlXvAo-f6gw-eqMz-5Y1d-YzYi-19tK-xZTWoE
So, the real question is, how can I make use of 66GB on /dev/sda3
without breaking anything in XenServer?
Best Answer
From archy.net:
Type :
fdisk -l
you’ll see the list of all volumes and hard drives, then :
Type :
pvcreate /dev/sdb
sdb is my new volume
and then to configure it as a local storage :
Type :
xe sr-create type=lvm content-type=user device-config:device=/dev/disk/by-id/scsi-SATA_ST3320620AS_5QF7QZZL name-label=”LOCAL SR”
scsi-SATA_ST3320620AS_5QF7QZZL
is the name of my volume, you’ll have to change this value with your own, and name-label is the name you want to give to your local storage.and this is it !
Remark : If your XenServer is a pool, you need to put it off, follow above steps and put back the XenServer in your pool.