summaryrefslogtreecommitdiff
path: root/tools
AgeCommit message (Collapse)Author
2021-09-27tools: Add coccinelle script to catch \n or \r at the end of zlog_*Donatas Abraitis
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2021-09-21tools: Add some new suppressionsDonald Sharp
Bunch of new stuff came in w/ the libyang2 upgrade that needs to be suppressed. Make it so. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-09-09Merge pull request #9497 from opensourcerouting/cli-better-noQuentin Young
2021-09-04tests: cleanup: rerun changed files through blackChristian Hopps
Signed-off-by: Christian Hopps <chopps@labn.net>
2021-09-04tests: cleanup - remove unused importsChristian Hopps
Signed-off-by: Christian Hopps <chopps@labn.net>
2021-09-04tools: move frr-reload.py to python3 explicitlyChristian Hopps
We already, reasonably, require python3 elsewhere. Do so here, and reap some benefit. Signed-off-by: Christian Hopps <chopps@labn.net>
2021-09-02Merge pull request #9340 from stefreak/patch-1David Lamparter
tools: fix frr pathspace folder permissions
2021-08-26lib: add `![...]` syntax for easy "no" formsDavid Lamparter
This allows defining a CLI command like this: `[no] some setting ![VALUE]` with VALUE being optional for the "no" form, but required for the positive form. It's just a `[...]` where the empty branch can only be taken for commands starting with `no`. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-08-23tools: significantly simplify frr-reload context processingIgor Ryzhov
Currently, in frr-reload we: - store a list of single-line context keywords which needs to be frequently updated, - have a separate "if" clause for every node and subnode we have in FRR. Instead, we can store the tree of all known FRR nodes. This tree needs to be updated whenever we add a new node, which is not frequent. And, most importantly, it allows us to write node-agnostic code and save more than 250 LOC. Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2021-08-18Merge pull request #9341 from LabNConsulting/chopps/ospf-support-bundleIgor Ryzhov
tools: add ospfd support bundle commands
2021-08-14Merge pull request #9271 from opensourcerouting/workflow-release-schedDonald Sharp
workflow: document release scheduling discussed
2021-08-11workflow: document release scheduling discussedDavid Lamparter
As discussed in the weekly meeting today, this is what we're trying to work with for the time being. (Date calculator included as a bonus goodie ;) Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-08-10tools: add ospfd support bundle commandsChristian Hopps
Signed-off-by: Christian Hopps <chopps@labn.net>
2021-08-10Merge pull request #9219 from mobash-rasool/ospfv2-bug-fixesChristian Hopps
tools: Add ospfv2 and ospfv3 commands in support bundle
2021-08-09tools: fix frr pathspace folder permissionsSteffen Neubauer
The pathspace folder in /var/run needs the x permission for the group too Otherwise vtysh fails when running it with groups frrvty and frr: $ vtysh -N gateway % Can't open configuration file /etc/frr/gateway/vtysh.conf due to 'Permission denied'. vtysh_connect(/var/run/frr/gateway/zebra.vty): stat = Permission denied Signed-off-by: Steffen Neubauer <s.neubauer@syseleven.de>
2021-08-08Merge pull request #8870 from anlancs/master-fix-reload-serviceDonald Sharp
tools: add "vni" to oneline list
2021-07-30tools: Add ospfv3 commands in the support bundleMobashshera Rasool
Co-authored-by: Yash Ranjan <ranjyany@vmware.com> Signed-off-by: Yash Ranjan <ranjyany@vmware.com> Co-authored-by: Mobashshera Rasool <mrasool@vmware.com> Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
2021-07-30tools: Add ospfd commands in support bundleMobashshera Rasool
Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
2021-07-15tools: improve frr-reload.py delta file creationChristian Hopps
- Remove incorrect requirement for `service integrated-vtysh-config` when producing a delta. - Add `--test-reset` option which suppresses non-parseable lines from the produced delta - Use new features in common_config.py Signed-off-by: Christian Hopps <chopps@labn.net>
2021-07-13tools: Add coccinelle script for hash compare functions NULL valuesDonatas Abraitis
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2021-07-06Merge pull request #8942 from ton31337/fix/cleanups_2Donald Sharp
Another round of cleanup
2021-07-06Merge pull request #8939 from LabNConsulting/chopps/sup-bund-fixesDonald Sharp
Speedup support bundles, fix bugs, add CLI timestamp
2021-07-03tools: Simplify the script to build Debian binary packageIgor Ryzhov
Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-07-03debian: Add support for Debian bullseye to the packaging scriptOndřej Surý
The Debian bullseye is frozen now, so this adds support to this Debian release to the packaging script. Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-07-03debian: Fix the debian packaging script to build on non-default branchOndřej Surý
The packaging script would fail to run on non-master branch, fix that by pulling original branch name. Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-07-03debian: Update the tools/build-debian-package.sh to be example build scriptOndřej Surý
Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-07-03debian: Remove now obsolete tarsource.sh scriptOndřej Surý
Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-07-03debian: Remove the changelog-auto automation in favor of dchOndřej Surý
Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-07-03debian: Update tools/build-debian-package.sh to use git-buildpackageOndřej Surý
Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-07-03debian: Adjust tarsource.sh to use native debian/changelogOndřej Surý
Signed-off-by: Ondřej Surý <ondrej@sury.org>
2021-06-30tests: collect support bundle data in parallel, fix bugsChristian Hopps
Speedup (large topo): OLD: ~6 minutes NEW: ~1 second. (when paired with common_config.py changes) - Collect each "proc" support in parallel - For each "proc" only call vtysh once with all commands Bug fixes: - output was broken, a dump of python "repr" format of str. Signed-off-by: Christian Hopps <chopps@labn.net>
2021-06-30tools: add "vni" to oneline listanlancs
Add "vni" into oneline list. Additionally, keep them in order in oneline list. Signed-off-by: anlancs <anlan_cs@tom.com>
2021-06-29tools: Add coccinelle script for checking against XMALLOC/XCALLOC NULLsDonatas Abraitis
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2021-06-23tools: limit bgp route-maps to direct changes onlyDonald Sharp
When using frr-reload.py to modify a bgp neighbors route-map the code was doing this: a) deleting the previous route-map: `no neighbor XX route-map YY (in|out)` b) Adding the new route-map back in `neighbor XX route-may ZZ (in|out)` Now imagine that we have an outgoing route-map that we are changing and the reload is large because of a large number of lines in frr.conf Item (a) will happen. BGP will immediately start sending all local routes. At some point in time in the future (b) will be applied. This of course causes a withdraw but for a short amount of time we are leaking unintended routes. This is bad for several reasons not 1) route churn upstream, 2) we might influence traffic to go the wrong way. 3) if upstream has a maximum-prefix command the routes being sent might trip its circuitry and shutdown the peer entirely not even allowing you to get to (b). Ticket: #2589685 Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-06-23Merge pull request #6695 from adharkar/frr-master-gateway_ipPatrick Ruddy
EVPN route type-5 gateway IP overlay Index
2021-06-22Merge pull request #8867 from wesleycoakley/pbr-table-range-single-lineMark Stapp
tools: make frr-reload recognize `pbr table range` lines as single-line contexts
2021-06-18tools: add mac access-list context to frr-reload.pyDon Slice
Problem reported that frr-reload.py didn't handle the mac access-list command correctly, causing reloads to fail. This fix adds the support for the command as a single line context. Signed-off-by: Don Slice <dslice@nvidia.com>
2021-06-16tools: reload recognizes `pbr table range` as single-line ctxWesley Coakley
The line `pbr table range ...` does not start a new context so treat it like a single-line context Signed-off-by: Wesley Coakley <w@wesleycoakley.com>
2021-06-07tools: Add EVPN show commands to support bundleAmeya Dharkar
Signed-off-by: Ameya Dharkar <adharkar@vmware.com>
2021-06-01Merge pull request #8353 from opensourcerouting/llvm-20210327Quentin Young
2021-05-28Merge pull request #6317 from rgirada/fix_route_dumpRafael Zalamena
zebrad: Added a command to dump routes in support bundle
2021-05-24tools: fix peer-group deletion in frr-reloadChirag Shah
All of peers and respective configs are wiped out when pee-group is removed. In an attempt to remove peer-group and its associated peers configs via frr-reload fails if the peer-group is removed first. To pass the peer-group config removal via frr-reload following steps are taken: Find the bgp context to which peer-group belongs. Find the peer-group associated peer(s) and store them in a list. Remove the peers config lines from the pending list. Move the peer-group deletion line to end of the pending list so any remaining peer-group associated config can be removed successfully. The above steps take 3 iterations over the pending list and scales linearly. Ticket:2656351 Reviewed By:CCR-11575 Testing Done: Broken: config: router bgp 5544 neighbor PG1 peer-group neighbor PG1 remote-as external neighbor swp10 interface peer-group PG1 neighbor swp10 timers 3 9 failed frr-reload log: 2021-05-17 22:02:42,608 INFO: Executed "router bgp 5544 no neighbor PG1 peer-group" 2021-05-17 22:02:42,708 INFO: Failed to execute router bgp 5544 no neighbor PG1 remote-as external 2021-05-17 22:02:42,808 INFO: Failed to execute router bgp 5544 no neighbor PG1 remote-as 2021-05-17 22:02:42,906 INFO: Failed to execute router bgp 5544 no neighbor PG1 2021-05-17 22:02:43,007 INFO: Failed to execute router bgp 5544 no neighbor 2021-05-17 22:02:43,106 INFO: Failed to execute router bgp 5544 no 2021-05-17 22:02:43,106 ERROR: "router bgp 5544 -- no" we failed to remove this command 2021-05-17 22:02:43,107 ERROR: % Create the peer-group or interface first With fix: 2021-05-17 22:05:27,687 INFO: Executed "router bgp 5544 no neighbor PG1 remote-as external" 2021-05-17 22:05:27,791 INFO: Executed "router bgp 5544 no neighbor PG1 peer-group" Signed-off-by: Chirag Shah <chirag@nvidia.com>
2021-05-13lib: adapt to version 2 of libyangChristian Hopps
Compile with v2.0.0 tag of `libyang2` branch of: https://github.com/CESNET/libyang staticd init load time of 10k routes now 6s vs ly1 time of 150s Signed-off-by: Christian Hopps <chopps@labn.net>
2021-05-09Merge pull request #8472 from donaldsharp/more_valgrind_stuffDavid Lamparter
tools: Add some more data to ignore for valgrind
2021-05-07Merge pull request #8632 from wesleycoakley/le-32-128-fixIgor Ryzhov
lib: ip prefix-list "le" and "ge" bug squish
2021-05-06tools: stop frr-reload squashing le 32 / le 128Wesley Coakley
frr-reload no longer consolidates ip prefix-list "le 32" or "le 128" rules when a "ge" is present, more accurately representing existing user config and reflecting also what is accepted in CLI. Signed-off-by: Wesley Coakley <wcoakley@nvidia.com>
2021-05-06zebrad: Added a command to dump routes in support bundlergirada
Description: Added a new show command("show ip zebra route dump") to dump all routes with detailed information including nexthops,flags, status ..etc. This helps for dubugging and added to support_bundle_command.conf. Defined this command as a hidden command. Signed-off-by: Rajesh Girada <rgirada@vmware.com>
2021-05-05tools: Add some more data to ignore for valgrindDonald Sharp
When running valgrind there are some possible memory leaks. These memory leaks we have absolutely no control over, mark them as not worthy of being reported. Finally move the valgrind suppressions file from bgpd/ to tools/ this is because this suppressions file can be used beyond bgpd Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-05-02lib: rework how we "override" assert()David Lamparter
The previous method, using zassert.h and hoping nothing includes assert.h (which, on glibc at least, just does "#undef assert" and puts its own definition in...) was fragile - and actually broke undetected. Just provide our own assert.h and control overriding by putting it in a separate directory to add to the include path (or not.) Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-04-21tools: Cleanup frr-reload.py by running black on itDonald Sharp
Signed-off-by: Donald Sharp <sharpd@nvidia.com>