Provisioning an Optimized Ubuntu Virtual Machine on Proxmox VE for Local Compute Workloads
This guide details the complete end-to-end setup of an Ubuntu Server LTS VM on Proxmox VE.
It covers hypervisor device option trade-offs, installer decisions, storage layout expansion, and post-installation system initialization—including troubleshooting regional repository mirror failures and establishing host-to-guest communication channels.
1. Target System Architecture & Hardware Allocation
Below is the finalized specification matrix for the Ubuntu Server VM provisioned on Proxmox VE:
| Resource / Parameter | Value / Selected Option | Technical Purpose & Justification |
|---|---|---|
| VM ID & Name | 200 (ubuntu-server) |
Dedicated virtual machine identifier and network hostname. |
| CPU Architecture | 10 Cores (1 Socket, Type: host) |
Passes through all host CPU SIMD flags (AVX2, AVX-512, FMA) required for matrix acceleration. |
| System Memory | 30.00 GiB (Min: 4.00 GiB) | Fits large memory working sets in RAM; utilizes memory ballooning to yield unused RAM to host. |
| Machine Type | q35 |
Modern PCIe root complex; mandatory for native PCIe device tree mapping and hardware passthrough. |
| SCSI Controller | VirtIO SCSI single |
Assigns an isolated SCSI controller and queue per virtual disk, enabling asynchronous IOThread execution. |
| Virtual Disk | 650 GiB (local-lvm, ext4) |
Provisioned with Discard (TRIM/UNMAP), SSD Emulation, and IOThread flags enabled. |
| System BIOS | SeaBIOS (Default) | Standard legacy BIOS; eliminates vTPM and UEFI NVRAM state storage overhead. |
| Network Device | VirtIO (vmbr0, Firewall On) |
Paravirtualized network interface providing near-line-rate gigabit throughput. |
2. Proxmox VE Provisioning: Hypervisor Options & Trade-Offs
When creating a VM through the Proxmox Web GUI, each wizard tab exposes low-level QEMU/KVM virtualization parameters.
A. General Tab
- VM ID & Name: Assigns a unique numerical index and host alias.
- Start at Boot: Set to
Yesfor infrastructure servers so the VM auto-starts following a Proxmox host reboot. - Resource Pool: (Optional) Allows logical grouping of VMs for Role-Based Access Control (RBAC) and host resource quotas.
B. OS (Operating System) Tab
- ISO Image: Selects the installation image stored in host storage (
local:iso/ubuntu-24.04-live-server-amd64.iso). - Guest OS Type: Set to Linux 6.x - 2.6 Kernel. This configures QEMU default clock source parameters (
kvm-clock) and CPU power management assumptions suitable for Linux kernels.
C. System Tab
| Option | Available Settings | Selected Setting | Technical Deep-Dive & Trade-Offs |
|---|---|---|---|
| Machine Type | i440fx, q35 |
q35 |
i440fx emulates an Intel PCI bus from 1996. q35 emulates a modern PCIe root bridge. q35 is selected because modern Linux kernels manage PCIe devices more efficiently, and it provides the PCIe topology required if physical GPU or NPU pass-through is implemented later. |
| BIOS | SeaBIOS, OVMF (UEFI) |
SeaBIOS |
OVMF is required for Secure Boot, Windows 11, or complex GPU passthrough setups, but requires an extra EFI disk file. SeaBIOS is a lightweight legacy BIOS that boots faster and avoids hypervisor storage overhead for standard Linux servers. |
| Add vTPM | Enabled / Disabled | Disabled | Emulated TPM 2.0 device. Unnecessary for Linux installations that do not require hardware-bound full-disk encryption (LUKS). |
| SCSI Controller | VirtIO SCSI, VirtIO SCSI single, LSI 53C895A, MegaRAID SAS, VMware PVSCSI |
VirtIO SCSI single |
Standard VirtIO SCSI shares one controller queue across all disks. VirtIO SCSI single creates a separate virtual controller for each disk, allowing Proxmox to assign a dedicated host CPU thread (IOThread) to handle asynchronous disk I/O independently. Emulated controllers (LSI/MegaRAID) add high CPU overhead. |
| QEMU Guest Agent | Enabled / Disabled | Enabled | Creates a virtio-serial channel between host and guest, allowing Proxmox to report guest IP addresses, execute graceful shutdowns, and trigger frozen filesystem backups (fsfreeze). |
D. Disks Tab
- Bus/Device: Set to SCSI attached to the
VirtIO SCSI singlecontroller. - Storage & Size: Provisioned on
local-lvm(LVM-Thin) with a 650 GiB allocation. - Cache: Set to No cache (Default). This bypasses the host page cache, piping VM disk writes directly to host storage via
O_DIRECT, preventing double-buffering in host RAM. - Advanced Flags:
Discard=on(TRIM/UNMAP): Passes guest file deletion commands (fstrim) down to the Proxmox LVM-Thin storage layer, allowing the host to instantly reclaim unallocated physical disk blocks.SSD Emulation=1: Reportsrotational=0to the guest OS. Ubuntu identifies the drive as non-rotational, automatically applying SSD-optimized I/O schedulers (none/mq-deadline).IOThread=1: Offloads disk I/O execution from the main QEMU process to a dedicated host thread.
E. CPU Tab
- Cores & Sockets: Configured with 1 Socket, 10 Cores.
- CPU Type: Set to
host. Default QEMU CPU models (kvm64,x86-64-v2) hide advanced CPU features for cross-host live-migration compatibility. Setting CPU Type tohostexposes all native instruction extensions—specifically AVX, AVX2, AVX-512, and FMA—which are critical for compute-heavy vector matrix calculations. - NUMA: Disabled. On single-socket host processors, emulating NUMA topologies forces QEMU to create fake memory nodes, leading to suboptimal Linux kernel memory allocation routines.
F. Memory Tab
- Memory Allocation: Max memory set to 30.00 GiB (30720 MiB).
- Advanced (Ballooning): Dynamic Memory (Ballooning) enabled with Minimum Memory set to 4.00 GiB (4096 MiB). When the VM is idle, the
virtio_balloondriver yields unused guest memory back to the Proxmox host pool for other VMs.
G. Network Tab
- Bridge: Bound to
vmbr0(main host network bridge). - Model: Set to VirtIO (paravirtualized). Provides high-throughput paravirtualized network drivers, avoiding the high CPU overhead of emulated hardware NICs like
E1000orRTL8139. - Firewall: Enabled to enforce Proxmox-level network filtering policies if configured.
3. Ubuntu Server Installation Walkthrough
Once the VM is powered on inside the Proxmox VNC Console, complete the installer steps as outlined below.
Step 1: Language & Base Installer Setup
- Select your preferred Language and Keyboard Layout.
- Select Ubuntu Server (standard base installation). Avoid minimal options to ensure basic networking and storage utilities are included by default.
Step 2: Network Configuration (Static IP Binding)
Dynamic IP addresses (DHCP) are unsuitable for headless servers. Assign a static IP address:
- Select interface
ens18- Change IPv4 Method toManual. - Input network details matching your subnet architecture:
- Subnet:
<your-subnet-cidr>(e.g.,192.168.1.0/24) - Address:
<your-static-ip>(e.g.,192.168.1.249) - Gateway:
<your-gateway-ip>(e.g.,192.168.1.254) - Name servers:
1.1.1.1,8.8.8.8(Public primary/secondary DNS)
- Subnet:
- Save network configuration and select [ Done ].
Step 3: Proxy & Mirror Configuration
- Proxy: Leave blank unless your network routes outbound traffic through an HTTP proxy.
- Ubuntu Archive Mirror: Default mirror location (e.g.,
http://archive.ubuntu.com/ubuntu). Select [ Done ].
Step 4: Storage Layout & Logical Volume (LVM) Expansion
By default, the Ubuntu installer assigns only 100 GB to the root logical volume (ubuntu-lv), regardless of disk size.
- On Guided storage configuration:
- Choose (X) Use an entire disk.
- Keep [X] Set up this disk as an LVM group checked.
- Keep LUKS encryption unchecked to avoid disk I/O performance drops.
- On the Storage configuration summary screen:
- Under USED DEVICES, select
ubuntu-lv(mounted at/) $\rightarrow$ Press Enter $\rightarrow$ Select Edit. - Modify Size from
100.000Gto647.996G(100% of available disk space). - Confirm Format is set to
ext4. - Select [ Save ], then select [ Done ].
- Under USED DEVICES, select
- Confirm destructive formatting by selecting [ Continue ].
Filesystem Comparison:
ext4(Selected): Extremely stable, low memory overhead, supports online growth, and handles TRIM operations cleanly.xfs: Highly performant for massive files, but cannot be shrunk once formatted.btrfs: Native Copy-on-Write (CoW) feature set causes severe write amplification when nested inside hypervisor thin-provisioned storage (local-lvm).
Step 5: Profile & SSH Setup
- Enter your user credentials:
- Your name / Server name:
<your-name>/<your-hostname> - Username / Password:
<your-username>/<your-secure-password>
- Your name / Server name:
- On SSH Setup:
- Check [X] Install OpenSSH server to enable remote SSH terminal access.
Step 6: Featured Server Snaps (Package Selection Rationale)
Deselect all optional Snap packages (microk8s, prometheus, lxd, etc.) and select [ Done ].
- CKA Prep Compatibility:
microk8shides underlying Kubernetes control plane components behind custom wrapper commands (microk8s kubectl). For Certified Kubernetes Administrator (CKA) preparation, deploying clean upstream Kubernetes (kubeadm) directly on standard Linux systemd environments is required. - Resource Isolation: Snaps run inside containerized confinement namespaces that complicate configuration edits. Furthermore, running background daemons on a compute node creates CPU/RAM contention.
Select [ Reboot Now ] upon completion and detach the installation ISO.
4. Post-Install Administration & Maintenance
Log in to the server via SSH:
ssh <your-username>@<your-static-ip>
Remediation: Fixing Regional Repository Mirror Failures (HTTP 403)
During initial package updates, regional Ubuntu mirrors (e.g., sg.archive.ubuntu.com) may fail with HTTP 403 Forbidden due to mirror synchronization delays or geo-IP restrictions.
To fix this, execute a sed inline replacement to point all repository files—including legacy sources.list and modern DEB822 .sources format files—to the primary global Ubuntu archive:
sudo sed -i 's/sg\.archive\.ubuntu\.com/archive\.ubuntu\.com/g' /etc/apt/sources.list /etc/apt/sources.list.d/*.sources 2>/dev/null
Refresh repository metadata and upgrade all system packages:
sudo apt update
sudo apt upgrade -y
Installing and Verifying QEMU Guest Agent
Install the QEMU Guest Agent package along with utility tooling (curl, zstd):
sudo apt install -y qemu-guest-agent curl zstd
Enable and start the agent service:
sudo systemctl enable --now qemu-guest-agent
Note on Systemd Static Units: Running
systemctl enableonqemu-guest-agentdisplays a message stating that the unit file isstaticand has no[Install]section. This is expected behavior. Static units are managed directly by systemd activation sockets or hypervisor events.
Verify that the service is running properly:
systemctl status qemu-guest-agent
Expected Status Output:
● qemu-guest-agent.service - QEMU Guest Agent
Loaded: loaded (/usr/lib/systemd/system/qemu-guest-agent.service; static)
Active: active (running) since Sun 2026-08-30 10:13:27 UTC
Main PID: 22055 (qemu-ga)
Tasks: 2 (limit: 35385)
Memory: 960K
CGroup: /system.slice/qemu-guest-agent.service
└─22055 /usr/sbin/qemu-ga
qemu-ga[22055]: info: guest-ping called
The guest-ping called log entries confirm that the Proxmox host is successfully communicating with the guest operating system across the VirtIO serial channel.
5. Summary Checklist
- Hypervisor Acceleration: Expose host CPU flags by setting CPU Type to
hostin Proxmox. - Storage Optimization: Ensure
VirtIO SCSI single,Discard=on, andIOThread=1are configured on virtual disks to allow background TRIM and isolated queue processing. - Partition Allocation: Expand the default 100 GB
ubuntu-lvlogical volume during OS installation to utilize 100% of provisioned drive space. - Mirror Reliability: Update
aptsource definitions to global mirrors (archive.ubuntu.com) if regional mirrors produce HTTP 403 errors. - Host-Guest Telemetry: Install and verify
qemu-guest-agentso Proxmox can monitor system states and execute graceful host shutdowns.