组播源是否必须连接到 RP 才能使 Cisco PIM-SM 工作?

网络工程 思科 路由 多播 皮姆
2022-02-16 06:42:14

一般来说,我对网络相当陌生,但我需要开发一个 4 点网格,具有从 A 点到 B 点和 C 点的冗余路径路由多播。我已经设置了网格并使用 OSPF 和 PIM-SM 进行网络重新分配正在运行和工作(无论如何 99% ......我认为),但是,我遇到了一个问题,如果源连接到不是 RP 的任何路由器(其中 RP 也是源的网关),多播没有分发。

据我了解,接收多播的路由器应该通知 RP 他拥有该组的源,以便 RP 可以构建 SPT,或者应该将流单播到 RP 以进行重新分配,但没有流量来自此路由器朝向 RP。

在我的实验室中,我使用带有 EMI 固件的 4 个 Catalyst 3550 交换机来启用多播路由。我已经使用 autorp 功能设置它(我只打算有一个 RP),以防我们稍后决定为设计添加更多冗余。

我需要在非 rp 路由器上做些什么来告诉他“如果您看到这个多播 IP 源自您的一个网络中,将其中继到 RP”,还是应该自行发生?

反相:

version 12.2
no service pad
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname PT
!
no logging console
!
username EDITED privilege 15 secret 5 EDITED
aaa new-model
!
!
!
!
!
aaa session-id common
ip subnet-zero
ip routing
no ip domain-lookup
!
!
ip multicast-routing
!
!
!
spanning-tree mode rapid-pvst
spanning-tree extend system-id
!
vlan internal allocation policy ascending
!
ip ssh version 2
!
!
!
!
!
interface Loopback0
 ip address 172.30.255.0 255.255.255.255
 ip pim sparse-mode
!
interface FastEthernet0/1
 description CNMG
 no switchport
 ip address 172.30.2.1 255.255.255.252
 ip pim sparse-mode
 ip ospf cost 100
 load-interval 30
!
!
interface FastEthernet0/3
 description TT
 no switchport
 ip address 172.30.2.17 255.255.255.252
 ip pim sparse-mode
 ip ospf cost 1000
 load-interval 30
!
!
!
interface FastEthernet0/24
 description WinPC_Server_Source
 switchport access vlan 2
 switchport mode access
 load-interval 30
 spanning-tree portfast
!
interface GigabitEthernet0/1
 switchport mode dynamic desirable
!
interface GigabitEthernet0/2
 switchport mode dynamic desirable
!
interface Vlan1
 ip address 192.168.20.254 255.255.255.0
!
interface Vlan2
 ip address 172.30.100.6 255.255.255.248
 ip pim sparse-mode
!
router ospf 100
 log-adjacency-changes
 redistribute connected metric-type 1 subnets
 network 172.30.2.0 0.0.0.3 area 0
 network 172.30.2.16 0.0.0.3 area 0
!
ip default-gateway 172.30.0.254
ip classless
ip http server
ip http secure-server
!
ip pim autorp listener
ip pim send-rp-announce Loopback0 scope 12 group-list 1
ip pim send-rp-discovery scope 12
!
access-list 1 permit 239.10.10.0 0.0.0.255
!
control-plane
!
!
line con 0
line vty 0 4
 privilege level 15
line vty 5 15
!
end

来源:

version 12.2
no service pad
service timestamps debug datetime msec
service timestamps log datetime msec localtime show-timezone
no service password-encryption
!
hostname Cumberland
!
no logging console
!
username EDITED secret 5 EDITED
aaa new-model
!
!
!
!
!
aaa session-id common
clock timezone POS -4
ip subnet-zero
ip routing
no ip domain-lookup
!
!
ip multicast-routing
no ip igmp snooping
!
!
!
!
spanning-tree mode pvst
spanning-tree extend system-id
!
vlan internal allocation policy ascending
!
!
!
!
!
!
interface Loopback0
 ip address 172.30.255.2 255.255.255.255
!
interface FastEthernet0/1
 description TT
 no switchport
 ip address 172.30.2.10 255.255.255.252
 ip pim sparse-mode
 ip ospf cost 200
 load-interval 30
!
interface FastEthernet0/2
 description CNMG
 no switchport
 ip address 172.30.2.5 255.255.255.252
 ip pim sparse-mode
 ip ospf cost 100
 load-interval 30
!
! int 3-47 not in use
!
interface FastEthernet0/48
 switchport access vlan 2
 switchport mode access
 load-interval 30
 spanning-tree portfast
!
interface GigabitEthernet0/1
 switchport mode dynamic desirable
!
interface GigabitEthernet0/2
 switchport mode dynamic desirable
!
interface Vlan1
 ip address 192.168.22.254 255.255.255.0
!
interface Vlan2
 ip address 172.30.100.22 255.255.255.248
 ip pim sparse-mode
!
router ospf 100
 log-adjacency-changes
 redistribute connected metric-type 1 subnets
 network 172.30.2.4 0.0.0.3 area 0
 network 172.30.2.8 0.0.0.3 area 0
!
ip classless
ip http server
ip http secure-server
!
ip pim autorp listener
ip pim send-rp-discovery scope 12
!
!
control-plane
!
!
line con 0
line vty 0 4
 privilege level 15
line vty 5 15
!
end

更新: 这是描述我的拓扑的图表:

拓扑图

更新#2: 我在评论中添加了 Ron 要求的节目数据:

Cumberland>show ip mroute
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.10.10.1), 2d02h/stopped, RP 172.30.255.0, flags: SJC
  Incoming interface: FastEthernet0/2, RPF nbr 172.30.2.6
  Outgoing interface list:
    Vlan2, Forward/Sparse, 2d02h/00:02:45, H

(172.30.100.5, 239.10.10.1), 2d02h/00:02:59, flags: JT
  Incoming interface: FastEthernet0/2, RPF nbr 172.30.2.6
  Outgoing interface list:
    Vlan2, Forward/Sparse, 2d02h/00:02:45, H

(*, 224.0.1.39), 2d02h/stopped, RP 0.0.0.0, flags: DCL
  Incoming interface: Null, RPF nbr 0.0.0.0
  Outgoing interface list:
    Vlan2, Forward/Sparse, 2d02h/00:00:00
    FastEthernet0/2, Forward/Sparse, 2d02h/00:00:00
    FastEthernet0/1, Forward/Sparse, 2d02h/00:00:00

(172.30.255.0, 224.0.1.39), 2d02h/00:02:48, flags: LT
  Incoming interface: FastEthernet0/2, RPF nbr 172.30.2.6
  Outgoing interface list:
    FastEthernet0/1, Prune/Sparse, 00:02:14/00:00:45
    Vlan2, Forward/Sparse, 2d02h/00:00:00

(*, 224.0.1.40), 2d02h/stopped, RP 0.0.0.0, flags: DCL
  Incoming interface: Null, RPF nbr 0.0.0.0
  Outgoing interface list:
    FastEthernet0/2, Forward/Sparse, 2d02h/00:00:00
    FastEthernet0/1, Forward/Sparse, 2d02h/00:00:00
    Vlan2, Forward/Sparse, 2d02h/00:00:00

(172.30.2.10, 224.0.1.40), 00:01:37/00:01:22, flags: L
  Incoming interface: FastEthernet0/1, RPF nbr 0.0.0.0
  Outgoing interface list:
    Vlan2, Forward/Sparse, 00:01:37/00:00:00
    FastEthernet0/2, Forward/Sparse, 00:01:37/00:00:00

(172.30.2.5, 224.0.1.40), 00:01:37/00:01:22, flags: L
  Incoming interface: FastEthernet0/2, RPF nbr 0.0.0.0
  Outgoing interface list:
    Vlan2, Forward/Sparse, 00:01:37/00:00:00
    FastEthernet0/1, Forward/Sparse, 00:01:37/00:00:00

(172.30.2.17, 224.0.1.40), 2d02h/00:02:16, flags: LT
  Incoming interface: FastEthernet0/1, RPF nbr 172.30.2.9
  Outgoing interface list:
    Vlan2, Forward/Sparse, 2d02h/00:00:00
    FastEthernet0/2, Prune/Sparse, 00:01:50/00:01:09

(172.30.2.1, 224.0.1.40), 2d02h/00:02:16, flags: LT
  Incoming interface: FastEthernet0/2, RPF nbr 172.30.2.6
  Outgoing interface list:
    FastEthernet0/1, Forward/Sparse, 2d02h/00:00:00
    Vlan2, Forward/Sparse, 2d02h/00:00:00

Cumberland>sh ip pim neighbor
PIM Neighbor Table
Mode: B - Bidir Capable, DR - Designated Router, N - Default DR Priority,
      P - Proxy Capable, S - State Refresh Capable
Neighbor          Interface                Uptime/Expires    Ver   DR
Address                                                            Prio/Mode
172.30.2.9        FastEthernet0/1          2d02h/00:01:42    v2    1 / S P
172.30.2.6        FastEthernet0/2          2d02h/00:01:16    v2    1 / DR S P
Cumberland>sh ip pim rp map
PIM Group-to-RP Mappings
This system is an RP-mapping agent

Group(s) 239.10.10.0/24
  RP 172.30.255.0 (?), v2v1
    Info source: 172.30.255.0 (?), elected via Auto-RP
         Uptime: 2d02h, expires: 00:02:14
Cumberland>
2个回答

请参阅图中关于 PIM 位于路由器之间的位置,而 IGMP 位于路由器和主机之间的位置。IGMP snooping 是一种交换机命令,对于组播操作来说不是必需的,但它可以让交换机侦听主机和路由器之间的 IGMP 消息。即使没有 IGMP snooping,您仍然需要 IGMP;多播侦听器应用程序向路由器发送一条 IGMP 消息,告诉它开始将多播组发送到路由器接口。IGMP 侦听所做的只是让交换机以特定端口为目标,而不是淹没所有端口。该图显示了旧的 CGMP 而不是 IGMP 侦听,但目的是相同的。

在此处输入图像描述

一旦主机应用程序想要监听一个多播组,它就会向路由器发送一个组的 IGMP 加入消息。然后路由器将设置多播转发并将多播发送到接口。路由器将定期向接口发送 IGMP 查询,以查看是否有任何主机仍对接收此组播组感兴趣。如果在该时间段内没有收到回复,则停止向该接口发送组播组。

您没有指定源类型是什么,也没有指定目标应用程序。您可能对其中一个有问题。如果源应用程序正在发送多播,您可能需要检查目标应用程序。您可以ip igmp join-group <group-address>在路由器上使用 interface 命令来帮助您进行测试。

笔记:

您将 RP 和源都设置为 RP 映射代理 ( ip pim send-rp-discovery scope 12)。您只需在 RP 上执行此操作,因为 RP 可以是映射代理。

您应该输入您的环回作为 RP 映射代理的接口 ID:

ip pim send-rp-discovery Loopback0 scope 12

你不应该ip default-gateway 172.30.0.254在路由器中。路由器应该有由 OSPF 提供的路由。

您正在重新分配连接的路由,但其中两个路由有明确的网络声明。你应该选择一种方式或另一种方式。而不是redistribute connected,您可能应该使用广泛的网络声明,以便您的路由不是外部路由:

router ospf 100
 log-adjacency-changes
 passive-interface default
 no passive-interface FastEthernet0/1
 no passive-interface FastEthernet0/3
 network 0.0.0.0 255.255.255.255 area 0
!

仔细检查单播路由,尤其要确保源路由器有到 RP 环回的路由。

在对这里讨论的所有内容进行了广泛尝试之后,我转向对流量进行有线共享,结果发现我的源上存在一个错误,导致生成的流的 TTL 为 0(无论 GUI 设置如何)。