User virtual machines on VLAB servers

From techdocs
Revision as of 14:07, 1 Haziran 2023 by Plinich (talk | contribs)
Jump to navigation Jump to search

Proposed user-defined virtual machine setup for VLAB servers. Not operational.

Implement and run a user-defined virtual machine (VM).

Programs

Program name Description
vmcreatedisk Create a virtual hard disk (file).
vmrun

Run a virtual machines, booting either from a supplied CD/ISO image or from virtual hard disk.

vmcreatedisk

Do we really need this? Can't users just run qemu-img instead?

Usage: vmcreatedisk [options] <disk0>

-h Display this help
-s Size of new virtual hard disk in megabytes. Conflicts with -b
-b Backing image for virtual hard disk. Conflicts with -s

<disk0> virtual hard disk path for new disk

vmrun

Usage: vmrun [options] [<disk0> [<disk1> ...]]

-h Display this help
-m RAM megabytes (128/2048 - default 1024)
-n virtual CPUs (1/2 - default 1)
-i CD/ISO file path
-I boot from CD/ISO instead of virtual hard disk

<diskn> virtual hard disk path

vmrun runs a user-defined virtual machine using qemu/KVM.

  • The machine will be configured for "user" networking, meaning it will be on its own private subnetwork. It will be able to connect externally using Network Address Translation (NAT) but will not be reachable itself from external hosts (including from the server the virtual machine is running on). The VM will see the network interfaces as an Intel E1000 card.
  • It will have a graphical console.
  • The [virtual] CPU will be Intel. There can be a maximum of TWO per VM.

Scribbles

Installing qemu-system-x86_64 package on nw-syd-armvx1:

Start-Date: 2023-06-01  14:04:59
Commandline: apt-get install qemu-system-x86
Install: qemu-system-x86:arm64 (1:5.2+dfsg-11+deb11u2), ovmf:arm64 (2020.11-2+deb11u1, automatic), libcapstone4:arm64 (4.0.2-3, automatic), libvdeplug2:arm64 (4.0.1-2, automatic), libbrlapi0.8:arm64 (6.3+dfsg-1+deb11u1, automatic), libexecs0:arm64 (1.3-1, automatic), libspice-server1:arm64 (0.14.3-2.1, automatic), ipxe-qemu:arm64 (1.0.0+git-20190125.36a4c85-5.1, automatic), libusbredirparser1:arm64 (0.8.0-1+b1, automatic), seabios:arm64 (1.14.0-2, automatic), libcacard0:arm64 (1:2.8.0-3, automatic), qemu-system-common:arm64 (1:5.2+dfsg-11+deb11u2, automatic), libvirglrenderer1:arm64 (0.8.2-5+deb11u1, automatic), qemu-system-data:arm64 (1:5.2+dfsg-11+deb11u2, automatic), qemu-system-gui:arm64 (1:5.2+dfsg-11+deb11u2, automatic)
End-Date: 2023-06-01  14:05:04