Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. If you'd prefer to explore, try our test area to get started. And see here for current known issues.

pots and voip dial-peers, preference order outgoing calls?

I have CME.  connected to pstn by FXO ports and SIP trunk. so I have incoming numbers in fxo ports and incoming numbers in sip trunk too.

 

every inconming called number has corresponding local number.

how to make outgoing call so that everybody will call with its own corresponding incoming number? 

as documented CME first uses for outgoing call lowest preference POTS dial-peer. and only when all pots bisy  it uses lowest preference voip dial-peer

8 REPLIES

Can you please give some more

Can you please give some more information, like what number is coming in.

what number user wnats to dial, and for what interface it should go out.

 

and example will be much helpful.

 

regards

Chintan

local numbers 4901 to 4939

local numbers 4901 to 4939

 

voice-port 0/0/0
 connection plar 4937
 description 393604            --- incoming called number from pstn 393604 transfered to local 4937

voice-port 0/0/0
 connection plar 4937
 description 393604
 
voice-port 0/0/1
 connection plar 4932
 description 393603

voice-port 0/0/2
 connection plar 4935
 description 393605
 !         
voice-port 0/0/3
 connection plar 4901
 description 393601
 !         

 outgoing dial-peers for call to pstn 9......$


dial-peer voice 60 pots
 translation-profile outgoing cut-9
 preference 5
 destination-pattern 9......$
 no digit-strip
 port 0/0/3
 forward-digits all
!
dial-peer voice 61 pots
 translation-profile outgoing cut-9
 preference 4
 destination-pattern 9......$
 no digit-strip
 port 0/0/2
 forward-digits all
!

dial-peer voice 7182 voip
 description SIP to kt pavl
 translation-profile outgoing cut-9p
 preference 1
 destination-pattern 9......
 session protocol sipv2
 session target ipv4:10.235.226.241
 voice-class codec 2  
 voice-class sip bind control source-interface Loopback2
 voice-class sip bind media source-interface Loopback2
 dtmf-relay rtp-nte
!         

 

 

for outgoing call  CME first uses dial-peer voice 61 pots. when it is bisy CME  uses dial-peer voice 60 pots.

when it is bisy too CME use dial-peer voice 7182 voip

 

 

Hi, I still dont understand

Hi,

 

I still dont understand what exactly your question is?

my assumption:

you have fxo ports and you  have number on which PSTN will ring FXO port.

now every fxo port maps one to one with some internal directory number.

 

so when you dial out, instead of using internal directory number you want use the external fxo numbers?

 

regards

Chintan

yes.I want those connected to

yes.

I want those connected to FXO to dial out throu FXO

those connected to inbound SIP nimbers to dial out throu SIP

 

is it possoble?

 

and I want to be able to switch preference between FXO and SIP outgoing calls

yes, looks like it is

yes, looks like it is possible.

now question 1.

 

who are connected to FXO port, who are those plar numbers? (CME ephones?)

and who are connected to inbound sip numbers? any exapmle?

 

regards

Chintan

yes. CME ephones this example

yes. CME ephones

 

this example FXO incoming


ephone-dn  32  dual-line
 number 4932
ephone  5 
 button  1:5 2:32


this example SIP incoming 7182704056 translated to 704056


voice translation-rule 92
 rule 1 /^7182704/ /704/

ephone-dn  56  dual-line
 number 704056

ephone  13
  button  1:13 2:56        

Man!! now it looks crystal

Man!! now it looks crystal clear.

 

so lets start by fxo attched ephone. i would just provide you the logic on how you can achieve this.

lets say than you have 4 ephone, and 4 ephone-dn

ephone-dn 1 is mapped to fxo port 1, ephone-dn to is mapped to fxo2, ephone-dn 3 mapped to fxo3 and ephone-dn 4 to sip trunk.

 

any outgoig calls from ephone dn should you the mapped fxo port or sip trunk, that is your requirement.

 

i would use prefix and traslation pattern to achive this.

prefix 1 is for fxo1

prefix 2 is for fxo2

prefix 3 is for fxo3

prefix 4 is for siptrunk

 

so create a trasation rule to prefix number ephones are calling with prefix

voice translation-rule 1
 rule 1 /\(.*\)/ /1\1/
 

voice translation-rule 2
 rule 1 /\(.*\)/ /2\1/

 

voice translation-rule 3
 rule 1 /\(.*\)/ /3\1/

 

voice translation-rule 4
 rule 1 /\(.*\)/ /4\1/
 

 

create profile to appply this rule on called number.


voice translation-profile fxo1
 translate called 1

 

voice translation-profile fxo2
 translate called 2

voice translation-profile fxo3
 translate called 3

voice translation-profile sip4
 translate called 4

 

now on appropriate ephone dn apply thi profile on inbound leg.

ephone-dn 1 (maps to fxo1)

translation-profile incoming fxo1

 

ephone-dn 2 (maps to fxo2)

translation-profile incoming fxo2

 

ephone-dn 3 (maps to fxo3)

translation-profile incoming fxo3

 

ephone-dn 4 (maps to sip trunk)

translation-profile incoming sip4

 

so after all this,

1. if ephone-dn 1 dials number XXX it will be traslated to 1XXX

2. if ephone-dn 2 dials number XXX it will be traslated to 2XXX

3. if ephone-dn 3 dials number XXX it will be traslated to 3XXX

4. if ephone-dn 4 dials number XXX it will be traslated to 4XXX

 

 

now some thing to play with dial-peers,

 

create dial-peer which routes anything that have dialed 1XXX goes throgh fxo1 (you can see maping on ephone 1 to fxo1)

dial-peer voice 1 pots

 destination-pattern 1T

 port fxo1

 

dial-peer voice 2 pots

 destination-pattern 2T

 port fxo2

 

dial-peer voice 3 pots

 destination-pattern 3T

 port fxo3

 

default digit strip will strip prefix 1,2,3 by default and you get your original diled number is being sent to pstn.

 

for voip this will not work, so you have to create 1 more trastion profile remove prefix before sending the number out

 

lets first create dial-peer for pattern 4xxx to be routed through sip

dial-peer voice 4 voip

 destination-pattern 4xxx

 session protocal sipv2

 session targer <sip server>

 

 

but the prefix 4 will not be stripped so , here you have to create one more tranlation profile to strip prefix.

 

voice translation-rule 5
 rule 1 /^1/ //

voice translation-profile sip_out
 translate called 4

 

now apply it to sip dial-peer,

dial-peer voice 4 voip

 destination-pattern 4xxx

 session protocal sipv2

 session targer <sip server>

 translation-profile outgoing sip_out

 

 

 

fewwww, that was lot information.

i hope you may got the idea how you can do that.

 

Regards

Chintan

 

~please rate and mark answers as correct if helpful

 

now apply this t

 

tnxvery complicated solution

tnx

very complicated solution

224
Views
10
Helpful
8
Replies