Proxmox: QEMU Guest Agent How To

Proxmox offers support for the QEMU Guest Agent helper daemon on both Linux and Windows. We’ll discuss why this is important, as well as how to implement it on Linux virtual machines.

What Purpose Does the QEMU Guest Agent Serve?

According to QEMU, when ran inside a virtual machine, the QEMU Guest Agent allows the hypervisor host to perform various operations in the guest, including:

How Does Proxmox Use the QEMU Guest Agent?

According to Proxmox, it is used mainly for two things:

Installation on Guest Virtual Machines

The following commands must be ran as root or via sudo within the respective virtual machine

Debian and Ubuntu Based Systems

This includes distributions like Linux Mint and Raspberry Pi OS.

~ $ apt-get install qemu-guest-agent

RedHat Based Systems

This includes distributions like CentOS and Rocky Linux.

~ $ dnf install qemu-guest-agent

If you are on an older RedHat based system where dnf is not available, please use yum:

~ $ yum install qemu-guest-agent

Tell Linux to Start QEMU Guest Agent on Boot

The following command tells the system to start qemu-guest-agent automatically at boot, as well as starts it immediately if it’s not already running:

~ $ systemctl enable --now qemu-guest-agent

Configure Virtual Machine on Proxmox

  1. Select the virtual machine in Proxmox
  2. Click on “Options”
  3. Click the item with the Name “QEMU Guest Agent”
  4. Click the “Edit” button
  5. In the popup modal window, check the option with the label “Use QEMU Guest Agent”
  6. Click the “OK” button

Test QEMU Guest Agent Installation

After installing the QEMU Guest Agent on a virtual machine, it’s good practice to validate that it is working. From the Proxmox shell, run the following command, replacing vmid with the ID of the virtual machine you are looking to test:

root@pve:~# qm agent vmid ping

A successful test result is when no error message is returned.