Hi and Happy Holidays! I have a server currently running Apache Tomcat. It often crashes when the connections go over 40. The previous admin created a script that restarts apache and tomcat when it hits 40 connections. I was wondering if it's possible to to the same thing with Monit. Here is the current cron script that runs every minute: Code: #!/bin/bash source /etc/profile RESDATE=`date "+DATE: %m/%d/%y TIME: %H:%M:%S"` USER=`netstat -tunlap | grep ESTABLISHED | grep -v sshd | grep -v '127.0.0.1' | wc -l` if [ "$USER" -gt 40 ] || [ "$USER" = 0 ] then echo " SERVER RESTART @ $RESDATE" >> /root/scripts/RESTARTS.TXT service httpd stop;/usr/local/tomcat/bin/shutdown.sh;sleep 5;/usr/local/tomcat/bin/startup.sh;service httpd start else cat /dev/null fi Is there a way to get Monit to do the same thing with the above script? Thanks!