I created in /etc/init a monit.conf file that is pretty standard. During reboot, however, when monit tries to start, it checks dns resolution for things in its configuration file (monitrc) but fails. I had to add a pre-start stanza to get it to loop and keep trying to resolve a dns name before it goes and tries to start monit. It just seems kind of clunky though. I am guessing this is related to network stuff not starting until a script in /etc/init.d for networking runs and that my monit stuff starts before that unless I use this loop check. I tried:
start on (net-device-up IFACE=eth0 and runlevel ), thinking that this would make sure that the interface was up and that we were in a runlevel where networking should at least be running, but that did not help. Is there some other key word I can put in start on that checks if resolution is available? Please note my server is not running dns server.