一、依赖于lvm创建
lvcreate -L 1.6T -n kvmdata /dev/VolGroup00
二、修改domain xml
virsh edit domainname <disk type='block' device='disk'> <driver name='qemu' type='raw' cache='none'/> <source dev='/dev/VolGroup00/kvmdata'/> <target dev='vdb' bus='virtio'/> </disk>
哦了,重启domain name就可以了
三、 live add disk, 在线添加,重启失效
virsh attach-disk DomainName /dev/sr0 vdc --config --type cdrom --mode readonly
官方文档
https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Virtualization_Administration_Guide/sect-Virtualization-Adding_storage_devices_to_guests-Adding_hard_drives_and_other_block_devices_to_a_guest.html
转载于:https://blog.51cto.com/foxhound/1841207