Theme editor

Guide Linux Proxmox How to Create a New Virtual Machine (VM) in Proxmox VE

  • Thread starter Thread starter CL4Y
  • Start date Start date
  • Views 199

CL4Y

Keyboard Ninja
Administrator
Thread owner

How to Create a New Virtual Machine (VM) in Proxmox VE 🖥️​

Proxmox Virtual Environment (VE) is a powerful, open-source hypervisor that combines KVM for virtual machines and LXC for container-based virtualization. While the interface is user-friendly, creating a new Virtual Machine (VM) involves a series of critical steps that define the VM's performance, compatibility, and features.

This guide provides a comprehensive, step-by-step walkthrough of the VM creation process, ensuring each setting is configured correctly for a stable and efficient virtual server.



Step 1: Accessing the Proxmox VE Web Interface 🛠️​

All virtual machine management is handled through the Proxmox web-based graphical user interface (GUI). Before creating a VM, you must first authenticate to your Proxmox host.

You can access the interface using one of two methods:
  1. By IP Address: Navigate to your server's static IP address on port 8006.
    • https://[Your-Server-IP]:8006/
  2. By Hostname: Navigate to the fully qualified domain name of your host.
    • https://[proxmox.your-domain.com]:8006/
Note: To log in via a hostname (e.g., https://proxmox.jetto.net:8006/), you must have pre-configured the necessary A (or AAAA) records in your DNS server, pointing that hostname to the Proxmox host's IP address.

jetto-proxmox-virtual-machine-create-1.gif




Step 2: Initiating the VM Creation Wizard 🧙‍♂️​

Upon accessing the Proxmox GUI, the VM creation process is initiated from the Datacenter view.
  1. In the left-hand navigation tree, locate your physical host node under the "Datacenter" hierarchy. (The default name for this node is often pve, which is set during the initial Proxmox installation).
  2. Right-click the physical node and select "Create VM" from the context menu.
This action launches the "Create Virtual Machine" wizard. The first tab is General.
  • VM ID: This field requires a unique numerical identifier for the virtual machine. This ID is how the Proxmox cluster fundamentally manages and differentiates the VM. The system will automatically suggest the next available sequential number (e.g., 100, 101, 102), but any available ID can be used. For this guide, we will specify 300.
  • Name: This is the human-readable, descriptive name for the VM. Unlike the VM ID, this name serves as a label to identify the VM's purpose or project. As this VM is intended to be a VPN server, we will assign the name vpn-server.
After populating these fields, click Next to proceed to the "OS" tab.

jetto-proxmox-virtual-machine-create-2.gif




Step 3: Configuring the Guest OS 👨‍💻​

The "OS" tab is where the installation media and the guest's compatibility profile are defined.
  1. Select Installation Media:
    • Select the "Use CD/DVD disc image file (iso)" option.
    • Storage: From the first dropdown, select the storage pool where your ISO images are located (e.g., local).
    • Image: From the second dropdown, choose the specific ISO file you intend to install, such as ubuntu-24.04-server.iso.
  2. Define Guest OS Type:
    • Type: This setting informs Proxmox which type of operating system to optimize for. As we are installing Ubuntu, set this to Linux. (Conversely, this would be set to Windows for a Windows Server installation).
    • Version: This is a compatibility profile. For a modern operating system like Ubuntu 24.04, you must select the latest available kernel profile, which is typically "6.x / 5.x kernel".
Note: Selecting an older kernel version (like 2.6/3.x) is only intended for legacy operating systems and may cause boot or performance issues if misconfigured with a modern OS.
Click Next to proceed to the "System" tab.

jetto-proxmox-virtual-machine-create-3.gif




Step 4: Configuring System Hardware ⌨️​

The "System" tab defines the virtual hardware drivers and security features for the VM.
  1. Qemu Agent:
    • Check the box labeled "Qemu Agent".
    • This is a critical setting that enables communication between the Proxmox host and the guest OS for tasks like graceful shutdowns and retrieving accurate resource usage.
    • Note: Activating this checkbox is only the first step. The corresponding qemu-guest-agent software must be installed inside the guest operating system after the VM is built. (You can follow this guide for the guest OS installation: https://www.jetto.net/threads/how-to-install-qemu-guest-agent-on-proxmox-vms-debian-ubuntu.167/)
  2. Other Settings:
    • The default settings for Graphic card, SCSI Controller (VirtIO SCSI Single), and BIOS (SeaBIOS) are typically optimal for a modern Linux VM.
    • TPM (Trusted Platform Module): Leave this disabled. TPM is a security feature primarily required for Windows 11 and is not necessary for this Linux server setup.
Click Next to proceed to the "Disks" tab.

jetto-proxmox-virtual-machine-create-4.gif




Step 5: Defining the Virtual Disk 💾​

The "Disks" tab is used to configure the primary storage volume for the VM's operating system.
  1. Storage:
    • From the "Storage" dropdown, select the target storage pool where the virtual disk file will reside. If your host has multiple configured storage backends (e.g., local-lvm, local-zfs, or a shared storage like Ceph), they will all appear in this list. Select the one you intend to use.
  2. Disk size (GiB):
    • In this field, specify the total capacity you wish to allocate for the virtual disk. For this guide, we will allocate 100 GiB.
  3. Advanced Settings (Recommendation):
    • This page contains several advanced options, such as the Bus/Device (e.g., VirtIO Block, IDE, SATA), Cache mode, and Format (e.g., QEMU image format, Raw).
    • For optimal performance and stability with a modern Linux guest, it is strongly recommended to leave these settings at their defaults (typically "VirtIO Block" and "QEMU image format"). Altering these parameters without a specific technical requirement can introduce significant risks or performance bottlenecks.
Click Next to proceed to the "CPU" tab.

jetto-proxmox-virtual-machine-create-5.gif




Step 6: Configuring CPU Resources ⚡​

The "CPU" tab allows you to allocate processing power to your virtual machine.
  1. Sockets and Cores:
    • These fields define the virtual CPU (vCPU) topology. The total number of vCPUs available to the guest OS will be (Sockets x Cores).
    • For a lightweight application like a VPN server, a minimal allocation is often sufficient. We will configure 1 Socket and 1 Core, for a total of 1 vCPU.
    • For more demanding workloads, you would scale these numbers based on your physical host's available resources.
  2. Type:
    • This setting determines the CPU model presented to the guest OS. For maximum performance, set this to host.
    • The host type passes the host CPU's features (instruction sets like AES-NI, AVX, etc.) directly to the VM. This "passthrough" approach eliminates emulation overhead and provides significantly better performance than generic CPU types (like kvm64).
Click Next to proceed to the "Memory" tab.

jetto-proxmox-virtual-machine-create-6.gif




Step 7: Allocating Memory 💥​

The "Memory" tab is straightforward, defining the total RAM available to the VM.
  • Memory (MiB): Enter the amount of memory you wish to allocate in Megabytes (MiB). This value must be entered as an integer (e.g., 2048 for 2GiB, or 4096 for 4GiB).
  • For this VPN server, we will allocate 2048 MiB.
Click Next to proceed to the "Network" tab.

Step 8: Configuring Network Hardware 🌎​

The "Network" tab defines the VM's virtual network interface controller (vNIC).
  • Default Configuration: Proxmox automatically selects the best defaults for a modern Linux VM, typically bridging the vNIC to your host's primary bridge (e.g., vmbr0) and selecting the high-performance VirtIO (paravirtualized) model. For most use cases, these defaults should not be changed.
  • IP Address Configuration:
    • DHCP: If your network uses DHCP and you rely on MAC address reservations to assign static IPs, you can enter a specific MAC address in the "MAC address" field. The VM will then boot and request an IP.
    • Manual (Static) Configuration: If you do not specify a MAC address, you can leave the field blank. This is the standard approach for servers. The network interface will be configured manually with a static IP address, gateway, and netmask from inside the operating system during the Ubuntu installation process.
Click Next to proceed to the "Confirm" tab.

jetto-proxmox-virtual-machine-create-7.gif




Step 9: Review and Confirm Configuration ✅️​

The final tab, "Confirm," presents a complete summary of every setting you have configured, from the VM ID and name to the CPU, memory, and disk allocations.

This is your last opportunity to verify that all parameters are correct. Carefully review the configuration.
  • If you spot an error, you can click "Back" (or click the specific tab in the wizard) to make corrections.
  • If all settings are accurate, click the "Confirm" button to provision the virtual machine.
After clicking "Confirm," Proxmox will provision the hardware and create the VM (you will see it appear in the left-hand navigation tree).

This concludes the VM creation process. However, the VM is currently an empty shell; the operating system is not yet installed. The next phase involves starting the VM, opening the "Console," and proceeding with the Ubuntu 24.04 installation from the ISO image you attached.

We'll cover that installation process in a separate guide.
✅️
 
Back
Top