Wrong SIP channel Used

sukasem

Guru
Joined
Sep 13, 2008
Messages
142
Reaction score
26
Hi,

I have problem with wrong sip channel used. I have 3 sip accounts with one provider (SIP/account1, SIP/account2, SIP/account3). let say, when I have incoming call on account 3 but sip channel used in asterisk show SIP/account1-xxxx.

Is it normal? I think they're all have the same ip address so, asterisk pick up any channel.

Is there a way to get asterisk to show correct channel.

Thank you,
Sukasem
 

rossiv

Guru
Joined
Oct 26, 2008
Messages
2,624
Reaction score
139
I don't think that is normal unless you have it configured to do that. You also don't provide much information. Could you please provide the information listed in my signature? Thanks!
 

sukasem

Guru
Joined
Sep 13, 2008
Messages
142
Reaction score
26
Hi,

Sorry, about that. I'm running IPBX in VMware.

Here is Status Screen
Code:
Status Version 1.2.9 released on Date 042310
********************************************************************
*            PBX in a Flash Version  Daemon Status                 *
*                      Running Asterisk 1.4                        *
********************************************************************
* Asterisk  * ONLINE  * Zaptel    * ONLINE  * MySQL      * ONLINE  *
* SSH       * ONLINE  * Apache    * ONLINE  * Iptables   * ONLINE  *
* Fail2ban  * ONLINE  * IP Connect* ONLINE  * Ip6tables  * ONLINE  *
* BlueTooth * ONLINE  * Hidd      * ONLINE  * NTPD       * ONLINE  *
* Sendmail  * ONLINE  * Samba     * OFFLINE * Webmin     * ONLINE  *
* Ethernet0 * ONLINE  * Ethernet1 *   N/A   * Wlan0      *   N/A   *
********************************************************************
* Running Asterisk Version : Asterisk 1.4.21.2
* Asterisk Source Version  : 1.4.21.2
* Zaptel Source Version    : 1.4.12.1
* Libpri Source Version    : 1.4.10.2
* Addons Source Version    : 1.4.7
********************************************************************
pbx.local on 192.168.1.100 - eth0
CentOS release 5.4 (Final) :32 Bit Kernel: 2.6.18-92.1.22.el5vm
********************************************************************
 For help on PBX commands than you can run type help-pbx           *
********************************************************************
root@pbx:~ $

CLI screen when I call 14038794200

Code:
     -- Executing [[B][COLOR="Red"]14038794200[/COLOR][/B]@from-pstn:1] [B][COLOR="Red"]Set("SIP/14038796616-b7d30970", "__FROM_DID=14038794200")[/COLOR][/B] in new stack
    -- Executing [14038794200@from-pstn:2] Gosub("SIP/14038796616-b7d30970", "app-blacklist-check|s|1") in new stack
    -- Executing [s@app-blacklist-check:1] LookupBlacklist("SIP/14038796616-b7d30970", "") in new stack
    -- Executing [s@app-blacklist-check:2] GotoIf("SIP/14038796616-b7d30970", "0?blacklisted") in new stack
    -- Executing [s@app-blacklist-check:3] Set("SIP/14038796616-b7d30970", "CALLED_BLACKLIST=1") in new stack
    -- Executing [s@app-blacklist-check:4] Return("SIP/14038796616-b7d30970", "") in new stack
    -- Executing [14038794200@from-pstn:3] ExecIf("SIP/14038796616-b7d30970", "0 |Set|CALLERID(name)=14038796677") in new stack
    -- Executing [14038794200@from-pstn:4] Set("SIP/14038796616-b7d30970", "__CALLINGPRES_SV=allowed_not_screened") in new stack
    -- Executing [14038794200@from-pstn:5] SetCallerPres("SIP/14038796616-b7d30970", "allowed_not_screened") in new stack
    -- Executing [14038794200@from-pstn:6] Goto("SIP/14038796616-b7d30970", "8794200-in|_X.|1") in new stack
    -- Goto (8794200-in,_X.,1)
    -- Executing [_X.@8794200-in:1] NoOp("SIP/14038796616-b7d30970", "Incoming Call from 14038796677") in new stack
    -- Executing [_X.@8794200-in:2] Set("SIP/14038796616-b7d30970", "CALLERID(num)=4038796677") in new stack
    -- Executing [_X.@8794200-in:3] System("SIP/14038796616-b7d30970", "echo "4038796677" > /tmp/cid") in new stack
    -- Executing [_X.@8794200-in:4] System("SIP/14038796616-b7d30970", "echo "[email protected]" > /tmp/email") in new stack
    -- Executing [_X.@8794200-in:5] Dial("SIP/14038796616-b7d30970", "SIP/14038794200/4032006824|28") in new stack
    -- Called 14038794200/4032006824
    -- SIP/14038794200-08ce1188 is making progress passing it to SIP/14038796616-b7d30970
  == Spawn extension (8794200-in, _X., 5) exited non-zero on 'SIP/14038796616-b7d30970'
    -- Executing [h@8794200-in:1] Goto("SIP/14038796616-b7d30970", "SendNotification|s|CANCEL") in new stack

Trunk Name: 14038794200
Peer Detail:
Code:
type=friend
username=14038794200
secret=xxxxxxx
qualify=yes
nat=yes
insecure=port,invite
host=voip.freephoneline.ca
dtmfmode=inband
context=from-pstn
canreinvite=no
disallow=all
allow=g729&gsm&ulaw

Here from sip peer:
Code:
14038796616/14038796616    208.65.240.142       N      5060     OK (72 ms)           
14038795995/14038795995    208.65.240.142       N      5060     Unmonitored           
14038794200/14038794200    208.65.240.142       N      5060     OK (58 ms)           
101/101                    192.168.1.98     D   N   A  5061     OK (19 ms)

I don't know if you need any other screen.

Thank you,
Sukasem
 

rossiv

Guru
Joined
Oct 26, 2008
Messages
2,624
Reaction score
139
This is peculiar-
Code:
	   	14038796616/14038796616    208.65.240.142       N      5060     OK (72 ms)            14038795995/14038795995    208.65.240.142       N      5060     Unmonitored            14038794200/14038794200    208.65.240.142       N      5060     OK (58 ms)
Same IP, yet two are monitored, one is not. Is your trunk configuration the same for each trunk?
 

sukasem

Guru
Joined
Sep 13, 2008
Messages
142
Reaction score
26
Yes, same config, same provider, just one trunk I have qualify=no (unmonitored).
 

jeffmac

Guru
Joined
Jan 16, 2008
Messages
230
Reaction score
9
There's been some discussion of this in the past. When Asterisk receives the invite it uses the originating IP address to match for a "peer" in your system. Unfortunately, you have three trunks connected to the same provider (I assume that IP is some provider) and Asterisk find the "first" peer (trunk) and concludes that is the appropriate entity.

There were some folks that wanted to try defining their providers as "user" and "peer" separately to try to get Asterisk to look up the inbound request by username.

I was not successful with that approach and resigned myself to Asterisk's trunk assignment. Since its just my account and my son's I don't need any separate accounting, and I don't use FOP to monitor my system. Otherwise everything seems to work just fine.

If you need the additional accounting by trunk id or differentiation in FOP you should probably search the forums for the discussion from last year.

Jeff
 

sukasem

Guru
Joined
Sep 13, 2008
Messages
142
Reaction score
26
Hi Jeff,

Thank, at least I know it's not just me having this issue.

Cheers,
Sukasem
 

Members online

Forum statistics

Threads
25,824
Messages
167,827
Members
19,249
Latest member
jetest
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top