Clean up Incoming Caller ID

That’s what it looks like to me, with my little knowledge ! For some more detail my truck info is :

PEER details

Trunk Name LLBT

disallow=all
allow=ulaw
canreinvite=no
context=from-trunk-sip-LLBT
dtmfmode=rfc2833
host=dynamic
incominglimit=1
nat=never
port=5061
qualify=yes
secret=******************
type=friend
username=LLBT

That is the trunk setup, it is the context that you need to check is in the right place and being loaded, from the asterisk cli:-

dialplan show from-trunk-sip-LLBT

or from bash

rasterisk -x 'dialplan show from-trunk-sip-LLBT"

Hi Dicko, Thanks for bearing with me,

This is what I got back from the CLI

[ Context ‘from-trunk-sip-LLBT’ created by ‘pbx_config’ ]
’_.’ => 1. Set(GROUP()=OUT_8) [pbx_config]
2. Goto(from-trunk,${EXTEN},1) [pbx_config]
3. noop(CALLERID is now ${CALLERID(all)}) [pbx_config]
4. Goto(from-trunk,${EXTEN},1) [pbx_config]
Include => ‘from-trunk-sip-LLBT-custom’ [pbx_config]

-= 1 extension (4 priorities) in 1 context. =-

And of course that is exactly what is being processed. All I can say is “check your work!” :slight_smile:

Too cryptic ;-), I’ve checked things are spelt the same and can’t see anything wrong from what I been to to do ?. The trunk details are as I posted before and extensions_custom.conf :-

[custom-get-did-from-sip]
exten => s,1,Noop(Fixing DID using information from SIP TO header)
exten => s,n,Set(pseudodid=${SIP_HEADER(To)})
exten => s,n,Set(pseudodid=${CUT(pseudodid,@,1)})
exten => s,n,Set(pseudodid=${CUT(pseudodid,:,2)})
exten => s,n,Goto(from-trunk,${pseudodid},1)

[from-trunk-sip-LLBT]
exten => _.,1,set(CALLERID(number)=${REPLACE(CALLERID(number), ,)})
exten => _.,n,set(CALLERID(number)=${REPLACE(CALLERID(number),-,)})
exten => _.,n,noop(CALLERID is now ${CALLERID(all)})
exten => _.,n,Goto(from-trunk,${EXTEN},1)

I’m really lost to what to do next.

The ‘only’ thing I see is, Include => ‘from-trunk-sip-LLBT-custom’ [pbx_config]
has the the word ‘custom’ added I don’t know where that comes from ?

Should the [from-trunk-sip-LLBT] be [from-trunk-pstn-LLBT] ?? - I don’t know, I’m really grasping at straws now…

I don’t know what else to say, check your work AGAIN, issue a dialplan reload after each change, make sure the last reference to your desired context in the extensions* heirarchy is what you want, iterate the above steps until it works and I can assure you that it does work if you do it correctly.

what does ‘dialplan show from-trunk-sip-LLBT-custom’ and is that the context your inbound trunk is set to?

Hi Skyking, Thank you for replying. I have spent several hours trying to get this working

‘dialplan show from-trunk-sip-LLBT-custom’ came back with :-

There is no existence of ‘from-trunk-sip-LLBT-custom’ context
Command ‘dialplan show from-trunk-sip-LLBT-custom’ failed.

and context :-

context=from-trunk-sip-LLBT

This is in PEER Details and USER Details is blank

To summarize, what I have done is to copy Dicko’s code to /etc/asterisk/extensions_custom.conf and have the trunk context as above, I don’t know what else I should be doing??

The ‘from-trunk-sip-LLBT-custom’ custom bit maybe coming from extension_conf ?

Excerpt of :-

;-------------------------------------------------------------------------------
; from-pstn:
;
; Entry context for calls from the outside world to hit FreePBX
[from-pstn]
include => from-pstn-custom ; create this context in extensions_custom.conf to include customizations
include => ext-did
include => ext-did-post-custom
include => from-did-direct
include => ext-did-catchall ; THIS MUST COME AFTER ext-did
;-------------------------------------------------------------------------------

I’m not sure… I don’t know if it really has anything to do with this issue, but one thing I have discovered is in Trunk PEER Details I don’t need to add ‘username=LLBT’, it still works without it ?. This is the level I’ve got to now, changing things, partly to see what happens. The ‘Trunk Name’ is the username ID in the Linksys 3102 and PEER Details ‘secret’ is the password, Some of this I obviously knew, but I thought the 3102 username ID came from the ‘username=’ parameter of the PEER Details?

It has nothing to do with the issue :slight_smile: but keep reading and Learning all will e en tally become clear . . .

Didn’t think it did, just an interesting observation. Do you know how to fix this by the way ? - or are you just waiting for me to find out myself ?

I’m almost at the stage of ditching the whole thing over this ‘simple’ issue . I know it’s not a FreePBX/Asterisk problem and the problem stems from my telephone line provider !
I’ve done exactly what I’ve be told, add the code to extensions_custom.conf and context=from-trunk-sip-LLBT in PEER Details, I’ve checked spelling etc what else ?..

The method has been posted along with all the diagnostic tools to check.

Write a conyext, send the inbound call to that, reload the dialplan and check with “dialplan show (context)” that what you want is there. Check with the CLI that the call is processed as you want. That is all, many including myself use this methodology all the time.

Seems simple enough, more or less what I’ve been doing (forgot to reload (amprotal a r) couple of times though)) . Daft question, how do I know when ‘logger show channels’ is showing the ‘correct’ information ? What I may do is a fresh install and try that, right pain that’ll be reconfiguring !!

What does “logger show channels” have to do with the price of eggs?

It always shows what it is meant to.

I wish you would listen, amprotal a r (sic) is not necessary, a simple “dialplan reload” will suffice.

There is no need to do a fresh install, just follow the very explicit “instructions” and it will work for you the same way it works for everyone else.

SOLVED !

The fix was to remove the ‘-SIP’ from Dicko’s code ‘from-trunk-sip-LLBT’

Thanks guys for persuading me to carry on to resolve this issue. I’ve learnt a LOT !

Dave

It’s not 100% solved, as it appears to now bypasses the Asterisk Phone book and Superfecta’s ‘Send to email’ for ‘modified’ CID’s, - oh well can’t win them all !