My backup server (running Arch Linux) can be remotely powered on via its out of band power controller (HP ILO), using a simple ssh command.
Several clients will backup at the same time and each will take a different time to complete, meaning I can't simply tell the backup script to shutdown the server as it would negatively affect clients which are still working...
I would like the server however to power off (say) 10 minutes after the last backup has completed.
Is there already anything out there that does that ?
If not, my idea of an implementation would be to have each client simply keep an ssh session open with a specific user "keep_alive" for as long as they need the server up, and have the server poll every 10 minutes to see if user "keep_alive" has been logged in in the last 10 minutes and if not, to shut itself down.
I have already scripted this idea using python, but something already robust and tested would be of course far better...