02-20-2012 09:42 PM - last edited on 03-25-2019 08:13 PM by ciscomoderator
Hello,
I have stumbled upon what I believe is a voice translation rule issue in my Cisco voice home lab.
My senero is that I have one Cisco 1760 router with a FXO card connecting to the PSTN(home line 2). My second router is just a 2691 running CME that is hosting my cisco phones. finally I have an Asterisk server hosting an FXO card connecting to the PSTN (home line 1) and an SIP trunk to broadvoice.com. The issue I am having, as you can see from my config, is that when I dial 88 followed by the 10 digit number to send calls out on line 2 it is matching up with my dial-peer 102 and sending to asterisk instead of the 1760. I believe I need a voice translation rule that says when a dialing string starts with 88 followed by 10 digits send it to the 1760 and if just a 10 digit number (including one that starts with 866, 888, or any 8 for that matter) is dialed send it to asterisk.. Forgive me for any ignorance but this is the first time in my cvoice studies that I have run into this issue and i'm sure it is better that I run into it now, rather than exam day (lol). Any help is greatly appreciated.
Cisco 1760 192.168.2.3 (hosting FXO card for line 2)
dial-peer voice 100 voip
description *** Dial 9 and send to Asterisk SIP broadvoice ***
destination-pattern 9[2-9]..[2-9]......
session target ipv4:192.168.2.2
session protocol sipv2
codec g711ulaw
!
dial-peer voice 101 pots
description *** dial 88 Connection to line 2 on FXO port ***
destination-pattern 88[2-9]..[2-9]......
port 3/0
forward-digits 10
!
dial-peer voice 102
description *** 10 digit connection to asterisk line 1 FXO ***
destination-pattern [2-9]..[2-9]......
session target ipv4:192.168.2.2
session protocol sipv2
codec g711ulaw
cisco 2691 (hosting phones)
dial-peer voice 100 voip
description *** Dial 9 and send to Asterisk SIP broadvoice ***
destination-pattern 9[2-9]..[2-9]......
session target ipv4:192.168.2.2
session protocol sipv2
codec g711ulaw
!
dial-peer voice 101 voip
description *** dial 88 to access 1760 FXO port ***
destination-pattern 88[2-9]..[2-9]......
session target ipv4:192.168.2.3
codec g711ulaw
!
dial-peer voice 102
description *** 10 digit connection to asterisk line 1 FXO ***
destination-pattern [2-9]..[2-9]......
session target ipv4:192.168.2.2
session protocol sipv2
codec g711ulaw
Thanks
-Jeff
Solved! Go to Solution.
02-21-2012 04:35 AM
Hi,
Paolo is correct (+5 P ), this is dued to overlapping patterns
2 dial peers on the 2961 for the phones
!
dial-peer voice 101 voip
description *** dial 88 to access 1760 FXO port ***
destination-pattern 88[2-9]..[2-9]......
session target ipv4:192.168.2.3
codec g711ulaw
!
dial-peer voice 102
description *** 10 digit connection to asterisk line 1 FXO ***
destination-pattern [2-9]..[2-9]......
session target ipv4:192.168.2.2
session protocol sipv2
codec g711ulaw
!
From DP 101 -- 88[2-9]..[2-9]...... = 12 DIGITS
From DP 102 -- [2-9]..[2-9]...... = 10 DIGITS
As soon as the 10 digits pattern in DP102 is matched the call is sent to
that distination.
You would need to change onme of the patterns to use like an
access code say on DP 102
4[2-9]..[2-9]...... then remove the 4 with a profile or further down the line.
HTH
Alex
02-21-2012 12:07 AM
You are trying to to things with overlapping numbers - 88 followed by something. As sson the first Dp is matched, the call goes out that is normal.
Overlapping always cause problems. You should differentiate numbers, eg 1-886xxxzzz. so that there is no overlap.
02-21-2012 03:45 AM
Can you provide the debug dialpeer output. Of a 88xxxxxxxxxx call off the 2691 and see what numbers/ manipulation it gets offered that make it choose dialpeer 102 instead of 101
Thx
Sent from Cisco Technical Support iPhone App
02-21-2012 04:35 AM
Hi,
Paolo is correct (+5 P ), this is dued to overlapping patterns
2 dial peers on the 2961 for the phones
!
dial-peer voice 101 voip
description *** dial 88 to access 1760 FXO port ***
destination-pattern 88[2-9]..[2-9]......
session target ipv4:192.168.2.3
codec g711ulaw
!
dial-peer voice 102
description *** 10 digit connection to asterisk line 1 FXO ***
destination-pattern [2-9]..[2-9]......
session target ipv4:192.168.2.2
session protocol sipv2
codec g711ulaw
!
From DP 101 -- 88[2-9]..[2-9]...... = 12 DIGITS
From DP 102 -- [2-9]..[2-9]...... = 10 DIGITS
As soon as the 10 digits pattern in DP102 is matched the call is sent to
that distination.
You would need to change onme of the patterns to use like an
access code say on DP 102
4[2-9]..[2-9]...... then remove the 4 with a profile or further down the line.
HTH
Alex
02-21-2012 05:49 AM
Indeed +5 to Alex for taking the time of explaining what is wrong exactly.
02-26-2012 10:02 PM
Hey Guys,
Thanks for all the help and input. Alex I ended up using your suggestion of placing a 4 at the end and then stripping it off. Cisco's translation rules and a little more complex than asterisk. Just one last thing if you could help. This is my translation rule at the moment to add the 4 at the beginning of the string.
voice translation-rule 1
rule 1 /^/ /4/
is there a way that instead of the ^ I can specify to forward 10 digits instead of all of them.
Thank you very much
-Jeff
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: