qm-guest-exec
Run commands inside a Proxmox VM
TLDR
Execute a command via guest agent
$ qm guest exec 100 command arg1 arg2
Execute asynchronously$ qm guest exec 100 command --synchronous 0
Execute with timeout of 10 seconds$ qm guest exec 100 command --timeout 10
Execute and forward stdin to guest$ qm guest exec 100 command --pass-stdin 1
SYNOPSIS
qm guest exec vmid command [arguments...] [options]
DESCRIPTION
qm guest exec executes commands inside a virtual machine through the QEMU guest agent. This allows host-level control over guest operations without network access to the VM.
The guest agent must be installed and running inside the VM for this to work.
PARAMETERS
--synchronous 0|1
Run synchronously (default) or asynchronously--timeout seconds
Command timeout in seconds--pass-stdin 0|1
Forward stdin to guest agent
CAVEATS
Requires QEMU guest agent to be installed and running in the VM. Some commands may require specific permissions within the guest OS.
HISTORY
Part of Proxmox VE QEMU/KVM management tools. Guest agent communication provides out-of-band management capabilities.
