Server
- FOG Version: 1.3.0
- OS: Ubuntu 16.04.1 LTS
Client
- Service Version: Debian Lenny
- OS: Debian lenny (any modern Linux with virtio block driver)
Description
During Image Creation or Image Restore disks are not found if using paravirtual drivers (virtio).
When a VirtualMachine uses VirtIO (KVM/VMware) or (presumibily) XEN vbd disk, during capture/deploy process fog reports this error: “Cannot find disk on system (getHardDisk)”
I have see the code and I think it could be fixed adding the next Major numbers to the lsblk filter: 202(Xen) and 253 (VirtIO)
So, the code will be something like this:
cat fogproject/src/buildroot/package/fog/scripts/usr/share/fog/lib/funcs.sh
...snip...
getHardDisk() {
[[ -n $fdrive ]] && hd=$(echo $fdrive)
[[ -n $hd ]] && return
->>> local devs=$(lsblk -dpno KNAME -I 3,8,9,179,202,253,259 | uniq | sort -V) <<<-
disks=$(echo $devs)
[[ -z $disks ]] && handleError "Cannot find disk on system (${FUNCNAME[0]})\n Args Passed: $*"
[[ $1 == true ]] && return
for hd in $disks; do
break
done
}