From 452a9651f215205b34268c723beec5b2f964ad09 Mon Sep 17 00:00:00 2001 From: zsdc Date: Tue, 31 Dec 2019 00:04:50 +0200 Subject: FRRouting: T1514: Extended FRR restarting functionality and fixed some bugs This change addressed to fix bug with empty configuration after FRR restarting in some cases and protect from some other potential problems. * added warning and request for confirmation before doing any actions * added a couple of safety checks (already running restart, active watchfrr.sh or vtysh session) * now Python script running via sudo to give us the ability to get processes information and work with all directories and vtysh * moved configuration restoring functionality from frrcommon.sh to Python script, as frrcommon.sh implementation in some cases not load configuration in time, which leads to empty config after * the `/etc/frr/frr.conf` is not used anymore. Instead, we are saving active configuration to the temporary directory --- op-mode-definitions/restart-frr.xml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'op-mode-definitions/restart-frr.xml') diff --git a/op-mode-definitions/restart-frr.xml b/op-mode-definitions/restart-frr.xml index 4b649febd..96ad1a650 100644 --- a/op-mode-definitions/restart-frr.xml +++ b/op-mode-definitions/restart-frr.xml @@ -6,55 +6,55 @@ Restart FRRouting daemons - ${vyos_op_scripts_dir}/restart_frr.py --action restart + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart Restart Bidirectional Forwarding Detection daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bfdd + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bfdd Restart Border Gateway Protocol daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bgpd + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bgpd Restart OSPFv2 daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospfd + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospfd Restart OSPFv3 daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospf6d + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospf6d Restart Routing Information Protocol daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripd + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripd Restart RIPng daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripngd + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripngd Restart Static Route daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon staticd + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon staticd Restart IP routing manager daemon - ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon zebra + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon zebra -- cgit v1.2.3