]> git.proxmox.com Git - mirror_frr.git/log
mirror_frr.git
6 years agobgpd: add show bgp vrf all l2vpn evpn summary as an option
Mitesh Kanjariya [Mon, 19 Feb 2018 08:57:54 +0000 (00:57 -0800)]
bgpd: add show bgp vrf all l2vpn evpn summary as an option

Ticket: CM-19738
Review: CCR-7194
Testing: Manual

Signed-off-by: Mitesh Kanjariya <mitesh@cumulusnetworks.com>
6 years agoMerge pull request #1750 from donaldsharp/zebra_other_tables
Renato Westphal [Tue, 27 Feb 2018 00:29:57 +0000 (21:29 -0300)]
Merge pull request #1750 from donaldsharp/zebra_other_tables

Zebra other tables

6 years agoMerge pull request #1795 from qlyoung/vtysh-history-q2f
Renato Westphal [Tue, 27 Feb 2018 00:16:13 +0000 (21:16 -0300)]
Merge pull request #1795 from qlyoung/vtysh-history-q2f

vtysh: .history_quagga --> .history_frr

6 years agoMerge pull request #1793 from qlyoung/stylechecker
Philippe Guibert [Sat, 24 Feb 2018 06:24:06 +0000 (07:24 +0100)]
Merge pull request #1793 from qlyoung/stylechecker

Miscellaneous checkpatch fixes & improvements

6 years agoMerge pull request #1796 from donaldsharp/32_silliness
Martin Winter [Fri, 23 Feb 2018 21:52:42 +0000 (13:52 -0800)]
Merge pull request #1796 from donaldsharp/32_silliness

pimd: Fix some compiler issues

6 years agovtysh: .history_quagga --> .history_frr
Quentin Young [Fri, 23 Feb 2018 17:40:57 +0000 (12:40 -0500)]
vtysh: .history_quagga --> .history_frr

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
6 years agoMerge branch 'master' into stylechecker
Quentin Young [Fri, 23 Feb 2018 16:21:42 +0000 (11:21 -0500)]
Merge branch 'master' into stylechecker

6 years agotools: finer-grained error codes for checkpatch
Quentin Young [Fri, 23 Feb 2018 15:58:17 +0000 (10:58 -0500)]
tools: finer-grained error codes for checkpatch

* 2 for errors
* 1 for warnings
* 0 for clean
* Suppress all report text for a clean result
* Remove check for const structs from perl script
* Remove grep suppression for that check from shell script

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
6 years agotools: ignore FSF warning, fn macros in checkpatch
Quentin Young [Fri, 23 Feb 2018 15:11:19 +0000 (10:11 -0500)]
tools: ignore FSF warning, fn macros in checkpatch

* Unlike Linux we do require the GPL file header
* When checking for spaces between function names and parentheses,
  ignore all-uppercase function names as these are likely to be macros,
  and function-like macros may have that space

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
6 years agoMerge pull request #1792 from pguibert6WIND/issue_1786
Quentin Young [Fri, 23 Feb 2018 15:04:07 +0000 (10:04 -0500)]
Merge pull request #1792 from pguibert6WIND/issue_1786

tools: fix that filters issues on resulting file only

6 years agotools: fix that filters issues on resulting file only
Philippe Guibert [Fri, 23 Feb 2018 15:16:30 +0000 (16:16 +0100)]
tools: fix that filters issues on resulting file only

Because checkpatch result is applied to original and new file, the
analysis also parses what may be wrong with the original file.
Whereas the script should limit to analyse only what is wrong on new
file.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
6 years agozebra: Fix up some code formatting issues.
Donald Sharp [Fri, 23 Feb 2018 12:50:23 +0000 (07:50 -0500)]
zebra: Fix up some code formatting issues.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: Fix warning found in CI system
Donald Sharp [Sun, 18 Feb 2018 22:23:50 +0000 (17:23 -0500)]
zebra: Fix warning found in CI system

The Clang SA system found a new issue:

Dead store: Dead assignment.

This fixes that issue

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years ago*: Make assignment from RB_ROOT in while loop work better
Donald Sharp [Sun, 18 Feb 2018 00:02:55 +0000 (19:02 -0500)]
*: Make assignment from RB_ROOT in while loop work better

Fix up the assignment of the variable = RB_ROOT inside of
while loop patter we were using.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: On shutdown don't count removals
Donald Sharp [Fri, 16 Feb 2018 02:33:22 +0000 (21:33 -0500)]
zebra: On shutdown don't count removals

Some of the tables are no longer stored in the zvrf
and in the zns now.  On shutdown zns is cleaned up
after vrf( and rightly so!) As such we should not
attempt to count the information if we don't have
a zvrf.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: Add code to display interesting tables
Donald Sharp [Wed, 14 Feb 2018 03:38:47 +0000 (22:38 -0500)]
zebra: Add code to display interesting tables

With the ability of zebra to handle random tables,
add code to display those tables via the
show <ip|ipv6> route table (1-...) [json] command.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: Allow table creation for tables greater than 252
Donald Sharp [Wed, 14 Feb 2018 01:29:38 +0000 (20:29 -0500)]
zebra: Allow table creation for tables greater than 252

The linux kernel allows a vast expanse of tables to be used.
It would be useful for zebra to track these tables if they
are being used.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: Move zvrf->other_tables into zns
Donald Sharp [Wed, 14 Feb 2018 01:25:11 +0000 (20:25 -0500)]
zebra: Move zvrf->other_tables into zns

The other_tables data structure does not belong to a vrf.
It belongs to the zns.  This is because each vrf does not
need to have copies of each of other_tables.

Additionally move the array into a RB_TREE.  This will allow
us to sort quickly and easily expand the number of tables
we can support to beyond the ZEBRA_KERNEL_TABLE_MAX define.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agopimd: Fix some compiler issues
Donald Sharp [Fri, 23 Feb 2018 07:07:47 +0000 (02:07 -0500)]
pimd: Fix some compiler issues

Fix some compiler issues that were not picked up.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1723 from chiragshah6/ospf_vrf_dev
Rafael Zalamena [Thu, 22 Feb 2018 20:24:35 +0000 (17:24 -0300)]
Merge pull request #1723 from chiragshah6/ospf_vrf_dev

ospfd: fix ospf interface and neighbor json

6 years agoMerge pull request #1756 from qlyoung/stylechecker
Philippe Guibert [Thu, 22 Feb 2018 17:55:48 +0000 (18:55 +0100)]
Merge pull request #1756 from qlyoung/stylechecker

tools: improve checkpatch.sh

6 years agotools: improve checkpatch.sh
Quentin Young [Thu, 15 Feb 2018 18:37:03 +0000 (13:37 -0500)]
tools: improve checkpatch.sh

* Send reports to stderr; this allows you to get just the end result by
  redirecting stderr
* Don't attempt to copy nonexistent files

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
6 years agoMerge pull request #1749 from msablic/pim_mtrace_cc
Donald Sharp [Thu, 22 Feb 2018 13:15:38 +0000 (08:15 -0500)]
Merge pull request #1749 from msablic/pim_mtrace_cc

pimd: Multicast traceroute client and router

6 years agoMerge pull request #1730 from Orange-OpenSource/master
Russ White [Tue, 20 Feb 2018 12:11:58 +0000 (07:11 -0500)]
Merge pull request #1730 from Orange-OpenSource/master

ospfd: Fix ospfd crash

6 years agoMerge pull request #1757 from dwalton76/bgpd-remove-peer-in-peergroup
Russ White [Tue, 20 Feb 2018 12:01:17 +0000 (07:01 -0500)]
Merge pull request #1757 from dwalton76/bgpd-remove-peer-in-peergroup

bgpd: "no neighbor 10.13.0.12 peer-group ibgp" does not remove peer

6 years agoMerge pull request #1766 from donaldsharp/label_label_label
Russ White [Tue, 20 Feb 2018 11:58:01 +0000 (06:58 -0500)]
Merge pull request #1766 from donaldsharp/label_label_label

zebra: implement recursive MPLS labels

6 years agoMerge pull request #1732 from ak503/set_metric
Russ White [Tue, 20 Feb 2018 11:49:15 +0000 (06:49 -0500)]
Merge pull request #1732 from ak503/set_metric

ospfd: OSPF support the +/- in set metric <+/-metric>

6 years agopimd: Multicast traceroute client and router
Mladen Sablic [Mon, 12 Feb 2018 22:41:33 +0000 (23:41 +0100)]
pimd: Multicast traceroute client and router

This commit is the implementation of weak multicast traceroute.
It consists of IGMP module dealing with mtrace type IGMP messages
and client program mtrace/mtracebis for initiating mtrace queries.

Signed-off-by: Mladen Sablic <mladen.sablic@gmail.com>
6 years agoMerge pull request #1765 from donaldsharp/sa_stuff
Rafael Zalamena [Mon, 19 Feb 2018 20:23:49 +0000 (17:23 -0300)]
Merge pull request #1765 from donaldsharp/sa_stuff

Sa stuff

6 years agozebra: implement recursive MPLS labels
Renato Westphal [Wed, 20 Sep 2017 03:05:25 +0000 (00:05 -0300)]
zebra: implement recursive MPLS labels

When a BGP-labeled route is resolved into an LDP-labeled IGP route,
zebra would install it with no labels in the kernel. This patch implements
recursive MPLS labels, i.e. make zebra install all labels from the route's
nexthop chain (the labels from the top-level nexthop being installed in
the top of the MPLS label stack). Multiple recursion levels are supported.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
6 years agobgpd: Fix value set but never used
Donald Sharp [Sat, 17 Feb 2018 19:59:32 +0000 (14:59 -0500)]
bgpd: Fix value set but never used

The value 'pnt' was being set but never used.  If we need
this in the future it will be a simple thing to add back
in.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoisisd: Remove impossible check
Donald Sharp [Sat, 17 Feb 2018 19:52:44 +0000 (14:52 -0500)]
isisd: Remove impossible check

The circuit->area value is always true in every code path
to isis_circuit_af_set( isis_vty.c ).  Therefore was_enabled
will always be true.

If was_enabled ever became false then the area->ip_circuits
and area->ipv6_circuits lines would segfault.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1745 from mkanjari/type5-route-policy
Russ White [Fri, 16 Feb 2018 22:23:25 +0000 (17:23 -0500)]
Merge pull request #1745 from mkanjari/type5-route-policy

bgpd: Policy to control which RIB routes are injected into EVPN

6 years agoMerge pull request #1761 from pguibert6WIND/issue_1760
Lou Berger [Fri, 16 Feb 2018 18:58:32 +0000 (12:58 -0600)]
Merge pull request #1761 from pguibert6WIND/issue_1760

bgpd: prevent from configuring vrf-policy when in BGP VRF instance

6 years agoMerge pull request #1753 from donaldsharp/afi_vrf_label
Lou Berger [Fri, 16 Feb 2018 18:36:08 +0000 (12:36 -0600)]
Merge pull request #1753 from donaldsharp/afi_vrf_label

lib, sharpd, zebra: Update the zapi_vrf_label call to add afi

6 years agobgpd: prevent from configuring vrf-policy when in BGP VRF instance
Philippe Guibert [Fri, 16 Feb 2018 10:00:01 +0000 (11:00 +0100)]
bgpd: prevent from configuring vrf-policy when in BGP VRF instance

Under a BGP VRF instance, prevent from entering in vrf-policy mode. This
mode is reserved for non VRF instances that want to handle several VRF
at the same time.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
6 years agobgpd: "no neighbor 10.13.0.12 peer-group ibgp" does not remove peer
Daniel Walton [Thu, 15 Feb 2018 20:55:43 +0000 (20:55 +0000)]
bgpd: "no neighbor 10.13.0.12 peer-group ibgp" does not remove peer

Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
This worked for unnumbered peers but not for numbered peers. This is
before the fix:

router bgp 100
 coalesce-time 1000
 neighbor FOO peer-group
 neighbor FOO remote-as external
 neighbor swp1 interface peer-group FOO
 neighbor 1.1.1.1 peer-group FOO
!
line vty
 exec-timeout 0 0
!
end
cel-redxp-10# wr
Note: this version of vtysh never writes vtysh.conf
Building Configuration...
Integrated configuration saved to /etc/frr/frr.conf
[OK]
cel-redxp-10# conf t
cel-redxp-10(config)# router bgp
cel-redxp-10(config-router)# no neighbor swp1 interface peer-group FOO
cel-redxp-10(config-router)# no neighbor 1.1.1.1 peer-group FOO
cel-redxp-10(config-router)# do show run
Building configuration...

Current configuration:
!
frr version 4.1-dev
frr defaults datacenter
hostname cel-redxp-10
!
service integrated-vtysh-config
!
password cn321
!
log syslog
!
router bgp 100
 coalesce-time 1000
 neighbor FOO peer-group
 neighbor FOO remote-as external
 neighbor 1.1.1.1 remote-as external
 !
 address-family ipv4 unicast
  no neighbor 1.1.1.1 activate
 exit-address-family
!
line vty
 exec-timeout 0 0
!
end
cel-redxp-10(config-router)#

After the fix "no neighbor 1.1.1.1 peer-group FOO" removes the 1.1.1.1
neighbor.

6 years agoMerge pull request #1755 from donaldsharp/install_it_tar
Jafar Al-Gharaibeh [Thu, 15 Feb 2018 20:42:48 +0000 (14:42 -0600)]
Merge pull request #1755 from donaldsharp/install_it_tar

sharpd: Add ability to build from tarball

6 years agoMerge pull request #1754 from chiragshah6/ospfv3_dev
Jafar Al-Gharaibeh [Thu, 15 Feb 2018 20:39:09 +0000 (14:39 -0600)]
Merge pull request #1754 from chiragshah6/ospfv3_dev

ospf6d: Router-ID change notify to restart ospf6d

6 years agoMerge pull request #1752 from donaldsharp/coverity_1
Jafar Al-Gharaibeh [Thu, 15 Feb 2018 20:38:18 +0000 (14:38 -0600)]
Merge pull request #1752 from donaldsharp/coverity_1

Coverity 1

6 years agoMerge pull request #1742 from chiragshah6/mdev
Jafar Al-Gharaibeh [Thu, 15 Feb 2018 20:30:06 +0000 (14:30 -0600)]
Merge pull request #1742 from chiragshah6/mdev

ospf(6)d: Fix distance option command

6 years agosharpd: Add ability to build from tarball
Donald Sharp [Thu, 15 Feb 2018 18:35:10 +0000 (13:35 -0500)]
sharpd: Add ability to build from tarball

Since sharpd is only typically built with a development build
this was not noticed.  Add the necessary headers to build
this thingie(tm).

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: Ensure unconfiguration works properly for vrf labels
Donald Sharp [Thu, 15 Feb 2018 18:52:57 +0000 (13:52 -0500)]
zebra: Ensure unconfiguration works properly for vrf labels

If you were to configure a v4 and v6 vrf pop and forward label
that both happened to be the same, unconfiguring one would
remove them both.

This fixes that issue by noticing if we should remove it or
not based upon v4 or v6 having the same label or not.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoospf6d: router-id change notify to restart ospf6d
Chirag Shah [Mon, 12 Feb 2018 21:22:04 +0000 (13:22 -0800)]
ospf6d: router-id change notify to restart ospf6d

Notify user to store config and restart ospf6d
as part of router-id change cli if any of
the area active.
Store zebra router-id under ospf6, when static
router-id removed restore zebra router-id, ask
to restart ospf6d.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
6 years agoMerge pull request #1738 from chiragshah6/ospfv3_dev
Olivier Dugeon [Thu, 15 Feb 2018 16:17:38 +0000 (17:17 +0100)]
Merge pull request #1738 from chiragshah6/ospfv3_dev

ospf6d: Handle Premature Aging of LSAs

6 years agoospf6d: Handle Premature Aging of LSAs
Chirag Shah [Fri, 26 Jan 2018 22:53:43 +0000 (14:53 -0800)]
ospf6d: Handle Premature Aging of LSAs

RFC 2328 (14.1) Premature aging of LSAs from
routing domain :
When ospf6d is going away (router going down),
send MAXAGEd self originated LSAs to all
neighbors in routing domain to trigger
Premature aging to remove from resepective LSDBs.

Neighbor Router Reboot:
Upon receiving Self-originate MAXAGEd LSA, simply
discard, Current copy could be non maxaged latest.

For neighbor advertised LSA's (current copy in LSDB)
is set to MAXAGE but received new LSA with Non-MAXAGE
(with current age), discard the current MAXAGE LSA,
Send latest copy of LSA to neighbors and update the
LSDB with new LSA.

When a neighbor transition to FULL, trigger AS-External
LSAs update from external LSDB to new neighbor.

Testing:
R1 ---- DUT --- R5
| \
R2 R3
|
R4

Area 1: R5 and DUT
Area 0: DUT, R1, R2, R3
Area 2: R2 R4

Add IPv6 static routes at R5
Redistribute kernel routes at R5,
Validate routes at R4, redistributed via backbone
to area 2.
Stop n start frr.service at R5 and validated
MAXAGE LSAs then recent age LSAs in Database at DUT-R4.
Validated external routes installed DUT to R4.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
6 years agoisisd: Free up some memory allocated.
Donald Sharp [Sat, 10 Feb 2018 19:03:09 +0000 (14:03 -0500)]
isisd: Free up some memory allocated.

The v4 and v6 prefixes were created but not deleted on
shutdown properly.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
(cherry picked from commit 25b1001dc9c46bbfcb9e1af8231e0fa63a7d3bd3)
Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
6 years agolib, sharpd, zebra: Update the zapi_vrf_label call to add afi
Donald Sharp [Wed, 14 Feb 2018 06:11:09 +0000 (01:11 -0500)]
lib, sharpd, zebra: Update the zapi_vrf_label call to add afi

Add the ability to pass in an afi to zebra.  zebra_vrf keeps
track of the afi/label tuple and then does the right thing
before we call down.  AF_MPLS does not care about v4 or v6
it just knows label and what device to use for lookup.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: Clean up some SA issues found by new code
Donald Sharp [Wed, 14 Feb 2018 04:39:09 +0000 (23:39 -0500)]
zebra: Clean up some SA issues found by new code

1) Add asserts in a couple of spots to show we
never expect prefix to be bad.
2) Fix some bfd code where out_ctxt will
always be NULL.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoospfd: Fix some new SA issues found by coverity
Donald Sharp [Wed, 14 Feb 2018 04:37:08 +0000 (23:37 -0500)]
ospfd: Fix some new SA issues found by coverity

Fix a || && mixup.
Add an assert for area to show we expect it to be non-null
going forward.
When memory is allocated if it fails we abort then
no need to check for null.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoospf6d: Fix a possible deref by null found in SA
Donald Sharp [Wed, 14 Feb 2018 04:34:52 +0000 (23:34 -0500)]
ospf6d: Fix a possible deref by null found in SA

There exists a possibility that rtr_lsa may be null.
Add an assert that shows we actually expect it to
be non-null at this point in time going forward.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1701 from donaldsharp/zapi_vrf_label
Martin Winter [Wed, 14 Feb 2018 03:05:42 +0000 (19:05 -0800)]
Merge pull request #1701 from donaldsharp/zapi_vrf_label

Zapi vrf label

6 years agoMerge pull request #1734 from donaldsharp/control_me
Martin Winter [Tue, 13 Feb 2018 16:49:55 +0000 (08:49 -0800)]
Merge pull request #1734 from donaldsharp/control_me

debianpkg: Update build dependencies to say we don't co-exist with qu…

6 years agoMerge pull request #1683 from donaldsharp/doc_debian
Martin Winter [Tue, 13 Feb 2018 16:39:39 +0000 (08:39 -0800)]
Merge pull request #1683 from donaldsharp/doc_debian

doc: Fix Debian 9 build instructions

6 years agobgpd: Policy to control which RIB routes are injected into EVPN
Mitesh Kanjariya [Fri, 9 Feb 2018 09:09:20 +0000 (01:09 -0800)]
bgpd: Policy to control which RIB routes are injected into EVPN

FRR/CL provides the means for injecting regular (IPv4) routes
from the BGP RIB into EVPN as type-5 routes.
This needs to be enhanced to allow selective injection.
This can be achieved by adding a route-map option
for the "advertise ipv4/ipv6 unicast" command.

Signed-off-by: Mitesh Kanjariya <mitesh@cumulusnetworks.com>
6 years agoospfd: Fix distance command
Chirag Shah [Mon, 12 Feb 2018 04:27:43 +0000 (20:27 -0800)]
ospfd: Fix distance command

Reset prevoiusly configured distance command options
if user enters new (different) parameters.

Ticket:CM-19635
Testing Done:

R1(config-router)# distance ospf intra-area 45 external 45
R1# show running-config ospfd
router ospf
 distance ospf intra-area 45 external 45

R1(config-router)# distance ospf inter-area 45
R1# show running-config ospfd
router ospf
 distance ospf inter-area 45

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
6 years agoospf6d: Fix distance command
Chirag Shah [Mon, 12 Feb 2018 04:17:11 +0000 (20:17 -0800)]
ospf6d: Fix distance command

Reset prevoiusly configured distance command options
if user enters new (different) parameters.

Ticket:CM-19635
Reviewed By:
Testing Done:

R1(config-ospf6)# distance ospf6 intra-area 55 external 55
R1#show running-config ospf6d
router ospf6
 distance ospf6 intra-area 55 external 55

R1(config-ospf6)# distance ospf6 inter-area 55
R1#show running-config ospf6d
router ospf6
 distance ospf6 inter-area 55

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
6 years agoMerge pull request #1735 from LabNConsulting/working/master/pre-vpn-vrf-leak-indenting
Donald Sharp [Sat, 10 Feb 2018 14:24:40 +0000 (09:24 -0500)]
Merge pull request #1735 from LabNConsulting/working/master/pre-vpn-vrf-leak-indenting

Working/master/pre vpn vrf leak indenting

6 years agoMerge pull request #1737 from mkanjari/build-failure
Donald Sharp [Sat, 10 Feb 2018 01:53:03 +0000 (20:53 -0500)]
Merge pull request #1737 from mkanjari/build-failure

zebra: fix build breakage

6 years agozebra: fix build breakage
mitesh [Sat, 10 Feb 2018 00:57:37 +0000 (16:57 -0800)]
zebra: fix build breakage

is_vni_l3 was removed as a part of PR1700. However, it seems to be used in master.
Causing the breakage. Made the changes to not use the API anymore.

Signed-off-by: Mitesh Kanjariya <mitesh@cumulusnetworks.com>
6 years agoMerge pull request #1719 from donaldsharp/rip_split_fuckery
Renato Westphal [Sat, 10 Feb 2018 00:07:02 +0000 (22:07 -0200)]
Merge pull request #1719 from donaldsharp/rip_split_fuckery

ripd: Fix crash when ip rip split-horizon poisoned-reverse is configed

6 years agoMerge pull request #1731 from donaldsharp/zebra_stuff
Renato Westphal [Sat, 10 Feb 2018 00:01:12 +0000 (22:01 -0200)]
Merge pull request #1731 from donaldsharp/zebra_stuff

zebra: sharp protocol needs a default admin distance.

6 years agoMerge pull request #1700 from mkanjari/evpn-symm-routing-enhancements-2.0
Renato Westphal [Fri, 9 Feb 2018 23:20:27 +0000 (21:20 -0200)]
Merge pull request #1700 from mkanjari/evpn-symm-routing-enhancements-2.0

EVPN Symmetric routing enhancements 2.0

6 years agoMerge pull request #1722 from donaldsharp/vrf_mc_vrf
Renato Westphal [Fri, 9 Feb 2018 22:54:17 +0000 (20:54 -0200)]
Merge pull request #1722 from donaldsharp/vrf_mc_vrf

zebra: Fix vrf routes from assuming their nh's were in the default

6 years agowhitespace/comment fixes per qlyoung
G. Paul Ziemba [Fri, 9 Feb 2018 21:14:22 +0000 (13:14 -0800)]
whitespace/comment fixes per qlyoung

Signed-off-by: G. Paul Ziemba <paulz@labn.net>
6 years agobgpd: ran indent.py on some files prior to bgp vpn-vrf leaking changes
G. Paul Ziemba [Fri, 9 Feb 2018 18:22:50 +0000 (10:22 -0800)]
bgpd: ran indent.py on some files prior to bgp vpn-vrf leaking changes

Signed-off-by: G. Paul Ziemba <paulz@labn.net>
6 years agoalso protect ALIAS from indenting
G. Paul Ziemba [Fri, 9 Feb 2018 18:18:35 +0000 (10:18 -0800)]
also protect ALIAS from indenting

Signed-off-by: G. Paul Ziemba <paulz@labn.net>
6 years agoMerge branch 'working/master/json-bgp-vpn-fixes' of https://github.com/LabNConsulting...
G. Paul Ziemba [Fri, 9 Feb 2018 17:40:25 +0000 (09:40 -0800)]
Merge branch 'working/master/json-bgp-vpn-fixes' of https://github.com/LabNConsulting/frr into working/master/json-bgp-vpn-fixes

6 years agobgpd: json route table brace counting
G. Paul Ziemba [Fri, 9 Feb 2018 17:29:39 +0000 (09:29 -0800)]
bgpd: json route table brace counting

Signed-off-by: G. Paul Ziemba <paulz@labn.net>
6 years agobgpd: json route table brace counting
G. Paul Ziemba [Fri, 9 Feb 2018 17:29:39 +0000 (09:29 -0800)]
bgpd: json route table brace counting

6 years agoospfd: OSPF support the +/- in set metric <+/-metric>
dturlupov [Fri, 9 Feb 2018 14:10:22 +0000 (17:10 +0300)]
ospfd: OSPF support the +/- in set metric <+/-metric>

Signed-off-by: Dmitrii Turlupov <dturlupov@factor-rs.ru>
6 years agoospfd: Fix ospfd crash
Olivier Dugeon [Fri, 9 Feb 2018 11:13:07 +0000 (12:13 +0100)]
ospfd: Fix ospfd crash

 - ospfd/ospf_opaque.c: Update issue #1652 by introducing a new
function 'free_opaque_info_owner()' to clean list of callback owner
and call this function in appropriate place where 'listdelete_and_null'
is not used.

 - ospfd/ospf_packet.c: In case of crash, ospfd is not been able to
flush LSA. In case of self Opaque LSA, when restarting, ospfd crash
during the resynchronisation process with its neighbor due to an
empty list of LSA to flood. Just add a control on the list count
in 'ospf_ls_upd_queue_send()' to escape the function and avoid the
problem.

Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
6 years agozebra: Use appropriate output function for label printing
Donald Sharp [Fri, 9 Feb 2018 00:51:37 +0000 (19:51 -0500)]
zebra: Use appropriate output function for label printing

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agobgpd, lib, sharpd, zebra: Use MPLS_LABEL_NONE
Donald Sharp [Thu, 8 Feb 2018 15:19:34 +0000 (10:19 -0500)]
bgpd, lib, sharpd, zebra: Use MPLS_LABEL_NONE

Modify mpls.h to rename MPLS_LABEL_ILLEGAL to be MPLS_LABEL_NONE.
Fix all pre-existing code that used MPLS_LABEL_ILLEGAL.

Modify the zapi vrf label message to use MPLS_LABEL_NONE as the
signal to remove label associated with a vrf.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agolib, sharpd, zebra: Add new enum for lsp type and pass it through.
Donald Sharp [Thu, 8 Feb 2018 14:50:32 +0000 (09:50 -0500)]
lib, sharpd, zebra: Add new enum for lsp type and pass it through.

Add the ability to pass the lsp owner type through the zapi
and in addition add a new label type for the sharp protocol
for testing.

Finally modify zebra_mpls.h to not have defaults specified
for the enum.  That way when we add a new LSP type the
compile fails and the person doing the addition knows
where he has to touch shit.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years ago*: Make code use a consisten definition of labels
Donald Sharp [Wed, 31 Jan 2018 23:24:06 +0000 (18:24 -0500)]
*: Make code use a consisten definition of labels

Turns out we had 3 different ways to define labels
all of them overlapping with the same meanings.
Consolidate to 1.  This one choosen is consistent
naming wise with what the *bsd and linux kernels
use.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: Cleanup mpls handling to allow a NEXTHOP_TYPE_IFINDEX
Donald Sharp [Wed, 31 Jan 2018 21:29:24 +0000 (16:29 -0500)]
zebra: Cleanup mpls handling to allow a NEXTHOP_TYPE_IFINDEX

Add the ability for the nexthops to be a NEXTHOP_TYPE_IFINDEX.
Since we are using this code for L3vpn pop and forward operations
and we know that the lo or vrf device name must exist we
trust that it is correct.

Update display to show the correct data with a 'show mpls table'

Update the mpls install into the kernel to treat
NEXTHOP_TYPE_IFINDEX as special and we do not need
to pass in the nexthop label.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agosharpd: Consolidate commands under 'sharp' keyword
Donald Sharp [Tue, 30 Jan 2018 18:59:51 +0000 (13:59 -0500)]
sharpd: Consolidate commands under 'sharp' keyword

The commands if not careful needed a way to isolate
themselves from each other and 'real' system commands
so let's put them under the sharp keyword.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agosharpd: Add some infrastructure to allow test of ZEBRA_VRF_LABEL
Donald Sharp [Tue, 30 Jan 2018 18:54:38 +0000 (13:54 -0500)]
sharpd: Add some infrastructure to allow test of ZEBRA_VRF_LABEL

Add some infrastructure to allow the testing of ZEBRA_VRF_LABEL

Signed-off-by: Donald Sharp <sharp@cumulusnetworks.com>
6 years agolib, zebra: Add new api to specify a label associated with the vrf
Donald Sharp [Tue, 30 Jan 2018 18:30:36 +0000 (13:30 -0500)]
lib, zebra: Add new api to specify a label associated with the vrf

For L3VPN's we need to create a label associated with the specified
vrf to be installed into the kernel to allow a pop and lookup
operation.

The new api is:
zclient_send_vrf_label(struct zclient *zclient, vrf_id_t vrf_id,
                       mpls_label_t label);

For the specified vrf_id associate the specified label for
a pop and lookup operation for forwarding.

To setup a POP and Forward use MPLS_LABEL_IMPLICIT_NULL
If the same label is passed in we ignore the call.
If the label is different we update entry.
If the label is MPLS_LABEL_NONE we remove
the entry.

This sets up the api.  Future commits will have the functionality
to actually install into the kernel.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agolib, zebra: Move nh_resolve_via_default to appropriate header
Donald Sharp [Wed, 24 Jan 2018 20:35:37 +0000 (15:35 -0500)]
lib, zebra: Move nh_resolve_via_default to appropriate header

The nh_resolve_via_default function is an accessor function
for NHT in zebra.  Let's move this function to it's proper
place.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years ago*: Track vrfs per nexthop not per route entry
Donald Sharp [Thu, 8 Feb 2018 14:12:12 +0000 (09:12 -0500)]
*: Track vrfs per nexthop not per route entry

Track the vfrs on a per nexthop basis instead
of on a per route entry basis.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agozebra: sharp protocol needs a default admin distance.
Donald Sharp [Fri, 9 Feb 2018 00:30:34 +0000 (19:30 -0500)]
zebra: sharp protocol needs a default admin distance.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1720 from qlyoung/gitignore-changelog
Jafar Al-Gharaibeh [Thu, 8 Feb 2018 20:32:29 +0000 (14:32 -0600)]
Merge pull request #1720 from qlyoung/gitignore-changelog

debianpkg: .gitignore += changelog

6 years agodebianpkg: Update build dependencies to say we don't co-exist with quagga
Donald Sharp [Thu, 8 Feb 2018 18:51:04 +0000 (13:51 -0500)]
debianpkg: Update build dependencies to say we don't co-exist with quagga

The control files for all build platforms are not consistent.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1654 from mkanjari/evpn-symm-routing-enhancements
Philippe Guibert [Thu, 8 Feb 2018 10:46:29 +0000 (11:46 +0100)]
Merge pull request #1654 from mkanjari/evpn-symm-routing-enhancements

Evpn symmetric routing enhancements

6 years agoospfd: fix ospf interface and neighbor json
Chirag Shah [Thu, 8 Feb 2018 00:28:09 +0000 (16:28 -0800)]
ospfd: fix ospf interface and neighbor json

show ip ospf [vrf all] interface json and
show ip ospf [vrf all] neighbor json to display
objects in dictionary output rather in array list.

Ticket:CM-19115,CM-19097

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
6 years agozebra: Fix vrf routes from assuming their nh's were in the default
Donald Sharp [Wed, 7 Feb 2018 23:22:15 +0000 (18:22 -0500)]
zebra: Fix vrf routes from assuming their nh's were in the default

Fix the read in of vrf routes on a start or restart that caused
the nexthop_vrf to be assumed to be the default vrf.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1721 from opensourcerouting/isis-monitor-fds
Donald Sharp [Wed, 7 Feb 2018 19:35:08 +0000 (14:35 -0500)]
Merge pull request #1721 from opensourcerouting/isis-monitor-fds

isis: use descriptor polling instead of time

6 years agoisis: use descriptor polling instead of time
Rafael Zalamena [Wed, 7 Feb 2018 18:26:25 +0000 (16:26 -0200)]
isis: use descriptor polling instead of time

Allow other supported Operating Systems (OS) to use file descriptor
polling, instead of doing timed fd checks. This should improve
performance greatly on modern OSes (e.g. that support polling on
filtered sockets).

The known OS that doesn't support this is FreeBSD < 5.0, but even then
FRR doesn't compile in these versions. OSes using DLPI method (e.g
Solaris) does not support select()/poll()ing fds as well, so it will be
disabled for it.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
6 years agodebianpkg: .gitignore += changelog
Quentin Young [Wed, 7 Feb 2018 18:13:46 +0000 (13:13 -0500)]
debianpkg: .gitignore += changelog

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
6 years agoMerge pull request #1718 from ak503/keychain
Donald Sharp [Wed, 7 Feb 2018 14:56:42 +0000 (09:56 -0500)]
Merge pull request #1718 from ak503/keychain

lib: 'no accept-lifetime' and 'no send-lifetime' for keychain

6 years agolib: 'no accept-lifetime' and 'no send-lifetime' for keychain
dturlupov [Wed, 7 Feb 2018 11:56:06 +0000 (14:56 +0300)]
lib: 'no accept-lifetime' and 'no send-lifetime' for keychain

Signed-off-by: Dmitrii Turlupov <dturlupov@factor-rs.ru>
6 years agoripd: Fix crash when ip rip split-horizon poisoned-reverse is configed
Donald Sharp [Tue, 6 Feb 2018 23:48:09 +0000 (18:48 -0500)]
ripd: Fix crash when ip rip split-horizon poisoned-reverse is configed

The code was attempting to access a variable that would always be NULL.
In fact this code has been broken since the rip ECMP changes
were put into place a few years back.

I'm going to come straight out and say that I don't fully
understand this code.  rinfo is the first item in the ecmp
list and tmp_rinfo is used to iterate over all the items
in the ecmp list.  It sure looks like that the changes
made here were just hacked together.  So I modified
the tmp_rinfo loop to just work on tmp_rinfo and
the check that was crashing I modified to just use
the rinfo since that what was checked originally
in code before the ECMP was added.  So consider
this a hack job to stop the crashing.

I think worse case is that we might be sending some routes
back out interfaces it shouldn't be if you have
ip rip split-horizon poisoned-reverse configured but
that is less bad(tm) than crashing.

Fixes: #1717
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1712 from donaldsharp/nht_updates
Renato Westphal [Wed, 7 Feb 2018 01:34:12 +0000 (23:34 -0200)]
Merge pull request #1712 from donaldsharp/nht_updates

Nht updates

6 years agoMerge pull request #1677 from chiragshah6/ospfv3_dev
Jafar Al-Gharaibeh [Tue, 6 Feb 2018 20:33:10 +0000 (14:33 -0600)]
Merge pull request #1677 from chiragshah6/ospfv3_dev

ospf6d: Fix redistribute [connected] with route-map

6 years agoMerge pull request #1699 from silasm/debianpkg-fix-debian-rules
Martin Winter [Tue, 6 Feb 2018 19:10:12 +0000 (11:10 -0800)]
Merge pull request #1699 from silasm/debianpkg-fix-debian-rules

debianpkg: normalize rules files, simplify logic/editing with '?='

6 years agoconfigure: Update version to 4.1-dev
Donald Sharp [Tue, 6 Feb 2018 17:26:47 +0000 (12:26 -0500)]
configure: Update version to 4.1-dev

We are now working on 4.1-dev for new work.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
6 years agoMerge pull request #1542 from qlyoung/stylechecker
Martin Winter [Tue, 6 Feb 2018 16:44:37 +0000 (08:44 -0800)]
Merge pull request #1542 from qlyoung/stylechecker

tools: add style checking scripts

6 years agoMerge pull request #1653 from Orange-OpenSource/SR-Routing
Donald Sharp [Tue, 6 Feb 2018 16:32:51 +0000 (11:32 -0500)]
Merge pull request #1653 from Orange-OpenSource/SR-Routing

OSPFD: Add Experimental Segment Routing support