Commit Graph

8549 Commits

Author SHA1 Message Date
David Lamparter
ad5c17afcd Merge pull request #972 from chiragshah6/mdev
Pim Bfd related changes
2017-08-16 19:14:08 +02:00
Martin Winter
fb13970d31 Merge pull request #985 from chiragshah6/mdev2
ospfd: Fix ospfd crash in free_nexthop
2017-08-15 20:30:23 -07:00
Donald Sharp
0dac59e943 Merge pull request #983 from opensourcerouting/vtysh-watchfrr-no-conf
vtysh: don't collect config from watchfrr
2017-08-15 11:37:15 -04:00
Quentin Young
001169e172 Merge pull request #982 from opensourcerouting/buildfix-parallel-tests-clippy
tests: fix clippy include paths / double-build
2017-08-15 11:28:37 -04:00
Chirag Shah
cd4af52574 ospfd: Fix ospfd crash in free_nexthop
Fix ANVL-OSPF-5.1 reported ospfd crash.

vertex_nexthop_free was added as valgrind reported potential
memory leak, but in some cases nexthop would not be available
freed.
The actual nexthop free is part of ospf_canonical_nexthops_free(),
upon trying to free, qfree checks mtype count becomes 0 and asserts.
Removing vertex_nexthop_free() from ospf_spf_flush_parents().

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2017-08-15 07:47:08 -07:00
David Lamparter
a23587faac vtysh: don't collect config from watchfrr
This results in some hardcoded watchfrr logging config ending up in the
integrated config otherwise.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-15 13:43:50 +02:00
David Lamparter
e2799b1d67 Merge pull request #935 from donaldsharp/kernel_metric
zebra: Pay attention to metric from kernel
2017-08-15 13:42:04 +02:00
Donald Sharp
6e5d1bf498 Merge pull request #976 from lucize/lededoc
doc: add LEDE/OpenWRT build instructions
2017-08-15 07:30:54 -04:00
David Lamparter
279f5e0934 tests: fix clippy include paths / double-build
A mismatch between the make rule and the include path causes dependency
tracking to try to build the clippy.c file twice (at the same time),
which results in spurious build failures.

Fixes: #971
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-15 11:21:07 +02:00
David Lamparter
865f5bb8cb Merge pull request #978 from devicenull/master
bgpd: Check for per-peer outbound configuration, in addition to the peer-group config
2017-08-15 11:12:15 +02:00
David Lamparter
bf30e5eaf2 Merge pull request #948 from qlyoung/fix-set-ip-next-hop-peer-address
lib, bgpd: fix `set ip next-hop peer-address`
2017-08-15 11:10:01 +02:00
David Lamparter
24fb3b1873 Merge pull request #934 from qlyoung/mac-parser
lib: add CLI token for 48-bit mac addresses
2017-08-15 11:09:15 +02:00
Brian Rak
a1e91fee4c bgpd: Check for per-peer outbound configuration, in addition to the peer-group config
When displaying the config, bgpd only checked for the existance of a peer-group prefix-list before
deciding to not display the outbound prefix-list.  This commit updates the outbound prefix-list
logic to match the inbound.
2017-08-14 17:25:12 -04:00
Lucian Cristian
1c58ed47bf doc: add LEDE/OpenWRT build instructions
Signed-off-by: Lucian Cristian <lucian.cristian@gmail.com>
2017-08-14 22:22:06 +03:00
Quentin Young
473196f613
lib, python: add M:A:C support for clippy
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-08-14 11:30:08 -04:00
Jafar Al-Gharaibeh
7e4f56d349 Merge pull request #959 from donaldsharp/pim_fixes
Pim fixes
2017-08-14 09:58:23 -05:00
Chirag Shah
df83d4e19d pimd: pim bfd vrf aware
BFD replay for all interfaces was only considering VRF_DEFAULT interface
list.
The change will walk all VRFs, interface list per VRF to register pim
neighbor with BFD.

Signed-off-by: Chirag shah <chirag@cumulusnetworks.com>
2017-08-13 17:41:01 -07:00
Chirag Shah
2fd8de7d96 pimd: Fix pim bfd config order dependecny
Upon frr restart vtysh replays pim bfd configuration
cli before pim sm command, this results in failure
of pim bfd config on the VIF as it is not pim enabled yet.
Inside pim bfd configuration, call to create PIM vif
handler if it is not created yet.
no ip pim bfd, if pim is not enabled display warning and return.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2017-08-13 17:28:11 -07:00
Donald Sharp
e514716594 Merge pull request #969 from opensourcerouting/ownership-fix
zebra: don't raise privileges when creating unix zserv socket
2017-08-12 17:37:34 -04:00
Renato Westphal
e6c1975af8 zebra: don't raise privileges when creating unix zserv socket
Raising privileges is only necessary when binding to a TCP/UDP privileged
port (< 1024).

This solves a problem where the zserv.api socket was being created with
root ownership, preventing the client daemons to connect to zebra.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2017-08-12 16:13:58 -03:00
Donald Sharp
e1768e0a6e Merge pull request #964 from opensourcerouting/plist-trie-corruption-3.0
[3.0] lib: fix prefix list trie corruption
2017-08-11 14:41:59 -04:00
Donald Sharp
c040f4804a Merge pull request #963 from opensourcerouting/plist-trie-corruption
lib: fix prefix list trie corruption
2017-08-11 14:41:43 -04:00
David Lamparter
b4e55fc5e8 lib: fix prefix list trie corruption
The specific code here needs to establish an absolute order of more
specific to less specific possible matches in a prefix list.  This is
indirectly checked by an assert on insertion, because the "next best"
entry is required to be consistent even when joining multiple chains
of candidates.

Unfortunately, trie_install_fn() would insert entries too far ahead in
the chain if another entry with higher sequence number was seen.  This
breaks the trie and (rightfully) triggers the assertion failure on
insert.

Fixes: #937
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-11 19:02:22 +02:00
David Lamparter
6ac011aaad lib: fix prefix list trie corruption
The specific code here needs to establish an absolute order of more
specific to less specific possible matches in a prefix list.  This is
indirectly checked by an assert on insertion, because the "next best"
entry is required to be consistent even when joining multiple chains
of candidates.

Unfortunately, trie_install_fn() would insert entries too far ahead in
the chain if another entry with higher sequence number was seen.  This
breaks the trie and (rightfully) triggers the assertion failure on
insert.

Fixes: #937
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-11 19:02:08 +02:00
Quentin Young
9779e3f193
lib: add CLI token for 48-bit mac addresses
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-08-11 12:42:01 -04:00
David Lamparter
fc4ecb5a5e Merge pull request #957 from chiragshah6/mdev
ospfd: fix crash due to conflicting router-id, fix MI-OSPF cli in lib commands and fix memory leaks
2017-08-11 18:28:04 +02:00
Lou Berger
518387fc66 Merge pull request #960 from opensourcerouting/vty-fixes
vty stdio & newline fixing
2017-08-11 11:30:42 -04:00
Donald Sharp
c00df11623 Merge pull request #961 from opensourcerouting/isis-fragment-fix
isisd: always link fragments to fragment #0, even when learned by CSNP
2017-08-11 10:59:08 -04:00
Donald Sharp
841dcb24d7 Merge pull request #953 from jbonor/nhrpd-fixes
nhrpd: fix issues found by coverity
2017-08-11 10:38:00 -04:00
David Lamparter
4d30c6530e Merge pull request #954 from qlyoung/bgp-declvar
bgpd: don't use DECLVAR without qobj pointer
2017-08-11 16:37:02 +02:00
Christian Franke
8f5dbe1864 isisd: always link fragments to fragment #0, even when learned by CSNP
Signed-off-by: Christian Franke <chris@opensourcerouting.org>
2017-08-11 15:53:07 +02:00
David Lamparter
eef3d03026 lib: don't close stdio when running foreground
c9c8d0d ("lib: close stdin/out/err in non-terminal case") overshot its
goal and closes stdin/stdout/stderr even when a daemon is running in
foreground.  That means stdout logging & exit memory reporting are both
broken.

Reported-by: Lou Berger <lberger@labn.net>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-11 15:45:56 +02:00
David Lamparter
2cb5980f20 bgpd: don't sidestep vty code
afi_header_vty_out is sidestepping the vty code, writing straight to the
output (either stdout or the obuf), which results in newline translation
not being performed.

Easiest fix is replacing it with a macro.  Longer-term, I have some old
code to add "prefaces" to the vty output, planning to dig that up.

Fixes: #949 ("bgpd show running doesn't show new lines")
Reported-by: Lou Berger <lberger@labn.net>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-11 15:45:38 +02:00
Donald Sharp
a7f95c7671 pimd: Remove mroute when RPF is gone
This does three things:

1) When we get a RPF_FAILURE, remove the mroute associated
with it.
   -> This way when the RPF comes back we can just add the
      mroute in as part of the normal scanning process.
2) When we do a ecmp_nexthop_search return 1 when we found
something we can use.
3) Ignore output from pim_update_rp_nh
   -> When we do a ecmp_nexthop_search ignore the return
      code and do not attempt to gather it up to return
      to the calling function.  It is just ignored
      and we were not taking into account the what of
      multiple RP's we were looking at.

Ticket: CM-17218
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-08-11 07:36:47 -04:00
Donald Sharp
8022df6a6d pimd: Single Upstream join when Keepalive timer pops
If a single S,G is being deleted because the keepalive
timer has timed out, Send a *,G join upstream to clear
the S,G RPT prune bit.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-08-11 07:36:47 -04:00
Jorge Boncompte
6b07f6e1e8 nhrpd: fixes for clang scan-build issues
Signed-off-by: Jorge Boncompte <jbonor@gmail.com>
2017-08-11 12:19:23 +02:00
Donald Sharp
72faaf7946 Merge pull request #956 from lunn/eigrpd-bandwidth
eigrpd: fix spelling of "bandwidth"
2017-08-10 19:13:19 -04:00
Donald Sharp
44fe86a340 Merge pull request #950 from LabNConsulting/working/master/patch/alt-emacs-ws-convention
Initial take on project emacs variables file and settings.
2017-08-10 18:40:36 -04:00
Andrew Lunn
b1968f83da eigrpd: fix spelling of "bandwidth"
There are a number of spelling errors in eigrp. But this one is
particular annoying because it is a variable name, not in a comment.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
2017-08-10 17:24:24 -05:00
Chirag Shah
97a69b318c ospfd: Fix conflict router-id, memory leaks
Remove assert in path of router_id_update:
Upon configuring same router-id as neighbor's
assert would cause a crash. Log a warning message
and neighborship would not come up.

Address memory leaks

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2017-08-10 15:12:19 -07:00
Chirag Shah
825d5fbf59 lib: Fix multi instance ospf
ospfd crashes upon configuring multi-instance ospf
i.e 'router ospf x'.
ospfd can return CMD_NOT_MY_INSTANCE which
is not supported in lib/commands

Support two of the error codes
CMD_NOT_MY_INSTANCE and CMD_WARNING_CONFIG_FAILED

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2017-08-10 14:59:07 -07:00
Quentin Young
87f42c2cfa
bgpd: don't use DECLVAR without qobj pointer
Since we don't actually have a BGP context until we enter into the
`router bgp` node, debugging commands which use DECLVAR before that
happens will fail. This is just `no debug bgp` and `no debug bgp
updates`. Instead just iterate over all bgp instances and do the deed.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-08-10 17:05:08 -04:00
Jorge Boncompte
6c8ca26050 nhrpd: fix issues found by coverity
Signed-off-by: Jorge Boncompte <jbonor@gmail.com>
2017-08-10 21:21:14 +02:00
Donald Sharp
c93d2f4845 Merge pull request #952 from lunn/eigrpd-nbr-timer-crash
eigrp: Don't dereference NULL timer in a Neighbour
2017-08-10 15:11:37 -04:00
Andrew Lunn
2085179b22 eigrp: Don't dereference NULL timer in a Neighbour
Current, a eigrp_neighbor only has a t_holddown timer when in state
EIGRP_NEIGHBOR_PENDING and EIGRP_NEIGHBOR_UP. In state
EIGRP_NEIGHBOR_DOWN it could be a NULL pointer. Don't dereference the
timer when dumping the neighbour table without first checking it
exists. If it does not exist, display - instead of the remaining time.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
2017-08-10 13:25:37 -05:00
Lou Berger
86036536ef Initial take on project emacs variables file and settings. Sets tabs for c-mode. 2017-08-10 14:07:28 -04:00
Quentin Young
cca30ba8a9
bgpd: add no set ip next-hop unchanged
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-08-10 12:55:32 -04:00
Quentin Young
89602edb31
lib, bgpd: fix set ip next-hop peer-address
This bgp-specific command had its positive form defined only in bgpd and
its negative form defined only in lib, which broke the whole rule for
other daemons.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-08-10 12:31:47 -04:00
David Lamparter
043abefeb2 Merge pull request #941 from dwalton76/bgpd-peer-group-rebind
bgpd: do not bounce peer when re-binding to current peer-group
2017-08-10 08:19:33 +02:00
Jafar Al-Gharaibeh
165089f104 Merge pull request #938 from LabNConsulting/working/master/patch/pr784-partial-backout
configure: restore support for --with-rfp-path= broken by PR784
2017-08-09 23:42:39 -05:00