Staff VMs¶
List current VMs: sudo virsh list —all
List current zfs: zfs list
Start a shut off VM up again: sudo virsh start VMNAME
Access VM: sudo virsh console VMNAME
Destroy:
sudo virsh destroy VMNAME
sudo virsh undefine --nvram VMNAME
Creating new Staff VMs¶
- SSH into cloudsdale
-
Create a new zfs dataset for USERNAME (requires root)
sudo zfs create staffvm/USERNAME -o mountpoint=/staffvm/USERNAME3. Create the VM named VMNAME (natural disaster themed). iso is in
sudo virt-install \
--name VMNAME \
--memory 2048 \
--cpu host \
--vcpus 1 \
--disk size=5 \
--boot uefi \
--graphics none \
--cdrom debian-12.9.0-amd64-netinst.iso \
--osinfo detect=on,name=debian11
console=ttyS0 to the linux line
1. `/install.amd/vmlinuz console=ttyS0`
-
Set IP to new ip from Staff VM Allocations Spreadsheet
- take the ip of an unused/no longer exists staff vm lol
- Netmask is default
- Name server address:
169.229.226.22 - hostname same as vmname
- domain name: ocf.berkeley.edu
- pick the user's password
- do default disk partitioning
- Say no
- set ocf for mirrors
- no proxy
- add DNS
Log on creating a NixOS staff VM¶
When trying to provision a NixOS VM through ISO (after step 3.), we ran into an issue where no bootable option or device was found. The way to solve this was to attach the ISO first:
sudo virsh attach-disk [domain name] /var/lib/libvirt/images/latest-nixos-minimal-x86_64-linux.iso sda --driver qemu --type cdrom
Then disable secure boot in BIOs and add "console=ttys0" to the bootloader screen by pressing "e" and appending the parameter.