VM and virtualization configuration and tooling.
- Add VNC graphics to a domaineasy · in-browser
Write /home/player/domain.xml: a libvirt domain with a <graphics type='vnc'> device and a <video> model.
(Authored config, graded structurally — the engine isn't run here.)
- Add a virtio RNG deviceeasy · in-browser
Write /home/player/domain.xml: add an entropy source to a libvirt guest with a <rng model='virtio'> device whose <backend model='random'> reads from /dev/urandom. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Detect the hypervisoreasy
This machine is itself a virtual machine. Determine which virtualization platform it runs on and write that one-word answer to /home/player/virt.txt.
- Domain UUIDeasy · in-browser
Write /home/player/domain.xml with a <uuid> element and <name>web</name>.
(Authored config, graded structurally — the engine isn't run here.)
- Domain boot device ordereasy · in-browser
Write /home/player/domain.xml: inside a libvirt <os> block, set the OS type element to hvm (<type>hvm</type>) and define a two-step boot order so the guest tries the CD-ROM first and the hard disk second, using <boot dev='cdrom'/> then <boot dev='hd'/>.
(Authored config, graded structurally — the engine isn't run here.)
- Domain memory sizingeasy · in-browser
Write /home/player/domain.xml with <memory unit='KiB'>2097152</memory> and a matching <currentMemory>.
(Authored config, graded structurally — the engine isn't run here.)
- Guest netplan static IPeasy · in-browser
Write /home/player/01-netcfg.yaml: a netplan v2 config (renderer networkd) giving ethernet interface ens3 a static address 192.168.50.10/24 with gateway 192.168.50.1 and a nameserver 1.1.1.1. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Script virt-installeasy · in-browser
Write /home/player/create.sh invoking virt-install with --name web, --memory 2048, --vcpus 2, a --disk and --os-variant.
(Authored config, graded structurally — the engine isn't run here.)
- Write a Vagrantfileeasy · in-browser
Write /home/player/Vagrantfile: box ubuntu/jammy64, forwarded port guest 80 to host 8080.
(Authored config, graded structurally — the engine isn't run here.)
- cloud-init NoCloud meta-dataeasy · in-browser
Write /home/player/meta-data: a cloud-init NoCloud datasource meta-data file (plain YAML, NOT #cloud-config) setting instance-id to iid-vm01 and local-hostname to web01. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- qemu-img create backing diskeasy · in-browser
Write /home/player/mkdisk.sh: a bash script that uses qemu-img create to make an overlay. Create a qcow2 image named overlay.qcow2 of size 20G that uses base.qcow2 as its backing file (qemu-img create -f qcow2 -b base.qcow2 -F qcow2 overlay.qcow2 20G). (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- virtio memory ballooneasy · in-browser
Write /home/player/domain.xml: add a <memballoon model='virtio'> device with statistics collection enabled via a <stats period='10'/> child. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Attach a CD-ROMmedium · in-browser
Write /home/player/domain.xml with a <disk type='file' device='cdrom'> pointing at an .iso.
(Authored config, graded structurally — the engine isn't run here.)
- Author a Butane configmedium · in-browser
Write /home/player/config.bu: a Butane (FCOS) YAML with variant fcos and version 1.5.0 that defines the user 'core' with an ssh_authorized_keys entry and a systemd unit named docker.service that is enabled. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Author a VMware .vmxmedium · in-browser
Write /home/player/vm.vmx with memsize, numvcpus and a scsi0:0.fileName disk.
(Authored config, graded structurally — the engine isn't run here.)
- Author a libvirt domainmedium
Write /home/player/domain.xml: a libvirt KVM guest definition — <domain type='kvm'> named `web`, 2 vCPUs, 1048576 KiB memory, a disk device and a network interface.
- Author a libvirt networkmedium · in-browser
Write /home/player/net.xml: a libvirt <network> named default, forward mode nat, a <bridge>, and a <dhcp><range>.
(Authored config, graded structurally — the engine isn't run here.)
- Author a libvirt secretmedium · in-browser
Write /home/player/secret.xml: a libvirt <secret ephemeral='no' private='yes'> with a <uuid> element and a <usage type='ceph'> whose child <name> is 'client.admin secret'. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Author a storage poolmedium · in-browser
Write /home/player/pool.xml: a libvirt <pool type='dir'> named images with a <target><path>.
(Authored config, graded structurally — the engine isn't run here.)
- Domain CPU and OS typemedium · in-browser
Write /home/player/domain.xml with <os><type>hvm</type></os> and <cpu mode='host-passthrough'>.
(Authored config, graded structurally — the engine isn't run here.)
- QEMU user net + hostfwdmedium · in-browser
Write /home/player/run.sh: qemu-system-x86_64 with -netdev user,id=n0,hostfwd=tcp::2222-:22 and -device.
(Authored config, graded structurally — the engine isn't run here.)
- Serial console for a domainmedium · in-browser
Write /home/player/domain.xml: give a libvirt guest a text serial console by adding a <serial type='pty'> with <target port='0'/> and a matching <console type='pty'> with <target type='serial' port='0'/>. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Vagrant libvirt provider tuningmedium · in-browser
Write /home/player/Vagrantfile: use box generic/ubuntu2204 and a config.vm.provider :libvirt block that sets memory to 2048, cpus to 2, and nested virtualization on (libvirt.nested = true). (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Vagrant shell provisionermedium · in-browser
Write /home/player/Vagrantfile with config.vm.provision "shell" running apt-get update.
(Authored config, graded structurally — the engine isn't run here.)
- Write a QEMU commandmedium · in-browser
Write /home/player/run.sh launching qemu-system-x86_64 with -m 2048, -smp 2, a -drive, and -enable-kvm.
(Authored config, graded structurally — the engine isn't run here.)
- cloud-init SSH keysmedium · in-browser
Write /home/player/user-data (#cloud-config) adding an ssh_authorized_keys entry for the default user.
(Authored config, graded structurally — the engine isn't run here.)
- cloud-init network-configmedium · in-browser
Write /home/player/network-config: cloud-init v2 with ethernet eth0 set to dhcp4 true.
(Authored config, graded structurally — the engine isn't run here.)
- cloud-init power_statemedium · in-browser
Write /home/player/user-data (#cloud-config) with a power_state rebooting after setup.
(Authored config, graded structurally — the engine isn't run here.)
- libvirt network DNS host entrymedium · in-browser
Write /home/player/net.xml: a libvirt <network> named lab with forward mode nat, an <ip address='192.168.123.1' netmask='255.255.255.0'> and inside the network a <dns> block holding a <host ip='192.168.123.50'> with a <hostname>web.lab</hostname>. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- qemu-img snapshot scriptmedium · in-browser
Write /home/player/snap.sh creating a qcow2 then an internal snapshot with qemu-img snapshot -c base.
(Authored config, graded structurally — the engine isn't run here.)
- systemd-nspawn container configmedium · in-browser
Write /home/player/web.nspawn: an [Exec] Boot=yes and a [Network] section with a Zone or Bridge.
(Authored config, graded structurally — the engine isn't run here.)
- virt-install import existing diskmedium · in-browser
Write /home/player/import.sh: a virt-install command that boots an existing qcow2 image instead of installing. Use --name imported, --memory 1024, --vcpus 1, --disk path=/var/lib/libvirt/images/disk.qcow2,format=qcow2, --import, and --os-variant ubuntu22.04. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- virtio guest-agent channelmedium · in-browser
Write /home/player/domain.xml with a <channel type='unix'> using target name org.qemu.guest_agent.0.
(Authored config, graded structurally — the engine isn't run here.)
- virtiofs filesystem sharemedium · in-browser
Write /home/player/domain.xml: a snippet for a libvirt KVM guest exposing a host directory via virtiofs. Include a <filesystem type='mount' accessmode='passthrough'> with <driver type='virtiofs'/>, a <source dir='/srv/share'/> and a <target dir='share'/>. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Author a Packer templatepro · in-browser
Write /home/player/build.pkr.hcl: a qemu source with iso_url, ssh_username, and a build block referencing it.
(Authored config, graded structurally — the engine isn't run here.)
- Author a domain snapshotpro · in-browser
Write /home/player/snap.xml: a libvirt <domainsnapshot> with a <name> and a <disks> section.
(Authored config, graded structurally — the engine isn't run here.)
- Author an Ignition configpro · in-browser
Write /home/player/config.ign: a Fedora CoreOS Ignition JSON (ignition version 3.4.0) that creates the user 'core' with one sshAuthorizedKeys entry and writes the file /etc/hostname (mode 420) containing inline contents. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Author cloud-init user-datapro
Write /home/player/user-data: a cloud-init #cloud-config that creates a sudo user `ops`, installs the `nginx` package, writes a file via write_files, and runs a command via runcmd.
- Back memory with hugepagespro · in-browser
Write /home/player/domain.xml with a <memoryBacking><hugepages/></memoryBacking>.
(Authored config, graded structurally — the engine isn't run here.)
- Define guest NUMApro · in-browser
Write /home/player/domain.xml with <cpu><numa><cell .../></numa></cpu>.
(Authored config, graded structurally — the engine isn't run here.)
- Multi-machine Vagrantpro · in-browser
Write /home/player/Vagrantfile defining two machines web and db via config.vm.define.
(Authored config, graded structurally — the engine isn't run here.)
- PCI passthrough hostdevpro · in-browser
Write /home/player/domain.xml: pass a host PCI device into a KVM guest with a <hostdev mode='subsystem' type='pci' managed='yes'> whose <source> contains an <address> at domain 0x0000, bus 0x01, slot 0x00 and function 0x0. (Authored config, graded structurally - the engine isn't run here.)
(Authored config, graded structurally — the engine isn't run here.)
- Packer + Ansible provisionerpro · in-browser
Write /home/player/build.pkr.hcl with a build block whose provisioner is "ansible" with a playbook_file.
(Authored config, graded structurally — the engine isn't run here.)
- Terraform libvirt domainpro · in-browser
Write /home/player/main.tf declaring a libvirt_domain resource named web with memory and vcpu.
(Authored config, graded structurally — the engine isn't run here.)
- cloud-init disk setuppro · in-browser
Write /home/player/user-data (#cloud-config) using disk_setup, fs_setup, and mounts to format and mount /dev/vdb at /data.
(Authored config, graded structurally — the engine isn't run here.)