XenServer

From Hack Sphere Labs Wiki
Revision as of 20:20, 14 June 2015 by Webdawg (talk | contribs) (Adding an additional hard drive to XenServer)

Jump to: navigation, search

Creating Local ISO Library

ssh box
df -h

Not alot of space huh?

pvs

Look at all that space

vgs

Create a new LV group to Store ISOs

lvcreate -L 20G -n IsoImages VG_XenStorage-dae27f11-a60d-35d2-075a-b1c2e5fa1d81

Format that thing

mkfs.ext3 /dev/VG_XenStorage-dae27f11-a60d-35d2-075a-b1c2e5fa1d81/IsoImages

Create a place for it

mkdir /mnt/IsoImages

Turn on the LVM

vgchange -a y

Create the ISO repo in Xen

xe sr-create name-label=IsoImages type=iso device-config:location=/mnt/IsoImages/ device-config:legacy_mode=true content-type=iso

Check that Xen can see it

 xe sr-list

Mount it

mount -t ext3 /dev/VG_XenStorage-dae27f11-a60d-35d2-075a-b1c2e5fa1d81/IsoImages /mnt/IsoImages

Add it to fstab

echo "/dev/VG_XenStorage-dae27f11-a60d-35d2-075a-b1c2e5fa1d81/IsoImages /mnt/IsoImages ext3 defaults 1 1" >> /etc/fstab

Adding an additional hard drive to XenServer

fdisk -l
xe sr-create name-label=2TBNoRaid shared=false device-config:device=/dev/sdb type=lvm

Adding a existing network to a VM

xe vm-list
xe network-list
xe vif-create network-uuid=<networkuuid> vm-uuid=<vmuuid> device=2