summaryrefslogtreecommitdiffstats
path: root/tools (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #16723 from jklaiber/fix-reload-interface-deletionDonatas Abraitis8 days1-6/+7
|\ | | | | tools: fix reload interface deletion
| * tools: Allow deleting of interfacesJulian Klaiber14 days1-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | The frr-reload script currently deletes configurations line-by-line under an interface context, if the interface was removed. This approach fails when the interface has already been removed from the system. This change enables whole interface removal using a single command (no interface <interface-name>), simplifying the reload process and reducing reload errors. Signed-off-by: Julian Klaiber <jklaiber@open-systems.com>
* | tools: fix regression in gen_northbound_callback toolChristian Hopps10 days1-12/+8
|/ | | | | | | When support for new style `get()` was added inadvertently stopped generating other callbacks and prototypes. Fix this. Signed-off-by: Christian Hopps <chopps@labn.net>
* tools: fix frr-reload for nbr deletion of no form cmdsChirag Shah2025-01-131-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a bgp neighbor removed from associated to peer-group, the neighbor is fully deleted, subsequent deletion of any configuration related to the neighbor leads to failure in frr-reload. Handle any 'no neighbor ...' part of lines_to_del list Testing: Below first line would delete the neighbor swp1.10, the existing code before the change handles to remove config starts with 'neighbor swp1.10 ...' but not 'no neighbor swp1.10 ...'. (Pdb) (lines_to_del) (('router bgp 100',), 'neighbor swp1.10 interface peer-group dpeergrp_2'), (('router bgp 100',), 'neighbor swp1.10 advertisement-interval 1'), (('router bgp 100',), 'neighbor swp1.10 timers 3 9'), (('router bgp 100',), 'neighbor swp1.10 timers connect 1'), (('router bgp 100',), 'no neighbor swp1.10 capability dynamic'), Before fix: (Pdb) (lines_to_del) [(('router bgp 100',), 'neighbor swp1.10 interface peer-group dpeergrp_2'), (('router bgp 100',), 'no neighbor swp1.10 capability dynamic')] frr-reload log: 2025-01-13 05:13:11,172 INFO: Executed "router bgp 100 no neighbor swp1.10 interface peer-group dpeergrp_2 exit" 2025-01-13 05:13:11,227 ERROR: Failed to execute router bgp 100 neighbor swp1.10 capability dynamic exit 2025-01-13 05:13:11,228 ERROR: "router bgp 100 -- neighbor swp1.10 capability dynamic -- exit" we failed to remove this command After fix: (Pdb)(lines_to_del) [(('router bgp 100',), 'neighbor swp1.10 interface peer-group dpeergrp_2')] Signed-off-by: Chirag Shah <chirag@nvidia.com>
* Merge pull request #17772 from LabNConsulting/chopps/fix-oper-walkDonald Sharp2025-01-071-7/+8
|\ | | | | improve error handling of operational state walk callback
| * tools: we specifically added %Lu to our sprintfrr so allow itChristian Hopps2025-01-071-7/+8
| | | | | | | | Signed-off-by: Christian Hopps <chopps@labn.net>
* | tools: add new-style get operation callback supportChristian Hopps2025-01-071-17/+55
|/ | | | Signed-off-by: Christian Hopps <chopps@labn.net>
* tools: Add missing rpki keyword to vrf in frr-reloadJonathan Voss2025-01-031-1/+1
| | | | | | | | | | | | | | | | When reloading the following configuration: ``` vrf red rpki rpki cache tcp 172.65.0.2 8282 preference 1 exit exit-vrf ``` frr-reload.py does not properly enter the `rpki` context within a `vrf`. Because of this, it fails to apply RPKI configurations. Signed-off-by: Jonathan Voss <jvoss@onvox.net>
* Merge pull request #17719 from jvoss/srv6_formatDonatas Abraitis2024-12-311-1/+5
|\ | | | | tools: Add missing formats keyword to segment-routing in frr-reload
| * tools: Add missing formats keyword to segment-routing in frr-reloadJonathan Voss2024-12-241-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When reloading the following configuration: ``` segment-routing srv6 formats format usid-f3216 wide-local-id-block explicit start 100 exit ! format uncompressed-f4024 exit ! exit ! exit ! exit ``` frr-reload.py does not properly enter the `formats` context. Because of this, it fails with an unknown command error when applying new or updating format configuration. Signed-off-by: Jonathan Voss <jvoss@onvox.net>
* | tools: add support for multiple YANG pathsChristian Hopps2024-12-161-5/+10
|/ | | | Signed-off-by: Christian Hopps <chopps@labn.net>
* tools: Add rip support bundle commandsDonald Sharp2024-12-131-3/+5
| | | | Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* tools: fix style check babletrace fileChirag Shah2024-11-251-12/+42
| | | | | | python3 -m black tools/frr_babeltrace.py Signed-off-by: Chirag Shah <chirag@nvidia.com>
* tools: add helper function to print familyChirag Shah2024-11-251-0/+22
| | | | | | | | | | Ticket: #4127810 Testing: 2024-11-20T01:52:10.073 frr_zebra:netlink_neigh_update_msg_encode {'mac': '00:00:00:00:00:00', 'ip': '27.0.0.4', 'nhg': 0, 'flags': 2, 'state': 192, 'family': 'bridge', 'type': 0, 'op': 23} Signed-off-by: Chirag Shah <chirag@nvidia.com>
* tools: Add missing keyword `encapsulation` in frr-reloadCarmine Scarpitta2024-11-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Consider the following scenario. You start from the configuration below: ``` ! segment-routing srv6 encapsulation source-address fc00:0:1::1 ! ! ! ``` Then you change the source address: ``` r1# configure r1(config)# segment-routing r1(config-sr)# srv6 r1(config-srv6)# encapsulation r1(config-srv6-encap) source-address 1::1 ``` And finally, reload the configuration `python3 frr-reload.py --reload /etc/frr/frr.conf` frr-reload returns the error below: ``` Failed to execute segment-routing srv6 no source-address 1::1 exit exit "segment-routing -- srv6 -- no source-address 1::1 -- exit -- exit" we failed to remove this command % Unknown command: no source-address 1::1 [79975|mgmtd] sending configuration line 3: % Unknown command[76]: source-address fc00:0:1::1 [79975|mgmtd] Configuration file[/etc/frr/frr.conf] processing failure: 2 ``` The reason is that the keyword `encapsulation` is missing in frr-reload. This patch adds the missing keyword `encapsulation`. Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
* tools: Add missing keyword `node-msd` in frr-reloadCarmine Scarpitta2024-11-231-1/+3
| | | | | | | | | | | | | | | | | Fix the error below: ``` [58564|mgmtd] sending configuration [58565|zebra] sending configuration, line 14: % Unknown command[52]: max-segs-left 3 line 18: % Unknown command[52]: max-end-pop 3 line 22: % Unknown command[52]: max-h-encaps 2 line 26: % Unknown command[52]: max-end-d 5 [58573|isisd] sending configuration [58565|zebra] Configuration file[/etc/frr/frr.conf] processing failure: 2 ``` Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
* tools: Add missing keyword `segment-routing srv6` in frr-reloadCarmine Scarpitta2024-11-231-1/+3
| | | | | | | | | | | | | | Fix the error below: ``` [58564|mgmtd] sending configuration [58565|zebra] sending configuration, line 10: % Unknown command[52]: node-msd [58573|isisd] sending configuration [58565|zebra] Configuration file[/etc/frr/frr.conf] processing failure: 2 ``` Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
* tools: Add pim show commands to support bundleCorey Siltala2024-11-221-37/+64
| | | | | | Add more data gathering for pim and pim6 support bundles Signed-off-by: Corey Siltala <csiltala@atcorp.com>
* tools: Add pim msdp show commands to support bundleDonald Sharp2024-11-211-0/+3
| | | | | | | | The support bundle was not gathering any msdp data for pim at all. Let's add a bit to allow us to have more data here when a suppport bundle is generated Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* tools: Add zebra label show commands to support bundleDonald Sharp2024-11-211-0/+4
| | | | | | | | There were no zebra show commands related to mpls labels being generated for support bundles. Let's rectify that situation. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* tools: Add isis command generation to support bundleDonald Sharp2024-11-211-3/+12
| | | | | | | | When a support bundle is created no isis commands were issued to attempt to gather data about what is going on in isis. Let's rectify that Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* tools: Add bmp command to support bundle generationDonald Sharp2024-11-211-0/+1
| | | | | | Add a bit of bmp data gathering for bgp support bundle generation Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* tools: remove `strncpy()` useDavid Lamparter2024-10-222-3/+8
| | | | | | `checkpatch` has sufficiently annoyed me to fix this. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* tools/gcc-plugins: don't crash on array parametersDavid Lamparter2024-10-151-1/+2
| | | | | | | | | Need to have arrays as a stop condition in this type normalization function, like pointers and function pointers. Actual arrays as argument types are extremely rare to see because C has this array-decay-to-pointer thing, but it can happen. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* tools: Add missing mgmtd into logrotate/rsyslogdDonatas Abraitis2024-10-102-1/+3
| | | | Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
* lib: add flag to have libyang load internal ietf-yang-library moduleChristian Hopps2024-10-072-2/+2
| | | | | | | | | | | | | | | | | | | | Mgmtd makes use of libyang's internal ietf-yang-library module to add support for said module to FRR management. Previously, mgmtd was loading this module explicitly; however, that required that libyang's `ietf-yang-library.yang` module definition file be co-located with FRR's yang files so that it (and ietf-datastore.yang) would be found when searched for by libyang using FRRs search path. This isn't always the case depending on how the user compiles and installs libyang so mgmtd was failing to run in some cases. Instead of doing it the above way we simply tell libyang to load it's internal version of ietf-yang-library when we initialize the libyang context. This required adding a boolean to a couple of the init functions which is why so many files are touched (although all the changes are minimal). Signed-off-by: Christian Hopps <chopps@labn.net>
* tools: fix some special commands for reloading pimanlan_cs2024-10-051-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The issue is we can't remove all pim configurations including some special configurations (e.g., `no ip pim bsm`) for one interface. For one pim-disable interface, all such pim depdendent options (including `ip pim ` and `no ip pim `) should be completely removed. Also append `no ip multicast` for the same purpose, it is no use at present, but for future use. The running config: ``` interface A ip pim no ip pim bsm exit ``` Reload the new config: ``` interface A exit ``` Before: ``` 2024-10-05 20:52:33,467 INFO: Executed "interface A no ip pim exit" 2024-10-05 20:52:33,482 INFO: Executed "interface A ip pim bsm exit" ``` And the pim configurations in running configuration are not removed after reloading: ``` interface A ip pim <- Wrong exit ``` After: ``` 2024-10-05 20:56:27,489 INFO: Executed "interface A no ip pim exit" ``` And all the pim configuration are removed. Signed-off-by: anlan_cs <anlan_cs@126.com>
* tools: fix missing check interfaces for reloading pimanlan_cs2024-09-291-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without checking interfaces, the other interfaces' changes will be wrongly lost. Running config: ``` interface A ip pim ip pim use-source 11.0.0.1 exit ! interface B ip pim ip pim use-source 22.0.0.1 exit ! ``` Reload the new config: ``` interface A exit ! interface B ip pim exit ``` Before: ``` 2024-09-29 10:08:27,686 INFO: Executed "interface A no ip pim exit" ``` After: ``` 2024-09-29 10:05:01,356 INFO: Executed "interface A no ip pim exit" 2024-09-29 10:05:01,376 INFO: Executed "interface B no ip pim use-source 22.0.0.1 exit" ``` Signed-off-by: anlan_cs <anlan_cs@126.com>
* Merge pull request #16733 from gtataranni/fix/regex-stringDonatas Abraitis2024-09-041-3/+3
|\ | | | | tools: fix invalid escape on regex string
| * tools: fix invalid escape on regex stringGiovanni Tataranni2024-09-031-3/+3
| | | | | | | | | | | | fix usage of regex string without proper escaping Signed-off-by: Giovanni Tataranni <g.tataranni@gmail.com>
* | tools, ospfclient: add a config option to skip installing python scriptsJafar Al-Gharaibeh2024-08-221-3/+8
|/ | | | | | | | | | The new config option --disable-python-runtime allows make install to proceed without installing any of the python scripts. When installing from deb/rpm packages those are bundled as frr-pythontools, which is independent from the frr binaries and can already be skipped. I.e, this PR gives the option to skip those scripts when building/installing from sources too. Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
* tools: Fix python string escape warnings for frr-reload.pyDonatas Abraitis2024-08-081-25/+25
| | | | | | | | | | | | When using a regex (or anything that uses `\?` escapes) in python, raw strings (`r"content"`) should be used so python doesn't consume the escapes itself. Otherwise we get either broken behavior and/or `SyntaxWarning: invalid escape sequence '\['` Fixes: 8916953b534f64a7545860ad5b4b36dc2544f33a ("build: fix a few python string escape warnings") Fixes: https://github.com/FRRouting/frr/issues/16522 Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
* tools/checkpatch: recognize `+` as unary operatorDavid Lamparter2024-07-311-1/+1
| | | | | | Allow using "+1" when meaningful (i.e. cmd_graph_merge wants -1 or +1) Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* tools: Apply black formatting for the recent frr-reload.py changesDonatas Abraitis2024-07-201-3/+6
| | | | Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
* tools: Do not append an empty list (pim_vrfs) to the config linesDonatas Abraitis2024-07-201-1/+2
| | | | | | | | | | | | | | | | | | If pim_vrfs is empty, we append [] into the lines array, and the reload is broken since it expects only strings, but gets an array inside at the end. ``` Traceback (most recent call last): File "/usr/lib/frr/frr-reload.py", line 2227, in <module> log.debug("New Frr Config\n%s", newconf.get_lines()) File "/usr/lib/frr/frr-reload.py", line 436, in get_lines return "\n".join(self.lines) TypeError: sequence item 45: expected str instance, list found ``` Fixes: 98d47f43fbba4e376c8351c724e8c625799805f7 ("tools: Fix frr-reload to support legacy pim configuration from file") Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
* tools: Fix frr-reload to support legacy pim configuration from fileNathan Bahr2024-07-161-4/+60
| | | | | | | | Fix load from file in frr-reload to detect and convert legacy pim configuration so that the tool can continue to be used with legacy configurations. Signed-off-by: Nathan Bahr <nbahr@atcorp.com>
* tools/checkpatch: accept pim_* typedefsDavid Lamparter2024-06-211-0/+1
| | | | | | | pimd uses "v4/v6 dispatch" typedefs. Don't complain about those in checkpatch. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* tools/gcc-plugins: warn for `suseconds_t` formatDavid Lamparter2024-05-021-0/+6
| | | | | | | | | | The plugin was already catching attempts to print `time_t` without casting it first (there is no valid printf specifier without a cast), but `__suseconds64_t` needs the same treatment. (Probably `__suseconds_t` too, if it exists, which I'm not sure it does - but that doesn't matter, the plugin ignores non-existing types.) Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* Merge pull request #15834 from pguibert6WIND/alias_path_iproute2Donald Sharp2024-04-291-0/+1
|\ | | | | tools: add iproute2 alias for pathd daemon
| * tools: add iproute2 alias for pathd daemonPhilippe Guibert2024-04-291-0/+1
| | | | | | | | | | | | | | | | With SRv6 traffic engineering, some ipv6 routes will be installed by the Pathd daemon. Populate the iproute2 aliasing table with pathd. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
* | tools: Handle seq num for BGP as-path in frr-reload.pyChirag Shah2024-04-261-0/+29
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If frr.conf has bgp as-path access-list clause without sequence number then upon performing frr-rleoad, the running config clause with sequence number will always be deleted and the new ones without sequence will be re-added. This could lead to blackholing until the config gets reapplied. Testing: frr.conf: bgp as-path access-list important_internet_bgp_as_numbers permit _16509_ Running config: bgp as-path access-list important_internet_bgp_as_numbers seq 5 permit _16509_ ! Before fix Upon frr-reload it deletes and readd line as without seq 2024-04-26 03:16:45,772 INFO: Executed "no bgp as-path access-list important_internet_bgp_as_numbers seq 5 permit _16509_" 'bgp as-path access-list important_internet_bgp_as_numbers permit _16509_\n' After fix: no form is not executed and no delta determine between frr.conf and running-config. Signed-off-by: Chirag Shah <chirag@nvidia.com>
* tools: fix frr-reload for no ip msdp peer cmdChirag Shah2024-04-231-0/+11
| | | | | | | | | | | | | | | | | | | | | | | no form of 'ip pm msdp peer <> source <>' does not accept source argument. Stip the 'source <>' part from config line being deleted via frr-reload. Ticket: #3874971 Testing: Config: vrf blue ip msdp peer 1.1.1.1 source 1.1.1.1 frr-reload failure log: 2024-04-23 02:08:32,501 INFO: Failed to execute vrf blue no ip msdp peer 1.1.1.1 source 1.1.1.1 exit 2024-04-23 02:08:32,501 ERROR: "vrf blue -- no ip msdp peer 1.1.1.1 source 1.1.1.1 -- exit" we failed to remove this command 2024-04-23 02:08:32,501 ERROR: % Unknown command: no ip msdp peer 1.1.1.1 source 1.1.1.1 Signed-off-by: Chirag Shah <chirag@nvidia.com>
* tools: fix pim interface config deletionIIChirag Shah2024-04-231-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When no ip pim is performed subsequent pim related configs under the interface also implicitly deleted. The previous fix was attempting to remove from the same list which was being integrated. First collect the lines to remove in separate list then at the end remove from the original lines_to_del. commit 623af04e1c does not work properly if tries to delete an entry from existing list which is being walked on. Ticket: #3869779 Testing done: frr.conf: no interface config running-config: -------------- interface swp1 ip pim ip pim active-active ip pim allow-rp rp-list sample ip pim bfd ip pim use-source 1.1.1.1 ip multicast boundary oil test exit frr-reload log pointing only no ip pim config is removed under interface: 2024-04-18 18:44:37,202 INFO: "frr defaults datacenter" cannot be removed 2024-04-18 18:44:37,202 INFO: "service integrated-vtysh-config" cannot be removed 2024-04-18 18:44:37,504 INFO: Executed "interface swp1 no ip pim exit" 2024-04-18 18:44:37,505 INFO: /var/run/frr/reload-YHS51E.txt content Signed-off-by: Chirag Shah <chirag@nvidia.com>
* Merge pull request #15709 from chiragshah6/fdev2Mark Stapp2024-04-161-0/+21
|\ | | | | tools: frr-reload strip interface vrf ctx line
| * tools: frr-reload strip interface vrf ctx lineChirag Shah2024-04-111-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | if frr.conf file contains 'interface x vrf <name> config it causes protocol (like ospf) neighbor session flap, as it deletes interface base config line ('interface x') from running config and readds with 'interface x vrf <name>' line from frr.conf. This deletion and readdition of lines leads to neighborship flaps. This issue is by product of (PR-10411 | https://github.com/FRRouting/frr/pull/10411) (commit id: 788a036fdb) where running config for interface config no loger displays associated vrf line. Ticket: #3858146 Testing: frr.conf interface swp1.2 vrf vrf1012 ip ospf network point-to-point running-config: interface swp1.2 ip ospf network point-to-point exit Before fix: frr-reload logs: 2024-04-09 00:28:31,096 INFO: Executed "interface swp1.2 no ip ospf network point-to-point exit" 'interface swp1.2 vrf vrf1012\n ip ospf network point-to-point\nexit\n', After fix: frr-reload strips vrf line, thus no config change between frr.conf and running config. Signed-off-by: Chirag Shah <chirag@nvidia.com>
* | tools/indent.py: fix encoded byte stream handlingAndrew Cooks2024-04-101-2/+2
|/ | | | | | Python subprocess communication now operates on bytes, not strings. Signed-off-by: Andrew Cooks <acooks.at.bda@gmail.com>
* *: Add missing SPDX-License-Identifier for some .c/.h filesDonatas Abraitis2024-03-211-0/+2
| | | | | | Adding them as others: GPL-2.0-or-later Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
* doc, tools: Remove ARRAY_SIZE checkDonald Sharp2024-03-041-13/+0
| | | | | | | | checkpatch.pl wants you to use ARRAY_SIZE in a kernel header file. We don't have access to this kernel header file for normal compilation. I'm just going to remove it. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
* Merge pull request #14898 from chiragshah6/mdevDonatas Abraitis2024-02-291-4/+5
|\ | | | | tools: fix frr-reload for nbr deletion
| * tools: fix frr-reload for nbr deletionChirag Shah2024-01-061-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | bgp neighbor config can have multiple lines, if neighbor is deleted via frr-reload, no neighbor remote-as <> wipes out the neighbor, subsequent neighbor associated config deletion would throw generic error. Frr-reload needs to move neighbor remote-as line to end and allow all other config lines to be removed. Ticket:#3588361 #3589216 Testing Done: config: neighbor swp3 interface remote-as external neighbor swp3 bfd 3 300 300 neighbor swp3 password leaf11-spine INFO: Executed "router bgp 65101 no neighbor swp3 interface remote-as external" INFO: Failed to execute router bgp 65101 no neighbor swp3 bfd 3 300 300 INFO: Failed to execute router bgp 65101 no neighbor swp3 bfd 3 300 INFO: Failed to execute router bgp 65101 no neighbor swp3 bfd 3 INFO: Failed to execute router bgp 65101 no neighbor swp3 bfd INFO: Failed to execute router bgp 65101 no neighbor swp3 INFO: Failed to execute router bgp 65101 no neighbor INFO: Failed to execute router bgp 65101 no ERROR: "router bgp 65101 -- no" we failed to remove this command ERROR: % Specify remote-as or peer-group commands first INFO: Failed to execute router bgp 65101 no neighbor swp3 password leaf11-spine INFO: Failed to execute router bgp 65101 no neighbor swp3 password INFO: Failed to execute router bgp 65101 no neighbor swp3 INFO: Failed to execute router bgp 65101 no neighbor INFO: Failed to execute router bgp 65101 no ERROR: "router bgp 65101 -- no" we failed to remove this command ERROR: % Specify remote-as or peer-group commands first After fix: move the neighbor remote-as deletion line to end which allows to remove other neighbor associated lines to be deleted. router bgp 65101 no neighbor swp3 interface remote-as external Signed-off-by: Chirag Shah <chirag@nvidia.com>