ps ax | grep tomcat is not very helpful - sometimes the Tomcat process 
is running but Tomcat doesn't respond. So my "watch" script: I check 
selected URL directly using wget <URL> and examine the downloaded document 
for certain content (simple regexp matching). If it doesn't match then I 
try to download and check it again. If it doesn't match again then I 
restart Tomcat.

   The script "watch" is executed via cron every 2 minutes. And if restart 
is needed I'm informed via e-mail. Just for information - this kind of 
restart is raised once or twice a week.

   Vlastik

On Fri, 19 Oct 2012, Sean Carte wrote:

> On 18 October 2012 14:00, Vlastimil Krejcir <krej...@ics.muni.cz> wrote:
>> Tomcat seems to be running (ps ax | grep tomcat), but no response or
>> timeouting. No usefull info in logs. The solution is to restart the Tomcat -
>> I restart it once a day. And I have a "watch" script testing if Tomcat is
>> running correctly and if not then the "watch" restart him (this can include
>> kill -9 restart because sometimes Tomcat doesn't want to terminate himself
>> correctly).
>
> Thanks for the input Vlastik. In my case, though, Tomcat was no longer
> running. I also restart tomcat daily.
>
> About your 'watch' script, is that a bash script running ps ax | grep
> tomcat in a loop, and relaunching tomcat if it's not found?
>
> Sean
> -- 
> Sean Carte
> DUT E-Repository Administrator
> +27 72 898 8775
> +27 31 373 5761
> fax: +27 86 674 1254
> http://ir.dut.ac.za
>
> ------------------------------------------------------------------------------
> Everyone hates slow websites. So do we.
> Make your web apps faster with AppDynamics
> Download AppDynamics Lite for free today:
> http://p.sf.net/sfu/appdyn_sfd2d_oct
> _______________________________________________
> DSpace-tech mailing list
> DSpace-tech@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/dspace-tech
>

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
_______________________________________________
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech

Reply via email to