You say that after fencing and failure from init.d restart/status scripts it will try to start Tomcat on the other node? But I need Tomcat running on both nodes! The setup I am asking is:
HAProxy1--->Tomcat-1------->DB-1 (Linux-1) | +++^ | |-----+--------| | + | | HAProxy2++++>Tomcat-2---->DB-2 (Linux-2) I need Tomcat1-Tomcat2 processing requests concurrently and DB-1, DB-2 running in active/passing mode. So you are saying I can only monitor the load balancer (e.g. HAProxy) via Pacemaker? Not Tomcat or my DB? ________________________________ From: Digimer <[email protected]> To: Hermes Flying <[email protected]> Cc: David Coulson <[email protected]>; General Linux-HA mailing list <[email protected]> Sent: Saturday, December 1, 2012 7:25 PM Subject: Re: [Linux-HA] Some help on understanding how HA issues are addressed by pacemaker On 12/01/2012 08:58 AM, Hermes Flying wrote: > Actually each Tomcat uses a back-end database that has the notion of > "primary/backup". > I am trying to figure out if by using Pacemaker facilities I can avoid > splitbrain in the database as well. So far from what you described I > seem to get away with it meaning that by fencing, linux-1 will stop so > the secondary database in lunux-2 will become primary. > Am I on the right track here? If you have any recommendations for my > setup (2 linux running: 2 LB/2Tomcat/2Databases) please let me know! > Thank you for your time! You should check to see if there is a tomcat-specific resource agent for pacemaker. If there is, you should be able to do advanced checks. I can't speak to tomcat further as I do not use it. Speaking in general terms; Pacemaker will not normally fence a node simply because a resource on it has failed. Fencing (and quorum) are membership-level tools. If the node and it's cluster communication stack is healthy, it will be left alone. A resource failure will be addressed directly (by restarting it, relocating it, etc). So if you can do '/etc/init.d/tomcat status' and get a result, then pacemaker can tell when the status goes bad. At that time, it will call a 'stop' -> 'start' -> 'status' to see if it's ok. If it's not, it will try again or eventually simple stop it and try starting tomcat on the other node. (this I am guessing, as I mentioned earlier, I come from the rhcs world and have minimal pacemaker-specific experience). So if you tied your virtual IP and tomcat resources together in pacemaker, then the failure of one will trigger the restart or migration of both. -- Digimer Papers and Projects: https://alteeve.ca/w/ What if the cure for cancer is trapped in the mind of a person without access to education? _______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
