Adding a local storage repository to Citrix XenServer 5.x

Adding a local storage repository to a Citrix XenServer 5.x server can be done as follows:

NOTE: Extra precaution should be taken while using the following commands, as it could result in data loss.  Only perform these steps if you know what you are doing:

  1. Locate the disk ID by using the following command:
    # ls -al /dev/disk/by-id
  2. Create the local storage repository:
    # xe sr-create content-type=user device-config:device=/dev/disk/by-id/<scsi-xxxxxxxxxxxxxxxxxxxxxxxxx> name-label=”Local Storage X” shared=false type=lvm