FreeBSD 9.1 - disk growing
FreeBSD 9.1 disk growing.
1) resize underlying volume (some lvextend here..)
2) use servisni freebsd10: /etc/libvirt/domains/cldn/qemu/kvm_cldn_freebsd-servisni.xml (not defined in libvirt, use just create) and attach appropriate disk to this "servisni" qemu quest:
<disk type="block" device="disk">
<source dev="/dev/vg_lh4_0/<some production disk>"/>
<target dev="vdb" bus="virtio"/>
<driver name="qemu" discard="unmap" cache="writethrough"/>
<boot order="2"/>
</disk>
3) GPT has signature on the start and on the end of disk. When disk became larger, "end" signature lost and is needed to renew. Detect and repair corrupted gtp table by invoking:
gpart show (find string: [CORRUPT] and use coresponding device in the next command) gpart recover vtbd1
4) resize appropriate partition (-i) to max:
gpart resize -i 1 vtbd1
5) resize FS on appropriate partition (p1):
growfs /dev/vtbd1p1
6) shut down "servisni"
7) Don't forget remove production disk from this "servisni" xml domain to avoid disk corrupt on unexpected run of "servisni" !!!