
Configure voip service and add the IP addresses of the servers HQ-CUCM and BB-CUCM into the trusted list.
voice service voip
allow-connections sip to sip
media statistics
mode border-element
ip address trusted list
ipv4 10.1.5.15 255.255.255.255
ipv4 10.1.6.16 255.255.255.255
sip
early-offer forced

Configure the tenant 100 for HQ site, specify sip-server 10.1.5.15. For each dial peer instead of repeatedly entering the SIP server interface address for each dial peer. We will use the session target sip-server command under each outgoing dial peers. Specify the Binding interface that will receive incoming calls from HQ-CUCM.
voice class tenant 100
sip-server ipv4:10.1.5.15
session transport tcp
url sip
error-passthru
bind control source-interface GigabitEthernet1
bind media source-interface GigabitEthernet1
no pass-thru content custom-sdp

Configure the tenant 200 for BB site, specify sip-server 10.1.6.16. For each dial peer instead of repeatedly entering the SIP server interface address for each dial peer. We will use the session target sip-server command. Specify the Binding interface that will receive incoming calls from BB-CUCM.
voice class tenant 200
sip-server ipv4:10.1.6.16
session transport tcp
url sip
error-passthru
bind control source-interface GigabitEthernet3
bind media source-interface GigabitEthernet3
no pass-thru content custom-sdp

Calls from From HQ-CUCM To BB-CUCM
Configure the voice class URI 300 to match the HQ-CUCM IP address 10.1.5.15.
voice class uri 300 sip
host ipv4:10.1.5.15

Define the dial peer group 200, the purpose is to route incoming calls to dial peer 301301.
voice class dpg 200
description Incoming HQ-CUCM (Dial Peer 300) to BB-CUCM (Dial Peer 301301)
dial-peer 301301 preference 1

The incoming dial peer 300 matches the HQ-CUCM IP address 10.1.5.15 based on the voice class URI 300 using the incoming uri via 300 command, then the incoming call is routed to the dial peer group 200 because the destination dpg 200 command.
dial-peer voice 300 voip
description Incoming dial-peer from HQ-CUCM to BB-CUCM
session protocol sipv2
destination dpg 200
incoming uri via 300
voice-class sip tenant 100

Because the Dial Peer Group 200 points to Dial Peer Voice 301301 the call is routed to the outgoing dial peer 301301.
The dial peer 301301 is associated to the tenant 200 using the voice-class sip tenant 200 command, the session target sip-server command instructs the CUBE to use the sip-server 10.1.6.16 configured previously in voice class tenant 200 to send outgoing calls to BB-CUCM.
dial-peer voice 301301 voip
description Outbound to BB-CUCM
destination-pattern BAD.BAD
session protocol sipv2
voice-class sip tenant 200
session target sip-server

Calls From BB-CUCM To HQ-CUCM
Configure the voice class URI 400 to match the BB-CUCM IP address 10.1.6.16.
voice class uri 400 sip
host ipv4:10.1.6.16

Define the dial peer group 301, the purpose is to route incoming calls to dial peer 201201.
voice class dpg 301
description Incoming BB-CUCM (Dial Peer 500) to HQ-CUCM (Dial Peer 201201)
dial-peer 201201 preference 1

The incoming dial peer 400 matches the BB-CUCM IP address 10.1.6.16 based on the voice class URI 400 using the incoming uri via 400 command, then the incoming call is routed to the dial peer group 200 because the destination dpg 200 command.
dial-peer voice 500 voip
description Incoming dial-peer from BB-CUCM to HQ-CUCM
session protocol sipv2
destination dpg 301
incoming uri via 400
voice-class sip tenant 200

Because the Dial Peer Group 301 points to Dial Peer Voice 201201, the call is routed to the outgoing dial peer 201201.
The dial peer 201201 is associated to the tenant 100 using the voice-class sip tenant 100 command, the session target sip-server command instructs the CUBE to use the sip-server 10.1.15.15 configured previously in voice class tenant 100 to send outgoing calls to HQ-CUCM.
dial-peer voice 201201 voip
description Outbound to HQ-CUCM
destination-pattern AAAA
session protocol sipv2
voice-class sip tenant 100
session target sip-server

From Maradona Phone, place a call to Platini Phone. The call is successeful.


From Platini Phone, place a call to Maradona Phone. The call is successeful.

