How collectd gets which VM it gets the data?

I want to know the Opennebula VM id and name from inside a VM. Is Opennebula stores VM information inside VM?

Hi Ranjith,

AFAIK there are two ways to have information in the VM. One is via contextualization variables - you already have VMID in the contextualization probably the VM name could be added too. The other way is to query opennebula from the VM using opennebula-gate when configured properly.

Anton Todorov

1 Like

I have this VMID in Templates section of VM. I want to use this in my shell script.

This is my shell script. But its not printing VMID in VM itself.

echo 'VMID: '$VMID