When you’re running a server in a Virtual Environment with type one hypervisor and you’re require to add a new disk to your virtual machine then you will not have to bring down the server to add a new disk. You can do it with uptime. Here’s how you can do it in Citrix XenServer.
Connect to your XenServer using XenCenter(On Windows) or OpenXenManager(Linux – Unofficial). I’m using OpenXenManager.
Select a Virtual Machine in which you want to add a new disk. Open Storage tab and click on Add button.
Select which storage you want to use to create a Virtual Disk from. Name your virtual disk, fill a descriptive description or the purpose of the disk. e.g. what it will be used for. Size of the Virtual Disk and click on Apply button.
Verify the new storage in Storage tab of your Virtual Machine.
Login to your VM and list disks using fdisk utility.
[root@dbnode1 postgres]# fdisk -l
Disk /dev/xvda: 214.7 GB, 214748364800 bytes, 419430400 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x000cdbad
Device Boot Start End Blocks Id System
/dev/xvda1 * 2048 2099199 1048576 83 Linux
/dev/xvda2 2099200 419430399 208665600 8e Linux LVM
Disk /dev/mapper/ol_dbnode1-root: 53.7 GB, 53687091200 bytes, 104857600 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mapper/ol_dbnode1-swap: 2147 MB, 2147483648 bytes, 4194304 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mapper/ol_dbnode1-home: 157.8 GB, 157831659520 bytes, 308264960 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/xvdb: 5368 MB, 5368709120 bytes, 10485760 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0xc5005674
Check this post to know how to mount it.
There you go. Peace 🙂