Page 1 of 1
Changed IP address, carrier heading still contains old IP
Posted:
Mon Feb 17, 2014 1:44 pm
by Bentfinger
I changed IP addresses this weekend, and updated my LAN settings in Yast Lan and also used /usr/share/astguiclient/ADMIN_update_server_ip.pl . My main carrier now works only for manual dialing. Their tech said I was still broadcasting my old IP in the via headers. Any help would be appreciated.
Re: Changed IP address, carrier heading still contains old I
Posted:
Mon Feb 17, 2014 3:30 pm
by williamconley
/etc/asterisk/sip.conf
probably in "externip"
if that turns out wrong:
- Code: Select all
cd /etc/asterisk
grep xxx.xxx.xx.xx * -R -n
Obviously replace the x's with your actual IP address.
Re: Changed IP address, carrier heading still contains old I
Posted:
Mon Feb 17, 2014 6:10 pm
by Bentfinger
Thanks Bill. I checked my sip.conf file (using winscp) and the externip is still reading as my old IP.
Using Putty, I changed directory, then entered "grep xxx.xxx.xx.xx * -R -n" and; obviously; replaced the x's with my actual IP address.
Nothing seemed to happen. When I checked the sip.conf file again, it still showed my old IP address.
Do I have to reboot for grep to take effect?
Can I modify the text in the sip.conf file myself (using WinSCP's editor) to change it to the new IP address?
Thanks again!
Re: Changed IP address, carrier heading still contains old I
Posted:
Tue Feb 18, 2014 12:32 am
by williamconley
grep is a search tool.
you'll need to use a text editor to change it (nano or vi or anything ... yes that includes the winscp editor!)
and you'll need to restart asterisk after making the change to be sure it sticks.
Re: Changed IP address, carrier heading still contains old I
Posted:
Tue Feb 18, 2014 6:03 am
by Bentfinger
Thanks again. All is working OK now. You are always quick to reply on the boards, Bill; and I appreciate it.
BTW- I rebooted the server and the new IP stuck. Should I have restarted Asterisk in a different way, or is a reboot acceptable?
Re: Changed IP address, carrier heading still contains old I
Posted:
Tue Feb 18, 2014 12:16 pm
by williamconley
You got lucky. Ask around, I'm here or not based on luck of the draw.
Glad to help, though!
Reboot is always acceptable and the best way to be sure your server was not damaged by whatever you did (ie: if it will survive a reboot, you did not likely do harm!)