PIM Join/Prune报文格式
注册/剪枝(Join/Prune)消息可在PIM-DM和PIM-SM中使用。一条Join/Prune消息中可以同时包含Join信息和Prune信息。只包含Join信息的Join/Prune消息称为Join消息。只包含Prune信息的Join/Prune消息称为Prune消息。
一、Join/Prune消息报文格式
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-------+-------+---------------+-------------------------------+
|PIM Ver| Type | Reserved | Checksum |
+-------+-------+---------------+-------------------------------+
| Upstream Neighbor Address (Encoded-Unicast format) |
+-------------------------------+-------------------------------+
| Reserved | Num groups | Holdtime |
+-------------------------------+-------------------------------+
| Multicast Group Address 1 (Encoded-Group format) |
+-------------------------------+-------------------------------+
| Number of Joined Sources | Number of Pruned Sources |
+-------------------------------+-------------------------------+
| Joined Source Address 1 (Encoded-Source format) |
+---------------------------------------------------------------+
| . |
| . |
+---------------------------------------------------------------+
| Joined Source Address n (Encoded-Source format) |
+---------------------------------------------------------------+
| Pruned Source Address 1 (Encoded-Source format) |
+---------------------------------------------------------------+
| . |
| . |
+---------------------------------------------------------------+
| Pruned Source Address n (Encoded-Source format) |
+---------------------------------------------------------------+
| . |
| . |
+---------------------------------------------------------------+
| Multicast Group Address m (Encoded-Group format) |
+-------------------------------+-------------------------------+
| Number of Joined Sources | Number of Pruned Sources |
+-------------------------------+-------------------------------+
| Joined Source Address 1 (Encoded-Source format) |
+---------------------------------------------------------------+
| . |
| . |
+---------------------------------------------------------------+
| Joined Source Address n (Encoded-Source format) |
+---------------------------------------------------------------+
| Pruned Source Address 1 (Encoded-Source format) |
+---------------------------------------------------------------+
| . |
| . |
+---------------------------------------------------------------+
| Pruned Source Address n (Encoded-Source format) |
+---------------------------------------------------------------+
二、Join/Prune消息报文格式解释
字段 | 长度 | 说明 |
---|---|---|
PIM Ver | 4比特 | PIM版本,值为2。 |
Type | 4比特 | 消息类型,值为3。 |
Reserved | 8比特 | 保留。发送者将其设置为0,接收者忽略此字段。 |
Checksum | 16比特 | 校验和。 |
Upstream Neighbor Address | 32比特 | 上游邻居地址。也就是收到Join/Prune消息的路由器上,进行Join或Prune操作的下游接口地址。 |
Num groups | 8比特 | 消息中包含的组播组数目。 |
Holdtime | 16比特 | 接收Join/Prune消息的路由器保持相应接口加入/剪枝状态的时间。 |
Multicast Group Address | 32比特 | 组播组地址。 |
Number of Joined Sources | 16比特 | 针对该组播组,请求加入的组播源总数。 |
Number of Pruned Sources | 16比特 | 针对该组播组,请求剪枝的组播源总数。 |
Joined Source Address | 32比特 | 请求加入的组播源地址。 |
Pruned Source Address | 32比特 | 请求剪枝的组播源地址。 |
三、PIM Join消息报文示例
Frame 1: 76 bytes on wire (608 bits), 76 bytes captured (608 bits)
Encapsulation type: Ethernet (1)
Arrival Time: Feb 23, 2010 21:41:59.308212530
[Time shift for this packet: 0.000000000 seconds]
Epoch Time: 1266932519.308212530 seconds
[Time delta from previous captured frame: 0.000000000 seconds]
[Time delta from previous displayed frame: 0.000000000 seconds]
[Time since reference or first frame: 0.000000000 seconds]
Frame Number: 1
Frame Length: 76 bytes (608 bits)
Capture Length: 76 bytes (608 bits)
[Frame is marked: False]
[Frame is ignored: False]
[Protocols in frame: eth:ethertype:vlan:ethertype:ip:pim]
[Coloring Rule Name: Broadcast]
[Coloring Rule String: eth[0] & 1]
Ethernet II, Src: 00:e0:fc:00:29:cf (00:e0:fc:00:29:cf), Dst: IPv4mcast_0d (01:00:5e:00:00:0d)
Destination: IPv4mcast_0d (01:00:5e:00:00:0d)
Address: IPv4mcast_0d (01:00:5e:00:00:0d)
.... ..0. .... .... .... .... = LG bit: Globally unique address (factory default)
.... ...1 .... .... .... .... = IG bit: Group address (multicast/broadcast)
Source: 00:e0:fc:00:29:cf (00:e0:fc:00:29:cf)
Address: 00:e0:fc:00:29:cf (00:e0:fc:00:29:cf)
.... ..0. .... .... .... .... = LG bit: Globally unique address (factory default)
.... ...0 .... .... .... .... = IG bit: Individual address (unicast)
Type: 802.1Q Virtual LAN (0x8100)
802.1Q Virtual LAN, PRI: 6, CFI: 0, ID: 17
110. .... .... .... = Priority: Voice, < 10ms latency and jitter (6)
...0 .... .... .... = CFI: Canonical (0)
.... 0000 0001 0001 = ID: 17
Type: IP (0x0800)
Trailer: 0643e6be
Internet Protocol Version 4, Src: 10.7.22.7 (10.7.22.7), Dst: 224.0.0.13 (224.0.0.13)
Version: 4
Header Length: 20 bytes
Differentiated Services Field: 0xc0 (DSCP 0x30: Class Selector 6; ECN: 0x00: Not-ECT (Not ECN-Capable Transport))
1100 00.. = Differentiated Services Codepoint: Class Selector 6 (0x30)
.... ..00 = Explicit Congestion Notification: Not-ECT (Not ECN-Capable Transport) (0x00)
Total Length: 54
Identification: 0x0082 (130)
Flags: 0x00
0... .... = Reserved bit: Not set
.0.. .... = Don't fragment: Not set
..0. .... = More fragments: Not set
Fragment offset: 0
Time to live: 1
Protocol: PIM (103)
Header checksum: 0xc104 [validation disabled]
[Good: False]
[Bad: False]
Source: 10.7.22.7 (10.7.22.7)
Destination: 224.0.0.13 (224.0.0.13)
[Source GeoIP: Unknown]
[Destination GeoIP: Unknown]
Protocol Independent Multicast
0010 .... = Version: 2
.... 0011 = Type: Join/Prune (3)
Reserved byte(s): 00
Checksum: 0xa99f [correct]
PIM options
Upstream-neighbor: 10.7.22.22 (10.7.22.22)
Reserved byte(s): 00
Num Groups: 1
Holdtime: 210s
Group 0: 228.1.1.1/32
Num Joins: 1
IP address: 10.22.22.22/32 (SWR)
Num Prunes: 0
四、PIM Prune消息报文示例
Frame 1: 76 bytes on wire (608 bits), 76 bytes captured (608 bits)
Encapsulation type: Ethernet (1)
Arrival Time: Feb 23, 2010 21:41:49.079659960
[Time shift for this packet: 0.000000000 seconds]
Epoch Time: 1266932509.079659960 seconds
[Time delta from previous captured frame: 0.000000000 seconds]
[Time delta from previous displayed frame: 0.000000000 seconds]
[Time since reference or first frame: 0.000000000 seconds]
Frame Number: 1
Frame Length: 76 bytes (608 bits)
Capture Length: 76 bytes (608 bits)
[Frame is marked: False]
[Frame is ignored: False]
[Protocols in frame: eth:ethertype:vlan:ethertype:ip:pim]
[Coloring Rule Name: Broadcast]
[Coloring Rule String: eth[0] & 1]
Ethernet II, Src: 00:e0:fc:00:29:cf (00:e0:fc:00:29:cf), Dst: IPv4mcast_0d (01:00:5e:00:00:0d)
Destination: IPv4mcast_0d (01:00:5e:00:00:0d)
Address: IPv4mcast_0d (01:00:5e:00:00:0d)
.... ..0. .... .... .... .... = LG bit: Globally unique address (factory default)
.... ...1 .... .... .... .... = IG bit: Group address (multicast/broadcast)
Source: 00:e0:fc:00:29:cf (00:e0:fc:00:29:cf)
Address: 00:e0:fc:00:29:cf (00:e0:fc:00:29:cf)
.... ..0. .... .... .... .... = LG bit: Globally unique address (factory default)
.... ...0 .... .... .... .... = IG bit: Individual address (unicast)
Type: 802.1Q Virtual LAN (0x8100)
802.1Q Virtual LAN, PRI: 6, CFI: 0, ID: 17
110. .... .... .... = Priority: Voice, < 10ms latency and jitter (6)
...0 .... .... .... = CFI: Canonical (0)
.... 0000 0001 0001 = ID: 17
Type: IP (0x0800)
Trailer: ac69d623
Internet Protocol Version 4, Src: 10.7.22.7 (10.7.22.7), Dst: 224.0.0.13 (224.0.0.13)
Version: 4
Header Length: 20 bytes
Differentiated Services Field: 0xc0 (DSCP 0x30: Class Selector 6; ECN: 0x00: Not-ECT (Not ECN-Capable Transport))
1100 00.. = Differentiated Services Codepoint: Class Selector 6 (0x30)
.... ..00 = Explicit Congestion Notification: Not-ECT (Not ECN-Capable Transport) (0x00)
Total Length: 54
Identification: 0x007c (124)
Flags: 0x00
0... .... = Reserved bit: Not set
.0.. .... = Don't fragment: Not set
..0. .... = More fragments: Not set
Fragment offset: 0
Time to live: 1
Protocol: PIM (103)
Header checksum: 0xc10a [validation disabled]
[Good: False]
[Bad: False]
Source: 10.7.22.7 (10.7.22.7)
Destination: 224.0.0.13 (224.0.0.13)
[Source GeoIP: Unknown]
[Destination GeoIP: Unknown]
Protocol Independent Multicast
0010 .... = Version: 2
.... 0011 = Type: Join/Prune (3)
Reserved byte(s): 00
Checksum: 0xa99f [correct]
PIM options
Upstream-neighbor: 10.7.22.22 (10.7.22.22)
Reserved byte(s): 00
Num Groups: 1
Holdtime: 210s
Group 0: 228.1.1.1/32
Num Joins: 0
Num Prunes: 1
IP address: 10.22.22.22/32 (SWR)
发表评论