Thanks for your help now I raised the timeout to 120s and I see it trying for 180 seconds:
tomcat[1861]: 2008/07/04_15:55:27 DEBUG: start_tomcat[tomcat]: retry monitor_tomcat ... tomcat[1861]: 2008/07/04_15:58:23 DEBUG: start_tomcat[tomcat]: retry monitor_tomcat Is it waiting for a RC or is the monitor trying to connect to the statusurl? Like I said after ~50 seconds tomcat is running but heartbeat does not see that. I connect to the statusurl fine. Then heartbeats kills it and tomcat is stopped: lrmd[7325]: 2008/07/04_15:58:24 WARN: tomcat_21:start process (PID 1861) timed out (try 1). Killing with signal SIGTERM (15). lrmd[7325]: 2008/07/04_15:58:24 WARN: operation start[31] on ocf::tomcat::tomcat_21 for client 7328, its parameters: catalina_home=[/opt/jakarta/tomcat-5] CRM_meta_interval=[0] catalina_pid=[/opt/jakarta/tomcat-5/logs/catalina.pid] CRM_meta_id=[tomcat_start] CRM_meta_timeout=[180000] crm_feature_set=[2.0] java_home=[/usr/lib/java] statusurl=[http://localhost:8085/startcenter/jsp/login.jsp] CRM_meta_name=[start] : pid [1861] timed out crmd[7328]: 2008/07/04_15:58:24 ERROR: process_lrm_event: LRM operation tomcat_21_start_0 (31) Timed Out (timeout=180000ms) Its also strange that this PID 1861 is different with the one in /opt/jakarta/tomcat-5/logs/catalina.pid still it does kill tomcat. Thanks for helping -----Ursprüngliche Nachricht----- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Auftrag von Nick Gesendet: Freitag, 4. Juli 2008 15:17 An: General Linux-HA mailing list Betreff: Re: [Linux-HA] Tomcat times out Ehlers, Kolja ha scritto: > Hello, > > to begin with I am trying to startup a single tomcat instance. Even if I do > it by hand: > > export OCF_RESKEY_java_home=/usr/lib/java > export OCF_RESKEY_catalina_home=/opt/jakarta/tomcat-5 > export OCF_ROOT=/usr/lib/ocf > /usr/lib/ocf/resource.d/heartbeat/tomcat start > > on the shell, the system just hangs. To get the cursor back to the prompt I > need to cancel the script with crtl+c. The thing is that Tomcat actually > gets started. The pid file is located in the default dir > OCF_RESKEY_catalina_home/logs/catalina.pid. > > If I run heartbeats the tomcat start fails with -2 > > tomcat_21_start_0 (node=www1test, call=19, rc=-2): Timed Out > > Maybe the problem is that even when using my standard tomcat start script > the start takes almost 50 seconds to start up. Can I define timeouts for > single resources? > > Thanks > > Kolja > > Geschäftsführung: Dr. Michael Fischer, Reinhard Eisebitt > Amtsgericht Köln HRB 32356 > Steuer-Nr.: 217/5717/0536 > Ust.Id.-Nr.: DE 204051920 > -- > This email transmission and any documents, files or previous email > messages attached to it may contain information that is confidential or > legally privileged. If you are not the intended recipient or a person > responsible for delivering this transmission to the intended recipient, > you are hereby notified that any disclosure, copying, printing, > distribution or use of this transmission is strictly prohibited. If you > have received this transmission in error, please immediately notify the > sender by telephone or return email and delete the original transmission > and its attachments without reading or saving in any manner. > > _______________________________________________ > Linux-HA mailing list > [email protected] > http://lists.linux-ha.org/mailman/listinfo/linux-ha > See also: http://linux-ha.org/ReportingProblems tomcat meta-data output.. The start <operation> can have whatever timeout you want. <?xml version="1.0"?> <!DOCTYPE resource-agent SYSTEM "ra-api-1.dtd"> <resource-agent name="tomcat"> <version>1.0</version> <longdesc lang="en"> Resource script for tomcat. It manages a Tomcat instance as an HA resource. </longdesc> <shortdesc lang="en">tomcat resource agent</shortdesc> <parameters> <parameter name="tomcat_name" unique="1" > <longdesc lang="en"> The name of the resource </longdesc> <shortdesc>The name of the resource</shortdesc> <content type="string" default="" /> </parameter> <parameter name="script_log" unique="1"> <longdesc lang="en"> A destination of the log of this script </longdesc> <shortdesc>A destination of the log of this script</shortdesc> <content type="string" default="" /> </parameter> <parameter name="tomcat_stop_timeout" unique="0"> <longdesc lang="en"> Time-out at the time of the stop </longdesc> <shortdesc>Time-out at the time of the stop</shortdesc> <content type="integer" default="" /> </parameter> <parameter name="tomcat_suspend_trialcount" unique="0"> <longdesc lang="en"> The re-try number of times awaiting a stop </longdesc> <shortdesc>The re-try number of times awaiting a stop</shortdesc> <content type="integer" default="" /> </parameter> <parameter name="tomcat_user" unique="0"> <longdesc lang="en"> A user name to start a resource </longdesc> <shortdesc>A user name to start a resource</shortdesc> <content type="string" default="" /> </parameter> <parameter name="statusurl" unique="0"> <longdesc lang="en"> URL for state confirmation </longdesc> <shortdesc>URL for state confirmation</shortdesc> <content type="string" default="" /> </parameter> <parameter name="java_home" unique="1" required="1"> <longdesc lang="en"> Home directory of the Java </longdesc> <shortdesc>Home directory of the Java</shortdesc> <content type="string" default="" /> </parameter> <parameter name="catalina_home" unique="1" required="1"> <longdesc lang="en"> Home directory of Tomcat </longdesc> <shortdesc>Home directory of Tomcat</shortdesc> <content type="string" default="" /> </parameter> <parameter name="catalina_pid" unique="1"> <longdesc lang="en"> A PID file name of Tomcat </longdesc> <shortdesc>A PID file name of Tomcat</shortdesc> <content type="string" default="" /> </parameter> </parameters> <actions> <action name="start" timeout="60s" /> <action name="stop" timeout="120s" /> <action name="status" timeout="60" /> <action name="monitor" depth="0" timeout="30s" interval="10s" start-delay="10s" /> <action name="meta-data" timeout="5s" /> <action name="validate-all" timeout="5"/> </actions> </resource-agent> _______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems Geschäftsführung: Dr. Michael Fischer, Reinhard Eisebitt Amtsgericht Köln HRB 32356 Steuer-Nr.: 217/5717/0536 Ust.Id.-Nr.: DE 204051920 -- This email transmission and any documents, files or previous email messages attached to it may contain information that is confidential or legally privileged. If you are not the intended recipient or a person responsible for delivering this transmission to the intended recipient, you are hereby notified that any disclosure, copying, printing, distribution or use of this transmission is strictly prohibited. If you have received this transmission in error, please immediately notify the sender by telephone or return email and delete the original transmission and its attachments without reading or saving in any manner. _______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
