Delete all VM backups via API /prunebackups

lubr

New Member
May 13, 2024
16
1
3
Hi. I am using https://pve.proxmox.com/pve-docs/api-viewer/index.html#/nodes/{node}/storage/{storage}/prunebackups method to remove backups after VM is destroyed. In documentation, there is keep-all=<0|1> which I thought when set to 0 would prune all backups so no one is left in the end. But when I pass keep-all=0, it is ignored completely and does nothing, meaning taks is processed with OK status but no changes done or no errors are thrown. Seems like it behaves like keep-all was set to 1. When I pass any other parameter such as keep-daily, it behaves as expected.

What is the difference between keep-all=1 and keep-all=0 then? Or how to achieve to prune all backups completely after VM is destroyed (tried https://pve.proxmox.com/pve-docs/api-viewer/index.html#/nodes/{node}/storage/{storage}/content/{volume} but when there is lots of backups, it is faulty and some deletion ends on no such file or unable to read tail (got 0 bytes) although those backups exists and can be used to restore VM)?

PVE@8.4.1