[asterisk-users] Asterisk HA with heartbeat and systemd

Olivier oza.4h07 at gmail.com
Tue Oct 20 02:07:58 CDT 2015

My machines have both a /usr/lib/ocf/resource.d/heartbeat/asterisk file
(from resource-agents package, it seems).
If I'm not mistaken, this file is not run when asterisk is started/stopped
by hb_standby/hb_takeover commands (I added a touch /tmp/foobar line in
/usr/lib/ocf/resource.d/heartbeat/asterisk to check this).

How does this script compare with rc.debian.asterisk that can be found in
contrib/init.d directory ?
Is this file maintained by Asterisk community and closely following
Asterisk evolution or is it rather independant from Asterisk development
team ?
What would you recommend on this subject ?

2015-10-19 20:11 GMT+02:00 Olivier <oza.4h07 at gmail.com>:

> Hello,
> I'm setting up an active-passive Asterisk solution on Debian Jessie
> platforms.
> I'm using heartbeat package.
> As I'm not yet familiar with either systemd or heartbeat, I've got a
> couple of questions:
> 1. At the moment, I'm using /usr/share/heartbeat/hb_standby or
> /usr/share/heartbeat/hb_takeover scripts to both :
> - allocate "floating" IP addresses to active server
> - start/stop asterisk daemon.
> Is this appropriate ? What would you recommand instead ?
> 2. My /etc/ha.d/haresources file contains:
> machine1 asterisk
> With this, I can see that asterisk daemon is correctly started and stopped
> when hb_standby/hb_takeover commands are typed but "service
> asterisk,status" is a bit misleading with:
> service asterisk status
> ● asterisk.service - LSB: Asterisk PBX
>    Loaded: loaded (/etc/init.d/asterisk)
>    Active: active (exited) since lun. 2015-10-19 18:02:58 CEST; 41min ago
>   Process: 19576 ExecStop=/etc/init.d/asterisk stop (code=exited,
> status=0/SUCCESS)
>   Process: 19583 ExecStart=/etc/init.d/asterisk start (code=exited,
> status=0/SUCCESS)
> How can I best improve this and configure heartbeat to use "service
> asterisk start/stop" ?
> Regards
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20151020/2458e43c/attachment.html>

More information about the asterisk-users mailing list