Install Proxmox qemu-guest-agent on Ubuntu 20.04

In this tutorial I will show you how to install the qemu-guest-agent package on Ubuntu 20.04.

1. What is qemu-guest-agent?

The qemu-guest-agent is a helper daemon, which is installed in a guest VM. It is used to exchange information between the host and guest, and to execute commands in the guest machine.

For example, when using Proxmox VE, the qemu-guest-agent is used for the following major features:

  1. To properly shutdown the guest, instead of relying on ACPI commands or windows policies.
  2. To freeze the guest file system when making a backup (on windows, use the volume shadow copy service VSS).

It is a good practice to install the qemu-guest-agent on all VM’s for the above reasons but also for various other stability tweaks and features.

2. Enable qemu-guest-agent in Proxmox for VM

The first step is to enable the qemu-guest-agent option for your VM. In Proxmox VE you can do this as follows.

Firstly, connect to your Proxmox server web interface (by default this is https://proxmox_ip:8006).

Important: Make sure the VM is shutdown before continuing. If the VM is currently running, shut it down now.

Steps 1-3
  1. Select the VM in the Proxmox interface, and then click on the “options” tab.
  2. Click on the “QEMU Guest Agent” row.
  3. Click on the “Edit” button.
Steps 4-5
  1. Check the “Use QEMU Guest Agent” checkbox.
  2. Click “OK”.
  3. Boot the VM / turn it on.

3. Install QEMU guest agent package on Ubuntu VM

Login to your Ubuntu VM via SSH and issue the following commands:

sudo apt -y install qemu-guest-agent
sudo systemctl enable qemu-guest-agent
sudo systemctl start qemu-guest-agent

Note: if you get a message saying “The unit files have no installation config” you can safely ignore it.

The qemu-guest-agent is now installed! You can check if the service is running with this command:

sudo systemctl status qemu-guest-agent

This command should give the following output:

● qemu-guest-agent.service - QEMU Guest Agent
     Loaded: loaded (/lib/systemd/system/qemu-guest-agent.service; static; vendor preset: enabled)
     Active: active (running) since Mon 2021-11-22 19:52:07 CET; 19min ago
   Main PID: 464 (qemu-ga)
      Tasks: 1 (limit: 4637)
     Memory: 1.0M
     CGroup: /system.slice/qemu-guest-agent.service
             └─464 /usr/sbin/qemu-ga

4. Check if guest agent is succesfully running in Proxmox webinterface

An easy way to check if the qemu-guest-agent is running, is to look at the “summary” tab of your VM in Proxmox. It should now show the IP address(es) currently in use by the VM:

That’s it. Your VM is now running the qemu-guest-agent! I hope this guide helped you.

By Leendert de Borst

Freelance software architect with 10+ years of experience. Expert in translating complex technical problems into creative & simple solutions.


  1. Thanks for the instruction. If you start with running VM, you fail, so IMHO the line about suting down VM must be bold and hilighted

    1. Hello Peter, I’m happy to hear this article helped you. And thanks for your suggestion. I have now updated the article, and added a bold disclaimer telling that shutting down the VM is required.

Leave a comment

Your email address will not be published.