[PVE-User] Query disk usage

Dmitry Petuhov mityapetuhov at gmail.com
Wed Mar 8 13:32:22 CET 2017

08.03.2017 13:31, Marco Gaiarin wrote:
> Two question.
> 1) switching from VirtIO to SCSI-VirtIO mean that /dev/vda became
>  /dev/sda, right? So i have to keep into account for initrd and so on,
> right?
Usually it is seamless for guest, if all FSes are mounted by LVM path or partition/fs UUID,
which is default behavior of all current major distros. See /etc/fstab and /proc/cmdline
If there's no /dev/vd? entries, then there's nothing to worry about.

Also, you need relatively fresh distro in guest. Virtio-scsi driver is available in CentOS >=6,
Debian >=7 and so on (I don't use other distros).

> 2) also 'VirtIO' (plain) have the 'discard' box thickable. Why?

"discard" is option of image. But it is actually available only if interface
supports it. Like TRIM is supported on modern SSDs, but you can't use it with
old SAS controllers that do not support it.

Discard support on virtio-blk is on qemu's TODO list, but seems to be
not very important feature for them.

> I've found:
> 	https://pve.proxmox.com/wiki/Qemu_trim/discard_and_virtio_scsi
> but there's some data about performance loss (i think) enabling
> discard?
Yes, underlaying storage may need some extra work to actually wipe out huge
amounts of data at once, causing extra delays. For example on CEPH, it have to
delete hundreds of 4-MB files from backing disks, which is pretty slow operation.
Some storages do it faster, some slower, some ignores it at all. Just do some
tests and see if you can afford it.

More information about the pve-user mailing list