Fix find_free_vm_number
Not only did find_free_vm_number never work (taking the CIDR part of the IP address as part of the last byte, getting xxx\24 instead of just xxx), now it must base its functioning on the contents of /etc/hosts.
How to do it
The find_free_vm_number function:
- Find last used IP address based on the contents of
/etc/hosts - Increment the last byte of the address
- Print the result
The number won't be 100 based any more. Thus, update_hypervisor_config should not substract 100 from the number returned by find_free_vm_number any more.