mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-02 20:02:29 +01:00
KVM hosts which are actuall up, but if their agents are shutdown should be put in disconnected state. This would avoid getting the VMs HA'd and other commands such as deploying a VM will exclude that host and save us from errors. The improvement is that, we first try to contact the KVM host itself. If it fails we assume that it's disconnected, and then ask its KVM neighbours if they can check its status. If all of the KVM neighbours tell us that it's Down and we're unable to reach the KVM host, then the host is possibly down. In case any of the KVM neighbours tell us that it's Up but we're unable to reach the KVM host then we can be sure that the agent is offline but the host is running. Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com> Signed-off-by: wilderrodrigues <wrodrigues@schubergphilis.com> This closes #340