If you need to restart the network in the middle of the game on the Ubuntu server (12.04 in my case), you cannot use service :
# service networking restart stop: Job failed while stopping start: Job is already running: networking
It works on the command line, but with Ansible (1.8.4) it blocks you:
command: ifdown eth0 && ifup eth0
ifdown removes the interface, but ifup does not start
How to restart the interface?
source share