Installing Fedora Server Edition as a Virtual Machine using Proxmox Virtual Environment

Paul Maconi Version F41 Last review: 2024-11-02
This document outlines a method for installing Fedora Server from the qcow2 image as a virtual machine in the Proxmox Virtual Environment, henceforth simply Proxmox. VMs can be spun up very quickly after importing the disk image, saving much time and frustration. The setup used when writing this document may not match what yours, so certain details like file paths for the disk images may vary.

Why Fedora Server on Proxmox

Proxmox is an open source server virtualization management solution based on QEMU/KVM and LXC with a web interface for managing most aspects of the VM workflow. It is also popular with homelab enthusiasts. The Fedora Server disk image shortcuts the provisioning process by providing a pre-installed disk image that boots straight into the final setup menu. You can have a fresh Fedora Server VM provisioned in just a couple of minutes using this method.

Brief summary for experienced Proxmox users

Here are the key details if you’re already familiar with creating virtual machines in Proxmox.

  • The VM does not need installation media (ISO) mounted.

  • The VM must be in BIOS mode (SeaBIOS) with a VirtIO SCSI Single controller. Be sure to enable the Qemu Agent if you plan on using it.

  • This document omits the initial disk creation because we import the disk image later in the process.

    • qm disk import [vm_number] [image_name.qcow2] [target_storage] --format qcow2

  • You must attach the disk and ensure it is selected in the boot order under options for the VM before you try to boot the system.

Procedure

Note: This document assumes that you have ssh access to a Proxmox node and that you have already downloaded the Fedora Server qcow2 disk image. It also assumes centralized storage on an NFS mount, but your storage configuration may differ if you use local LVM storage or Ceph. We provided screenshots for each step of the VM configuration process, but the overall procedure comes from the Proxmox Wiki.

Locate the image file and upload it to Proxmox

Before we create the VM, we will need to find and upload our disk image to the Proxmox node. In the screenshot below you can see that we explored the system to determine that it is using centralized NFS storage mounted at /mnt/pve/nfs-kraken, and we made a directory at some point called osimages to contain our disk images.

Once we sorted out the path, we uploaded the file via scp into the Proxmox node. scp [image_filename] root@[node_name]:/path/to/images/[image_filename]

Upload Image File

Verify the image is in place

While not completely necessary, we logged back in to the Proxmox node and verified that the file had actually uploaded to the target directory. We’ll come back to this path later when it is time to import the disk image to a VM.

Locate Image File

VM Creation: General

Click on the Create VM button in the Proxmox UI, and the VM creation wizard should start. Select a node and give the VM a name. Note the VM ID. We will need this later. Click Next.

VM General

VM Creation: OS

We will not need to use an ISO to install the system, so change the radio button to Do not use any media and click Next.

VM OS

VM Creation: System

We get a handful of options to play with on this screen.

  • The Machine is whatever you prefer. q35 presents hardware in the PCIe topology, while i440fx will give you the older PCI topology.

  • The BIOS option needs to be SeaBIOS because the disk image will not boot under UEFI.

  • The SCSI Controller option should be set as VirtIO SCSI Single. The default option LSI 53C895A would not boot the disk image.

  • Also, remember to enable the Qemu Agent option if you intend to use it. You can safely enable this option if you are unsure.

Click Next.

VM System

VM Creation: Disks

Click the little trash can to the left of the disk it pre-populates for you. We will be importing the disk image as our primary disk. Click Next.

VM Disks

VM Creation: CPU

Set the CPU settings as you need them. The test cluster used when writing this documentation had identical processors across the cluster, so host was safe to use while still enabling live migration. Click Next.

VM CPU

VM Creation: Memory

Set the memory the amount you want assigned to the VM. Click Next.

VM Memory

VM Creation: Network

Select the network details. The test article had an Open vSwitch configured with VLAN port groups. VirtIO (paravirtualized) should yield the best performance. Click Next.

VM Network

VM Creation: Confirm

The wizard should end with a summary of the hardware settings. Click Finish to create the VM.

VM Confirm

VM Disk Import

Now that the VM itself has been built, we need to log in to the Proxmox node via the console feature or via SSH to import the disk image we uploaded earlier.

  • Log in to the Proxmox node

  • Navigate to the directory where you uploaded the disk image earlier.

    • This test article has storage mounted at /mnt/pve/nfs-kraken/osimages/, but your path will be different.

  • Use the qm disk import command to import your disk image.

    • qm disk import [vm_number] [image_name.qcow2] [target_storage] --format qcow2

      • [vm_number] is the vm number of the vm you just created in the previous steps.

      • [image_name.qcow2] is the file name of your Fedora Server image that you uploaded earlier.

      • [target_storage] is the storage volume where you want the disk image for the vm stored. For this test article, I told Proxmox to continue using a volume named nfs-kraken.

      • The format may vary depending on where you are storing the VM. The test articule uses an NFS mount, and qcow2 formatted images are preferred in this usage scenario.

VM Disk Import Start

When the import process finishes you should get a success message like the one show in the image below. This process was done on a storage array with rotational hard disks, and it still only took a few seconds to complete.

VM Disk Import End

VM Configuration: Disk

Now that the disk is part of the VM, we can go back to the hardware tab, highlight the new unused disk, and click edit. You shouldn’t need to change anything and can safely just click Add.

VM Configuration: Disk

VM Configuration: Boot Order

The final step before powering on the VM is to navigate to the VM’s Options tab, click on Boot Order, and ensure that the imported disk, typically scsi0, is selected for boot. Note that in the following screenshot, the other boot options are disabled and scsi0 is moved to the top of the list.

VM Configuration: Boot Order

VM Console: First Boot

Now we’re ready open up the console and boot the VM for the first time. You should see the normal GRUB boot loader and kernel messages stream across the console until you are presented with the final setup menu.

VM Console: First Boot

End Result

After you complete this process the VM is running just as if you had booted off of the ISO and went through the full server install process, only now it only takes a fraction of the time!

Next Steps

Be sure to check out the tasks in the general post-installation guide for virtual machines as well.