Date: Sat, 1 Aug 2015 20:12:51 +0300 From: Nikos Vassiliadis <nvass@gmx.com> To: "freebsd-virtualization@freebsd.org" <freebsd-virtualization@freebsd.org> Subject: hot-plugging disks to a VM Message-ID: <55BCFE13.2070501@gmx.com>
next in thread | raw e-mail | index | archive | help
Hi, I was thinking of creating a HAST disk and using that as second disk to a VM. It seems that when the backing file is gone and returned, it's never re-opened. Is this scenario possible? Host machine: > root@moby:~/VMs # diskinfo /dev/hast/shared > /dev/hast/shared 512 21474830848 41943029 0 0 and from withing the VM: > root@lamb:~ # diskinfo /dev/vtbd2 > /dev/vtbd2 512 21474830848 41943029 0 0 > root@lamb:~ # file -s /dev/vtbd2 > /dev/vtbd2: Unix Fast File system [v2] (little-endian) last mounted on /mnt, last written at Sat Aug 1 19:33:17 2015, clean flag 0, readonly flag 0, number of blocks 5242878, number of data blocks 5076797, number of cylinder groups 33, block size 32768, fragment size 4096, average file size 16384, average number of files in dir 64, pending blocks to free 0, pending inodes to free 0, system-wide uuid 0, minimum percentage of free blocks 8, TIME optimization Then I go to the host, destroy /dev/hast/shared and re-create it. The VM is not able to use the disk anymore: > root@lamb:~ # file -s /dev/vtbd2 > vtbd2: hard error cmd=read 0-255 > /dev/vtbd2: ERROR: cannot read `/dev/vtbd2' (Input/output error) Is this possible? Can I somehow achieve hot-plugging a disk? Thanks for any thoughts, Nikos
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?55BCFE13.2070501>