Have HyperV behave in 4.4 and return null instead of falseCommit 6a4927f660 made the HyperV investigator return false instead of null.
Returning false means the VM is NOT running, returning null means "I don't know". In 4.4 I experienced corruption because of HyperV returning false, instead of null.
Tonight I experienced corruption when one of our management servers went down (out-of-memory, not root caused yet). While all hypervisors that were connected to this management server were connecting the other, HA work started as well with investigators. HyperV happily reported everything as down (while it was still running), causing a mess.
In 4.5 and master this was already fixed. If you know a better way to fix this, please let me know!
This may cause another FindBugs alert, not sure how to resolve that. I just want this out ASAP. Maybe @DaanHoogland @wilderrodrigues or @miguelaferreira can advise on how to fix this properly.
* pr/761:
Have HyperV behave in 4.4 and return null instead of false
Signed-off-by: Wilder Rodrigues <wilder.rodrigues@ekholabs.nl>
Commit 6a4927f660 made the HyperV investigator return false insteads of null.
Returning false means the VM is NOT running, returning null means "I don't know". In 4.4 I experienced corruption because of HyperV returning false, instead of null.
When dumping XML use appropriate flags:
1, VIR_DOMAIN_XML_SECURE (dump security sensitive information too)
8, VIR_DOMAIN_XML_MIGRATABLE (dump XML suitable for migration)
Source:
https://libvirt.org/html/libvirt-libvirt-domain.html#virDomainXMLFlags
This fixes CVE 2015-3252: VNC password lost during VM migration across KVM
hosts. The issue is also seen when a VM is rebooted.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit cb2aca7516)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
This allows non-root users to add KVM hosts, the user should be an admin or
added to sudoers to execute sudo cloudstack-setup-agent.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Signed-off-by: Remi Bergsma <apache@remi.nl>
This closes#288
We don't need an external script to investigate the format of the RBD volume,
we only have to ask Libvirt to resize the volume and that will ask librbd to
do so.
Backport for 4.4, original commit: 173909e99d
The console-setup service brings a nice font to the console, but why would we
want to use it. In most cases it takes a <10 seconds to set it up. When using
nested hypervising, I found this takes much longer time that causes tests to
time-out. I'd suggest turning off these services. They are not required for the
services the systemvm provides.
Manually picked from commit 95e7673
PR #254
(cherry picked from commit 5921c493c8)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Without this upgrades from 3.0.7 version fails.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit a0cff4ca48)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
When a full cluster is down or unreachable,
CloudStack currently reports everything the
same as the last known state, which is usually
Up. When it cannot reach a host and cannot
reach another host in the same cluster either,
it returns null and says "I don't know". This
prevents it from reporting the problem. Now,
we return an Alert or Disconnected state so
proper action can be taken.
Also logging was added, so we know what part
of the code put it to Alert or Disconnected.
This is fixed already in master and 4.5 and did not occur in 4.3 and before.
This fixes it in 4.4 as well.
This closes#182
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
As recently discussed on the dev list:
This sorts the domain lists based on their path.
Especially handy when having a lot of domains,
like in a public cloud.
CentOS 7 does not ship with ifconfig anymore. We should use ip commands instead.
This also works on older versions, like CentOS 6 and Ubuntu 12.x/14.x, that we
support.
This closes#165
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>