Donald Sharp [Mon, 25 Sep 2017 23:10:40 +0000 (19:10 -0400)]
tools: Fix route flush
This commit does two things:
1) Flush by proto number not string
This is useful because not all systems might have the proto
values installed, or a version of iproute2 that they might
be installed with.
2) Flush missing routes that might have been installed( eigrp
and nhrp )
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Sebastian Lohff [Wed, 4 Oct 2017 19:55:51 +0000 (21:55 +0200)]
debian: Add iproute2 as dependency alternative in Debian package
iproute has been a transitional package that only depends on iproute2
since Debian Jessie or Ubuntu 14.04. To avoid installing this transitional
dummy package on newer installations we add iproute2 as a dependency
alternative to iproute. The iproute dependency can be dropped when
wheezy / 12.04 support is no longer needed.
Signed-off-by: Sebastian Lohff <seba@someserver.de>
Renato Westphal [Tue, 3 Oct 2017 19:11:07 +0000 (16:11 -0300)]
ldpd: detach stdin/stdout/stderr from the child processes
Doing a "ssh user@node 'ldpd -d'" was making the SSH session hang. In
the original OpenBSD's ldpd(8) daemon, the daemon function takes care
of connecting stdin/stdout/stderr to /dev/null. In the FRR port, this
only happens in the frr_run() function, after all children have been
forked. Ideally we could try to rearrange libfrr.c and ldpd.c in a way
that start_child() is called only after the parent connects the standard
I/O streams to /dev/null. But since this issue needs an immediate
fix, let's do this workaround for now. Note: even when running on the
foreground, all log messages from the child processes are sent to the
parent process, which then prints the messages to stdout/stderr and/or
to a log file.
Reported-by: Martin Winter <mwinter@opensourcerouting.org> Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Renato Westphal [Tue, 3 Oct 2017 13:24:45 +0000 (10:24 -0300)]
ldpd: fix wrong indentation in the help menu
The -n option was not aligned with the other ones:
% ldpd --help
[snip]
-A, --vty_addr Set vty's bind address
-P, --vty_port Set vty's port number
--ctl_socket Override ctl socket path
-n, --instance Instance id
Chirag Shah [Mon, 2 Oct 2017 21:07:13 +0000 (14:07 -0700)]
ospfd: Fix maxage_lsa lookup key
maxage_lsa using prefix structure to store in route_table.
The lsa pointer is 4-8 bytes depending on arch, but prefix member field
would be 1 byte. Use ptr field of prefix structure to store lsa pointer.
Also memset to initialize to avoid crash on ARM platform as same LSA is
referenced from multiple times during shutdown of ospf.
Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
Donald Sharp [Mon, 2 Oct 2017 14:47:25 +0000 (10:47 -0400)]
zebra: Cleanup ptm memory *after* we tell the sockets to clean up
The zebra_ptm_finish() code was being called before the
client_list deletion. The client_list deletion is
attempting to call the ptm daemon and shut down the connection.
We should not be doing this *after* we shut down memory associated
with it as that we were writing into memory in random spots
in this case.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Donald Sharp [Mon, 2 Oct 2017 14:45:30 +0000 (10:45 -0400)]
zebra: Properly initialize memory for rtadv
The adata pointer was not properly being set to
0 before being used. In addition notice malloc
failure and hard exit. If we have no memory on
startup something terrible has gone wrong and
we were going to crash shortly here anyways.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
ldpd: add more filtering options in some "show" commands
Being able to filter the output of some "show" commands is super useful
when troubleshooting large MPLS networks.
Examples:
% show mpls ldp ipv4 binding 10.0.0.48/29 longer-prefixes neighbor 192.168.0.5
AF Destination Nexthop Local Label Remote Label In Use
ipv4 10.0.0.48/30 192.168.0.5 24 26 no
ipv4 10.0.0.52/30 192.168.0.5 25 27 no
Quentin Young [Thu, 28 Sep 2017 18:01:05 +0000 (14:01 -0400)]
vtysh: more multi-instance fixing
Preexisting code to detect commands targeted at wrong instance didn't
work because a command applied to a disconnected vtysh_client counted as
a successful run overriding wrong instance error message
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Donald Sharp [Thu, 28 Sep 2017 12:05:20 +0000 (08:05 -0400)]
pimd: Add 'show ip mroute fill' command
When displaying the mroute table, add ability to fill
in all the missing data that for human eyes can be assumed.
This will allow people using grep over the command
can get more information.
Quentin Young [Wed, 27 Sep 2017 02:41:47 +0000 (22:41 -0400)]
vtysh: remove extra / in config path
before:
frrdev# do wr
Note: this version of vtysh never writes vtysh.conf
Building Configuration...
Integrated configuration saved to /etc/frr//frr.conf
[OK]
frrdev#
after:
frrdev# do wr
Note: this version of vtysh never writes vtysh.conf
Building Configuration...
Integrated configuration saved to /etc/frr/frr.conf
[OK]
frrdev#
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Donald Sharp [Wed, 27 Sep 2017 00:06:13 +0000 (20:06 -0400)]
bgpd: Reduce multiaccess_check_v4 overhead for subgroups
Perf results at scale( >1k peers) showed a non-trivial
amount of time spent in bgp_multiaccess_check_v4. Upon
function examination we are looking up the nexthops
connected node in each call as well as having to unlock
it after each iteration. Rewrite to lookup the nexthop
node once.
This should reduce the node lookup by aproximately 1/2
which should yield some performance results. There are
probably better things to do here but would require
deeper thought.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Donald Sharp [Tue, 26 Sep 2017 23:46:02 +0000 (19:46 -0400)]
zebra: Fix irdp so it doesn't crash when looked at
irdp is crashing because it assumes that people have
configured it in a certain way. Ensure that this
'way' is honored at least enough so that we don't
crash.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Donald Sharp [Tue, 26 Sep 2017 20:28:08 +0000 (16:28 -0400)]
vtysh: Remove double display of daemon info for 'show debugging'
When entering 'show debugging' we were outputting a line
from vtysh and a line from an individual daemon to show
the fact we were debugging. A bit overkill.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Quentin Young [Fri, 1 Sep 2017 18:33:00 +0000 (14:33 -0400)]
pimd: add support for boundaries
Adds the ability to filter PIM Joins & IGMP reports on an interface.
Enabling a multicast boundary on an interface for a particular group
will prevent the interface from appearing in the group's OIL.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>