LXC does not have any native system VMs, instead KVM will be used to run
system VMs. This means that your host will need to support both LXC and
KVM, thus most of the installation and configuration will be identical
to the KVM installation. The material in this section doesn’t duplicate
KVM installation docs. It provides the CloudStack-specific steps that
are needed to prepare a KVM host to work with CloudStack.

Warning

Before continuing, make sure that you have applied the latest updates to
your host.

Warning

It is NOT recommended to run services on this host not controlled by
CloudStack.

CloudStack uses libvirt for managing virtual machines. Therefore it is
vital that libvirt is configured correctly. Libvirt is a dependency of
cloudstack-agent and should already be installed.

In order to have live migration working libvirt has to listen for
unsecured TCP connections. We also need to turn off libvirts attempt
to use Multicast DNS advertising. Both of these settings are in
/etc/libvirt/libvirtd.conf

Set the following parameters:

listen_tls=0

listen_tcp=1

tcp_port="16509"

auth_tcp="none"

mdns_adv=0

Turning on “listen_tcp” in libvirtd.conf is not enough, we have to
change the parameters as well:

On RHEL or CentOS modify /etc/sysconfig/libvirtd:

Uncomment the following line:

#LIBVIRTD_ARGS="--listen"

On Ubuntu: modify /etc/default/libvirt-bin

Add “-l” to the following line

libvirtd_opts="-d"

so it looks like:

libvirtd_opts="-d -l"

In order to have the VNC Console work we have to make sure it will
bind on 0.0.0.0. We do this by editing /etc/libvirt/qemu.conf