XEN host operations (advanced)

XFS grow

Extend the size of a sparse image file (by adding some zeroes to it),

dd if=/dev/zero bs=1G count=10 >> suricat.img

Shutdown the guest, mount its fs and grow it, and bring it back,

xl shu suricat

mkdir lala
mount -o loop suricat.img lala
df -hT
xfs_growfs /data/guests/suricat/lala
df -hT
umount lala
rmdir lala

xl create suricat

Can I expand the size of a file based disk image? https://superuser.com/questions/693158/can-i-expand-the-size-of-a-file-based-disk-image

Hot-add disk

xl block-attach slackext4 tap:tapdisk:aio:/data/guests/slackext4/slackext4.data.ext4 xvdb1 w

How to dynamically attach a disk to running DomU in Xen? https://www.systutorials.com/how-to-dynamically-attach-a-disk-to-running-domu-in-xen/

Xen Disk Hot Add (Block Device) Howto https://backdrift.org/xen-disk-hot-add-block-device-howto


HOME | GUIDES | LECTURES | LAB | SMTP HEALTH | HTML5 | CONTACT
Copyright © 2024 Pierre-Philipp Braun