If SIP channel driver needs to connect to a remote GW over a dedicated SIP trunk BUT the remote GW has a 'standby' in case of failure, how can the sip configuration file be configured for the remote GW when there are actually two IP addresses. If the main remote GW fails control automatically switches to the standby GW, so how could the SIP configuration file hande this switch and support both host IP addresses. There is no DNS so straight IP addressing is used. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20140204/67b7a0c3/attachment.html>
Make two trunk entries in sip.conf for both IPs and do the failover routing in extensions.conf Mitul On Wednesday, February 5, 2014, Meadows Hoa <meadows_sub at yahoo.com> wrote:> If SIP channel driver needs to connect to a remote GW over a dedicated SIP > trunk BUT the remote GW has a 'standby' in case of failure, how can the sip > configuration file be configured for the remote GW when there are actually > two IP addresses. If the main remote GW fails control automatically > switches to the standby GW, so how could the SIP configuration file hande > this switch and support both host IP addresses. There is no DNS so straight > IP addressing is used. >-- Regards, Mitul Limbani, Chief Architech & Founder, Enterux Solutions Pvt. Ltd. 110 Reena Complex, Opp. Nathani Steel, Vidyavihar (W), Mumbai - 400 086. India http://www.enterux.com/ http://www.entvoice.com/ email: mitul at enterux.in DID: +91-22-71967196 Cell: +91-9820332422 -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20140205/15ee19fa/attachment.html>
On 04/02/14 18:56, Meadows Hoa wrote:> If SIP channel driver needs to connect to a remote GW over a dedicated > SIP trunk BUT the remote GW has a 'standby' in case of failure, how > can the sip configuration file be configured for the remote GW when > there are actually two IP addresses. If the main remote GW fails > control automatically switches to the standby GW, so how could the SIP > configuration file hande this switch and support both host IP > addresses. There is no DNS so straight IP addressing is used.Doing it in the dialplan is a bit of a bodge but perfectly possible. Just make sure you have qualify=yes so if a GW does down asterisk spots it and the Dial() command returns quickly. You might also wish to reduce the check interval down from the default of every minute. The proper way is to make use of DVS SRV however Asterisk doesnt support it properly (doesnt fail over). Not sure if that has been fixed in version 12. If there is just one active GW and one or more backups then the its normally fairly easy to create a virtual IP address on the GW so if one fails then another takes over. Only works if they are on the same network though. Alternatively use something like opensips as a front end. Thats what we do and it load balances between multiple asterisk server and detects if one fails. You can make use of keepalived to provide a virtual IP address which moves between boxes if one dies or the opensips process stops running.