APCUPSD

Dominik Wimmer

New Member
Feb 8, 2022
11
3
3
24
Hello dear Proxmox team,

Dear Proxmox Team, Our server is connected to a UPS. In the event of a power failure, the VMs on the server should shut down cleanly, as should the physical servers. Is there a template for a script that shuts down the individual VMs before the physical server? Unfortunately I couldn't find any on the internet.

Greetings from Dome
 
Thank you very much for your fast answer, so if I write into my host "stopall" every guest shut down cleanly? Or did I missunderstand something?
 
Thank you very much for your fast answer, so if I write into my host "stopall" every guest shut down cleanly? Or did I missunderstand something?
no, you'll need to send a request to the API endpoint. there are a few clients you can use [0]

but you can use our pvesh client on your node shell like this: pvesh create /nodes/localhost/stopall (you can change localhost with another node's name if you wish to stop the guests on there)

[0]: https://pve.proxmox.com/wiki/Proxmox_VE_API#Using_.27pvesh.27_to_access_the_API