list vms connected to bridge

Hyien

Member
Jun 18, 2021
95
3
13
35
how can i list all VMs (including powered off and disconnected ones) on a bridge?
 
that's not possible directly, but something like the following should work (replace XX with bridge of your choice):

grep -l '^net.*bridge=vmbrXX' /etc/pve/nodes/*/{qemu-server,lxc}/*.conf

but it might contain some false positives (e.g., it will also contain matches that are just in snapshots).
 
I realize this was awhile ago, but I just started using proxmox and wondered how todo this. Great answer. I think I will add it as a shell function, maybe even try to make a verbose version that will print the node.conf files for those listed. Or maybe that has been done since then or added as a command.
Thanks Fabian