====== Proxmox - Guests (VMs and Containers) - Qemu-guest-agent - Install Qemu-guest-agent ====== ===== Install the guest-agent in each VM ===== ==== Debian/Ubuntu ==== sudo apt install qemu-guest-agent ---- ==== Redhat ==== sudo yum install qemu-guest-agent ---- ==== Windows ==== Download the virtio-win driver iso (see Windows VirtIO Drivers). * Install the virtio-serial driver: * Attach the ISO to your windows VM (virtio-*.iso) * Go to the Windows **Device Manager**. * Look for **PCI Simple Communications Controller** * Right Click -> **Update Driver** and select on the mounted iso in DRIVE:\vioserial\\ where is your Windows Version (e.g. 2k12R2 for Windows 2012 R2). After that, you have to install the qemu-guest-agent: * Go to the mounted ISO in explorer. * The guest agent installer is in the directory guest-agent. * Execute the installer with double click (either qemu-ga-x86_64.msi (64-bit) or qemu-ga-i386.msi (32-bit). After that the qemu-guest-agent should be up and running. * Validate this in the list of Window Services, or in a PowerShell with: PS C:\Users\Administrator> Get-Service QEMU-GA returns: Status Name DisplayName ------ ---- ----------- Running QEMU-GA QEMU Guest Agent **NOTE:** If it is not running, use the **Services** control panel to start it and make sure that it will start automatically on the next boot. ---- ===== Start the Agent ===== Depending on the distribution, the guest agent might not start automatically after the installation. Start it either directly with sudo systemctl start qemu-guest-agent Then enable the service to autostart (permanently) if not auto started, with sudo systemctl enable qemu-guest-agent ---- ===== Enable the guest-agent ===== ==== In the Shell ==== qm set VMID --agent 1 ---- ==== In the Proxmox GUI ==== * Navigate to Options. * Enable to Guest Agent. ---- ===== Test that the communication with the guest agent is working ===== The communication with the guest agent takes place over a unix socket located in /var/run/qemu-server/.qga. Test the communication qm agent: qm agent ping **NOTE:** If the qemu-guest-agent is correctly runnning in the VM, it will return without an error message. ---- ===== References ===== https://pve.proxmox.com/wiki/Qemu-guest-agent