[OpenSIPS-Users] opensips HA resource script (for Heartbeat)

Iñaki Baz Castillo ibc at aliax.net
Tue Dec 28 02:55:19 CET 2010


2010/12/22 Alexandr A. Alexandrov <shurrman at gmail.com>:
> Does anyone by chance have opensips HA resource script (for using with
> Heartbeat)?

OpenSIPS is not good for init scripts as when running daemonized it
returns 0 (ok) even if it fails to start (due to DB wrong connection
or whatever module error).

So HA would start OpenSIPS. The OpenSIPs init script (or HA LSB / OCF
script) returns 0, but the fact is that the daemonized (forked)
process has failed to start (i.e. any module error).

Later HA monitors OpenSIPS status (by using the LSB script "status"
action or the OCF script "monitor" action) and realizes that OpenSIPS
is not running. Then HA tries to start it again, such action returns 0
again (the script returns 0 as there are not grammar errors in the
config script) so HA is happy, but again, OpenSIPS is not running, and
so on.

This makes OpenSIPS not valid for full HA environment, so be careful.

-- 
Iñaki Baz Castillo
<ibc at aliax.net>



More information about the Users mailing list