qemu-server icon indicating copy to clipboard operation
qemu-server copied to clipboard

Proxmox VE uses token based authentication not support option skiplock(Only root may use)

Open shining-github opened this issue 2 years ago • 0 comments

Proxmox VE uses token based authentication not support option skiplock(Only root may use) Use cookie authorization is ok.

delete vm api https://pve.proxmox.com/pve-docs/api-viewer/index.html#/nodes/{node}/qemu/{vmid}

APINODE=10.0.0.160
TARGETNODE=pve2
VMID=106
curl -v --insecure -X DELETE -H 'Authorization: PVEAPIToken=root@pam!root_tokenid=xxxxxx' "https://$APINODE:8006/api2/json/nodes/$TARGETNODE/qemu/$VMID?destroy-unreferenced-disks=0&purge=1&skiplock=1" | jq '.'
return:
{
  "data": null,
  "errors": {
    "skiplock": "Only root may use this option."
  }
}

shining-github avatar Jun 29 '22 12:06 shining-github