Hi all,
I use ansible to shutdown some computer. I need to do it in a certain order.
My point is that I would like to check first if some machines are really off before stopping a second group of computers.
More specifically, I have two pools in my hosts file : computing-servers and storage-servers
I want to shutdown computing server AND BE SURE that they are all off before shutting down the storage-servers.
He want to be sure the server is halted, wait_for probably just checks
some service port like ssh, which doesn't say if the machine is powered of.
IMHO he'll need some out of band way to check that.
Sure I could use IPMI… for the computers which support it (but unfortunatey not all of them).
And the other point is that all my pools are already defined in ansible, so it would be cool to use them directly from ansible.
Finally, I found a way to do it.
I juste run “ansible computing-servers --list-hosts” into a bash script and use the return to ping the machines one by one. Thus when they are all down, I can shutdown the storage-servers.
F.