jriguera / ansible-ironic-standalone

Ansible roles and playbook to setup an Ironic standalone server to deploy baremetal hosts
http://jose.riguera.es/blog/openstack/2015/12/19/Ironic-2/
Apache License 2.0
43 stars 18 forks source link

Centos: after updating to release Mitaka-3.1, dnsmasq does not work with monit #10

Open jriguera opened 8 years ago

jriguera commented 8 years ago

It is caused by the change on the pidfile location. Now the pidfile is located in /var/run/dnsmasq/dnsmasq.pid instead of on /var/run/dnsmasq.pid and monit process is not restarted by the playbook.

$ monit summary
The Monit daemon 5.14 uptime: 5m 

Process 'rabbitmq'                  Running
Process 'nginx'                     Running
Process 'mysql'                     Running
System 'localhost.localdomain'      Running
Filesystem 'root'                   Accessible
Filesystem 'boot'                   Accessible
Process 'ironic-inspector'          Running
Process 'ironic-conductor'          Running
Process 'ironic-api'                Running
Process 'dnsmasq'                   Execution failed
jriguera commented 8 years ago

It is a temporary issue because of the changes in the systemd configuration and pidfile location. To fix it:

# Stop the process with systemd
$ systemctl stop dnsmasq

# and start the process with monit
$ monit start dnsmasq

After a couple of minutes:

$ monit status dnsmasq
The Monit daemon 5.14 uptime: 16m 

Process 'dnsmasq'
  status                            Running
  monitoring status                 Monitored
  pid                               27848
  parent pid                        1
  uid                               99
  effective uid                     99
  gid                               99
  uptime                            2m 
  children                          0
  memory                            1.3 MB
  memory total                      1.3 MB
  memory percent                    0.0%
  memory percent total              0.0%
  cpu percent                       0.0%
  cpu percent total                 0.0%
  port response time                0.099s to [localhost]:53 type TCP/IP protocol DNS
  data collected                    Sun, 31 Jul 2016 16:39:45