]> git.proxmox.com Git - mirror_frr.git/commitdiff
ospfd, ospf6d: log when GR messages are sent to zebra
authorRenato Westphal <renato@opensourcerouting.org>
Fri, 3 Mar 2023 16:09:20 +0000 (13:09 -0300)
committerRenato Westphal <renato@opensourcerouting.org>
Tue, 9 May 2023 00:47:44 +0000 (21:47 -0300)
This should be useful to troubleshoot possible GR problems in the
future.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
ospf6d/ospf6_zebra.c
ospfd/ospf_zebra.c

index 1132c0a801819dbb9272f08fef3034321f25f85f..0f631c4d01f154fc36910fed00d8bbb43fa6a9f3 100644 (file)
@@ -239,12 +239,18 @@ static int ospf6_zebra_gr_update(struct ospf6 *ospf6, int command,
 
 int ospf6_zebra_gr_enable(struct ospf6 *ospf6, uint32_t stale_time)
 {
+       if (IS_DEBUG_OSPF6_GR)
+               zlog_debug("Zebra enable GR [stale time %u]", stale_time);
+
        return ospf6_zebra_gr_update(ospf6, ZEBRA_CLIENT_GR_CAPABILITIES,
                                     stale_time);
 }
 
 int ospf6_zebra_gr_disable(struct ospf6 *ospf6)
 {
+       if (IS_DEBUG_OSPF6_GR)
+               zlog_debug("Zebra disable GR");
+
        return ospf6_zebra_gr_update(ospf6, ZEBRA_CLIENT_GR_DISABLE, 0);
 }
 
index e7a98188ab894cfe5e68fad01fd05bbfdde68ea2..27d74cd4fcd9199543b635720b447f1e22292aef 100644 (file)
@@ -1252,12 +1252,18 @@ static int ospf_zebra_gr_update(struct ospf *ospf, int command,
 
 int ospf_zebra_gr_enable(struct ospf *ospf, uint32_t stale_time)
 {
+       if (IS_DEBUG_OSPF_GR)
+               zlog_debug("Zebra enable GR [stale time %u]", stale_time);
+
        return ospf_zebra_gr_update(ospf, ZEBRA_CLIENT_GR_CAPABILITIES,
                                    stale_time);
 }
 
 int ospf_zebra_gr_disable(struct ospf *ospf)
 {
+       if (IS_DEBUG_OSPF_GR)
+               zlog_debug("Zebra disable GR");
+
        return ospf_zebra_gr_update(ospf, ZEBRA_CLIENT_GR_DISABLE, 0);
 }