Notice “Call from X to extension X rejected because extension not found in context X”

Once I was asked by a client to see why he could not get through to one of the numbers.
I opened the asterisk console:

asterisk -rvv

I told the client to make a call to this number, after which a notification was displayed:

NOTICE[15622][C-00000736]: chan_sip.c:25450 handle_request_invite: Call from ‘207’ (192.168.2.2:5060) to extension ‘06600000001’ rejected because extension not found in context ‘sip-dialout’.

I counted the number of digits in the number, I realized that one digit is superfluous, accordingly such a number does not exist and naturally I did not register such numbers in /etc/asterisk/extensions.conf.

Therefore, in order not to display this notification, you must dial the correct number, or if the number was dialed correctly, then it is not registered in /etc/asterisk/extensions.conf, then you need to register.

Also, one day I ran into a similar problem for another reason:

chan_sip.c: Call from ‘goip4new’ (192.168.2.2:5060) to extension ‘goip4new’ rejected because extension not found in context ‘goip4new’.

The reason was because I duplicated the old context, but forgot to specify “goip4new” instead of the old “goip4”:

[goip4new]
exten => goip4,1,DIAL(SIP/205,30)
exten => goip4,n,...
...

See also my articles:
Adding SIP clients to Asterisk
Asterisk time based routing

Leave a comment

Leave a Reply