For some time I have not been able to use SIP on the Vigor itself as it gives problems on conference calls when new callers join - the simulated DTMF codes on joining caused my connection to drop or play a continuous tone. I then opted to try the HT502, bought directly from my previous SIP provider, thinking it would be 100% compatible. Not so, but at least it makes makes my VoIP solution portable.
Anyway cutting a long story short, downgrading the firmware on the Vigor did not work - I could not use my 3G USB modem on WAN2. Eventually had to upgrade again to latest, beta_0414, which gives me WAN2 again.
HT502 NR persisted so I have written some shell/expect scripts on my Ubuntu box to periodically check for:
Register transaction got code 0:403
in syslog. Using Splunk simplifies this as it is so easy to limit the time span to the last minute and run this with cron every 5 or 10 minutes.
The Expect script then uses telnet to check the status. If there are no FXS ports 'Off Hook', then another expect script is called to reboot the HT502, again using telnet. This resolves the NR and keeps down time to a minimum.
Main code here, if anyone is interested:
#!/bin/bash #set -x cd /opt/splunk/bin lg=/opt/splunk/var/log/ht502hr.log > $lg ./splunk search ' Register transaction got code 0:403 earliest=-1m ' -auth splunk_user:splunk_passwd >> $lg exec 6<&0 exec 0<$lg while read line1 do [ `/usr/sbin/ht502stat.sh | grep -c 'Off Hook' ` -eq 0 ] || break /usr/sbin/ht502ipl.sh mail -s "HT-502 NR (rebooting)" firstname.lastname@example.org < $lg break done exec 0<&6
#!/usr/bin/expect spawn telnet <ip address> expect "Password:" send "admin\r" expect "*>" send "status\r" expect "*>" send "exit\r"
#!/usr/bin/expect spawn telnet <ip address> expect "Password:" send "admin\r" expect "*>" send "status\r" expect "*>" send "reboot\r" expect "*>" send "exit\r"