Proxmox api, stop running task

Melanxolik

Well-Known Member
Dec 18, 2013
86
0
46
Hello all, I have small problem with proxmox again.

I started from gui or console run task and got task id:
INFO: started backup task '94fdd0a3-28b5-4078-b9d9-06d098ec1a36'

but, I want to stop run this task from proxmox api, I tried search this in pvesh and didn't find.


Looked to api http://pve.proxmox.com/pve2-api-doc/ and see:
Code:
pvesh delete /nodes/{node}/tasks/{upid}

How can I compare taskid and upid for stop do task?
 
thanks, it's working, but I have other question about api

How can I get current running task connected with vmid?
In [8]: proxmox.nodes("virt01").tasks().get(vmid=231)
this query show me only complete task, but I want show running task for this vmid

It's need for control duplicate the tasks in shared queue to create backups.