DEV Community

Pradeep Kumar
Pradeep Kumar

Posted on

Attach physical hard disk to Xen/XCP-ng Server

Login to Server via SSH.

Install lshw

yum install lshw
Enter fullscreen mode Exit fullscreen mode

Check disks:

lshw -class disk -short
Enter fullscreen mode Exit fullscreen mode

This command will show the device name of disks.

Get host uuid:

xe host-list
Enter fullscreen mode Exit fullscreen mode

Create/Attach disk:

xe sr-create content-type=user device-config:device=<device-name> host-uuid=<host-uuid> name-label="Disk-Label"  shared=false type=ext
Enter fullscreen mode Exit fullscreen mode

This will return new disk uuid and now you will be able to see the disk with the label in Storage section of your Xen Center or XCP-ng Center

Top comments (0)