Proxmox API, change VM network configuration

HarusKG

Renowned Member
May 28, 2012
8
0
66
Perm, Russia
Greetings!

Proxmox API provides the following command for a VM network adapter configuration:

# pvesh set /nodes/{node}/qemu/{vmid}/config –net0 'virtio,bridge=vmbr0,firewall=0,link_down=1'

If I run it without specifying the MAC address, it generates a new one.


Is there a way to run this command without altering the MAC address?
In my case, it is quite complicated to retrieve the MAC address in advance.
 
pvesh get /nodes/{node}/qemu/{vmid}/config --output-format=json | jq .net0 should be fairly straight-forward..