SG

SG

Selasa, 13 Desember 2011

Lab Multicast : PIM-DM

 
berikut ada konfigurasinya :

setelah configurasinya, dan pastikan semua bisa ping dengan ok.kita akan mencoba konfigurasikan multicast IP Pim dense-mode...





## R1 dense mode multicast
ip multicast-routing

int ser 0/0/1
ip pim dense-mode

## end R1 dense mode multicast

## R2 dense mode multicast
ip multicast-routing

int ser 0/1/0
ip pim dense-mode
## end R2 dense mode multicast

## R3 dense mode multicast
ip multicast-routing

int ser 0/0/0
ip pim dense-mode

int ser 0/0/0.1
ip pim dense-mode

int ser 0/1/0
ip pim dense-mode

int ser 0/1/1
ip pim dense-mode
## end R3 dense mode multicast

## R4 dense mode multicast
ip multicast-routing

int ser 0/1/0
ip pim dense-mode

## end R4 dense mode multicast

## R5 dense mode multicast
ip multicast-routing

int ser 0/0/0
ip pim dense-mode

int ser 0/1/0
ip pim dense-mode
## end R5 dense mode multicast

## R6 dense mode multicast
ip multicast-routing

int ser 0/0/0
ip pim dense-mode






selesai, lalu bagaimana kita tesnya?
kita bisa mencobanya dengan join multicast grup di R1 loopback dan generate traffic dengan ping dari R4
kita berharap :


  • R1 akan menerima multicast dan me-reply ping tersebut
  • R2 atau R6 akan menerima traffic multicast juga, karena itu flooding
pertama kita debug dulu di R2

on R2
R2(config)#access-list 100 permit ip any host 239.1.1.2
R2(config)#do debug ip pack 100 detail
IP packet debugging is on (detailed) for access list 100
!-- on R3:
R3(config-if)#do debug ip pim
PIM debugging is on

lalu join grup dengan R1 dan ping ke R4
Then Join a group on R1 and send a ping from R4:
!-- on R1:
R1(config)#int lo 0
R1(config-if)#ip igmp join-group 239.1.1.2

!-- on R4:
R4(config-if)#do ping 239.1.1.2

Type escape sequence to abort.
Sending 1, 100-byte ICMP Echos to 239.1.1.2, timeout is 2 seconds:

Reply to request 0 from 10.0.13.1, 64 ms

Pada R2, kalian akan lihat initial flooding dan R2 menerima traffic walaupun R2 belum join grup itu:
R2(config)#
*Mar 26 20:37:52.282: IP: s=4.4.4.4 (Serial0/1/0), d=239.1.1.2, len 100, input feature
*Mar 26 20:37:52.282:     ICMP type=8, code=0, MCI Check(59), rtype 0, forus FALSE, sendself FALSE, mtu 0
*Mar 26 20:37:52.282: FIBipv4-packet-proc: route packet from Serial0/1/0 src 4.4.4.4 dst 239.1.1.2
*Mar 26 20:37:52.282: FIBfwd-proc: Default:224.0.0.0/4 multicast entry
*Mar 26 20:37:52.282: FIBipv4-packet-proc: packet routing failed

Pada R3, kalian lihat pim pruning message dari R2 dan R6, setiap pruning dikirin 2 x(kali) memastikan traffic diterima:
R3(config-if)#
*Mar 26 20:47:29.974: PIM(0): Received v2 Join/Prune on Serial0/1/1 from 10.0.23.2, to us
*Mar 26 20:47:29.974: PIM(0): Prune-list: (4.4.4.4/32, 239.1.1.2)
*Mar 26 20:47:29.974: PIM(0): Prune Serial0/1/1/239.1.1.2 from (4.4.4.4/32, 239.1.1.2)
*Mar 26 20:47:30.174: PIM(0): Received v2 Join/Prune on Serial0/0/0.1 from 10.0.36.6, to us
*Mar 26 20:47:30.174: PIM(0): Prune-list: (4.4.4.4/32, 239.1.1.2)
*Mar 26 20:47:30.174: PIM(0): Prune Serial0/0/0.1/239.1.1.2 from (4.4.4.4/32, 239.1.1.2)
*Mar 26 20:47:31.074: PIM(0): Received v2 Join/Prune on Serial0/0/0.1 from 10.0.36.6, to us
*Mar 26 20:47:31.074: PIM(0): Prune-list: (4.4.4.4/32, 239.1.1.2)
*Mar 26 20:47:36.974: PIM(0): Received v2 Join/Prune on Serial0/1/1 from 10.0.23.2, to us
*Mar 26 20:47:36.974: PIM(0): Prune-list: (4.4.4.4/32, 239.1.1.2)

Lalu bagaimana jika R2 loopback join ke grup tersebut sekarang?
dengan dense mode, R2 tidak akan mengirim pim message untuk menginformasikan R3 akan join grup yang baru. R2 akan menunggu flooding berikutnya untuk mengirim traffic, menunggu 3 menit maksimal,  defaultnya.

!-- on R2:
R2(config)#int lo 0
R2(config-if)#ip igmp join-group 239.1.1.2

!-- on R4:
R4(config-if)#do ping 239.1.1.2

Type escape sequence to abort.
Sending 1, 100-byte ICMP Echos to 239.1.1.2, timeout is 2 seconds:

Reply to request 0 from 10.0.13.1, 60 ms
R4(config-if)#

Lalu, tidak ada response dari R2, kita tunggu beberapa menit lagi...


R4(config-if)#do ping 239.1.1.2 Type escape sequence to abort. Sending 1, 100-byte ICMP Echos to 239.1.1.2, timeout is 2 seconds: Reply to request 0 from 10.0.13.1, 60 ms Reply to request 0 from 10.0.23.2, 64 ms R4(config-if)#


Mari kita lihat lebih dekat ke routing table multicast pada R3:


R3(config-if)#do sh ip mroute 239.1.1.2
IP Multicast Routing Table
Flags: D - Dense, S - Sparse, B - Bidir Group, s - SSM Group, C - Connected,
       L - Local, P - Pruned, R - RP-bit set, F - Register flag,
       T - SPT-bit set, J - Join SPT, M - MSDP created entry,
       X - Proxy Join Timer Running, A - Candidate for MSDP Advertisement,
       U - URD, I - Received Source Specific Host Report,
       Z - Multicast Tunnel, z - MDT-data group sender,
       Y - Joined MDT-data group, y - Sending to MDT-data group,
       V - RD & Vector, v - Vector
Outgoing interface flags: H - Hardware switched, A - Assert winner
 Timers: Uptime/Expires
 Interface state: Interface, Next-Hop or VCD, State/Mode

(*, 239.1.1.2), 00:00:03/stopped, RP 0.0.0.0, flags: D
  Incoming interface: Null, RPF nbr 0.0.0.0
  Outgoing interface list:
    Serial0/1/1, Forward/Dense, 00:00:03/00:00:00
    Serial0/1/0, Forward/Dense, 00:00:03/00:00:00
    Serial0/0/0.1, Forward/Dense, 00:00:03/00:00:00
    Serial0/0/0, Forward/Dense, 00:00:03/00:00:00

(4.4.4.4, 239.1.1.2), 00:00:04/00:02:55, flags: T
  Incoming interface: Serial0/0/0, RPF nbr 10.0.35.5
  Outgoing interface list:
    Serial0/0/0.1, Prune/Dense, 00:00:04/00:02:55
    Serial0/1/0, Forward/Dense, 00:00:04/00:00:00
    Serial0/1/1, Forward/Dense, 00:00:04/00:00:00

Entry pertama, (*,G) tidak digunakan pada PIM-DM, dan oleh karena itu kenapa incoming interfacenya selalu kosong.
Entry kedua, (S,G) yang hanya digunakan oleh PIM-DM...

Ok lalu bagaimana jika kita tambah link antar R3 dan R4 melalui Frame-Relay Cloud?
Mari kita coba...menyakinkan bahwa R4 akan generate traffic terus menerus ke arah grup 239.1.1.2


## on R4
int ser 0/0/0
shut
encapsulation frame-relay
int ser 0/0/0.1 point
frame-relay interface-dlci 403
ip address 10.0.34.4 255.255.255.0
ip ospf 1 area 0
ipv6 enable
ipv6 address fe80::4 link
ipv6 address 2001:cc1e:34::4/64
ipv6 ospf 1 area 0
ip pim dense-mode
exit

ip sla 1
 icmp-echo 239.1.1.2 source-interface Loopback0
 request-data-size 1450
 timeout 2000
 threshold 3000
 frequency 2
ip sla schedule 1 life forever start-time now


## on R5
int ser 0/0/0.2 point
frame-relay interface-dlci 304
ip address 10.0.34.3 255.255.255.0
ip ospf 1 area 0
ipv6 enable
ipv6 address fe80::3 link
ipv6 address 2001:cc1e:34::3/64
ipv6 ospf 1 area 0
ip pim dense-mode
exit


Disini saya coba biarkan S0/0/0 dalam kondisi shutdown di R4, untuk mengetes kita debug...apa yang akan terjadi ketika R3 temukan best router ke R4
coba kita lakukan debug pada R3 dan no shut pada R4 S0/0/0




R3#debug ip mrouting
IP multicast routing debugging is on
R3#debug ip routing
IP routing debugging is on
R3#


R4(config-subif)# int ser 0/0/0
R4(config-if)#no shutdown
R4(config-if)#
*Mar 29 21:31:17.581: %LINK-3-UPDOWN: Interface Serial0/0/0, changed state to up
*Mar 29 21:31:18.581: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0/0, changed state to up
*Mar 29 21:31:37.717: %PIM-5-NBRCHG: neighbor 10.0.34.3 UP on interface Serial0/0/0.1
*Mar 29 21:31:38.409: %OSPF-5-ADJCHG: Process 1, Nbr 3.3.3.3 on Serial0/0/0.1 from LOADING to FULL, Loading Done
*Mar 29 21:31:39.621: %OSPFv3-5-ADJCHG: Process 1, Nbr 3.3.3.3 on Serial0/0/0.1 from LOADING to FULL, Loading Done
R4(config-if)#


Tidak lama kemudian, pada R3


*Mar 29 21:37:38.021: RT: add 10.0.34.0/24 via 10.0.35.5, ospf metric [110/192]
*Mar 29 21:37:38.021: RT: NET-RED 10.0.34.0/24
*Mar 29 21:37:45.521: PIM(*): Frame-relay DLCI active now on Serial0/0/0.2
*Mar 29 21:37:45.521: RT: is_up: Serial0/0/0.2 1 state: 4 sub state: 1 line: 0 has_route: False
*Mar 29 21:37:45.521: RT: closer admin distance for 10.0.34.0, flushing 1 routes
*Mar 29 21:37:45.521: RT: NET-RED 10.0.34.0/24
*Mar 29 21:37:45.525: RT: add 10.0.34.0/24 via 0.0.0.0, connected metric [0/0]
*Mar 29 21:37:45.525: RT: NET-RED 10.0.34.0/24
*Mar 29 21:37:45.525: RT: interface Serial0/0/0.2 added to routing table
*Mar 29 21:37:52.517: %PIM-5-NBRCHG: neighbor 10.0.34.4 UP on interface Serial0/0/0.2
*Mar 29 21:37:52.517: MRT(0): WAVL Insert interface: Serial0/0/0.2 in (4.4.4.4,239.1.1.2) Successful
*Mar 29 21:37:52.521: MRT(0): set min mtu for (4.4.4.4, 239.1.1.2) 1500->1500
*Mar 29 21:37:52.521: MRT(0): Add Serial0/0/0.2/239.1.1.2 to the olist of (4.4.4.4, 239.1.1.2), Forward state - MAC not built
*Mar 29 21:37:52.521: PIM(0): Add Serial0/0/0.2/10.0.34.4 to (4.4.4.4, 239.1.1.2), Forward state, by PIM *G Join
*Mar 29 21:37:52.521: MRT(0): Add Serial0/0/0.2/239.1.1.2 to the olist of (4.4.4.4, 239.1.1.2), Forward state - MAC not built
*Mar 29 21:37:52.521: MRT(0): WAVL Insert interface: Serial0/0/0.2 in (* ,239.1.1.2) Successful
*Mar 29 21:37:52.521: MRT(0): set min mtu for (0.0.0.0, 239.1.1.2) 1500->1500
*Mar 29 21:37:52.521: MRT(0): Add Serial0/0/0.2/239.1.1.2 to the olist of (*, 239.1.1.2), Forward state - MAC not built
*Mar 29 21:37:52.521: PIM(0): Add Serial0/0/0.2/10.0.34.4 to (*, 239.1.1.2), Forward state, by PIM *G Join
*Mar 29 21:37:52.521: MRT(0): Add Serial0/0/0.2/239.1.1.2 to the olist of (*, 239.1.1.2), Forward state - MAC not built
*Mar 29 21:37:52.525: MRT(0): WAVL Insert interface: Serial0/0/0.2 in (* ,224.0.1.40) Successful
*Mar 29 21:37:52.529: MRT(0): set min mtu for (0.0.0.0, 224.0.1.40) 1500->1500
*Mar 29 21:37:52.529: MRT(0): Add Serial0/0/0.2/224.0.1.40 to the olist of (*, 224.0.1.40), Forward state - MAC not built
*Mar 29 21:37:52.529: PIM(0): Add Serial0/0/0.2/10.0.34.4 to (*, 224.0.1.40), Forward state, by PIM *G Join
*Mar 29 21:37:52.529: MRT(0): Add Serial0/0/0.2/224.0.1.40 to the olist of (*, 224.0.1.40), Forward state - MAC not built
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 224.0.1.40, Serial0/0/0.2: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 224.0.1.40, Serial0/0/0.1: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 224.0.1.40, Serial0/1/1: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 224.0.1.40, Serial0/1/0: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 224.0.1.40, Serial0/0/0: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/0/0.2: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/0/0.1: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/1/1: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/1/0: no entries
*Mar 29 21:37:52.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/0/0: no entries
*Mar 29 21:37:52.789: PIM(0): Send v2 Assert on Serial0/0/0.2 for 239.1.1.2, source 4.4.4.4, metric [110/129]
*Mar 29 21:37:52.789: PIM(0): Assert metric to source 4.4.4.4 is [110/129]
*Mar 29 21:37:52.793: PIM(0): We win, our metric [110/129]
*Mar 29 21:37:52.793: PIM(0): Prune Serial0/0/0.2/239.1.1.2 from (4.4.4.4/32, 239.1.1.2)
*Mar 29 21:37:52.793: PIM(0): Pruning immediately Serial0/0/0.2 (p2p)
*Mar 29 21:37:53.101: %OSPF-5-ADJCHG: Process 1, Nbr 4.4.4.4 on Serial0/0/0.2 from LOADING to FULL, Loading Done
*Mar 29 21:37:54.397: %OSPFv3-5-ADJCHG: Process 1, Nbr 4.4.4.4 on Serial0/0/0.2 from LOADING to FULL, Loading Done
*Mar 29 21:37:54.789: PIM(0): Send v2 Assert on Serial0/0/0.2 for 239.1.1.2, source 4.4.4.4, metric [110/129]
*Mar 29 21:37:55.893: PIM(0): Received v2 Assert on Serial0/0/0.2 from 10.0.34.4
*Mar 29 21:37:55.893: PIM(0): Assert metric to source 4.4.4.4 is [0/0]
*Mar 29 21:37:55.893: PIM(0): We lose, our metric [110/129]
*Mar 29 21:37:55.893: PIM(0): Insert (4.4.4.4,239.1.1.2) prune in nbr 10.0.34.4's queue
*Mar 29 21:37:55.893: PIM(0): Send (4.4.4.4, 239.1.1.2) PIM-DM prune to oif Serial0/0/0.2 in Prune state
*Mar 29 21:37:55.893: PIM(0): (4.4.4.4/32, 239.1.1.2) oif Serial0/0/0.2 in Prune state
*Mar 29 21:37:55.893: PIM(0): Building Join/Prune packet for nbr 10.0.34.4
*Mar 29 21:37:55.893: PIM(0):  Adding v2 (4.4.4.4/32, 239.1.1.2) Prune
*Mar 29 21:37:55.893: PIM(0): Send v2 join/prune to 10.0.34.4 (Serial0/0/0.2)
*Mar 29 21:37:58.021: RT: del 4.4.4.4/32 via 10.0.35.5, ospf metric [110/129]
*Mar 29 21:37:58.021: RT: add 4.4.4.4/32 via 10.0.34.4, ospf metric [110/65]
*Mar 29 21:37:58.021: RT: NET-RED 4.4.4.4/32
*Mar 29 21:37:58.021: RT: add 10.0.45.0/24 via 10.0.34.4, ospf metric [110/128]
*Mar 29 21:37:58.021: RT: NET-RED 10.0.45.0/24
*Mar 29 21:37:58.489: MRT(0): Delete Serial0/0/0.2/239.1.1.2 from the olist of (4.4.4.4, 239.1.1.2)
*Mar 29 21:37:58.489: MRT(0): (4.4.4.4,239.1.1.2), RPF change from Serial0/0/0/10.0.35.5 to Serial0/0/0.2/10.0.34.4
*Mar 29 21:37:58.489: MRT(0): WAVL Insert interface: Serial0/0/0 in (4.4.4.4,239.1.1.2) Successful
*Mar 29 21:37:58.489: MRT(0): set min mtu for (4.4.4.4, 239.1.1.2) 1500->1500
*Mar 29 21:37:58.489: MRT(0): Add Serial0/0/0/239.1.1.2 to the olist of (4.4.4.4, 239.1.1.2), Forward state - MAC not built
*Mar 29 21:37:58.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/0/0.2:
     4.4.4.4/32 count 1
*Mar 29 21:37:58.585: PIM(0): Send v2 Graft to 10.0.34.4 (Serial0/0/0.2)
*Mar 29 21:37:58.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/0/0.1: no entries
*Mar 29 21:37:58.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/1/1: no entries
*Mar 29 21:37:58.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/1/0: no entries
*Mar 29 21:37:58.585: PIM(0): Building Graft message for 239.1.1.2, Serial0/0/0: no entries
*Mar 29 21:37:58.597: PIM(0): Received v2 Graft-Ack on Serial0/0/0.2 from 10.0.34.4
*Mar 29 21:37:58.597:      Group 239.1.1.2:
     4.4.4.4/32
*Mar 29 21:37:58.881: PIM(0): Send v2 Assert on Serial0/0/0 for 239.1.1.2, source 4.4.4.4, metric [110/65]
*Mar 29 21:37:58.881: PIM(0): Assert metric to source 4.4.4.4 is [110/65]
*Mar 29 21:37:58.885: PIM(0): We win, our metric [110/65]
*Mar 29 21:37:58.885: PIM(0): Schedule to prune Serial0/0/0
*Mar 29 21:37:58.885: PIM(0): (4.4.4.4/32, 239.1.1.2) oif Serial0/0/0 in Forward state
*Mar 29 21:37:58.917: PIM(0): Received v2 Assert on Serial0/0/0 from 10.0.35.5
*Mar 29 21:37:58.917: PIM(0): Assert metric to source 4.4.4.4 is [110/65]
*Mar 29 21:37:58.917: PIM(0): We lose, our metric [110/65]
*Mar 29 21:37:58.917: PIM(0): Prune Serial0/0/0/239.1.1.2 from (4.4.4.4/32, 239.1.1.2)
*Mar 29 21:37:58.917: PIM(0): Insert (4.4.4.4,239.1.1.2) prune in nbr 10.0.35.5's queue
*Mar 29 21:37:58.917: PIM(0): Send (4.4.4.4, 239.1.1.2) PIM-DM prune to oif Serial0/0/0 in Prune state
*Mar 29 21:37:58.917: PIM(0): (4.4.4.4/32, 239.1.1.2) oif Serial0/0/0 in Prune state
*Mar 29 21:37:58.917: PIM(0): Building Join/Prune packet for nbr 10.0.35.5
*Mar 29 21:37:58.921: PIM(0):  Adding v2 (4.4.4.4/32, 239.1.1.2) Prune
*Mar 29 21:37:58.921: PIM(0): Send v2 join/prune to 10.0.35.5 (Serial0/0/0)
*Mar 29 21:37:59.917: PIM(0): Received v2 Assert on Serial0/0/0 from 10.0.35.5
*Mar 29 21:37:59.917: PIM(0): Assert metric to source 4.4.4.4 is [110/65]
*Mar 29 21:37:59.917: PIM(0): We lose, our metric [110/65]
*Mar 29 21:37:59.917: PIM(0): Insert (4.4.4.4,239.1.1.2) prune in nbr 10.0.35.5's queue
*Mar 29 21:37:59.917: PIM(0): Send (4.4.4.4, 239.1.1.2) PIM-DM prune to oif Serial0/0/0 in Prune state
*Mar 29 21:37:59.917: PIM(0): (4.4.4.4/32, 239.1.1.2) oif Serial0/0/0 in Prune state
*Mar 29 21:37:59.917: PIM(0): Building Join/Prune packet for nbr 10.0.35.5
*Mar 29 21:37:59.917: PIM(0):  Adding v2 (4.4.4.4/32, 239.1.1.2) Prune
*Mar 29 21:37:59.921: PIM(0): Send v2 join/prune to 10.0.35.5 (Serial0/0/0)


Dari debug yang panjang ini kita dapa membaca :
  • interfacenya up
  • R3 membuat PIM adjacency sendiri dengan R4 dan mengirim pruning message karena best routenya menuju R4 masih melalui R5
  • R3 mengirim pruining message untuk grup 239.1.1.2 ke R5, memberitahukan untuk stop mengirim traffic pada grup tersebut
cukup dulu untuk multicast ini...


Tidak ada komentar:

Posting Komentar