summaryrefslogtreecommitdiff
path: root/isisd/isis_circuit.c
diff options
context:
space:
mode:
authorlynnemorrison <lynne.morrison@ibm.com>2022-04-13 16:07:44 -0400
committerlynnemorrison <lynne.morrison@ibm.com>2022-04-18 11:15:15 -0400
commitc7b253d0bbcb9e55029bfcd72d2488dd6595a177 (patch)
treed5ff51bc2232791628e3939cd97628b3c9c86a09 /isisd/isis_circuit.c
parent926e00236e525aebb9fa49039bec876c222c1c7d (diff)
isisd: Fix crash in ISIS when mtu mismatch occurs
When lsp-mtu is configured larger than interface mtu and the interface is brought up, the ISIS code would crash. When other vendors have this misconfiguration they just continue ISIS running and allow the LSP packets to be created but not sent. When the misconfiguration is corrected the LSP packets start being sent. This change creates that same behavior in FRR. The startup issue I am hitting is when the isis lsp-mtu is larger that the interfaces mtu. We run into this case when we are in the process of changing the mtu on a tunnel. I issue a shutdown/no shutdown on the interface, because the tunnel MTU is smaller than the lsp-mtu, it is considered an error and calls circuit_if_del. This deletes part of the circuit information, which includes the circuit->ip_addr list. Later on we get an address update from zebra and try to add the interface address to this list and crash. 2022/04/07 20:19:52.032 ISIS: [GTRPJ-X68CG] CSM_EVENT for tun_gw2: IF_UP_FROM_Z calls isis_circuit_if_add this initialize the circuit->ip_addrs isis_circuit_up has the mtu check circuit->area->lsp_mtu > isis_circuit_pdu_size(circuit) and fails returns ISIS_ERROR on failure call isis_circuit_if_del this deletes the circiut->ip_addrs list <---- 2022/04/07 20:19:52.032 ZEBRA: [NXYHN-ZKW2V] zebra_if_addr_update_ctx: INTF_ADDR_ADD: ifindex 3, addr 192.168.0.1/24 message to isisd to add address isis_zebra_if_address_add isis_circuit_add_addr circuit->ip_addr we try to add the ip address to the list, but it was deleted above and isisd crashes Signed-off-by: Lynne Morrison <lynne.morrison@ibm.com>
Diffstat (limited to 'isisd/isis_circuit.c')
-rw-r--r--isisd/isis_circuit.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/isisd/isis_circuit.c b/isisd/isis_circuit.c
index c7bf1e2012..fedceed3bb 100644
--- a/isisd/isis_circuit.c
+++ b/isisd/isis_circuit.c
@@ -661,8 +661,11 @@ int isis_circuit_up(struct isis_circuit *circuit)
"Interface MTU %zu on %s is too low to support area lsp mtu %u!",
isis_circuit_pdu_size(circuit),
circuit->interface->name, circuit->area->lsp_mtu);
- isis_circuit_update_all_srmflags(circuit, 0);
- return ISIS_ERROR;
+
+ /* Allow ISIS to continue configuration. With this
+ * configuration failure ISIS will attempt to send lsp
+ * packets but will fail until the mtu is configured properly
+ */
}
if (circuit->circ_type == CIRCUIT_T_BROADCAST) {