Let's say FRR is compiled with ECMP max 16, we enter `allow-ecmp 10`, but
Zebra supports only 4.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
Before:
```
Routing Protocol is "rip"
Sending updates every 5 seconds with +/-50%, next due in 0 seconds
Timeout after 15 seconds, garbage collect after 10 seconds
Outgoing update filter list for all interface is not set
Incoming update filter list for all interface is not set
Default redistribution metric is 1
Redistributing:
Default version control: send version 2, receive any version
Interface Send Recv Key-chain
r1-eth0 2 1 2
Routing for Networks:
192.168.1.0/24
Routing Information Sources:
Gateway BadPackets BadRoutes Distance Last Update
192.168.1.2 0 0 120 00:00:05
192.168.1.3 0 0 120 00:00:04
Distance: (default is 120)
```
After:
```
Routing Protocol is "rip"
Sending updates every 5 seconds with +/-50%, next due in 4 seconds
Timeout after 15 seconds, garbage collect after 10 seconds
Outgoing update filter list for all interface is not set
Incoming update filter list for all interface is not set
Default redistribution metric is 1
Redistributing:
Default version control: send version 2, receive any version
Interface Send Recv Key-chain
r1-eth0 2 1 2
Routing for Networks:
192.168.1.0/24
Routing Information Sources:
Gateway BadPackets BadRoutes Distance Last Update
192.168.1.2 0 0 120 00:00:00
192.168.1.3 0 0 120 00:00:04
Distance: (default is 120)
```
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
Without this patch, it's never get non-passive and even listed under status:
Configuration:
```
router rip
network 192.168.1.0/24
network 10.10.10.1/32
passive-interface default
no passive-interface r2-eth0
timers basic 5 15 10
exit
```
```
r2# do sh ip rip status
Routing Protocol is "rip"
Sending updates every 5 seconds with +/-50%, next due in 4 seconds
Timeout after 15 seconds, garbage collect after 10 seconds
Outgoing update filter list for all interface is not set
Incoming update filter list for all interface is not set
Default redistribution metric is 1
Redistributing:
Default version control: send version 2, receive any version
Interface Send Recv Key-chain
lo 2 1 2
r2-eth0 2 1 2
Routing for Networks:
10.10.10.1/32
192.168.1.0/24
Passive Interface(s):
lo
r2-eth0
Routing Information Sources:
Gateway BadPackets BadRoutes Distance Last Update
192.168.1.3 0 0 120 00:00:04
Distance: (default is 120)
r2#
```
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
All the event changes exposed a bunch of places where
we were not properly following our standards. Just
clean them up in one big fell swoop.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Effectively a massive search and replace of
`struct thread` to `struct event`. Using the
term `thread` gives people the thought that
this event system is a pthread when it is not
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This is a first in a series of commits, whose goal is to rename
the thread system in FRR to an event system. There is a continual
problem where people are confusing `struct thread` with a true
pthread. In reality, our entire thread.c is an event system.
In this commit rename the thread.[ch] files to event.[ch].
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Rather than running selected source files through the preprocessor and a
bunch of perl regex'ing to get the list of all DEFUNs, use the data
collected in frr.xref.
This not only eliminates issues we've been having with preprocessor
failures due to nonexistent header files, but is also much faster.
Where extract.pl would take 5s, this now finishes in 0.2s. And since
this is a non-parallelizable build step towards the end of the build
(dependent on a lot of other things being done already), the speedup is
actually noticeable.
Also files containing CLI no longer need to be listed in `vtysh_scan`
since the .xref data covers everything. `#ifndef VTYSH_EXTRACT_PL`
checks are equally obsolete.
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
There are lib debugs being set but never show up in
`show debug` commands because there was no way to show
that they were being used. Add a bit of infrastructure
to allow this and then use it for `debug route-map`
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Let's just use THREAD_OFF consistently in the code base
instead of each daemon having a special macro that needs to
be looked at and remembered what it does.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
The entirety of this file is heavily indented. Work some coding
structure to make it easier to read and understand and not be
so heavily indented.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>