]> git.puffer.fish Git - mirror/frr.git/log
mirror/frr.git
4 years agoisisd, ospfd: increase timeout to fix intermittent LDP Sync test failure 7661/head
Karen Schoener [Thu, 3 Dec 2020 16:23:59 +0000 (11:23 -0500)]
isisd, ospfd: increase timeout to fix intermittent LDP Sync test failure

Currently, IGPs are coded to receive a 'hello' message from LDP every second.
Intermittently, LDP Sync topotests are failing because the IGPs fail to
receive this 'hello' message every second.
When the LDP Sync topotests fail, LDP logs show that LDP is processing
zapi messages for 1-2 seconds.

This is a shortterm fix, in order to prevent CI pipeline failures.
The longterm fix is in progress.

Signed-off-by: Karen Schoener <karen@voltanet.io>
4 years agoMerge pull request #7660 from rampxxxx/master
Donald Sharp [Thu, 3 Dec 2020 13:29:02 +0000 (08:29 -0500)]
Merge pull request #7660 from rampxxxx/master

doc: add building steps for openSUSE

4 years agodoc: add building steps for openSUSE 7660/head
Javier Garcia [Thu, 3 Dec 2020 10:59:01 +0000 (11:59 +0100)]
doc: add building steps for openSUSE

Signed-off-by: Javier Garcia <rampxxxx@gmail.com>
4 years agoMerge pull request #7349 from opensourcerouting/bgp-delayopen
Donatas Abraitis [Thu, 3 Dec 2020 06:26:44 +0000 (08:26 +0200)]
Merge pull request #7349 from opensourcerouting/bgp-delayopen

bgpd: RFC 4271 optional session attribute DelayOpenTimer

4 years agoMerge pull request #7638 from donaldsharp/reduce_warn
Donatas Abraitis [Thu, 3 Dec 2020 06:17:59 +0000 (08:17 +0200)]
Merge pull request #7638 from donaldsharp/reduce_warn

zebra: Reduce warn -> debug

4 years agoMerge pull request #6950 from opensourcerouting/bfd-distributed-v3
Donald Sharp [Thu, 3 Dec 2020 01:50:47 +0000 (20:50 -0500)]
Merge pull request #6950 from opensourcerouting/bfd-distributed-v3

bfdd: distributed BFD

4 years agoMerge pull request #7590 from opensourcerouting/isisd-lfa
Donald Sharp [Thu, 3 Dec 2020 01:43:51 +0000 (20:43 -0500)]
Merge pull request #7590 from opensourcerouting/isisd-lfa

isisd: add support for classic LFA

4 years agoMerge pull request #7657 from mjstapp/fix_topo_asan_noise
Donald Sharp [Thu, 3 Dec 2020 01:07:53 +0000 (20:07 -0500)]
Merge pull request #7657 from mjstapp/fix_topo_asan_noise

tests: Cleanup topo asan noise

4 years agoMerge pull request #7625 from donaldsharp/pointtomultipoint
Russ White [Wed, 2 Dec 2020 18:07:28 +0000 (13:07 -0500)]
Merge pull request #7625 from donaldsharp/pointtomultipoint

Pointtomultipoint

4 years agoMerge pull request #7596 from gpnaveen/ospf_basic
Donald Sharp [Wed, 2 Dec 2020 17:35:43 +0000 (12:35 -0500)]
Merge pull request #7596 from gpnaveen/ospf_basic

tests : Adding 3 base ospf testcases.

4 years agoMerge pull request #7589 from pguibert6WIND/show_bgp_summary_desc
Donald Sharp [Wed, 2 Dec 2020 17:18:07 +0000 (12:18 -0500)]
Merge pull request #7589 from pguibert6WIND/show_bgp_summary_desc

Show bgp summary desc

4 years agoMerge pull request #7572 from idryzhov/ospf6-cleanup
Donald Sharp [Wed, 2 Dec 2020 16:10:48 +0000 (11:10 -0500)]
Merge pull request #7572 from idryzhov/ospf6-cleanup

ospf6 code cleanup

4 years agotests: quiet noisy error log about asan files 7657/head
Mark Stapp [Wed, 2 Dec 2020 16:08:38 +0000 (11:08 -0500)]
tests: quiet noisy error log about asan files

Turn a noisy error log into a debug - it's just reporting
that we're _looking_ for asan output.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agotests: fix typo in asan variable names
Mark Stapp [Wed, 2 Dec 2020 16:08:03 +0000 (11:08 -0500)]
tests: fix typo in asan variable names

Use AddressSanitizer consistently

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #7648 from donaldsharp/store_curr_mtu
Russ White [Wed, 2 Dec 2020 15:25:42 +0000 (10:25 -0500)]
Merge pull request #7648 from donaldsharp/store_curr_mtu

ospfd: Set Curr_mtu to when we get the mtu

4 years agoMerge pull request #7612 from deastoe/ospf-vlink-auth-cfg
Donald Sharp [Wed, 2 Dec 2020 14:27:16 +0000 (09:27 -0500)]
Merge pull request #7612 from deastoe/ospf-vlink-auth-cfg

ospfd: vlink auth type not shown in running config

4 years agoMerge pull request #7615 from gromit1811/feature_topotest_module_noload
Donald Sharp [Wed, 2 Dec 2020 14:23:30 +0000 (09:23 -0500)]
Merge pull request #7615 from gromit1811/feature_topotest_module_noload

tests: Add TOPOTEST_NOLOAD to skip module loading question

4 years agoMerge pull request #7644 from mjstapp/dplane_cleaner
Donald Sharp [Wed, 2 Dec 2020 14:01:44 +0000 (09:01 -0500)]
Merge pull request #7644 from mjstapp/dplane_cleaner

zebra: add an api to process/clean the pending dplane queue

4 years agoMerge pull request #7646 from volta-networks/fix_show_route_summary
Donald Sharp [Wed, 2 Dec 2020 13:59:54 +0000 (08:59 -0500)]
Merge pull request #7646 from volta-networks/fix_show_route_summary

zebra: fix show ip route vrf X summary

4 years agoospfd: Set Curr_mtu to when we get the mtu 7648/head
Donald Sharp [Tue, 1 Dec 2020 20:37:03 +0000 (15:37 -0500)]
ospfd: Set Curr_mtu to when we get the mtu

Currently if you start ospfd, bring up neighbors and then issue
a tcpdump on a interface ospf is peering over, this causes the neighbor
relationship to be restarted:

root@spectrum301(mlx-4600c-01):mgmt:~# tcpdump -i vlan402
2020-11-13T21:25:38.059671+00:00 spectrum301 ospfd[29953]: AdjChg: Nbr 202.0.0.3(default) on vlan402:200.0.3.1: Full -> Deleted (KillNbr)
2020-11-13T21:25:38.065520+00:00 spectrum301 ospfd[29953]: ospfTrapNbrStateChange: trap sent: 200.0.3.2 now Deleted/DROther
2020-11-13T21:25:38.065922+00:00 spectrum301 ospfd[29953]: ospfTrapIfStateChange: trap sent: 200.0.3.1 now Down
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on vlan402, link-type EN10MB (Ethernet), capture size 262144 bytes
21:25:38.072330 IP 200.0.3.1 > igmp.mcast.net: igmp v3 report, 1 group record(s)
2020-11-13T21:25:38.080430+00:00 spectrum301 ospfd[29953]: ospfTrapIfStateChange: trap sent: 200.0.3.1 now Point-To-Point
2020-11-13T21:25:38.080654+00:00 spectrum301 ospfd[29953]: SPF Processing Time(usecs): 9734
2020-11-13T21:25:38.080829+00:00 spectrum301 ospfd[29953]:             SPF Time: 6422
2020-11-13T21:25:38.080991+00:00 spectrum301 ospfd[29953]:            InterArea: 1572
2020-11-13T21:25:38.081152+00:00 spectrum301 ospfd[29953]:                Prune: 67
2020-11-13T21:25:38.081329+00:00 spectrum301 ospfd[29953]:         RouteInstall: 1396
2020-11-13T21:25:38.081548+00:00 spectrum301 ospfd[29953]: Reason(s) for SPF: N, S, ABR, ASBR
21:25:38.092510 IP 200.0.3.1 > ospf-all.mcast.net: OSPFv2, Hello, length 44

This is happening because the curr_mtu is not being properly stored.  It was being set
on interface creation( but we have not actually read in the mtu part of the interface data, so
it is still 0 ).

Modify the code to store the curr_mtu at a point in interface creation *After* we have read
in interface data.

Ticket: CM-32276
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agoMerge pull request #7647 from ton31337/feature/show_best_path_reason_in_show_bgp
Donald Sharp [Wed, 2 Dec 2020 11:52:30 +0000 (06:52 -0500)]
Merge pull request #7647 from ton31337/feature/show_best_path_reason_in_show_bgp

bgpd: Show best path reason in JSON output for `show bgp` command

4 years agoMerge pull request #7651 from idryzhov/ospf-init-instance
Donald Sharp [Wed, 2 Dec 2020 11:50:15 +0000 (06:50 -0500)]
Merge pull request #7651 from idryzhov/ospf-init-instance

ospf: fix instance initialization when using multi-instance mode

4 years agoospf: fix instance initialization when using multi-instance mode 7651/head
Igor Ryzhov [Wed, 2 Dec 2020 00:36:10 +0000 (03:36 +0300)]
ospf: fix instance initialization when using multi-instance mode

OSPF instance initialization was moved from "router ospf" vty command to
ospf_get function some time ago but the same thing must be done in
ospf_get_instance function used when multi-instance mode is enabled.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agoMerge pull request #7645 from sworleys/NHG-IFP-Error2Log 7653/head
Mark Stapp [Tue, 1 Dec 2020 22:17:59 +0000 (17:17 -0500)]
Merge pull request #7645 from sworleys/NHG-IFP-Error2Log

zebra: make a couple NHG errors debugs

4 years agoospfd: vlink auth type not shown in running config 7612/head
Duncan Eastoe [Thu, 26 Nov 2020 17:34:09 +0000 (17:34 +0000)]
ospfd: vlink auth type not shown in running config

The following virtual-link configuration was not represented in the
running configuration:
  area <area> virtual-link <ip> authentication [null|message-digest]

Signed-off-by: Duncan Eastoe <duncan.eastoe@att.com>
4 years agoMerge pull request #7601 from patrasar/pim_fix
Donald Sharp [Tue, 1 Dec 2020 20:53:53 +0000 (15:53 -0500)]
Merge pull request #7601 from patrasar/pim_fix

Pim fix

4 years agobgpd: Show best path reason in JSON output for `show bgp` command 7647/head
Donatas Abraitis [Tue, 1 Dec 2020 20:36:05 +0000 (22:36 +0200)]
bgpd: Show best path reason in JSON output for `show bgp` command

exit1-debian-9# show ip bgp json
{
 "vrfId": 0,
 "vrfName": "default",
 "tableVersion": 2,
 "routerId": "192.168.255.1",
 "defaultLocPrf": 100,
 "localAS": 65000,
 "routes": { "172.16.255.254/32": [
  {
    "valid":true,
    "bestpath":true,
    "selectionReason":"First path received",
    "pathFrom":"external",
    "prefix":"172.16.255.254",
    "prefixLen":32,
    "network":"172.16.255.254\/32",
    "metric":0,
    "weight":0,
    "peerId":"192.168.255.2",
    "path":"65001",
    "origin":"incomplete",
    "nexthops":[
      {
        "ip":"192.168.255.2",
        "hostname":"exit1-debian-9",
        "afi":"ipv4",
        "used":true
      }
    ]
  }
],"192.168.255.0/24": [
  {
    "valid":true,
    "bestpath":true,
    "selectionReason":"First path received",
    "pathFrom":"external",
    "prefix":"192.168.255.0",
    "prefixLen":24,
    "network":"192.168.255.0\/24",
    "metric":0,
    "weight":0,
    "peerId":"192.168.255.2",
    "path":"65001",
    "origin":"incomplete",
    "nexthops":[
      {
        "ip":"192.168.255.2",
        "hostname":"exit1-debian-9",
        "afi":"ipv4",
        "used":true
      }
    ]
  }
] }  }

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agoMerge pull request #7617 from deastoe/dplane-fpm-lsp
Rafael Zalamena [Tue, 1 Dec 2020 19:01:09 +0000 (16:01 -0300)]
Merge pull request #7617 from deastoe/dplane-fpm-lsp

zebra: dplane FPM LSP support

4 years agozebra: remove unused EC_ZEBRA_IF_LOOKUP_FAILED 7645/head
Stephen Worley [Tue, 1 Dec 2020 18:05:36 +0000 (13:05 -0500)]
zebra: remove unused EC_ZEBRA_IF_LOOKUP_FAILED

EC_ZEBRA_IF_LOOKUP_FAILED is no longer being used,
remove it.

Signed-off-by: Stephen Worley <sworley@nvidia.com>
4 years agoMerge pull request #7641 from rampxxxx/fix_run_folder
Donald Sharp [Tue, 1 Dec 2020 17:40:40 +0000 (12:40 -0500)]
Merge pull request #7641 from rampxxxx/fix_run_folder

Fix run folder permissions

4 years agoMerge pull request #7483 from AnuradhaKaruppiah/evpn-mh-dad
Patrick Ruddy [Tue, 1 Dec 2020 17:37:32 +0000 (17:37 +0000)]
Merge pull request #7483 from AnuradhaKaruppiah/evpn-mh-dad

bgpd, zebra: Keep DAD disabled if EVPN MH is turned on

4 years agozebra: fix show ip route vrf X summary 7646/head
Emanuele Di Pascale [Tue, 1 Dec 2020 17:24:46 +0000 (18:24 +0100)]
zebra: fix show ip route vrf X summary

The lookup for non default VRFs was always using a tableId; if not
provided, we were defaulting to RT_TABLE_MAIN. This is fine for the
default VRF but not for others. As a result, the command was silently
failing for non-default VRFs unless we also specified the correct tableId.

Fix this by only performing the lookup using the tableId if it is
provided; else use zebra_vrf_table.

Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
4 years agoMerge pull request #7632 from idryzhov/vtysh-memory-fixes
Donald Sharp [Tue, 1 Dec 2020 17:08:52 +0000 (12:08 -0500)]
Merge pull request #7632 from idryzhov/vtysh-memory-fixes

vtysh memory fixes

4 years agozebra: make a couple NHG errors debugs
Stephen Worley [Tue, 1 Dec 2020 17:04:30 +0000 (12:04 -0500)]
zebra: make a couple NHG errors debugs

A couple NHG messages we were logging as errors are a bit spammy
in usecases where you routinely add/remove interfaces (VM heavy
deployments). Its not really an error a user cares about and
more for a developer to know what went wrong after the fact so
it makes more sense for these to be under a debug rather than
an error since seeing them does not implicitly mean error during
those usecases.

Signed-off-by: Stephen Worley <sworley@nvidia.com>
4 years agoMerge pull request #7642 from donaldsharp/remove_pimd_version
Mark Stapp [Tue, 1 Dec 2020 16:59:31 +0000 (11:59 -0500)]
Merge pull request #7642 from donaldsharp/remove_pimd_version

pimd: Remove pim_version.c it is never used

4 years agoMerge pull request #7640 from opensourcerouting/bfd-echo-minttl-check
Donald Sharp [Tue, 1 Dec 2020 14:31:57 +0000 (09:31 -0500)]
Merge pull request #7640 from opensourcerouting/bfd-echo-minttl-check

bfdd: session specific command type checks

4 years agopimd: mesh group not removed when configured for multiple groups 7601/head
Sarita Patra [Wed, 25 Nov 2020 11:00:06 +0000 (03:00 -0800)]
pimd: mesh group not removed when configured for multiple groups

Issue:
Configure msdp mesh mg1 for 2 groups.
ip msdp mesh-group mg1 member 1.1.1.1
ip msdp mesh-group mg1 member 1.1.1.2

Remove mg1 for 1.1.1.1
no ip msdp mesh-group mg1 member 1.1.1.1

mg1 for 1.1.1.1 still present. This is fixed.

Signed-off-by: Sarita Patra <saritap@vmware.com>
4 years agopimd: rp not removed when configured for multiple groups
Sarita Patra [Wed, 25 Nov 2020 08:26:25 +0000 (00:26 -0800)]
pimd: rp not removed when configured for multiple groups

Issue:
Configure RP.
ip pim rp 20.0.0.1 239.1.1.1/32
ip pim rp 20.0.0.1 239.1.1.2/32

Remove RP.
no ip pim rp 20.0.0.1 239.1.1.1/32
Rp is not removed. This is fixed now.

Signed-off-by: Sarita Patra <saritap@vmware.com>
4 years agopimd: Remove pim_version.c it is never used 7642/head
Donald Sharp [Tue, 1 Dec 2020 12:57:45 +0000 (07:57 -0500)]
pimd: Remove pim_version.c it is never used

The pim_version.[c|h] files are never used and we are getting
warnings about PIM_VERSION changing pointer sizes from
newer versions of the compiler.  I see no reason to keep this

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agoMerge pull request #7404 from vishaldhingra/pim
Donald Sharp [Tue, 1 Dec 2020 12:48:54 +0000 (07:48 -0500)]
Merge pull request #7404 from vishaldhingra/pim

pimd: (*,G) Prune processing doesn't remove SGRpt ifchannel

4 years agoMerge pull request #7578 from mjstapp/fix_pim_subdir_am
Donald Sharp [Tue, 1 Dec 2020 12:41:33 +0000 (07:41 -0500)]
Merge pull request #7578 from mjstapp/fix_pim_subdir_am

pimd: fix build and compilation errors

4 years agotools: Fix run folder permissions 7641/head
Javier Garcia [Tue, 1 Dec 2020 11:28:39 +0000 (12:28 +0100)]
tools: Fix run folder permissions

In the case of some linux distros the /var/run dir is mounted
with tmpfs so in every reboot it's removed.
Then the frrcommon.sh will recreate it without 'x' perm
So no pid file cannot be created in /var/run/frr

Signed-off-by: Javier Garcia <rampxxxx@gmail.com>
4 years agobfdd: session specific command type checks 7640/head
Rafael Zalamena [Tue, 1 Dec 2020 11:01:37 +0000 (08:01 -0300)]
bfdd: session specific command type checks

Replace the unclear error message:

```
% Failed to edit configuration.

YANG error(s):
 Schema node not found.
 YANG path: /frr-bfdd:bfdd/bfd/sessions/single-hop[dest-addr='192.168.253.6'][interface=''][vrf='default']/minimum-ttl
```

With:

```
frr(config-bfd-peer)# minimum-ttl 250
% Minimum TTL is only available for multi hop sessions.

! or

frr(config-bfd-peer)# echo
% Echo mode is only available for single hop sessions.
frr(config-bfd-peer)# echo-interval 300
% Echo mode is only available for single hop sessions.
```

Reported-by: Trae Santiago
Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
4 years agodoc: add description of the new memory macro 7632/head
Igor Ryzhov [Tue, 1 Dec 2020 08:39:40 +0000 (11:39 +0300)]
doc: add description of the new memory macro

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agoMerge pull request #7630 from donaldsharp/snmp_clarity
Donatas Abraitis [Tue, 1 Dec 2020 08:32:06 +0000 (10:32 +0200)]
Merge pull request #7630 from donaldsharp/snmp_clarity

doc: Explicitly call out need to add snmp module

4 years agobgpd: add peer description for each afi/safi line in show summary 7589/head
Philippe Guibert [Mon, 23 Nov 2020 14:29:40 +0000 (14:29 +0000)]
bgpd: add peer description for each afi/safi line in show summary

For each afi/safi of 'show bgp summary', display the peer description
each time needed. This information is useful, for instance in the case
of a device connected with multiple peers.
The topotest all_protocol_startup is changed accordingly.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agozebra: Reduce warn -> debug 7638/head
Donald Sharp [Tue, 1 Dec 2020 00:37:53 +0000 (19:37 -0500)]
zebra: Reduce warn -> debug

During times of network trauma and when we are at large network scale
the process_remote_macip_add function can issue a zlog_warn for
a common occurrence.  Modify the code to be a debug statement.
This behavior is the same now as the process_remote_macip_del function

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agozebra: add an api to process/clean the pending dplane queue 7644/head
Mark Stapp [Mon, 30 Nov 2020 21:42:18 +0000 (16:42 -0500)]
zebra: add an api to process/clean the pending dplane queue

Add an api that allows a caller in the zebra main pthread to
process the queue of pending dplane updates. The caller supplies
a function to call to test each pending context. Selected
contexts are dequeued, and freed without being processed.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #7631 from mjstapp/fix_pw_ctx_leak
Donald Sharp [Mon, 30 Nov 2020 18:48:38 +0000 (13:48 -0500)]
Merge pull request #7631 from mjstapp/fix_pw_ctx_leak

zebra: free dplane ctx after pw update

4 years agovtysh: fix incorrect memory statistics
Igor Ryzhov [Mon, 30 Nov 2020 15:50:51 +0000 (18:50 +0300)]
vtysh: fix incorrect memory statistics

As code comment states, 1 count of MTYPE_COMPLETION is leaked for each
autocompleted token. Let's manually decrement the counter before passing
the pointer to readline.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agovtysh: fix memory leak
Igor Ryzhov [Mon, 30 Nov 2020 15:44:10 +0000 (18:44 +0300)]
vtysh: fix memory leak

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agozebra: free dplane ctx after pw update 7631/head
Mark Stapp [Mon, 30 Nov 2020 15:02:40 +0000 (10:02 -0500)]
zebra: free dplane ctx after pw update

Free the dplane contexts used for pseudowire updates; we were
leaking these.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoospf6: move serv_close to ospf6_delete 7572/head
Igor Ryzhov [Fri, 20 Nov 2020 03:06:51 +0000 (06:06 +0300)]
ospf6: move serv_close to ospf6_delete

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agoospf6: fix crash on shutdown
Igor Ryzhov [Fri, 20 Nov 2020 03:00:31 +0000 (06:00 +0300)]
ospf6: fix crash on shutdown

The crash is sometimes reproduced by all_protocol_startup topotest.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agoospf6: get instance from lsdb data
Igor Ryzhov [Fri, 20 Nov 2020 03:01:55 +0000 (06:01 +0300)]
ospf6: get instance from lsdb data

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agoospf6: get instance from route table scope
Igor Ryzhov [Fri, 20 Nov 2020 01:13:52 +0000 (04:13 +0300)]
ospf6: get instance from route table scope

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agodoc: Explicitly call out need to add snmp module 7630/head
Donald Sharp [Mon, 30 Nov 2020 13:39:29 +0000 (08:39 -0500)]
doc: Explicitly call out need to add snmp module

The documentation implied how snmp works.  Explicitly call
it out a bit more for future users.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agoMerge pull request #7621 from idryzhov/fix-cisco-access-list
Rafael Zalamena [Mon, 30 Nov 2020 12:16:33 +0000 (09:16 -0300)]
Merge pull request #7621 from idryzhov/fix-cisco-access-list

yang: fix cisco access list source value

4 years agozebra: dplane FPM LSP table walk 7617/head
Duncan Eastoe [Fri, 27 Nov 2020 16:12:22 +0000 (16:12 +0000)]
zebra: dplane FPM LSP table walk

Add routines to walk the LSP table and generate FPM updates for all
entries. A walk of the LSP table is triggered when (re-)connecting
to an FPM.

Signed-off-by: Duncan Eastoe <duncan.eastoe@att.com>
4 years agoMerge pull request #7620 from ckishimo/cosmetic2
Rafael Zalamena [Mon, 30 Nov 2020 11:53:33 +0000 (08:53 -0300)]
Merge pull request #7620 from ckishimo/cosmetic2

ospfd: fix a couple of typos

4 years agoospfd: Restore POINTOMULTIPOINT to working order 7625/head
Donald Sharp [Sat, 28 Nov 2020 20:35:18 +0000 (15:35 -0500)]
ospfd: Restore POINTOMULTIPOINT to working order

Commit: 1d376ff539508f336cb5872c5592b780e3db180b removed
the code to find nexthops for the POINTOMULTIPOINT and
replaced it with a generic bit of code that was
supposed to handle both POINTOPOINT and POINTOMULTIPOINT
the problem is that the ospf rfc states that the
network mask on point to multipoint should be /32
which will not allow you to properly do a prefix match
on it against the network.

Restore original behavior as much as possible and leave
the new POINTOPOINT code alone.

Fixes: #7624
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agoeigrpd: Remove unneeeded if state types
Donald Sharp [Sat, 28 Nov 2020 12:45:08 +0000 (07:45 -0500)]
eigrpd: Remove unneeeded if state types

There are some unused/unneeded if state types in eigrp, remove them

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agoMerge pull request #7584 from opensourcerouting/topotest-asan-fix
Donald Sharp [Fri, 27 Nov 2020 22:35:08 +0000 (17:35 -0500)]
Merge pull request #7584 from opensourcerouting/topotest-asan-fix

tests: Fix Topotest runs with newerversion of Address Sanitizer

4 years agoyang: fix cisco access list source value 7621/head
Igor Ryzhov [Fri, 27 Nov 2020 18:53:25 +0000 (21:53 +0300)]
yang: fix cisco access list source value

Source value must be a choice between host, network and any, not a set
of all three.

Fixes #7599.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
4 years agotests: Ignore YANG stderr messages in test_all_protocol_startup test 7584/head
Martin Winter [Fri, 27 Nov 2020 02:20:16 +0000 (03:20 +0100)]
tests: Ignore YANG stderr messages in test_all_protocol_startup test

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
4 years agotests: Fix logging output directory for older tests
Martin Winter [Fri, 27 Nov 2020 02:16:55 +0000 (03:16 +0100)]
tests: Fix logging output directory for older tests

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
4 years agotests: Fix FRR process shutdown in failed topotest teardown phase
Martin Winter [Wed, 25 Nov 2020 21:59:40 +0000 (22:59 +0100)]
tests: Fix FRR process shutdown in failed topotest teardown phase

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
4 years agotests: Fix Topotest runs with newerversion of Address Sanitizer
Martin Winter [Mon, 23 Nov 2020 03:06:07 +0000 (04:06 +0100)]
tests: Fix Topotest runs with newerversion of Address Sanitizer

Fix Address Sanitizer Issue detection with newer ASAN versions

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
4 years agozebra: dplane FPM handle LSP install/update/delete
Duncan Eastoe [Fri, 27 Nov 2020 15:45:35 +0000 (15:45 +0000)]
zebra: dplane FPM handle LSP install/update/delete

Export netlink_lsp_msg_encoder() and use it to encode and send netlink
messages concerning LSP updates to connected FPMs.

Signed-off-by: Duncan Eastoe <duncan.eastoe@att.com>
4 years agoMerge pull request #7614 from donaldsharp/more_use_after_free
Renato Westphal [Fri, 27 Nov 2020 11:51:24 +0000 (08:51 -0300)]
Merge pull request #7614 from donaldsharp/more_use_after_free

ldpd: Prevent usage after free

4 years agoMerge pull request #7593 from opensourcerouting/bgp_features_ospf_fix
Donald Sharp [Thu, 26 Nov 2020 23:36:54 +0000 (18:36 -0500)]
Merge pull request #7593 from opensourcerouting/bgp_features_ospf_fix

tests: Make ospf in bgp_features testsuite predictable

4 years agoMerge pull request #7611 from opensourcerouting/docker_key_update
Donald Sharp [Thu, 26 Nov 2020 23:33:12 +0000 (18:33 -0500)]
Merge pull request #7611 from opensourcerouting/docker_key_update

tests: Update topotest Dockerfile to pick up keys from deb repo

4 years agoldpd: Prevent usage after free 7614/head
Donald Sharp [Thu, 26 Nov 2020 23:23:57 +0000 (18:23 -0500)]
ldpd: Prevent usage after free

error 26-Nov-2020 14:35:02 ERROR: AddressSanitizer: heap-use-after-free on address 0x631000024838 at pc 0x55cefae977e9 bp 0x7ffdd3546860 sp 0x7ffdd3546850
error 26-Nov-2020 14:35:02 READ of size 4 at 0x631000024838 thread T0
error 26-Nov-2020 14:35:02     #0 0x55cefae977e8 in ldpe_imsg_compose_parent_sync ldpd/ldpe.c:256
error 26-Nov-2020 14:35:02     #1 0x55cefae9ab13 in vlog ldpd/log.c:53
error 26-Nov-2020 14:35:02     #2 0x55cefae9b21f in log_info ldpd/log.c:102
error 26-Nov-2020 14:35:02     #3 0x55cefae96eae in ldpe_shutdown ldpd/ldpe.c:237
error 26-Nov-2020 14:35:02     #4 0x55cefae99254 in ldpe_dispatch_main ldpd/ldpe.c:585
error 26-Nov-2020 14:35:02     #5 0x55cefaf93875 in thread_call lib/thread.c:1681
error 26-Nov-2020 14:35:02     #6 0x55cefae97304 in ldpe ldpd/ldpe.c:136
error 26-Nov-2020 14:35:02     #7 0x55cefae5a2e2 in main ldpd/ldpd.c:322
error 26-Nov-2020 14:35:02     #8 0x7f4ef0c33b96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
error 26-Nov-2020 14:35:02     #9 0x55cefae525e9 in _start (/usr/lib/frr/ldpd+0xb35e9)
error 26-Nov-2020 14:35:02
error 26-Nov-2020 14:35:02 0x631000024838 is located 65592 bytes inside of 65632-byte region [0x631000014800,0x631000024860)
error 26-Nov-2020 14:35:02 freed by thread T0 here:
error 26-Nov-2020 14:35:02     #0 0x7f4ef21e37a8 in __interceptor_free (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xde7a8)
error 26-Nov-2020 14:35:02     #1 0x55cefae96e91 in ldpe_shutdown ldpd/ldpe.c:234
error 26-Nov-2020 14:35:02     #2 0x55cefae99254 in ldpe_dispatch_main ldpd/ldpe.c:585
error 26-Nov-2020 14:35:02     #3 0x55cefaf93875 in thread_call lib/thread.c:1681
error 26-Nov-2020 14:35:02     #4 0x55cefae97304 in ldpe ldpd/ldpe.c:136
error 26-Nov-2020 14:35:02     #5 0x55cefae5a2e2 in main ldpd/ldpd.c:322
error 26-Nov-2020 14:35:02     #6 0x7f4ef0c33b96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
error 26-Nov-2020 14:35:02
error 26-Nov-2020 14:35:02 previously allocated by thread T0 here:
error 26-Nov-2020 14:35:02     #0 0x7f4ef21e3d28 in __interceptor_calloc (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xded28)
error 26-Nov-2020 14:35:02     #1 0x55cefae9725d in ldpe ldpd/ldpe.c:127
error 26-Nov-2020 14:35:02     #2 0x55cefae5a2e2 in main ldpd/ldpd.c:322
error 26-Nov-2020 14:35:02     #3 0x7f4ef0c33b96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)

Clean this problem up in the same way as the previous commit

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agotests: Update topotest Dockerfile to pick up keys from deb repo 7611/head
Martin Winter [Thu, 26 Nov 2020 13:50:38 +0000 (14:50 +0100)]
tests: Update topotest Dockerfile to pick up keys from deb repo

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
4 years agotests: Add TOPOTEST_NOLOAD to skip module loading question 7615/head
Martin Buck [Thu, 26 Nov 2020 15:12:21 +0000 (16:12 +0100)]
tests: Add TOPOTEST_NOLOAD to skip module loading question

This is the opposite of TOPOTEST_AUTOLOAD: Instead of automatically loading
missing modules, TOPOTEST_NOLOAD prevents module loading and supresses
questions about it.

Signed-off-by: Martin Buck <mb-tmp-tvguho.pbz@gromit.dyndns.org>
4 years agoMerge pull request #7603 from donaldsharp/ospf_crash_fix
Donatas Abraitis [Thu, 26 Nov 2020 12:53:18 +0000 (14:53 +0200)]
Merge pull request #7603 from donaldsharp/ospf_crash_fix

ospfd: Prevent crash by accessing memory not owned.

4 years agoMerge pull request #7586 from kuldeepkash/bgp_multi_vrf
Donatas Abraitis [Thu, 26 Nov 2020 07:48:54 +0000 (09:48 +0200)]
Merge pull request #7586 from kuldeepkash/bgp_multi_vrf

tests: Add tests to bgp_multi_vrf_topo2

4 years agotests: Make ospf convergence predictable by setting if priority 7593/head
Martin Winter [Mon, 23 Nov 2020 22:34:51 +0000 (23:34 +0100)]
tests: Make ospf convergence predictable by setting if priority

Added OSPF priorities to force a predictable DR/Backup router selection

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
4 years agoMerge pull request #7600 from pjdruddy/evpn-mh-sa
Donald Sharp [Wed, 25 Nov 2020 21:30:29 +0000 (16:30 -0500)]
Merge pull request #7600 from pjdruddy/evpn-mh-sa

bgpd: correctly store allocated ES struct

4 years agoMerge pull request #7608 from qlyoung/fix-missing-sockunion-init
Mark Stapp [Wed, 25 Nov 2020 21:07:08 +0000 (16:07 -0500)]
Merge pull request #7608 from qlyoung/fix-missing-sockunion-init

bgpd: remove unused, uninitialized sockunion

4 years agoMerge pull request #7607 from pguibert6WIND/topo_python3_preparation
Mark Stapp [Wed, 25 Nov 2020 19:22:10 +0000 (14:22 -0500)]
Merge pull request #7607 from pguibert6WIND/topo_python3_preparation

Topo python3 preparation

4 years agobgpd: correctly store allocated ES struct 7600/head
Pat Ruddy [Wed, 25 Nov 2020 10:18:45 +0000 (10:18 +0000)]
bgpd: correctly store allocated ES struct

in the rare situation where we allocate the ES during the path link
we fail to check/store the allocated ES pointer thus leading to a
NULL dereference later in the function.

Signed-off-by: Pat Ruddy <pat@voltanet.io>
4 years agoMerge pull request #7602 from donaldsharp/ldp_use_after_free
Renato Westphal [Wed, 25 Nov 2020 17:51:53 +0000 (14:51 -0300)]
Merge pull request #7602 from donaldsharp/ldp_use_after_free

ldpd: Prevent usage after free

4 years agobgpd: remove unused, uninitialized sockunion 7608/head
Quentin Young [Wed, 25 Nov 2020 17:49:06 +0000 (12:49 -0500)]
bgpd: remove unused, uninitialized sockunion

Signed-off-by: Quentin Young <qlyoung@nvidia.com>
4 years agotopotests: precise importation folder 7607/head
Philippe Guibert [Tue, 24 Nov 2020 13:10:16 +0000 (13:10 +0000)]
topotests: precise importation folder

the topolog importation folder must be precised. otherwise following
error message appears:

root@dut-vm:~/topotests/bgp_flowspec# python3 test_bgp_flowspec_topo.py
Traceback (most recent call last):
  File "test_bgp_flowspec_topo.py", line 96, in <module>
    from lib.lutil import lUtil
  File "/root/topotests/bgp_flowspec/../lib/lutil.py", line 25, in <module>
    from topolog import logger
ImportError: No module named 'topolog'
root@dut-vm:~/topotests/bgp_flowspec#

The same error occurs with lutil and bgprib which are 2 libraries
located under lib/ folder. Some precisions are added too.

PR=71290
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agotopotests: python3, replace iteritems with items
Philippe Guibert [Wed, 25 Nov 2020 16:23:19 +0000 (16:23 +0000)]
topotests: python3, replace iteritems with items

replace iteritems() calls with items()

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agotopotests: python3, rename iterkey() with key() for dictionary usage
Philippe Guibert [Wed, 25 Nov 2020 12:49:45 +0000 (12:49 +0000)]
topotests: python3, rename iterkey() with key() for dictionary usage

dictionary method iterkey() is not used in python3 and is replaced with
key() method.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agotopotests: python3, fix error ValueError: can't have unbuffered text I/O
Philippe Guibert [Wed, 25 Nov 2020 09:32:51 +0000 (09:32 +0000)]
topotests: python3, fix error ValueError: can't have unbuffered text I/O

This error occurs when passing some 0 values to open() extra argument.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agotopotests: python3, replace execfile with exec
Philippe Guibert [Wed, 25 Nov 2020 09:37:15 +0000 (09:37 +0000)]
topotests: python3, replace execfile with exec

python3 does not support execfile implementation.
replace it with open and exec api that are available in both python 2
and 3 implementations.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agoospfd: Prevent crash by accessing memory not owned. 7603/head
Donald Sharp [Wed, 25 Nov 2020 14:49:28 +0000 (09:49 -0500)]
ospfd: Prevent crash by accessing memory not owned.

When allocating memory for the `struct ospf_metric` we
were using `uint32_t` instead of the actual size of this
structure.  When we wrote to it we would be writing
into other people's memory.

Found-by: Amol Lad
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agoldpd: Prevent usage after free 7602/head
Donald Sharp [Wed, 25 Nov 2020 12:36:43 +0000 (07:36 -0500)]
ldpd: Prevent usage after free

We are using data after it has been freed and handed back to the
OS.
Address Sanitizer output:

error 23-Nov-2020 18:53:57 ERROR: AddressSanitizer: heap-use-after-free on address 0x631000024838 at pc 0x55f825998f58 bp 0x7fffa5b0f5b0 sp 0x7fffa5b0f5a0
error 23-Nov-2020 18:53:57 READ of size 4 at 0x631000024838 thread T0
error 23-Nov-2020 18:53:57     #0 0x55f825998f57 in lde_imsg_compose_parent_sync ldpd/lde.c:226
error 23-Nov-2020 18:53:57     #1 0x55f8259ca9ed in vlog ldpd/log.c:48
error 23-Nov-2020 18:53:57     #2 0x55f8259cb1c8 in log_info ldpd/log.c:102
error 23-Nov-2020 18:53:57     #3 0x55f82599e841 in lde_shutdown ldpd/lde.c:208
error 23-Nov-2020 18:53:57     #4 0x55f8259a2703 in lde_dispatch_parent ldpd/lde.c:666
error 23-Nov-2020 18:53:57     #5 0x55f825ac3815 in thread_call lib/thread.c:1681
error 23-Nov-2020 18:53:57     #6 0x55f825998d5e in lde ldpd/lde.c:160
error 23-Nov-2020 18:53:57     #7 0x55f82598a289 in main ldpd/ldpd.c:320
error 23-Nov-2020 18:53:57     #8 0x7fe3f749db96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
error 23-Nov-2020 18:53:57     #9 0x55f825982579 in _start (/usr/lib/frr/ldpd+0xb3579)
error 23-Nov-2020 18:53:57
error 23-Nov-2020 18:53:57 0x631000024838 is located 65592 bytes inside of 65632-byte region [0x631000014800,0x631000024860)
error 23-Nov-2020 18:53:57 freed by thread T0 here:
error 23-Nov-2020 18:53:57     #0 0x7fe3f8a4d7a8 in __interceptor_free (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xde7a8)
error 23-Nov-2020 18:53:57     #1 0x55f82599e830 in lde_shutdown ldpd/lde.c:206
error 23-Nov-2020 18:53:57     #2 0x55f8259a2703 in lde_dispatch_parent ldpd/lde.c:666
error 23-Nov-2020 18:53:57     #3 0x55f825ac3815 in thread_call lib/thread.c:1681
error 23-Nov-2020 18:53:57     #4 0x55f825998d5e in lde ldpd/lde.c:160
error 23-Nov-2020 18:53:57     #5 0x55f82598a289 in main ldpd/ldpd.c:320
error 23-Nov-2020 18:53:57     #6 0x7fe3f749db96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
error 23-Nov-2020 18:53:57
error 23-Nov-2020 18:53:57 previously allocated by thread T0 here:
error 23-Nov-2020 18:53:57     #0 0x7fe3f8a4dd28 in __interceptor_calloc (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xded28)
error 23-Nov-2020 18:53:57     #1 0x55f825998cb7 in lde ldpd/lde.c:151
error 23-Nov-2020 18:53:57     #2 0x55f82598a289 in main ldpd/ldpd.c:320
error 23-Nov-2020 18:53:57     #3 0x7fe3f749db96 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21b96)
error 23-Nov-2020 18:53:57

The fix is to put this in global space.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
4 years agoMerge pull request #7594 from ton31337/feature/show_pfxSnt_for_show_bgp_summary
Donald Sharp [Wed, 25 Nov 2020 12:02:13 +0000 (07:02 -0500)]
Merge pull request #7594 from ton31337/feature/show_pfxSnt_for_show_bgp_summary

bgpd: Show pfxSnt in JSON output for show bgp summary even if not established

4 years agoMerge pull request #7502 from AnuradhaKaruppiah/evpn-mh-irb
Patrick Ruddy [Wed, 25 Nov 2020 09:57:56 +0000 (09:57 +0000)]
Merge pull request #7502 from AnuradhaKaruppiah/evpn-mh-irb

evpn-mh: support for symmetric routing

4 years agotests: Add tests to bgp_multi_vrf_topo2 7586/head
Kuldeep Kashyap [Mon, 23 Nov 2020 04:37:55 +0000 (04:37 +0000)]
tests: Add tests to bgp_multi_vrf_topo2

1. Added 4 test cases for frr/daemon restart(chaos testing)

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
4 years agobgpd: Show pfxSnt in JSON output for show bgp summary even if not established 7594/head
Donatas Abraitis [Tue, 24 Nov 2020 08:22:01 +0000 (10:22 +0200)]
bgpd: Show pfxSnt in JSON output for show bgp summary even if not established

spine1-debian-9# show ip bgp summary json
{
"ipv4Unicast":{
  "routerId":"192.168.3.2",
  "as":200,
  "vrfId":0,
  "vrfName":"default",
  "tableVersion":4,
  "ribCount":1,
  "ribMemory":184,
  "peerCount":1,
  "peerMemory":23384,
  "peers":{
    "192.168.0.1":{
      "hostname":"exit1-debian-9",
      "remoteAs":100,
      "version":4,
      "msgRcvd":5,
      "msgSent":6,
      "tableVersion":0,
      "outq":0,
      "inq":0,
      "peerUptime":"00:00:09",
      "peerUptimeMsec":9000,
      "peerUptimeEstablishedEpoch":1606206209,
      "pfxRcd":0,
      "pfxSnt":0,
      "state":"Idle (Admin)",
      "connectionsEstablished":1,
      "connectionsDropped":1,
      "idType":"ipv4"
    }
  },
  "failedPeers":1,
  "totalPeers":1,
  "dynamicPeers":0,
  "bestPath":{
    "multiPathRelax":"false"
  }
}
}

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agoMerge pull request #7591 from opensourcerouting/isisd-bug-fixes
Donald Sharp [Wed, 25 Nov 2020 01:59:50 +0000 (20:59 -0500)]
Merge pull request #7591 from opensourcerouting/isisd-bug-fixes

isisd: assorted bug fixes

4 years agoMerge pull request #7595 from ton31337/feature/bgpState_json
Donald Sharp [Wed, 25 Nov 2020 01:55:34 +0000 (20:55 -0500)]
Merge pull request #7595 from ton31337/feature/bgpState_json

bgpd: Add peerStatus for show bgp summary json

4 years agotests : Adding 3 base ospf testcases. 7596/head
nguggarigoud [Wed, 25 Nov 2020 00:04:06 +0000 (05:34 +0530)]
tests : Adding 3 base ospf testcases.

Test suite execution time is 90 Secs.

Signed-off-by: nguggarigoud <nguggarigoud@vmware.com>
4 years agotests: add IS-IS classic LFA topotest 7590/head
Renato Westphal [Fri, 20 Nov 2020 15:43:27 +0000 (12:43 -0300)]
tests: add IS-IS classic LFA topotest

This new topotest comprises of 13 testing steps and tests essentially
all implemented LFA knobs.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
4 years agotests: add IS-IS classic LFA unit tests
Renato Westphal [Fri, 20 Nov 2020 21:35:37 +0000 (18:35 -0300)]
tests: add IS-IS classic LFA unit tests

These unit tests check the basic LFA loop-free condition on a
variety of different network topologies. None of the implemented
LFA tie-breakers are tested here.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>