Find node based on VMID

Karberg

New Member
Nov 14, 2018
3
0
1
37
Hi,

I can see in the web interface when I click on a VM i get listed what node the VM is on.
How can I get that info based on CLI commands?

In this scenario i should expect i don't know what node the container is on.
So I want to extract the information out so my script can SSH into that specific node and run commands based on the specified VMID.
 
api call to /cluster/resources gives a list of nodes/storages/vms etc. with this information
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!