sudo apt-get install -y libvirt-bin virtinst qemu-kvm virt-manager git wget genisoimage
sudo service libvirt-bin startFor the Windows VM support install bsdtar (this tool allows to extract zip archive from stdin):
sudo apt-get install bsdtarsudo yum install -y libvirt virt-install qemu-kvm virt-manager git wget genisoimage NetworkManager
sudo service libvirtd startFor the Windows VM support install bsdtar (this tool allows to extract zip archive from stdin):
sudo yum install bsdtarThis string inside your ~/.profile will allow you to use virsh:
export LIBVIRT_DEFAULT_URI=qemu:///system- Ubuntu 18.04 (
systemd-resolved(c))
The setting below is not preserved on reboot:
systemd-resolve --set-dns=192.168.122.1 --set-domain=vm --interface=virbr0Verify:
systemd-resolve --status virbr0Add the following section into libvirt default network (sudo virsh net-edit default):
<domain name='vm' localOnly='yes'/>And restart the network:
sudo virsh net-destroy default
sudo virsh net-start default- Ubuntu/Debian
virsh net-dumpxml default | sed -r ":a;N;\$!ba;s#.*address='([0-9.]+)'.*#nameserver \1#" | sudo tee -a /etc/resolvconf/resolv.conf.d/head && sudo resolvconf -u- Fedora/CentOS
sudo systemctl enable NetworkManager
echo -e "[main]\ndns=dnsmasq" | sudo tee -a /etc/NetworkManager/NetworkManager.conf
virsh net-dumpxml default | sed -r ":a;N;\$!ba;s#.*address='([0-9.]+)'.*#server=\1\nall-servers#" | sudo tee /etc/NetworkManager/dnsmasq.d/libvirt_dnsmasq.conf
sudo systemctl restart NetworkManagersudo usermod -aG libvirtd $USER # for Debian/Ubuntu14.04/Ubuntu16.04
sudo usermod -aG libvirt $USER # for CentOS/Fedora/Ubuntu18.04NOTE: You have to relogin into your UI environment to apply these changes.
setfacl -m "u:libvirt-qemu:--x" $HOME # for Debian/Ubuntu
setfacl -m "u:qemu:--x" $HOME # for CentOS/Fedorasetfacl -m "u:libvirt-qemu:---" $HOME # for Debian/Ubuntu
setfacl -m "u:qemu:---" $HOME # for CentOS/Fedorasetfacl -b $HOME
getfacl $HOMEsudo usermod -aG $USER libvirt-qemu # for Debian/Ubuntu
sudo usermod -aG $USER qemu # for CentOS/Fedora
chmod g+x $HOMEsudo usermod -G "" libvirt-qemu # for Debian/Ubuntu
sudo usermod -G "kvm" qemu # for CentOS/Fedora
chmod g-x $HOMEecho "export LIBVIRT_DEFAULT_URI=qemu:///system" >> ~/.bashrccat dot_ssh_config >> ~/.ssh/config
chmod 600 ~/.ssh/config./deploy_coreos_cluster.sh -s 3user_data file works only for CoreOS and contains a template for CoreOS configuration and it configures etcd2 and fleet.
Create Tectonoic credentials files:
tectonic.lic# raw base64 encoded licencedocker.cfg# raw base64 encoded dockercfg
Deploy cluster:
./deploy_k8s_cluster.sh --tectonicEnter your Kubernetes master node:
ssh core@k8s-master # [-i ~/.ssh/id_rsa]Get Tectonic admin@example.com password:
kubectl --namespace=tectonic-system get secret tectonic-identity-admin-password -o template --template="{{.data.password}}" | base64 -d && echoLogin Tectonic:
Username: admin@example.com
Password: see above
Run three CentOS VMs
./deploy_vms_cluster.sh -o centos -s 3Run one Windows IE11.Win7 VM
./deploy_vms_cluster.sh -o windows -r IE11.Win7 -m 1024 -u 2Download and run FreeBSD:
./deploy_vms_cluster.sh -o freebsd # for 10.3 RELEASE
./deploy_vms_cluster.sh -o freebsd -c 11.0 -r RC1 # for 11.0 RC1FreeBSD QEMU images don't support cloud-init, so you have to configure network and ssh manually through the console:
dhclient vtnet0
echo 'sshd_enable=YES' >> /etc/rc.conf
echo 'ifconfig_DEFAULT=DHCP' >> /etc/rc.conf
echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config
service sshd start
passwdpkg install bash wget bzip2 gnupg cdrtools libvirt qemu virt-manager
kldload vmm
libvirtd -d
ifconfig tap create
ifconfig bridge create
ifconfig bridge0 addm tap0 upvirt-install version > 1.4 should use following parameters:
--nographic \
--console nmdm,source.master=/dev/nmdm0A,source.slave=/dev/nmdm0B \
--network bridge=bridge0 \and without --vnc flag. VNC flag produces following XML:
<graphics type="vnc" port="-1" keymap="en-us"/>which causes internal error: cannot determine default video type error message.
./remove_cluster.sh coreos