Specifically, an elasticsearch cluster, but doing this the right way would 
also apply to other kinds of clusters, like RabbitMQ or Redis.

I'm using https://github.com/LaneCommunityCollege/aspects_elasticsearch to 
manage my elasticsearch cluster. Currently, if I modify the configuration 
settings, Ansible would issue a restart to all the nodes in the cluster. 

The obvious answer is to only run the playbook on one node at a time. But 
there are situations where that isn't convenient. If I run Ansible like a 
puppet agent then setting the configuration setting in the group_vars file 
will apply it on all the nodes, thus restarting them all. Or if I have a 
large number of nodes. Or simply need to apply the change, but don't have 
time to do it one or two nodes at a time.

The other solutions I've thought of involve custom scripts that would not 
be part of the Ansible playbook. And likely be application specific.

Is there a way to tell ansible to set a service restart task sometime in 
the future? Say, right now for node1, 5 minutes later for node2, 10 minutes 
later for node3, and so on. 

Maybe the at module? How would it know to set it 10 minutes in the future 
instead of 5 for the third node? 

So, yeah, is there a good Ansible specific method for this? Or do I need to 
look outside of Ansible?

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/dcd691af-f8f3-47c8-b481-87a49c55ab89%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to