VoIP: (02.02.01) Điều hướng cuộc gọi Translation-Rule trên CME (SIP Via)

By , 0 View

Mục tiêu thực hành:
- Cấu hình Dial-Peer trên CME1 đóng vai trò ITSP.
- Cấu hình Dial-Peer và Translation-Rule trên CME2.
- Thực hiện quá trình debug ccsip message trên CME2.
- Khảo sát lỗi debug ccsip message (forbidden) trên CME2.

Các bước triển khai:
Cấu hình Dial-Peer trên CME1 đóng vai trò ITSP.
- ITSP là nhà cung cấp dịch vụ SIP Trunk chẳng hạn như Viettel, VNPT, FTP, CMC.
dial-peer voice 1 voip
  destination-pattern 02838120120
  session protocol sipv2
  session target ipv4:10.0.1.2
  codec g711ulaw
  exit
dial-peer voice 2 voip
  destination-pattern 02838120130
  session protocol sipv2
  session target ipv4:10.0.1.2
  codec g711ulaw
  exit

Cấu hình Dial-Peer và Translation-Rule trên CME2.

- Cấu hình Dial-Peer và Translation-Rule tiếp nhận cuộc gọi tới 02838120120 và chuyển cuộc gọi cho 201.
voice service voip
  ip address trusted list
    ipv4 10.0.1.0 255.255.255.0
    exit
  exit

voice translation-rule 1
  rule 1 /02838120120/ /201/
  exit
voice translation-profile SipTrunk_Incoming
  translate called 1
  exit

voice class uri 120 sip
  host ipv4:10.0.1.1
  exit

dial-peer voice 1 voip
  incoming uri via 120
  session protocol sipv2
  codec g711ulaw
  translation-profile incoming SipTrunk_Incoming
  exit

Thực hiện quá trình debug ccsip message trên CME2.
- Thực hiện quá trình debug ccsip message trên CME2 khi IP Phone 101 thực hiện cuộc gọi tới 02838120120.
CME2# debug ccsip message
SIP Call messages tracing is enabled
CME2#
*Mar 25 07:58:16.213: //-1/xxxxxxxxxxxx/SIP/Msg/ccsipDisplayMsg:
Received: 
INVITE sip:02838120120@10.0.1.2:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKDF1A
Remote-Party-ID: "101" <sip:101@10.0.1.1>;party=calling;screen=no;privacy=off
From: "101" <sip:101@10.0.1.1>;tag=56819E8-1E74
To: <sip:02838120120@10.0.1.2>
Date: Thu, 25 Mar 2021 07:58:16 GMT
Call-ID: B09E5BC8-8C7611EB-80D2D365-CE99E1AB@10.0.1.1
Supported: 100rel,timer,resource-priority,replaces,sdp-anat
Min-SE:  1800
Cisco-Guid: 2963118153-2356548075-2160907109-3466191275
User-Agent: Cisco-SIPGateway/IOS-15.2.4.M5.3
Allow: INVITE, OPTIONS, BYE, CANCEL, ACK, PRACK, UPDATE, REFER, SUBSCRIBE, NOTIFY, INFO, REGISTER
CSeq: 101 INVITE
Timestamp: 1616659096
Contact: <sip:101@10.0.1.1:5060>
Expires: 180
Allow-Events: telephone-event
Max-Forwards: 69
Content-Type: application/sdp
Content-Disposition: session;handling=required
Content-Length: 203

v=0
o=CiscoSystemsSIP-GW-UserAgent 3599 6581 IN IP4 10.0.1.1
s=SIP Call
c=IN IP4 10.0.1.1
t=0 0
m=audio 16406 RTP/AVP 0 19
c=IN IP4 10.0.1.1
a=rtpmap:0 PCMU/8000
a=rtpmap:19 CN/8000
a=ptime:20

*Mar 25 07:58:16.218: //172/B09D984980CC/SIP/Msg/ccsipDisplayMsg:
Sent: 
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKDF1A
From: "101" <sip:101@10.0.1.1>;tag=56819E8-1E74
To: <sip:02838120120@10.0.1.2>
Date: Thu, 25 Mar 2021 07:58:16 GMT
Call-ID: B09E5BC8-8C7611EB-80D2D365-CE99E1AB@10.0.1.1
Timestamp: 1616659096
CSeq: 101 INVITE
Allow-Events: telephone-event
Server: Cisco-SIPGateway/IOS-15.2.4.M5.3
Content-Length: 0


*Mar 25 07:58:16.219: //173/B09D984980CC/SIP/Msg/ccsipDisplayMsg:
Sent: 
INVITE sip:201@172.16.2.2:38966 SIP/2.0
Via: SIP/2.0/UDP 172.16.2.1:5060;branch=z9hG4bK92011
Remote-Party-ID: "101" <sip:101@172.16.2.1>;party=calling;screen=no;privacy=off
From: "101" <sip:101@172.16.2.1>;tag=56817EF-1490
To: <sip:201@172.16.2.2>
Date: Thu, 25 Mar 2021 07:58:16 GMT
Call-ID: B09F1EAD-8C7611EB-80BF8E17-1B7BC789@172.16.2.1
Supported: 100rel,timer,resource-priority,replaces
Min-SE:  1800
Cisco-Guid: 2963118153-2356548075-2160907109-3466191275
User-Agent: Cisco-SIPGateway/IOS-15.2.4.M5.3
Allow: INVITE, OPTIONS, BYE, CANCEL, ACK, PRACK, UPDATE, REFER, SUBSCRIBE, NOTIFY, INFO, REGISTER
CSeq: 101 INVITE
Timestamp: 1616659096
Contact: <sip:101@172.16.2.1:5060>
Expires: 180
Allow-Events: telephone-event
Max-Forwards: 68
Content-Type: application/sdp
Content-Disposition: session;handling=required
Content-Length: 265

v=0
o=CiscoSystemsSIP-GW-UserAgent 2107 8273 IN IP4 172.16.2.1
s=SIP Call
c=IN IP4 172.16.2.1
t=0 0
m=audio 16400 RTP/AVP 0 101 19
c=IN IP4 172.16.2.1
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=rtpmap:19 CN/8000
a=ptime:20

*Mar 25 07:58:16.324: //173/B09D984980CC/SIP/Msg/ccsipDisplayMsg:
Received: 
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 172.16.2.1:5060;branch=z9hG4bK92011
Contact: <sip:201@172.16.2.2:38966>
To: <sip:201@172.16.2.2>;tag=7b156d49
From: "101"<sip:101@172.16.2.1>;tag=56817EF-1490
Call-ID: B09F1EAD-8C7611EB-80BF8E17-1B7BC789@172.16.2.1
CSeq: 101 INVITE
User-Agent: X-Lite release 1006e stamp 34025
Content-Length: 0


*Mar 25 07:58:16.328: //172/B09D984980CC/SIP/Msg/ccsipDisplayMsg:
Sent: 
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKDF1A
From: "101" <sip:101@10.0.1.1>;tag=56819E8-1E74
To: <sip:02838120120@10.0.1.2>;tag=5681859-BE4
Date: Thu, 25 Mar 2021 07:58:16 GMT
Call-ID: B09E5BC8-8C7611EB-80D2D365-CE99E1AB@10.0.1.1
Timestamp: 1616659096
CSeq: 101 INVITE
Require: 100rel
RSeq: 8533
Allow: INVITE, OPTIONS, BYE, CANCEL, ACK, PRACK, UPDATE, REFER, SUBSCRIBE, NOTIFY, INFO, REGISTER
Allow-Events: telephone-event
Remote-Party-ID: <sip:201@10.0.1.2>;party=called;screen=no;privacy=off
Contact: <sip:201@10.0.1.2:5060>
Server: Cisco-SIPGateway/IOS-15.2.4.M5.3
Content-Length: 0


*Mar 25 07:58:16.333: //-1/xxxxxxxxxxxx/SIP/Msg/ccsipDisplayMsg:
Received: 
PRACK sip:201@10.0.1.2:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKEA4E
From: "101" <sip:101@10.0.1.1>;tag=56819E8-1E74
To: <sip:02838120120@10.0.1.2>;tag=5681859-BE4
Date: Thu, 25 Mar 2021 07:58:16 GMT
Call-ID: B09E5BC8-8C7611EB-80D2D365-CE99E1AB@10.0.1.1
CSeq: 102 PRACK
RAck: 8533 101 INVITE
Allow-Events: telephone-event
Max-Forwards: 70
Content-Length: 0


*Mar 25 07:58:16.337: //172/B09D984980CC/SIP/Msg/ccsipDisplayMsg:
Sent: 
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKEA4E
From: "101" <sip:101@10.0.1.1>;tag=56819E8-1E74
To: <sip:02838120120@10.0.1.2>;tag=5681859-BE4
Date: Thu, 25 Mar 2021 07:58:16 GMT
Call-ID: B09E5BC8-8C7611EB-80D2D365-CE99E1AB@10.0.1.1
Server: Cisco-SIPGateway/IOS-15.2.4.M5.3
CSeq: 102 PRACK
Content-Length: 0

CME2#

Khảo sát lỗi debug ccsip message (forbidden) trên CME2.
- Khảo sát lỗi debug ccsip message (forbidden) trên CME2 tiếp nhận cuộc gọi tới 02838120130 và chuyển cuộc gọi cho 202.

voice service voip
  ip address trusted list
    no ipv4 10.0.1.0 255.255.255.0
    exit
  exit

CME2# debug ccsip messages 
SIP Call messages tracing is enabled
CME2#
*Mar 25 08:20:43.710: //-1/xxxxxxxxxxxx/SIP/Msg/ccsipDisplayMsg:
Received: 
INVITE sip:02838120120@10.0.1.2:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKF570
Remote-Party-ID: "101" <sip:101@10.0.1.1>;party=calling;screen=no;privacy=off
From: "101" <sip:101@10.0.1.1>;tag=57CA98D-1EB1
To: <sip:02838120120@10.0.1.2>
Date: Thu, 25 Mar 2021 08:20:43 GMT
Call-ID: D3C9509D-8C7911EB-80DBD365-CE99E1AB@10.0.1.1
Supported: 100rel,timer,resource-priority,replaces,sdp-anat
Min-SE:  1800
Cisco-Guid: 3553136055-2356744683-2161496933-3466191275
User-Agent: Cisco-SIPGateway/IOS-15.2.4.M5.3
Allow: INVITE, OPTIONS, BYE, CANCEL, ACK, PRACK, UPDATE, REFER, SUBSCRIBE, NOTIFY, INFO, REGISTER
CSeq: 101 INVITE
Timestamp: 1616660443
Contact: <sip:101@10.0.1.1:5060>
Expires: 180
Allow-Events: telephone-event
Max-Forwards: 69
Content-Type: application/sdp
Content-Disposition: session;handling=required
Content-Length: 203

v=0
o=CiscoSystemsSIP-GW-UserAgent 3665 6100 IN IP4 10.0.1.1
s=SIP Call
c=IN IP4 10.0.1.1
t=0 0
m=audio 16410 RTP/AVP 0 19
c=IN IP4 10.0.1.1
a=rtpmap:0 PCMU/8000
a=rtpmap:19 CN/8000
a=ptime:20

*Mar 25 08:20:43.715: //177/D3C88DB780D5/SIP/Msg/ccsipDisplayMsg:
Sent: 
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKF570
From: "101" <sip:101@10.0.1.1>;tag=57CA98D-1EB1
To: <sip:02838120120@10.0.1.2>
Date: Thu, 25 Mar 2021 08:20:43 GMT
Call-ID: D3C9509D-8C7911EB-80DBD365-CE99E1AB@10.0.1.1
Timestamp: 1616660443
CSeq: 101 INVITE
Allow-Events: telephone-event
Server: Cisco-SIPGateway/IOS-15.2.4.M5.3
Content-Length: 0

*Mar 25 08:20:43.715: //177/D3C88DB780D5/SIP/Msg/ccsipDisplayMsg:
Sent: 
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKF570
From: "101" <sip:101@10.0.1.1>;tag=57CA98D-1EB1
To: <sip:02838120120@10.0.1.2>;tag=57CA798-2622
Date: Thu, 25 Mar 2021 08:20:43 GMT
Call-ID: D3C9509D-8C7911EB-80DBD365-CE99E1AB@10.0.1.1
Timestamp: 1616660443
CSeq: 101 INVITE
Allow-Events: telephone-event
Server: Cisco-SIPGateway/IOS-15.2.4.M5.3
Reason: Q.850;cause=21
Content-Length: 0

*Mar 25 08:20:43.724: //-1/xxxxxxxxxxxx/SIP/Msg/ccsipDisplayMsg:
Received: 
ACK sip:02838120120@10.0.1.2:5060 SIP/2.0
Via: SIP/2.0/UDP 10.0.1.1:5060;branch=z9hG4bKF570
From: "101" <sip:101@10.0.1.1>;tag=57CA98D-1EB1
To: <sip:02838120120@10.0.1.2>;tag=57CA798-2622
Date: Thu, 25 Mar 2021 08:20:43 GMT
Call-ID: D3C9509D-8C7911EB-80DBD365-CE99E1AB@10.0.1.1
Max-Forwards: 70
CSeq: 101 ACK
Allow-Events: telephone-event
Content-Length: 0

*Mar 25 08:20:43.953: //-1/xxxxxxxxxxxx/SIP/Msg/ccsipDisplayMsg:
Received: 

CME2#

- Cấu hình Dial-Peer và Translation-Rule tiếp nhận cuộc gọi tới 02838120130 và chuyển cuộc gọi cho 202.

Tham khảo các Videos lý thuyết CCNA Voice (Collaboration) trước khi tham khảo các bài hướng dẫn thực hành VoIP. Mọi thắc mắc, các bạn vui lòng liên lạc với mình thông qua kênh Zalo (Jade Bùi) 076.877.2021.

You Might Also Like

0 comments