[asterisk-users] Asterisk Heartbeat Monitor for Fail safe.

2009-12-20 Thread DHAVAL INDRODIYA
Dear All,

I want to configure Asterisk/Kamailio Like system monitor with Heartbeat

is there any way to monitor Service

If NODE1 is stopped or over loaded then NODE 2 will work and vice verse.

any help appreciated because i m stuck in heartbeat to configure service.

regards
Dhaval
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Asterisk Heartbeat Monitor for Fail safe.

2009-12-20 Thread Alex Balashov
On 12/21/2009 12:24 AM, DHAVAL INDRODIYA wrote:

 I want to configure Asterisk/Kamailio Like system monitor with Heartbeat

There is, but Asterisk/Kamailio-like system is a meaninglessly vague 
description.  That's like saying, Is there any way I can ride 
car/elephant-like transportation?

 is there any way to monitor Service

 If NODE1 is stopped or over loaded then NODE 2 will work and vice verse.

 any help appreciated because i m stuck in heartbeat to configure service.

You would want to use a tool like SIP Swiss Army Knife (sipsak) to check 
for basic SIP responsiveness.  It can be wrapped inside a custom OCF 
resource agent script, if you're using Heartbeat v2.

-- 
Alex Balashov - Principal
Evariste Systems
Web : http://www.evaristesys.com/
Tel : (+1) (678) 954-0670
Direct  : (+1) (678) 954-0671

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Asterisk Heartbeat Monitor for Fail safe.

2009-12-20 Thread DHAVAL INDRODIYA
Thanks Alex,

regards
Dhaval

On Mon, Dec 21, 2009 at 11:52 AM, Alex Balashov
abalas...@evaristesys.comwrote:

 On 12/21/2009 12:24 AM, DHAVAL INDRODIYA wrote:

  I want to configure Asterisk/Kamailio Like system monitor with Heartbeat

 There is, but Asterisk/Kamailio-like system is a meaninglessly vague
 description.  That's like saying, Is there any way I can ride
 car/elephant-like transportation?

  is there any way to monitor Service
 
  If NODE1 is stopped or over loaded then NODE 2 will work and vice verse.
 
  any help appreciated because i m stuck in heartbeat to configure service.

 You would want to use a tool like SIP Swiss Army Knife (sipsak) to check
 for basic SIP responsiveness.  It can be wrapped inside a custom OCF
 resource agent script, if you're using Heartbeat v2.

 --
 Alex Balashov - Principal
 Evariste Systems
 Web : http://www.evaristesys.com/
 Tel : (+1) (678) 954-0670
 Direct  : (+1) (678) 954-0671

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] [Asterisk-users] asterisk +heartbeat (Wilton Helm)

2008-10-17 Thread Freddi Hansen

 having two NICs on the same subnet

 I'm trying to wrap my brain around that in the larger network 
 picture.  Two
 NICs in the same subnet (presumably on the same computer) would have 
 access
 to the same other devices.  This could potentially increase bandwidth
 (maybe?) and offer redundancy (if NICS, wiring or switches were the 
 biggest
 source of failure).  I'm not sure how the OS would decide which one to 
 use
 for a given packet, or if an application (such as Asterisk) could 
 determine
 which one to use.  I can see potential problems with addressing, as other
 devices could send to one, and would definitely not know what to do 
 with a
 reply from the other, etc.  I'm not sure this would be an Asterisk bug.
 Without some concept of what I am missing here, I would consider it a
 cockpit error on system setup.  The only reason I can think of for having
 two NICs in a computer would be using it as a router--in which case they
 wouldn't be on the same subnet.  (OK I've done it before for redundant
 paths, but again, the paths should be on different subnets, otherwise how
 does one tell the OS which path was intended?)

Try reading:
http://www.linuxfoundation.org/en/Net:Bonding
We have 3 networks on each of our servers. Each network (and IP) is 
served by 2 nics. (yes 6 nics per server)
Works well with Asterisk, you can disconnect cables or take power from 
one of the core switches without as much as a click  in audio in ongoing 
connections.
 



___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] [Asterisk-users] asterisk +heartbeat (Wilton Helm)

2008-10-17 Thread Steve Totaro
On Fri, Oct 17, 2008 at 4:17 AM, Freddi Hansen [EMAIL PROTECTED] wrote:

 having two NICs on the same subnet

 I'm trying to wrap my brain around that in the larger network
 picture.  Two
 NICs in the same subnet (presumably on the same computer) would have
 access
 to the same other devices.  This could potentially increase bandwidth
 (maybe?) and offer redundancy (if NICS, wiring or switches were the
 biggest
 source of failure).  I'm not sure how the OS would decide which one to
 use
 for a given packet, or if an application (such as Asterisk) could
 determine
 which one to use.  I can see potential problems with addressing, as other
 devices could send to one, and would definitely not know what to do
 with a
 reply from the other, etc.  I'm not sure this would be an Asterisk bug.
 Without some concept of what I am missing here, I would consider it a
 cockpit error on system setup.  The only reason I can think of for having
 two NICs in a computer would be using it as a router--in which case they
 wouldn't be on the same subnet.  (OK I've done it before for redundant
 paths, but again, the paths should be on different subnets, otherwise how
 does one tell the OS which path was intended?)

 Try reading:
 http://www.linuxfoundation.org/en/Net:Bonding
 We have 3 networks on each of our servers. Each network (and IP) is
 served by 2 nics. (yes 6 nics per server)
 Works well with Asterisk, you can disconnect cables or take power from
 one of the core switches without as much as a click  in audio in ongoing

I have mutihomed boxen on many different networks as well, this has
never been an issue.

Let's put aside why would you or there is no reason, and then think
about it again.  Let's just say you wanted two NICs on the same subnet
with different IPS,  Is it a bug or by design?

I am fully aware of aggregated (bonding) of links too.

I didn't bother to click the link because I assume it is just plain
old network bonding (aggregating) like in the Cisco world, you can
bond several NICs and get higher bandwidth on a switch, I have three
NICS bonded for a three gigabit uplink and that material is too dry
for this morning, and if it is what I think it is, I have been doing
it for years, let's see I got my CCNA in 97 and renewed sometime or
another

Cisco calls this Multiliink in the router space..  I had three bonded
T1s, I could unplug up to two of the T1s and and the internet stayed
up up, just at 33% capacity.

I am talking about NICs with different IPs on the same subnet.  Is
Asterisk or Linux deciding to reply to a packet sent to 10.0.0.1
(eht0) by sending that packet through 10.0.0.254?

-- 
Thanks,
Steve Totaro
+18887771888 (Toll Free)
+12409381212 (Cell)
+12024369784 (Skype)

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] [Asterisk-users] asterisk +heartbeat (Wilton Helm)

2008-10-17 Thread Kristian Kielhofner
On Fri, Oct 17, 2008 at 9:29 AM, Steve Totaro
[EMAIL PROTECTED] wrote:

 I have mutihomed boxen on many different networks as well, this has
 never been an issue.

 Let's put aside why would you or there is no reason, and then think
 about it again.  Let's just say you wanted two NICs on the same subnet
 with different IPS,  Is it a bug or by design?

  This whole discussion seems to have forgotten about ARP...  The
kernel will dynamically learn MAC address to IP address associations
as well as which interface the association was learned over using ARP
broadcasts.

  This config is broken.

 I am fully aware of aggregated (bonding) of links too.

 I didn't bother to click the link because I assume it is just plain
 old network bonding (aggregating) like in the Cisco world, you can
 bond several NICs and get higher bandwidth on a switch, I have three
 NICS bonded for a three gigabit uplink and that material is too dry
 for this morning, and if it is what I think it is, I have been doing
 it for years, let's see I got my CCNA in 97 and renewed sometime or
 another

  Most Cisco devices (especially back in the day - 1997?) were using
Cisco's EtherChannel:

http://en.wikipedia.org/wiki/EtherChannel

  Which is not quite the same as IEEE 802.3ad (referred to as LACP on
some switches).  I was working with Cisco devices at the time but I
don't remember if I ever had the opportunity to configure bonding on
my Cat 2950s...  I can tell you that even though 802.3ad is a
multi-vendor standard, many Cisco admins still configure EtherChannel
between Cisco devices.

  Whether you are using EtherChannel or 802.3ad the catch is your
switch needs to support one or the other and you have to specifically
configure switch ports to be a member of that aggregation group.  It
limits bonded functionality to at least smart switches if not full
blown managed switches like those from Cisco, HP, Foundry, etc.

  With most Linux users being as cheap as they are ;), the Link kernel
bonding module provides an ability to bond NICS *without* requiring
any special support or configuration on the switch.  You are even
provided various configuration options at module load time to tweak
this.  I've never used it (I use 802.3ad) so I can't be exactly sure
how it works but I can bet there is some ARP magic in there
somewhere...

 Cisco calls this Multiliink in the router space..  I had three bonded
 T1s, I could unplug up to two of the T1s and and the internet stayed
 up up, just at 33% capacity.

  Depending on how you were doing it (Multilink PPP?) that is VERY
different technology.  Not to be confused with what we have been
calling bonding (sometimes referred to as teaming) which use a
variety of Ethernet specific technologies.  Although Token Ring, etc
might have some equivalent (overlapping?) standards, u - who cares
;)?

 I am talking about NICs with different IPs on the same subnet.  Is
 Asterisk or Linux deciding to reply to a packet sent to 10.0.0.1
 (eht0) by sending that packet through 10.0.0.254?


  Understood.  When you up an interface with an IP address and netmask
the kernel automatically inserts a route for that network in the route
table (using that interface):

ip route show:
10.16.5.0/24 dev eth0  proto kernel  scope link  src 10.16.5.233  metric 1
default via 10.16.5.1 dev eth0  proto static

  As you can see I've also added a default route here.  Now, if I ping
my default route the kernel's ARP cache learns which MAC address that
IP has and over which interface:

arp -an:
? (10.16.5.1) at 00:13:72:26:36:b7 [ether] on eth0

  My guess is that if you had two NICs on the same subnet with
different IPs the kernel route table and ARP cache would get pretty
confused.  This seems so incredibly broken to me I've never tried

  Something else that seems strange about this arrangement, why would
you want to bother to configure other hosts on the LAN differently?
You're not really adding bandwidth/reliability (if you could call it
that) unless you configure other machines on the LAN to use the
different addresses...  Weird.

  In short: If you want to have two NICs on the same network, run them
through bonding.ko - PLEASE! ;)  If you need other IPs, add an alias
to your bonded interface!

-- 
Kristian Kielhofner
http://blog.krisk.org
http://www.submityoursip.com
http://www.astlinux.org
http://www.star2star.com

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] [Asterisk-users] asterisk +heartbeat

2008-10-16 Thread Wilton Helm
 having two NICs on the same subnet

I'm trying to wrap my brain around that in the larger network picture.  Two
NICs in the same subnet (presumably on the same computer) would have access
to the same other devices.  This could potentially increase bandwidth
(maybe?) and offer redundancy (if NICS, wiring or switches were the biggest
source of failure).  I'm not sure how the OS would decide which one to use
for a given packet, or if an application (such as Asterisk) could determine
which one to use.  I can see potential problems with addressing, as other
devices could send to one, and would definitely not know what to do with a
reply from the other, etc.  I'm not sure this would be an Asterisk bug.
Without some concept of what I am missing here, I would consider it a
cockpit error on system setup.  The only reason I can think of for having
two NICs in a computer would be using it as a router--in which case they
wouldn't be on the same subnet.  (OK I've done it before for redundant
paths, but again, the paths should be on different subnets, otherwise how
does one tell the OS which path was intended?)

Wilton


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] [Asterisk-users] asterisk +heartbeat

2008-10-16 Thread Steve Totaro
On Thu, Oct 16, 2008 at 1:09 PM, Wilton Helm [EMAIL PROTECTED] wrote:
 having two NICs on the same subnet

 I'm trying to wrap my brain around that in the larger network picture.  Two
 NICs in the same subnet (presumably on the same computer) would have access
 to the same other devices.  This could potentially increase bandwidth
 (maybe?) and offer redundancy (if NICS, wiring or switches were the biggest
 source of failure).  I'm not sure how the OS would decide which one to use
 for a given packet, or if an application (such as Asterisk) could determine
 which one to use.  I can see potential problems with addressing, as other
 devices could send to one, and would definitely not know what to do with a
 reply from the other, etc.  I'm not sure this would be an Asterisk bug.
 Without some concept of what I am missing here, I would consider it a
 cockpit error on system setup.  The only reason I can think of for having
 two NICs in a computer would be using it as a router--in which case they
 wouldn't be on the same subnet.  (OK I've done it before for redundant
 paths, but again, the paths should be on different subnets, otherwise how
 does one tell the OS which path was intended?)

 Wilton


 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


If you are referring to my post about strange behavior of asterisk
sending on one NIC and receiving on another.  This could be a useful
feature but I think it was a bug and caused issues.

The phone is programmed with the IP of the NIC to use, so it should
send packets there, Asterisk should send packets back out the same NIC
that they came in on (in case, all LAN, server and phones).

The path should be determined by IP and or MAC address.  I would
definitely call it a bug.

Increased bandwidth is nice but in a world of cheap gigabit switches
and servers with standard dual gigabit NICs, I don' see a huge need.

I have dual homed servers on the same subnet in case a NIC or switch
died, by plugging into different switches.  I have also done this
(although not necessary) with Quintum boxes, register four 24 port FXS
boxes to one NIC and four to the secondary.

With STP 
http://www.cisco.com/univercd/cc/td/doc/product/rtrmgmt/sw_ntman/cwsimain/cwsi2/cwsiug2/vlan2/stpapp.htm
You can mesh your network without worrying about packet storms.

-- 
Thanks,
Steve Totaro
+18887771888 (Toll Free)
+12409381212 (Cell)
+12024369784 (Skype)

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] asterisk+heartbeat

2008-10-15 Thread Gleim, Jason
How did you define the secondary IP address? Did you actually set that
up in the network scripts and bind it to eth0 or did you just define it
in /etc/ha.d/haresources? You should only have the virtual IP defined in
haresources along with the primary server and what you want to do on
node up/down.

My haresources file has a single line:
ohasterisk01 10.191.32.31 MailTo::user@domain.com::Asterisk
fonulator asterisk

We're obviously using the redFone FoneBRIDGE for our T1 connection as
you can see we're firing the fonulator script and then asterisk.

HTH!

Jason


 -Original Message-
 From: [EMAIL PROTECTED] [mailto:asterisk-users-
 [EMAIL PROTECTED] On Behalf Of Nhadie
 Sent: Tuesday, October 14, 2008 12:47 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: [asterisk-users] asterisk+heartbeat
 
 Hi,
 
 I'm using heartbeat as a failover for my asterisk server.
 
 on the active server 1 i have
 
 10.10.10.1 eth0
 10.10.10.3 secondary eth0
 
 asterisk listens to the secondary ip, so that if server 1 fails,
server
 2 will then get that IP.
 
 so if server 1 fails, server 2 will have the IP
 
 10.10.10.2 eth0
 10.10.10.3 secondary eth0
 
 problem is i have to bind asterisk to the secondary IP if dont, i cant
 make calls. but if server 2 is inactive, asterisk does not run, as on
 the config it is binded on the secondary ip.
 
 anyone uses heartbeat for failover? tia.
 
 regards,
 nhadie
 
 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] asterisk+heartbeat

2008-10-15 Thread Steve Totaro
I had an issue in 1.2.x that I am not sure ever got fixed but having two
NICs on the same subnet did strange things.  Strange like one NIC would be
used for outbound traffic and the other for inbound traffic.

Maybe someone knows why, if it was a bug, if it was fixed?

I could think of something creative but am drained right now and have to go
buy some coax and connectors.

If nobody helps you by then, I will.

Thanks,
Steve Totaro

On Wed, Oct 15, 2008 at 3:39 PM, Gleim, Jason [EMAIL PROTECTED]wrote:

 How did you define the secondary IP address? Did you actually set that
 up in the network scripts and bind it to eth0 or did you just define it
 in /etc/ha.d/haresources? You should only have the virtual IP defined in
 haresources along with the primary server and what you want to do on
 node up/down.

 My haresources file has a single line:
 ohasterisk01 10.191.32.31 MailTo::user@domain.com::Asterisk
 fonulator asterisk

 We're obviously using the redFone FoneBRIDGE for our T1 connection as
 you can see we're firing the fonulator script and then asterisk.

 HTH!

 Jason


  -Original Message-
  From: [EMAIL PROTECTED] [mailto:asterisk-users-
  [EMAIL PROTECTED] On Behalf Of Nhadie
  Sent: Tuesday, October 14, 2008 12:47 PM
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: [asterisk-users] asterisk+heartbeat
 
  Hi,
 
  I'm using heartbeat as a failover for my asterisk server.
 
  on the active server 1 i have
 
  10.10.10.1 eth0
  10.10.10.3 secondary eth0
 
  asterisk listens to the secondary ip, so that if server 1 fails,
 server
  2 will then get that IP.
 
  so if server 1 fails, server 2 will have the IP
 
  10.10.10.2 eth0
  10.10.10.3 secondary eth0
 
  problem is i have to bind asterisk to the secondary IP if dont, i cant
  make calls. but if server 2 is inactive, asterisk does not run, as on
  the config it is binded on the secondary ip.
 
  anyone uses heartbeat for failover? tia.
 
  regards,
  nhadie
 


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] asterisk+heartbeat

2008-10-15 Thread Edgar Guadamuz
Are you using bindaddr=0.0.0.0 in sip.conf and iax.conf ??




On Wed, Oct 15, 2008 at 5:35 PM, Steve Totaro 
[EMAIL PROTECTED] wrote:

 I had an issue in 1.2.x that I am not sure ever got fixed but having two
 NICs on the same subnet did strange things.  Strange like one NIC would be
 used for outbound traffic and the other for inbound traffic.

 Maybe someone knows why, if it was a bug, if it was fixed?

 I could think of something creative but am drained right now and have to go
 buy some coax and connectors.

 If nobody helps you by then, I will.

 Thanks,
 Steve Totaro


 On Wed, Oct 15, 2008 at 3:39 PM, Gleim, Jason [EMAIL PROTECTED]wrote:

 How did you define the secondary IP address? Did you actually set that
 up in the network scripts and bind it to eth0 or did you just define it
 in /etc/ha.d/haresources? You should only have the virtual IP defined in
 haresources along with the primary server and what you want to do on
 node up/down.

 My haresources file has a single line:
 ohasterisk01 10.191.32.31 MailTo::user@domain.com::Asterisk
 fonulator asterisk

 We're obviously using the redFone FoneBRIDGE for our T1 connection as
 you can see we're firing the fonulator script and then asterisk.

 HTH!

 Jason


  -Original Message-
  From: [EMAIL PROTECTED] [mailto:asterisk-users-
  [EMAIL PROTECTED] On Behalf Of Nhadie
  Sent: Tuesday, October 14, 2008 12:47 PM
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: [asterisk-users] asterisk+heartbeat
 
  Hi,
 
  I'm using heartbeat as a failover for my asterisk server.
 
  on the active server 1 i have
 
  10.10.10.1 eth0
  10.10.10.3 secondary eth0
 
  asterisk listens to the secondary ip, so that if server 1 fails,
 server
  2 will then get that IP.
 
  so if server 1 fails, server 2 will have the IP
 
  10.10.10.2 eth0
  10.10.10.3 secondary eth0
 
  problem is i have to bind asterisk to the secondary IP if dont, i cant
  make calls. but if server 2 is inactive, asterisk does not run, as on
  the config it is binded on the secondary ip.
 
  anyone uses heartbeat for failover? tia.
 
  regards,
  nhadie
 



 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] asterisk+heartbeat

2008-10-15 Thread Nhadie
hi sir

as mentioned i need to bind it on the secondary ip.
coz if i bind it to 0.0.0.0, it's rejecting the call.

i'm not sure if possible with heartbeat to execute a command after it 
takes over an IP. so i can reload asterisk on the failover server once 
it has the ip so i can bind asterisk to it.

regards
nhadie

Edgar Guadamuz wrote:
 Are you using bindaddr=0.0.0.0 http://0.0.0.0 in sip.conf and iax.conf ??
  
 
 
  
 On Wed, Oct 15, 2008 at 5:35 PM, Steve Totaro 
 [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] 
 wrote:
 
 I had an issue in 1.2.x that I am not sure ever got fixed but having
 two NICs on the same subnet did strange things.  Strange like one
 NIC would be used for outbound traffic and the other for inbound
 traffic.
 
 Maybe someone knows why, if it was a bug, if it was fixed?
 
 I could think of something creative but am drained right now and
 have to go buy some coax and connectors.
 
 If nobody helps you by then, I will.
 
 Thanks,
 Steve Totaro
 
 
 On Wed, Oct 15, 2008 at 3:39 PM, Gleim, Jason
 [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote:
 
 How did you define the secondary IP address? Did you actually
 set that
 up in the network scripts and bind it to eth0 or did you just
 define it
 in /etc/ha.d/haresources? You should only have the virtual IP
 defined in
 haresources along with the primary server and what you want to do on
 node up/down.
 
 My haresources file has a single line:
 ohasterisk01 10.191.32.31 http://10.191.32.31/
 MailTo::user@domain.com::Asterisk
 fonulator asterisk
 
 We're obviously using the redFone FoneBRIDGE for our T1
 connection as
 you can see we're firing the fonulator script and then asterisk.
 
 HTH!
 
 Jason
 
 
   -Original Message-
   From: [EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED]
 [mailto:asterisk-users- mailto:asterisk-users-
   [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]]
 On Behalf Of Nhadie
   Sent: Tuesday, October 14, 2008 12:47 PM
   To: Asterisk Users Mailing List - Non-Commercial Discussion
   Subject: [asterisk-users] asterisk+heartbeat
  
   Hi,
  
   I'm using heartbeat as a failover for my asterisk server.
  
   on the active server 1 i have
  
   10.10.10.1 http://10.10.10.1/ eth0
   10.10.10.3 http://10.10.10.3/ secondary eth0
  
   asterisk listens to the secondary ip, so that if server 1 fails,
 server
   2 will then get that IP.
  
   so if server 1 fails, server 2 will have the IP
  
   10.10.10.2 http://10.10.10.2/ eth0
   10.10.10.3 http://10.10.10.3/ secondary eth0
  
   problem is i have to bind asterisk to the secondary IP if
 dont, i cant
   make calls. but if server 2 is inactive, asterisk does not
 run, as on
   the config it is binded on the secondary ip.
  
   anyone uses heartbeat for failover? tia.
  
   regards,
   nhadie
  
 
 
 
 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com
 http://www.api-digital.com/ --
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
 
 
 
 
 
 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] asterisk+heartbeat

2008-10-15 Thread Nhadie


Gleim, Jason wrote:
 How did you define the secondary IP address? Did you actually set that
 up in the network scripts and bind it to eth0 or did you just define it
 in /etc/ha.d/haresources? You should only have the virtual IP defined in
 haresources along with the primary server and what you want to do on
 node up/down.

hi sir,

secondary is asisgned by heartbeat via haresources.

 
 My haresources file has a single line:
 ohasterisk01 10.191.32.31 MailTo::user@domain.com::Asterisk
 fonulator asterisk

does this mean asterisk will run after it takes over the IP?
can i do this without the fonulator script?

 
 We're obviously using the redFone FoneBRIDGE for our T1 connection as
 you can see we're firing the fonulator script and then asterisk.
 
 HTH!
 
 Jason
 
 
 -Original Message-
 From: [EMAIL PROTECTED] [mailto:asterisk-users-
 [EMAIL PROTECTED] On Behalf Of Nhadie
 Sent: Tuesday, October 14, 2008 12:47 PM
 To: Asterisk Users Mailing List - Non-Commercial Discussion
 Subject: [asterisk-users] asterisk+heartbeat

 Hi,

 I'm using heartbeat as a failover for my asterisk server.

 on the active server 1 i have

 10.10.10.1 eth0
 10.10.10.3 secondary eth0

 asterisk listens to the secondary ip, so that if server 1 fails,
 server
 2 will then get that IP.

 so if server 1 fails, server 2 will have the IP

 10.10.10.2 eth0
 10.10.10.3 secondary eth0

 problem is i have to bind asterisk to the secondary IP if dont, i cant
 make calls. but if server 2 is inactive, asterisk does not run, as on
 the config it is binded on the secondary ip.

 anyone uses heartbeat for failover? tia.

 regards,
 nhadie

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 
 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users
 

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] asterisk+heartbeat

2008-10-15 Thread Edgar Guadamuz
Version 2 of Linux-HA allows order constraints, so you can first set the IP
and then start asterisk. (service asterisk should be down until IP address
moves)



On Wed, Oct 15, 2008 at 7:17 PM, Nhadie [EMAIL PROTECTED] wrote:



 Gleim, Jason wrote:
  How did you define the secondary IP address? Did you actually set that
  up in the network scripts and bind it to eth0 or did you just define it
  in /etc/ha.d/haresources? You should only have the virtual IP defined in
  haresources along with the primary server and what you want to do on
  node up/down.

 hi sir,

 secondary is asisgned by heartbeat via haresources.

 
  My haresources file has a single line:
  ohasterisk01 10.191.32.31 MailTo::user@domain.com::Asterisk
  fonulator asterisk

 does this mean asterisk will run after it takes over the IP?
 can i do this without the fonulator script?

 
  We're obviously using the redFone FoneBRIDGE for our T1 connection as
  you can see we're firing the fonulator script and then asterisk.
 
  HTH!
 
  Jason
 
 
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:asterisk-users-
  [EMAIL PROTECTED] On Behalf Of Nhadie
  Sent: Tuesday, October 14, 2008 12:47 PM
  To: Asterisk Users Mailing List - Non-Commercial Discussion
  Subject: [asterisk-users] asterisk+heartbeat
 
  Hi,
 
  I'm using heartbeat as a failover for my asterisk server.
 
  on the active server 1 i have
 
  10.10.10.1 eth0
  10.10.10.3 secondary eth0
 
  asterisk listens to the secondary ip, so that if server 1 fails,
  server
  2 will then get that IP.
 
  so if server 1 fails, server 2 will have the IP
 
  10.10.10.2 eth0
  10.10.10.3 secondary eth0
 
  problem is i have to bind asterisk to the secondary IP if dont, i cant
  make calls. but if server 2 is inactive, asterisk does not run, as on
  the config it is binded on the secondary ip.
 
  anyone uses heartbeat for failover? tia.
 
  regards,
  nhadie
 
  ___
  -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
  asterisk-users mailing list
  To UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users
 
  ___
  -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
  asterisk-users mailing list
  To UNSUBSCRIBE or update options visit:
 http://lists.digium.com/mailman/listinfo/asterisk-users
 

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] asterisk+heartbeat

2008-10-15 Thread Steve Totaro
So Redfone relies on http running?  That is almost as bad as using
ping.  HTTP could be up but Asterisk could have crapped out but ping
and HTTP could still be up.  I think the manager is the best way.

If your backup box has 10.10.10.3 hardcoded and up, you have an IP
conflict and I am surprised it works at all.

Just a thought, but how about you run a cron job on your backup that
connects to your primary Asterisk boxes' AMI and issues some benign
command and pings it.  If it works as expected, then all is well, if
it AMI doesn't reply, continue your cron to ping.  If no ping replies,
then proceed to bring up 10.10.10.3. on your secondary box  If ping
works but asterisk doesn't, you could continue your cron job to ssh
the primary box and disable the 10.10.10.3 NIC and then bring up the
10.10.10.3 NIC on the spare.

If this is for SIP, just use OpenSer, if for TDM, use Redfone.

Thanks,
Steve Totaro


On Wed, Oct 15, 2008 at 9:12 PM, Nhadie [EMAIL PROTECTED] wrote:
 hi sir

 as mentioned i need to bind it on the secondary ip.
 coz if i bind it to 0.0.0.0, it's rejecting the call.

 i'm not sure if possible with heartbeat to execute a command after it
 takes over an IP. so i can reload asterisk on the failover server once
 it has the ip so i can bind asterisk to it.

 regards
 nhadie

 Edgar Guadamuz wrote:
 Are you using bindaddr=0.0.0.0 http://0.0.0.0 in sip.conf and iax.conf ??




 On Wed, Oct 15, 2008 at 5:35 PM, Steve Totaro
 [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
 wrote:

 I had an issue in 1.2.x that I am not sure ever got fixed but having
 two NICs on the same subnet did strange things.  Strange like one
 NIC would be used for outbound traffic and the other for inbound
 traffic.

 Maybe someone knows why, if it was a bug, if it was fixed?

 I could think of something creative but am drained right now and
 have to go buy some coax and connectors.

 If nobody helps you by then, I will.

 Thanks,
 Steve Totaro


 On Wed, Oct 15, 2008 at 3:39 PM, Gleim, Jason
 [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote:

 How did you define the secondary IP address? Did you actually
 set that
 up in the network scripts and bind it to eth0 or did you just
 define it
 in /etc/ha.d/haresources? You should only have the virtual IP
 defined in
 haresources along with the primary server and what you want to do on
 node up/down.

 My haresources file has a single line:
 ohasterisk01 10.191.32.31 http://10.191.32.31/
 MailTo::user@domain.com::Asterisk
 fonulator asterisk

 We're obviously using the redFone FoneBRIDGE for our T1
 connection as
 you can see we're firing the fonulator script and then asterisk.

 HTH!

 Jason


   -Original Message-
   From: [EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED]
 [mailto:asterisk-users- mailto:asterisk-users-
   [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]]
 On Behalf Of Nhadie
   Sent: Tuesday, October 14, 2008 12:47 PM
   To: Asterisk Users Mailing List - Non-Commercial Discussion
   Subject: [asterisk-users] asterisk+heartbeat
  
   Hi,
  
   I'm using heartbeat as a failover for my asterisk server.
  
   on the active server 1 i have
  
   10.10.10.1 http://10.10.10.1/ eth0
   10.10.10.3 http://10.10.10.3/ secondary eth0
  
   asterisk listens to the secondary ip, so that if server 1 fails,
 server
   2 will then get that IP.
  
   so if server 1 fails, server 2 will have the IP
  
   10.10.10.2 http://10.10.10.2/ eth0
   10.10.10.3 http://10.10.10.3/ secondary eth0
  
   problem is i have to bind asterisk to the secondary IP if
 dont, i cant
   make calls. but if server 2 is inactive, asterisk does not
 run, as on
   the config it is binded on the secondary ip.
  
   anyone uses heartbeat for failover? tia.
  
   regards,
   nhadie
  



 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com
 http://www.api-digital.com/ --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users



 

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com

Re: [asterisk-users] asterisk+heartbeat

2008-10-15 Thread Nhadie


Edgar Guadamuz wrote:
 Version 2 of Linux-HA allows order constraints, so you can first set the 
 IP and then start asterisk. (service asterisk should be down until IP 
 address moves)

hi sir,

i think this should do the trick for me. asterisk should be stopped, 
then when it gets the VIP, i will start asterisk and bind it to the VIP.

is this how i should do it?

asterisk-2 \
 LVSSyncDaemonSwap::master \
 IPaddr2::10.10.10.3/28/eth1/10.10.10.15 asterisk

TIA.

Regards,
Ron

 
 
  
 On Wed, Oct 15, 2008 at 7:17 PM, Nhadie [EMAIL PROTECTED] 
 mailto:[EMAIL PROTECTED] wrote:
 
 
 
 Gleim, Jason wrote:
   How did you define the secondary IP address? Did you actually set
 that
   up in the network scripts and bind it to eth0 or did you just
 define it
   in /etc/ha.d/haresources? You should only have the virtual IP
 defined in
   haresources along with the primary server and what you want to do on
   node up/down.
 
 hi sir,
 
 secondary is asisgned by heartbeat via haresources.
 
  
   My haresources file has a single line:
   ohasterisk01 10.191.32.31 http://10.191.32.31/
 MailTo::user@domain.com::Asterisk
   fonulator asterisk
 
 does this mean asterisk will run after it takes over the IP?
 can i do this without the fonulator script?
 
  
   We're obviously using the redFone FoneBRIDGE for our T1 connection as
   you can see we're firing the fonulator script and then asterisk.
  
   HTH!
  
   Jason
  
  
   -Original Message-
   From: [EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED]
 [mailto:asterisk-users- mailto:asterisk-users-
   [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]] On
 Behalf Of Nhadie
   Sent: Tuesday, October 14, 2008 12:47 PM
   To: Asterisk Users Mailing List - Non-Commercial Discussion
   Subject: [asterisk-users] asterisk+heartbeat
  
   Hi,
  
   I'm using heartbeat as a failover for my asterisk server.
  
   on the active server 1 i have
  
   10.10.10.1 http://10.10.10.1/ eth0
   10.10.10.3 http://10.10.10.3/ secondary eth0
  
   asterisk listens to the secondary ip, so that if server 1 fails,
   server
   2 will then get that IP.
  
   so if server 1 fails, server 2 will have the IP
  
   10.10.10.2 http://10.10.10.2/ eth0
   10.10.10.3 http://10.10.10.3/ secondary eth0
  
   problem is i have to bind asterisk to the secondary IP if dont,
 i cant
   make calls. but if server 2 is inactive, asterisk does not run,
 as on
   the config it is binded on the secondary ip.
  
   anyone uses heartbeat for failover? tia.
  
   regards,
   nhadie
  
   ___
   -- Bandwidth and Colocation Provided by
 http://www.api-digital.com http://www.api-digital.com/ --
  
   asterisk-users mailing list
   To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users
  
   ___
   -- Bandwidth and Colocation Provided by
 http://www.api-digital.com http://www.api-digital.com/ --
  
   asterisk-users mailing list
   To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users
  
 
 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com
 http://www.api-digital.com/ --
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
 
 
 
 
 
 ___
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] asterisk+heartbeat

2008-10-14 Thread Nhadie
Hi,

I'm using heartbeat as a failover for my asterisk server.

on the active server 1 i have

10.10.10.1 eth0
10.10.10.3 secondary eth0

asterisk listens to the secondary ip, so that if server 1 fails, server 
2 will then get that IP.

so if server 1 fails, server 2 will have the IP

10.10.10.2 eth0
10.10.10.3 secondary eth0

problem is i have to bind asterisk to the secondary IP if dont, i cant 
make calls. but if server 2 is inactive, asterisk does not run, as on 
the config it is binded on the secondary ip.

anyone uses heartbeat for failover? tia.

regards,
nhadie

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users