LDP Hello packets are generated to answer incoming Hello before forming neighbor adjacency.
According to RFC 5036, Hello packets should be generated periodically at a certain interval. By default, it is 5 sec.
But in FRR we see strange behavior. If a router has not formed an LDP neighbor adjacency yet, it answers to all received LDP Hello packets from not neighbors with new Hello packets.
That behavior is incorrect.
Example:
Network MAP:
Three routers in one broadcast domain are connected to the same switch by eth0
Configurations:
R1:
set interfaces ethernet eth0 address '192.168.139.121/24' set interfaces loopback lo address '1.1.1.1/32' set protocols isis interface eth0 circuit-type 'level-1' set protocols isis interface lo set protocols isis log-adjacency-changes set protocols isis metric-style 'wide' set protocols isis net '49.0001.1001.2202.1049.00' set protocols mpls interface 'eth0' set protocols mpls ldp discovery transport-ipv4-address '1.1.1.1' set protocols mpls ldp interface 'eth0' set protocols mpls ldp interface 'lo' set protocols mpls ldp router-id '1.1.1.1'
R2:
set interfaces ethernet eth0 address '192.168.139.122/24' set interfaces loopback lo address '1.1.1.2/32' set protocols isis interface eth0 circuit-type 'level-1' set protocols isis interface lo set protocols isis log-adjacency-changes set protocols isis metric-style 'wide' set protocols isis net '49.0001.1001.2202.0170.00' set protocols mpls interface 'eth0' set protocols mpls ldp discovery transport-ipv4-address '1.1.1.2' set protocols mpls ldp interface 'eth0' set protocols mpls ldp interface 'lo' set protocols mpls ldp router-id '1.1.1.2'
R3:
set interfaces ethernet eth0 address '192.168.139.123/24' set interfaces loopback lo address '1.1.1.3/32' set protocols isis interface eth0 circuit-type 'level-1' set protocols isis interface lo set protocols isis log-adjacency-changes set protocols isis metric-style 'wide' set protocols isis net '49.0001.1001.2202.0174.00' set protocols mpls interface 'eth0' set protocols mpls ldp discovery transport-ipv4-address '1.1.1.3' set protocols mpls ldp interface 'eth0' set protocols mpls ldp interface 'lo' set protocols mpls ldp router-id '1.1.1.3'
When we try to connect R3 to the network, we see Hello Packets, which are generated not in a certain interval of 5s.
This is not correct.
This issue can lead to unpredictable behaviour when there are a lot of routers in one broadcast domain.
PCAP file is attached.