Exemplo n.º 1
0
    def _configureKvm(self):
        super(CentOS, self)._configureKvm()
        self.executeCmd(['/etc/init.d/libvirtd start'])
        # Sleep to give a chance to libvirt to create the libvirt-sock
        Util.sleep(5)
        self.executeCmd(['usermod', '-G', 'kvm', '-a', self.oneUsername])
        self.executeCmd(['chown', 'root:kvm',
                        '/var/run/libvirt/libvirt-sock'])
        self.executeCmd(['chmod', 'g+r+w', '/var/run/libvirt/libvirt-sock'])

        self.executeCmd('ln -s /usr/libexec/qemu-kvm /usr/bin/qemu-kvm'.split())