tools: virt-host-validator is not consistent on how it treats warnings
Software environment
- Operating system: Fedora 34
- Architecture: aarch64
- kernel version: 5.12.8-300.fc34.aarch64
- libvirt version: 7.0.0 (7.0.0-4.fc34.aarch64)
- Hypervisor and version: QEMU 5.2.0 (qemu-5.2.0-7.fc34)
Description of problem
virt-host-validate doesn't treat warnings consistently. Either a warn should not cause the command to fail, or any warning should cause the command to fail.
[root@dentola]# virt-host-validate qemu
QEMU: comprobando if device /dev/kvm exists : PASA
QEMU: comprobando if device /dev/kvm is accessible : PASA
QEMU: comprobando if device /dev/vhost-net exists : PASA
QEMU: comprobando if device /dev/net/tun exists : PASA
QEMU: comprobando for cgroup 'cpu' controller support : PASA
QEMU: comprobando for cgroup 'cpuacct' controller support : PASA
QEMU: comprobando for cgroup 'cpuset' controller support : PASA
QEMU: comprobando for cgroup 'memory' controller support : PASA
QEMU: comprobando for cgroup 'devices' controller support : PASA
QEMU: comprobando for cgroup 'blkio' controller support : PASA
ADVERTENCIA (Unknown if this platform has IOMMU support)
QEMU: comprobando for secure guest support : ADVERTENCIA (Unknown if this platform has Secure Guest support)
[root@dentola]# echo $?
1
Steps to reproduce
- On a default Fedora machine, run
virt-host-validate qemu
- Check its result when warnings are present