Hi Lonnie, Thanks for the answer, Do you mean that will fix this issue wit the registering? Or is this for testing only why мy astlinux not register?
The Michael has the same issue with clustered registrar.. My Provider told me that is not provider issue, and I’m confused, I have one Gigaset SIP Phone as backup line registered inside the same network to this same number that I used on astlinux ( SIP-Forking) and if I have this registering issue the gigaset sip phone is still registered astlinux not. At the first I will trying this with register_retry_403=yes and waiting. I have this issue in my case only with one internet provider swisscom.ch and one VOIP Provider Sipcall.ch If I have more different provider on the same pbx usually only the one VOIP Provider in my case sipcall(voipgateway.org) have the status „rejected" or *send request" Can you please check my script for Ip change. I have this script running on the pbx but if I checking my sip.conf I can't notice any change with this script. The script is executable and running but my sip.conf not change as sample if I put manually in my sip.conf any ip adress under general. I put wrong external IP adress in sip.conf general and run the script but nothing changing. I think there is something wrong or I not understood this. As sample I put wrong external IP Adress under general and runing the script. externip=94.128.12.12 I have this script under /mnt/kd/checksetexternip.sh This is the script I’m try ti using to overcome this problem. It should check the external IP and update the sip.conf with the new IP . I Run this script as cronjob every 5 minutes. But I can’t notice any change I my sip.conf. #!/bin/bash # checksetexternip.sh # Author: John Cahill email at johncahill.net # Licence: GPL v3 # Description: script that queries checkip.dyndns.com to find the server's external IP address. Updates asterisk's externip value and does a sip reload if necessary. # Last modified 06/02/2012 is_ip(){ input=$1 octet1=$(echo $input | cut -d "." -f1) octet2=$(echo $input | cut -d "." -f2) octet3=$(echo $input | cut -d "." -f3) octet4=$(echo $input | cut -d "." -f4) stat=1 if [[ $input =~ ^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]] && [ $octet1 -le 255 ] && [ $octet2 -le 255 ] && [ $octet3 -le 255 ] && [ $octet4 -le 255 ]; then stat=0 fi return $stat } EXTERNIP=`wget -qO- http://checkip.dyndns.com | awk '{print $6}'| cut -d"<" -f1` is_ip $EXTERNIP if [ $? -ne 0 ] then logger -s "checksetexternip.sh: External IP address invalid or unavailable, exiting." exit 1 fi OLDEXTERNIP=`grep externip /etc/asterisk/sip.conf | cut -d"=" -f2` if [ "$EXTERNIP" = "$OLDEXTERNIP" ] then logger -s "checksetexternip.sh: External IP address is the same, nothing to do exiting." exit 0 else logger -s "checksetexternip.sh: External IP address has changed, changing /etc/asterisk/sip.conf" #grep -v "externip" /etc/asterisk/sip.conf > /etc/asterisk/sip.conf.tmp #echo "externip=$EXTERNIP" >> /etc/asterisk/sip.conf.tmp #cp /etc/asterisk/sip.conf.tmp /etc/asterisk/sip.conf #rm /etc/asterisk/sip.conf.tmp sed -i -e "s/^externip *=.*/externip=$EXTERNIP/" /etc/asterisk/sip.conf logger -s "Doing asterisk -rx "sip reload"" asterisk -rx "sip reload" Regards nedi > Am 10.05.2018 um 05:23 schrieb Lonnie Abelbeck <li...@lonnie.abelbeck.com>: > > Hi Nedi, > > I appreciate your detailed description and for the record I feel your > frustration. > > I seem to recall Michael Knill described a similar situation in the recent > past. > > My educated guess is this is a firewall statefull-inspection "stuck-state" > somewhere in the network path. AstLinux's firewall is not the issue > otherwise a reboot would solve the problem. > > Long story short, as a test, I would determine a time of day where shutting > down asterisk is acceptable (say 2:00 am) and keep asterisk down for 10 > minutes or so, something like: > > -- cron at 2:00 am or so -- > service asterisk stop > sleep 600 > service asterisk init > -- > (make sure you don't have any other background scripts looking to restart > asterisk other than the cron script) > > Possibly 5 minutes is all that is needed, but I would start at 10 minutes. > Most any firewall UDP state should expire in 10 minutes. > > Sadly, this test may take weeks to confirm if it helps. > > If you are already using cron to rewrite the sip.conf this test will be a > simple addition by delaying starting up asterisk. > > Lonnie > > > > >> On May 9, 2018, at 6:58 PM, nedi <n...@gmx.ch> wrote: >> >> Hi, >> >> I have some Astlinux boxes as local pbx after Modem with standard firewall >> inside modems , Astlinux have different Releases, and since years I have >> this issue and can’t fix that: >> After a week or month and sometimes longer the voip number can’t be >> registered and Status show me „rejected“ >> >> Reboot can’t help - Aterisk Reload can’t help - I can’t reproduce that for >> testing. >> If I have this problem only change the SIP Server to another Sipcall sip >> server can help to fix that issues. >> >> As sample if I was registered to business1.voipgateway.org I must change >> registrar to business2.voipgateway.org and I can save and reload to >> register without reboot. >> >> I have tried instead of registrar name to use the ip adress but this not >> fixed my problem. >> I use Sipcall DNS IP’s to in the Astlinux Network setting that don’t help, >> I don’t use IPV6. IPV6 is disabled in the Network Settings. >> Nat and Firewall in Astlinux are enabled and. >> >> I found that I have this issue only with the provider Sipcall.ch ( if >> registered on different subdomains of voipgateay.org ) and only if I use >> Swisscom as Internet Provider. On others provider on the same astlinux and >> at the same time I don’ t have this issues. >> On the same Astlinux box by some customer I have different provider and >> sipcall on the same astlinux box and only the Sipcall have this all other >> provider worked onlythe the Sipcall account get rejected. >> >> At now I use Alix Board and AstLinux Release astlinux-1.2.6.1 i586 - >> Asterisk 1.8.32.3, but i had this issues with oter astlinux release to. >> >> Some of my customer changed to internet with fix ip adress and there are >> this issue not so often.before with Dynamic IP Adress i had this issues >> oftener. >> >> The Sipcall support told me that is not the problem on the Sipcall site. >> Some times the Sipcall told me Astlinux trying to register with old IP >> Adress and sometimes they told me Astlinux don’t try to register for some >> hours or days and they don’t getting inquiry from pbx to register) >> >> I tried to change some settings in my sip.conf and there is nothing what >> helped me to resolve the issue. >> >> egisterattempts=0 >> registertimeout=20 >> maxexpiry=3600 >> defaultexpiry=600 >> qualify=2500 >> srvlookup=no >> nat=yes >> >> I use a cron script if external IP changed and update the sip.conf with the >> new IP for dynamic IP and again I have this problem, that not helped me >> great. >> >> The PBX can work for weeks and months without problem but after some time I >> get that again. >> >> I don’t know have this issue something with Astlinux firewall or with >> swisscom modem or with Sipcall. >> >> I think when, for some reason the registry fail and the state of the >> registry becomes REJECTED, asterisk stops trying to register. Can someone >> help me figuring out why this occur and a way to prevent asterisk from stop >> sending the registration requests. >> >> Does anybody have an idea about that problem ? How can we configure Asterisk >> to retry after some time in case of rejection ? >> >> >> Im my sip.conf I have this: >> >> >> I use a cron script to change the IP Adress in Astlinux if external ip >> adress was changed and again I have this problem that some customer get >> rejected. >> >> The PBX can work for weeks and months without problem but after some time I >> get that again. >> >> I don’t know have this issue something with Astlinux firewall or with >> swisscom modem or with Sipcall. >> >> I think when, for some reason the registry fail and the state of the >> registry becomes REJECTED, asterisk stops trying to register. Can someone >> help me figuring out why this occur and a way to prevent asterisk from stop >> sending the registration requests. >> >> Does anybody have an idea about that problem ? How can we configure Asterisk >> to retry after some time in case of rejection ? >> >> >> Im my sip.conf I have this: >> >> [general] >> useragent=mypbxname >> port=5060 >> context = from-sip-external; send unknown sip callers to this context >> alwaysauthreject=yes >> deny = 0.0.0.0/0.0.0.0 >> permit = 10.0.0.0/255.255.255.0 >> permit = 10.8.0.6/255.255.255.0 >> allowguest=no >> disallow=all >> allow=alaw >> allow=ulaw >> language=de >> registerattempts=0 >> registertimeout=20 >> maxexpiry=3600 >> defaultexpiry=600 >> qualify=2500 >> notifycid=yes >> srvlookup=no >> nat=yes >> allow subscribe = yes >> subscribecontext = hints >> trustrpid=yes >> sendrpid=yes >> ;t38pt_udptl = yes >> faxdetect=yes >> >> register => 4171511xxxx:2345678@212.117.203.35/4171511xxxx >> >> [071511xxxx] >> type=peer >> username=4171511xxxx >> secret=2345678 >> host=212.117.203.35 >> ;fromuser=4171511xxxx >> fromdomain=212.117.203.35 >> directmedia=no >> insecure=port,invite >> disallow=all >> allow=alaw >> allow=ulaw >> context=incoming212.117.203.35 >> dtmfmode=info >> trustrpid=yes >> sendrpid=pai >> >> >> >> Best regards >> Nedi >> >> ------------------------------------------------------------------------------ >> Check out the vibrant tech community on one of the world's most >> engaging tech sites, Slashdot.org! >> http://sdm.link/slashdot_______________________________________________ >> Astlinux-users mailing list >> Astlinux-users@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/astlinux-users >> >> Donations to support AstLinux are graciously accepted via PayPal to >> pay...@krisk.org. > > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > Astlinux-users mailing list > Astlinux-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/astlinux-users > > Donations to support AstLinux are graciously accepted via PayPal to > pay...@krisk.org. ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Astlinux-users mailing list Astlinux-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/astlinux-users Donations to support AstLinux are graciously accepted via PayPal to pay...@krisk.org.