Looks to me suspiciously like an issue with wget instead of tomcat. Wget is making an attempt using a stale cached connection, failing, and retrying. For some reason the result of the retry isn't present in the stdout file.
You could try adding the -S option to wget and then check for the string 'HTTP/1.1 200' instead. That seems to me to be a more reliable method. --David [EMAIL PROTECTED] wrote: >unfortunately it is in German: > >--15:17:51-- http://localhost:8080/myapp/index.jsp > (Versuch: 5) => `index.jsp' >Verbindungsaufbau zu >xxx|yyy|:8080... fehlgeschlagen: Die Wartezeit für die Verbindung ist >abgelaufen. >Erneuter Versuch. > >in English the whole stdout should mean: > >--15:17:51-- http://localhost:8080/myapp/index.jsp > (attempt: 5) => `index.jsp' >connection establishing to >xxx|yyy|:8080... failed: the idle time for the connection is expred. >new attemtpt. > > > >----- Originalnachricht ----- >Von: David Smith <[EMAIL PROTECTED]> >Datum: Dienstag, 28. November 2006 1:31 pm >Betreff: Re: server not reachable in regular period of time > > > >>What does stdout have in it when your script registers a server down >>condition? >> >>--David >> >>[EMAIL PROTECTED] wrote: >> >> >> >>>Hi all, >>> >>>I run a Linux script to check every 5 minutes whether my server is >>> >>> >>still on: >> >> >>>#! /bin/bash >>>while true; do >>>sleep 300 >>> `wget http://localhost:8080/myapp/index.jsp -o stdout` >>> result=`grep -c 'OK' stdout` >>> if [ $result -eq 0 ]; then >>> echo "server down" | mail -s "warning:server down" >>>[EMAIL PROTECTED] >>> fi >>> done >>> >>> >>> >>>From this script I noticed that my server is not reachable every 70 >> >> >>>minutes. Then, I open a browser and request my application. It >>> >>> >>still works. >> >> >>>Could any body please have an explanation for this phenomenon? >>> >>>Thanks. >>> >>>Gop >>> >>> >>>------------------------------------------------------------------- >>> >>> >>-- >> >> >>>To start a new topic, e-mail: users@tomcat.apache.org >>>To unsubscribe, e-mail: [EMAIL PROTECTED] >>>For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >>> >>> >>> >>-------------------------------------------------------------------- >>- >>To start a new topic, e-mail: users@tomcat.apache.org >>To unsubscribe, e-mail: [EMAIL PROTECTED] >>For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> > > >--------------------------------------------------------------------- >To start a new topic, e-mail: users@tomcat.apache.org >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > > --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]