The below configuration detect my website failures perfect but it never runs the exec. I have tried to put commands directly in the quotes with no success either "/bin/date >> /var/monit.log"
I'm new to monit. Can someone please tell me what's wrong here? Thank you
check host shorthostname with address xxx.xxx.xxx.xxx if failed url http://somewebserver/folder/index.jsp and content == 'MM_preloadImages'
then exec "/usr/local/sbin/tomcat-restart"