]> git.proxmox.com Git - mirror_frr.git/log
mirror_frr.git
7 years agosnap: add vtysh as a "proper" command alias for frr.vtysh
Jafar Al-Gharaibeh [Thu, 11 May 2017 21:52:27 +0000 (16:52 -0500)]
snap: add vtysh as a "proper" command alias for frr.vtysh

   This allows direct access to vtysh without the "frr." prefix.
   The alias can be enabled by sudo snap frr vtysh

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
7 years agoMerge pull request #521 from opensourcerouting/bgpd-fixes-stable
Donald Sharp [Sat, 13 May 2017 16:24:32 +0000 (12:24 -0400)]
Merge pull request #521 from opensourcerouting/bgpd-fixes-stable

bgpd: assorted fixes (stable/3.0)

7 years agoMerge pull request #508 from LabNConsulting/working/3.0/patch/issue198
David Lamparter [Sat, 13 May 2017 07:10:09 +0000 (09:10 +0200)]
Merge pull request #508 from LabNConsulting/working/3.0/patch/issue198

bgpd: Issue #198 - clean up duplicate encap SAFI commands

7 years agoMerge pull request #524 from qlyoung/blublublub3.0
David Lamparter [Sat, 13 May 2017 07:08:55 +0000 (09:08 +0200)]
Merge pull request #524 from qlyoung/blublublub3.0

lib: use %p specifier for pointers

7 years agolib: use %p specifier for pointers
Quentin Young [Fri, 12 May 2017 21:37:36 +0000 (21:37 +0000)]
lib: use %p specifier for pointers

Fixes builds on ARM

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
7 years agobgpd: fix segfault with '[no] bgp network import-check'
Renato Westphal [Fri, 12 May 2017 14:01:02 +0000 (11:01 -0300)]
bgpd: fix segfault with '[no] bgp network import-check'

These commands were causing bgpd to crash if a static VPN route was
configured.

While here, fix a bug in bgp_static_add() and bgp_static_delete().

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agobgpd: fix duplicate install of command
Renato Westphal [Fri, 12 May 2017 12:40:21 +0000 (09:40 -0300)]
bgpd: fix duplicate install of command

Only happens when FRR is configured with --enable-oldvpn-commands.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agobgpd: fix 'show bgp [...] longer-prefixes'
Renato Westphal [Fri, 12 May 2017 12:19:42 +0000 (09:19 -0300)]
bgpd: fix 'show bgp [...] longer-prefixes'

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agobgpd: Issue #198 - clean up duplicate command resulting from CLI refactoring
Lou Berger [Thu, 11 May 2017 12:46:48 +0000 (08:46 -0400)]
bgpd: Issue #198 - clean up duplicate command resulting from CLI refactoring

Signed-off-by: Lou Berger <lberger@labn.net>
7 years agobgpd: fixup bgpd: allow VPN next hop to be different AFI than NLRI next
Philippe Guibert [Wed, 10 May 2017 17:27:33 +0000 (19:27 +0200)]
bgpd: fixup bgpd: allow VPN next hop to be different AFI than NLRI next
hop for EVPN

In the case of EVPN, add the nexthop attribute.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
7 years agoadded troubleshooting section to debian 8 build doc
Adam Fitzgerald [Thu, 11 May 2017 11:03:23 +0000 (21:03 +1000)]
added troubleshooting section to debian 8 build doc

7 years agoMerge pull request #500 from qlyoung/fix-router-rip-3.0-3.0
David Lamparter [Thu, 11 May 2017 11:58:40 +0000 (13:58 +0200)]
Merge pull request #500 from qlyoung/fix-router-rip-3.0-3.0

vtysh: add \n to 'router rip[ng]' docstrings (3.0)

7 years agovtysh: add \n to 'router rip[ng]' docstrings
Quentin Young [Tue, 9 May 2017 21:04:00 +0000 (21:04 +0000)]
vtysh: add \n to 'router rip[ng]' docstrings

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
7 years agoAddress the error "Dead assignment" of static analysif
Hung-Weic Chiu [Wed, 10 May 2017 02:51:28 +0000 (02:51 +0000)]
Address the error "Dead assignment" of static analysif

- Refer to https://ci1.netdef.org/browse/FRR-FRR4-44/artifact/shared/static_analysis/index.html
- Remove unused variable

Signed-off-by: Hung-Weic Chiu <sppsorrg@gmail.com>
7 years ago- Solve the Coverity Scan PW.ASSIGN_WHERE_COMPARE_MEANT
Hung-Weic Chiu [Wed, 10 May 2017 01:57:11 +0000 (01:57 +0000)]
- Solve the Coverity Scan PW.ASSIGN_WHERE_COMPARE_MEANT

- Minor refactoring

Signed-off-by: Hung-Weic Chiu <sppsorrg@gmail.com>
7 years agoMerge pull request #486 from LabNConsulting/working/3.0/patch/issue483
Russ White [Tue, 9 May 2017 23:56:47 +0000 (19:56 -0400)]
Merge pull request #486 from LabNConsulting/working/3.0/patch/issue483

bgp rfapi: rfapi shouldn't be called (yet) for BGP VRF instances.

7 years agoMerge pull request #488 from donaldsharp/sudoers3
Russ White [Tue, 9 May 2017 23:48:00 +0000 (19:48 -0400)]
Merge pull request #488 from donaldsharp/sudoers3

*: Remove ability to install frr_sudoers for 3.0

7 years ago*: Remove ability to install frr_sudoers
Donald Sharp [Tue, 9 May 2017 20:18:04 +0000 (16:18 -0400)]
*: Remove ability to install frr_sudoers

If the user were to uncomment last line
and allow VTYSH_SHOW to be used as a non-root
account, this would allow arbitrary command completion
inside of vtysh via multiple -c ... -c .... lines

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoMerge pull request #485 from LabNConsulting/working/3.0/patch-set/missing1
Donald Sharp [Tue, 9 May 2017 19:45:15 +0000 (15:45 -0400)]
Merge pull request #485 from LabNConsulting/working/3.0/patch-set/missing1

Pick up a couple of patches to master that are needed on 3.0

7 years agobgp rfapi: rfapi shouldn't be called (yet) for BGP VRF instances.
Lou Berger [Tue, 9 May 2017 18:38:55 +0000 (14:38 -0400)]
bgp rfapi: rfapi shouldn't be called (yet) for BGP VRF instances.

7 years agobgpd: restore -S, --skip_runas options
Lou Berger [Sun, 2 Apr 2017 19:34:55 +0000 (15:34 -0400)]
bgpd: restore  -S, --skip_runas options

Signed-off-by: Lou Berger <lberger@labn.net>
7 years agobgp: fix a couple of instances of bm being used before init'ed
Lou Berger [Sun, 2 Apr 2017 17:55:58 +0000 (13:55 -0400)]
bgp: fix a couple of instances of bm being used before init'ed

Signed-off-by: Lou Berger <lberger@labn.net>
7 years agoMerge pull request #469 from qlyoung/fix-list-perm-3.0
David Lamparter [Tue, 9 May 2017 15:54:46 +0000 (17:54 +0200)]
Merge pull request #469 from qlyoung/fix-list-perm-3.0

lib: fix 'list permutations' (3.0)

7 years agoMerge pull request #475 from chiragshah6/pim_dev_3_0
Jafar Al-Gharaibeh [Mon, 8 May 2017 20:01:04 +0000 (15:01 -0500)]
Merge pull request #475 from chiragshah6/pim_dev_3_0

Pim related defect fixes

7 years agopimd: Fix WG/SGRpt & WG J/P processing
Chirag Shah [Fri, 21 Apr 2017 22:08:03 +0000 (15:08 -0700)]
pimd: Fix WG/SGRpt & WG J/P processing

During processing of Join/Prune,
for a S,G entry, current state is SGRpt, when only *,G is
received, need to clear SGRpt and add/inherit the *,G OIF to S,G so
it can forward traffic to downstream where *,G is received.
Upon receiving SGRpt prune remove the inherited *,G OIF.

From, downstream router received *,G Prune along with SGRpt
prune. Avoid sending *,G and SGRpt Prune together.
Reset upstream_del reset ifchannel to NULL.

Testing Done:
Run failed smoke test of sending data packets, trigger SPT switchover,
*,G path received SGRpt later data traffic stopped S,G ages out from LHR, sends only
*,G join to upstream, verified S,G entry inherit the OIF.
Upon receiving SGRpt deletes inherited oif and retains in SGRpt state.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agopimd: replay IGMP static group upon if creation
Chirag Shah [Wed, 26 Apr 2017 01:56:00 +0000 (18:56 -0700)]
pimd: replay IGMP static group upon if creation

Upon static IGMP configured port down igmp source info is destroyed.
Upon port up or quagga restart (if addr add) register IGMP sock with
port, source, group.

Testing Done:
Configure IGMPv3 Report on Host swpx, ifdown/ifup swpx,
verify ip mroute containng IGMP mroute

tor-1# show ip mroute
Source          Group           Proto  Input      Output     TTL  Uptime
30.1.1.1        225.1.1.21      IGMP   swp2       swp3       1    00:00:05

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agopimd: fix pimd crash when pim interface disabled
Chirag Shah [Thu, 4 May 2017 01:56:44 +0000 (18:56 -0700)]
pimd: fix pimd crash when pim interface disabled

Upon pim enabled disabled, current upstreams entries rpf update callback,
needs to check if old rpf is still pim enabled otherwise do not trigger
prune towards old rpf.

Testing Done:
Verified by disabling pim enabled rpf interface and
 crash is not observed upon disabling pim on rpf interface.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agopimd: fix pim ecmp rebalance config write
Chirag Shah [Mon, 10 Apr 2017 20:27:56 +0000 (13:27 -0700)]
pimd: fix pim ecmp rebalance config write

ip pim ecmp and ip pim ecmp rebalance configuration CLIs were
not adding to Quagga.confg or running configuration.
Added both the configuration write in Config write handler.

Testing Done: Execute configuration cli and verified running config
and Quagga.conf file containing both configuration.

03# show running-config
Building configuration...

Current configuration:
!
ip multicast-routing
ip pim rp 6.0.0.9 230.0.0.0/16
ip pim join-prune-interval 61
ip pim ecmp
ip pim ecmp rebalance
!

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agopimd: fix channel_oil and upstream RPF in sync
Chirag Shah [Thu, 27 Apr 2017 18:01:32 +0000 (11:01 -0700)]
pimd: fix channel_oil and upstream RPF in sync

During PIM Neighbor change/UP event, pim_scan_oil api
scans all channel oil to see any rpf impacted. Instead of
passing current upstream's RPF it passes current RPF as 0 and
does query to rib for nexhtop (without ECMP/Rebalance). This creates
inconsist RPF between Upstream and Channel oil.
In Channel Oil keep backward pointer to upstream DB and fetch up's
RPF and passed to channel_oil scan.
Decrement channel_oil ref_count in upstream_del when decrementing
up ref_count and it is not the last.
Created ECMP based FIB lookup API.

Testing Done:
Performed following testing on tester setup:
5 x LHR, 4 x MSDP Spines, 6 Sources each sending to 1023 groups from one of the spines.
Total send rate 8Mpps.
Test that caused problems was to reboot every device at the same time.
After fix performed 5 iterations of reboot devices and show no sign of the problem.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agoMerge pull request #462 from donaldsharp/poll_3.0
Russ White [Sat, 6 May 2017 22:33:38 +0000 (18:33 -0400)]
Merge pull request #462 from donaldsharp/poll_3.0

lib: Rename HAVE_POLL to prevent conflicting #defines

7 years agoMerge pull request #470 from dslicenc/cm16223
Russ White [Sat, 6 May 2017 22:24:36 +0000 (18:24 -0400)]
Merge pull request #470 from dslicenc/cm16223

bgpd: resolve crash displaying bgp vrf routing info

7 years agoMerge pull request #447 from donaldsharp/moobot
Martin Winter [Sat, 6 May 2017 00:51:18 +0000 (17:51 -0700)]
Merge pull request #447 from donaldsharp/moobot

doc: Fix systemd build instructions

7 years agobgpd: resolve crash displaying bgp vrf routing info
Don Slice [Fri, 5 May 2017 13:53:49 +0000 (06:53 -0700)]
bgpd: resolve crash displaying bgp vrf routing info

Problem uncovered with crash when entering the command "show ip bgp
vrf vrf1001 0.0.0.0".   The crash was caused by a mistake incrementing
the index value in the vrf/view case.  Manual testing completed and
failing test case now passes successfully.

Ticket: CM-16223
Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
Reviewed By: Donald Sharp <sharpd@cumulusnetworks.com>

7 years agolib: fix 'list permutations'
Quentin Young [Thu, 4 May 2017 22:46:46 +0000 (22:46 +0000)]
lib: fix 'list permutations'

Cyclic graphs ftw

Also remove graph pretty printer from permutations.c 'cause it's not
really needed anymore

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
7 years agoMerge pull request #465 from opensourcerouting/cli-fuzzer-fixes
Donald Sharp [Thu, 4 May 2017 20:27:12 +0000 (16:27 -0400)]
Merge pull request #465 from opensourcerouting/cli-fuzzer-fixes

*: fix a bunch of segfaults detected by a CLI fuzzer

7 years agoMerge pull request #452 from hwchiu/fix_ldpd
Renato Westphal [Thu, 4 May 2017 18:14:49 +0000 (15:14 -0300)]
Merge pull request #452 from hwchiu/fix_ldpd

Fix the error message when execute ldpd with --enable-tcp-zebra

7 years agoMerge pull request #463 from donaldsharp/pim_stable_3.0
Jafar Al-Gharaibeh [Thu, 4 May 2017 18:09:44 +0000 (13:09 -0500)]
Merge pull request #463 from donaldsharp/pim_stable_3.0

Pim stable 3.0

7 years ago*: fix a bunch of segfaults detected by a CLI fuzzer
Renato Westphal [Thu, 4 May 2017 02:49:50 +0000 (23:49 -0300)]
*: fix a bunch of segfaults detected by a CLI fuzzer

This patch fixes the following segfaults:
zebra aborted: vtysh -c "show ipv6 mroute"
zebra aborted: vtysh -c "configure terminal" -c "debug zebra kernel msgdump"
zebra aborted: vtysh -c "configure terminal" -c "interface eth99" -c "link-params" -c "no packet-loss"
zebra aborted: vtysh -c "configure terminal" -c "interface eth99" -c "link-params" -c "no metric"
zebra aborted: vtysh -c "configure terminal" -c "interface eth99" -c "link-params" -c "no ava-bw"
zebra aborted: vtysh -c "configure terminal" -c "interface eth99" -c "link-params" -c "no res-bw"
zebra aborted: vtysh -c "configure terminal" -c "interface eth99" -c "link-params" -c "no use-bw"
ospfd aborted: vtysh -c "configure terminal" -c "router ospf" -c "area 1.1.1.1 nssa"
ospfd aborted: vtysh -c "configure terminal" -c "router ospf" -c "area 4294967295 nssa"
pimd aborted: vtysh -c "show ip msdp sa 1.1.1.1"
pimd aborted: vtysh -c "configure terminal" -c "ip ssmpingd"
pimd aborted: vtysh -c "configure terminal" -c "no ip ssmpingd"
pimd aborted: vtysh -c "configure terminal" -c "no ip msdp mesh-group WORD source"
pimd aborted: vtysh -c "configure terminal" -c "interface eth99" -c "ip pim hello 180"
bgpd aborted: vtysh -c "show bgp l2vpn evpn rd 1:1"
bgpd aborted: vtysh -c "clear vnc nve un *"
bgpd aborted: vtysh -c "clear vnc nve un 1.1.1.1"
bgpd aborted: vtysh -c "clear vnc nve un 2001:db8::1"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 1.1.1.1 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 1.1.1.1 cost 255 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 1.1.1.1 cost 255"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 1.1.1.1"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 2001:db8::1 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 2001:db8::1 cost 255 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 2001:db8::1 cost 255"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 1.1.1.1 un 2001:db8::1"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 1.1.1.1 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 1.1.1.1 cost 255 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 1.1.1.1 cost 255"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 1.1.1.1"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 2001:db8::1 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 2001:db8::1 cost 255 lifetime 4294967295"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 2001:db8::1 cost 255"
bgpd aborted: vtysh -c "add vnc mac 11:11:11:11:11:11 virtual-network-identifier 4294967295 vn 2001:db8::1 un 2001:db8::1"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp 1" -c "no vnc export bgp ipv4 prefix-list NAME"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp 1" -c "no vnc export bgp ipv6 prefix-list NAME"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp 1" -c "no vnc export bgp route-map NAME"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp 1" -c "no vnc export zebra ipv4 prefix-list NAME"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp 1" -c "no vnc export zebra ipv6 prefix-list NAME"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp 1" -c "no vnc export zebra route-map NAME"
bgpd aborted: vtysh -c "configure terminal" -c "route-map RMAP permit 1" -c "no set ipv6 vpn next-hop"
bgpd aborted: vtysh -c "configure terminal" -c "route-map RMAP permit 1" -c "set vpnv4 next-hop"
bgpd aborted: vtysh -c "configure terminal" -c "route-map RMAP permit 1" -c "set vpnv6 next-hop"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp" -c "address-family ipv6 vpn" -c "network 2001:db8::1/128 rd 1:1 tag WORD"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp" -c "address-family vpnv6 unicast" -c "network 2001:db8::1/128 rd 1:1 tag WORD"
bgpd aborted: vtysh -c "configure terminal" -c "router bgp" -c "no neighbor WORD shutdown message MSG..."
bgpd aborted: vtysh -c "configure terminal" -c "router bgp" -c "neighbor WORD shutdown message MSG..."

More to come later.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agoMerge pull request #450 from donaldsharp/afi_safi3
Renato Westphal [Thu, 4 May 2017 17:33:43 +0000 (14:33 -0300)]
Merge pull request #450 from donaldsharp/afi_safi3

Afi safi3

7 years agopimd: Note when a S,G stream should be a FHR as well
Donald Sharp [Tue, 25 Apr 2017 14:00:39 +0000 (10:00 -0400)]
pimd: Note when a S,G stream should be a FHR as well

When we have a S,G being created, that it might
also be a FHR router as well.  This happens
when the FHR is in the path of the RP->LHR
for when it builds it's SPT tree for the S,G.

Ticket: CM-16056, CM-15836
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agopimd: Only compare the actual IIF of the *,G to S,G
Donald Sharp [Thu, 20 Apr 2017 20:11:58 +0000 (16:11 -0400)]
pimd: Only compare the actual IIF of the *,G to S,G

Now that pim has the ability to use ecmp, the Group
path to the RP, may be different than what is choosen
for the *,G IIF.  As such when we are making the
spt switchover decision, compare the S,G IIF to the
*,G IIF.

Ticket: CM-15870
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agolib: Rename HAVE_POLL to prevent conflicting #defines
Donald Sharp [Thu, 4 May 2017 14:24:25 +0000 (10:24 -0400)]
lib: Rename HAVE_POLL to prevent conflicting #defines

Rename HAVE_POLL to HAVE_POLL_CALL, when compiling with
snmp and poll enabled this was causing issues.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoospf6d: Allow some route-map commands to work
Donald Sharp [Wed, 3 May 2017 18:39:21 +0000 (14:39 -0400)]
ospf6d: Allow some route-map commands to work

The generic callbacks need to be enabled in order
for some route-map commands to properly work.

I've tried to match up to what is programmed to work
within ospfv3.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoospf6d: Fix redistribution debug knowledge
Donald Sharp [Wed, 3 May 2017 18:33:28 +0000 (14:33 -0400)]
ospf6d: Fix redistribution debug knowledge

When redistributing into ospfv3 specify that the
route is add or delete correctly.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoMerge pull request #451 from opensourcerouting/ospfd-fix-cmdstr
Jafar Al-Gharaibeh [Wed, 3 May 2017 15:04:59 +0000 (10:04 -0500)]
Merge pull request #451 from opensourcerouting/ospfd-fix-cmdstr

ospfd: fix small problem in the redistribute command

7 years agodoc: Add systemd dev package to doc
Donald Sharp [Wed, 3 May 2017 13:35:06 +0000 (09:35 -0400)]
doc: Add systemd dev package to doc

Add the systemd dev package to the list of items to install

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoFix the error message when execute ldpd with --enable-tcp-zebra
Hung-Weic Chiu [Wed, 3 May 2017 13:27:29 +0000 (13:27 +0000)]
Fix the error message when execute ldpd with --enable-tcp-zebra

- If we use the option "--enable-tcp-zebra " to configure, the zclient will use the tcp socket instead of unix domain socket.
- The ldpd will pass the "-z path" options to `frr_opt` and that will execute zclient_serv_path_set to check the domain socket.
- Add the define to ldpd, if the "HAVE_TCP_ZEBRA" has been define, don't pass the "-z path" to `frr_opt`.

Signed-off-by: Hung-Weic Chiu <sppsorrg@gmail.com>
7 years agobgpd: Fix crashes with '[no] neighbor ... shutdown ..' command
Donald Sharp [Wed, 3 May 2017 13:13:12 +0000 (09:13 -0400)]
bgpd: Fix crashes with '[no] neighbor ... shutdown ..' command

This fixes two crashes:

1) When we enter a 'neighbor shutdown..' command for a peer
group or interface based peer we were not properly looking
up the peer.

2) When we we enter 'no neighbor shutdown..' command for
a peer group or interface based peer we were not properly
lookup up the peer.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoospfd: fix small problem in the redistribute command
Renato Westphal [Wed, 3 May 2017 13:03:14 +0000 (10:03 -0300)]
ospfd: fix small problem in the redistribute command

The use of {<>} is unnecessary and not correct.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agozebra: Fix leaked memory in label manager code
Donald Sharp [Wed, 3 May 2017 12:11:38 +0000 (08:11 -0400)]
zebra: Fix leaked memory in label manager code

When we fail to properly setup we can leak some memory.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agodoc: Fix systemd build instructions
Donald Sharp [Wed, 3 May 2017 11:06:20 +0000 (07:06 -0400)]
doc: Fix systemd build instructions

Fix the build/install instructions for Ubuntu 16.04 and
systemd.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoMerge pull request #442 from Jafaral/pim-hello-fix
Donald Sharp [Tue, 2 May 2017 23:49:13 +0000 (19:49 -0400)]
Merge pull request #442 from Jafaral/pim-hello-fix

Fix: Off by one error, correct index for hold timer

7 years agoFix: Off by one error, correct index for hold timer
Jafar Al-Gharaibeh [Tue, 2 May 2017 22:23:34 +0000 (17:23 -0500)]
Fix: Off by one error, correct index for hold timer

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
7 years agoupdate doc of ubuntu 12.04
Hung-Wei Chiu [Thu, 27 Apr 2017 15:30:56 +0000 (23:30 +0800)]
update doc of ubuntu 12.04

1. modify the prefix to /usr (which is hard-code in /etc/init.d/frr)
2. install init.d related files.

7 years agoUpdate 14.04 docs to support init.d service
Hung-Wei Chiu [Thu, 27 Apr 2017 15:14:23 +0000 (23:14 +0800)]
Update 14.04 docs to support init.d service

1. Configure the prefix to /usr  (frr script hard-code those path in /etc/init.d/frr)
2. Install the service file to /etc/init.d

7 years agoMerge pull request #440 from donaldsharp/afi_safi3
Jafar Al-Gharaibeh [Tue, 2 May 2017 19:20:30 +0000 (14:20 -0500)]
Merge pull request #440 from donaldsharp/afi_safi3

Afi safi3

7 years agoMerge pull request #439 from Jafaral/pim_rpgrp-fix
Donald Sharp [Tue, 2 May 2017 18:31:55 +0000 (14:31 -0400)]
Merge pull request #439 from Jafaral/pim_rpgrp-fix

Fix: reverse logic of when to pass the supplied group address

7 years agoMerge pull request #438 from hwchiu/fix_nhrpd_privs
Donald Sharp [Tue, 2 May 2017 18:20:43 +0000 (14:20 -0400)]
Merge pull request #438 from hwchiu/fix_nhrpd_privs

Fix the error when execute nhrpd

7 years agopimd: Fix cli uplift mistakes
Donald Sharp [Tue, 2 May 2017 17:55:02 +0000 (13:55 -0400)]
pimd: Fix cli uplift mistakes

When we uplifted the cli from old -> new, I did not properly
handle the switch from <1-3> to (1-3) for number ranges.

Also fix some minor variable renaming that happened?

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoospfd: Fix a variant of the ospf redistribute command
Donald Sharp [Tue, 2 May 2017 13:47:16 +0000 (09:47 -0400)]
ospfd: Fix a variant of the ospf redistribute command

Fix 'redistribute (ospf|table) ....' command

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoFix: reverse logic of when to pass the supplied group address
Jafar Al-Gharaibeh [Tue, 2 May 2017 17:15:06 +0000 (12:15 -0500)]
Fix: reverse logic of when to pass the supplied group address

   This was causing a crash when no group address was passed
   because a garbage pointer valuse was used. It also was ignoring
   the group address when passing one.

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
7 years agoFix the wrong user/group for nhrpd.
Hung-Weic Chiu [Tue, 2 May 2017 15:42:31 +0000 (15:42 +0000)]
Fix the wrong user/group for nhrpd.

- Modify the defince from quagga to frr

Signed-off-by: Hung-Weic Chiu <sppsorrg@gmail.com>
7 years agoMerge pull request #426 from donaldsharp/afi_safi2
Renato Westphal [Tue, 2 May 2017 15:09:18 +0000 (12:09 -0300)]
Merge pull request #426 from donaldsharp/afi_safi2

Afi safi2

7 years agoMerge pull request #431 from opensourcerouting/fix-iface-renames
Donald Sharp [Mon, 1 May 2017 18:17:42 +0000 (14:17 -0400)]
Merge pull request #431 from opensourcerouting/fix-iface-renames

Fix interface renames

7 years agoMerge pull request #432 from opensourcerouting/ldpd-link-detect
Donald Sharp [Mon, 1 May 2017 18:17:14 +0000 (14:17 -0400)]
Merge pull request #432 from opensourcerouting/ldpd-link-detect

ldpd: respect link-detect configuration

7 years agoldpd: respect link-detect configuration
Renato Westphal [Sun, 30 Apr 2017 23:16:15 +0000 (20:16 -0300)]
ldpd: respect link-detect configuration

We shouldn't check the operational status of an interface in ldpd if
it's configured with "no link-detect" in zebra. That's what all the
other routing daemons do.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agoldpd: fixes to handle interface renames properly
Renato Westphal [Sun, 30 Apr 2017 13:26:57 +0000 (10:26 -0300)]
ldpd: fixes to handle interface renames properly

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agozebra: fix detection of interface renames
Renato Westphal [Sun, 30 Apr 2017 13:26:06 +0000 (10:26 -0300)]
zebra: fix detection of interface renames

Restore the original logic in netlink_link_change() which works like this:
* once an interface event is detected, lookup the associated interface
  by its name;
* call the set_ifindex() function;
* set_ifindex() will lookup the interface again but now by its ifindex. If
  the lookups by name and ifindex yield to different results, then the
  interface was renamed and set_ifindex() will take care of that.

In the future, zns->if_table will be split into two different data
structures to allow faster lookups by both name and ifindex.

Fixes Issue #397.

Regression introduced by commit 12f6fb9.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agoMerge pull request #406 from chiragshah6/pim_dev_3_0
Jafar Al-Gharaibeh [Sun, 30 Apr 2017 22:59:51 +0000 (17:59 -0500)]
Merge pull request #406 from chiragshah6/pim_dev_3_0

Pim dev 3 0

7 years agoMerge pull request #430 from opensourcerouting/zebra-vrfdel-fix
Donald Sharp [Sun, 30 Apr 2017 12:57:12 +0000 (08:57 -0400)]
Merge pull request #430 from opensourcerouting/zebra-vrfdel-fix

zebra: fix infinite loop when deleting non-default vrf

7 years agozebra: fix infinite loop when deleting non-default vrf
Renato Westphal [Sat, 29 Apr 2017 17:15:11 +0000 (14:15 -0300)]
zebra: fix infinite loop when deleting non-default vrf

How to reproduce the bug:
% ip link add vrf-red type vrf table 10
% ip link set dev vrf-red up
% ip rule add oif vrf-red table 10
% ip rule add iif vrf-red table 10
% ip link add name lo1 type dummy
% ip link set dev lo1 up
% ip link set dev lo1 master vrf-red
% ip link del dev vrf-red
(zebra gets stuck in an infinite loop inside work_queue_run())

Regression introduced by commit 5a8dfcd8.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agoMerge pull request #427 from opensourcerouting/zebra-ifdel-fix
Donald Sharp [Fri, 28 Apr 2017 19:56:10 +0000 (15:56 -0400)]
Merge pull request #427 from opensourcerouting/zebra-ifdel-fix

lib: fix segfault on exit caused by interface removal

7 years agolib: fix segfault on exit caused by interface removal
Renato Westphal [Wed, 26 Apr 2017 14:17:38 +0000 (11:17 -0300)]
lib: fix segfault on exit caused by interface removal

Add missing bits to properly unlink interface in the if_unlink_per_ns()
function.

In the long term we should convert if_table to use a more convenient
data structure like a red-black tree instead of a routing table.

Fixes issue #398.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agobgpd: Fix some crashes due to NULL pointer
Donald Sharp [Fri, 28 Apr 2017 17:50:09 +0000 (13:50 -0400)]
bgpd: Fix some crashes due to NULL pointer

If you specified A.B.C.D, the code would still try to
read A.B.C.D/M and not find it and pass in a NULL pointer
which crashed the code.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoMerge pull request #417 from donaldsharp/stable_2_0_fixes_into_stable_3_0
Donald Sharp [Fri, 28 Apr 2017 15:42:21 +0000 (11:42 -0400)]
Merge pull request #417 from donaldsharp/stable_2_0_fixes_into_stable_3_0

Stable 2.0 fixes into stable 3.0

7 years agoMerge branch 'stable/3.0' into pim_dev_3_0
Jafar Al-Gharaibeh [Fri, 28 Apr 2017 15:38:05 +0000 (10:38 -0500)]
Merge branch 'stable/3.0' into pim_dev_3_0

7 years agoMerge pull request #381 from donaldsharp/pimmerino
Jafar Al-Gharaibeh [Fri, 28 Apr 2017 15:13:39 +0000 (10:13 -0500)]
Merge pull request #381 from donaldsharp/pimmerino

Pimmerino

7 years agoospf6d: Fix parse_type_spec
Donald Sharp [Fri, 28 Apr 2017 02:04:56 +0000 (22:04 -0400)]
ospf6d: Fix parse_type_spec

The function parse_type_spec was always looking in argv[0] of
for figuring out the type of the command.  Since the type location
could change, use the passed in idx_lsa.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoospf6d: Fix some issues with 'show ipv6 ospf6 data..'
Donald Sharp [Fri, 28 Apr 2017 01:51:26 +0000 (21:51 -0400)]
ospf6d: Fix some issues with 'show ipv6 ospf6 data..'

1) linkstate-id was made optional in one case
2) The ipv4 address was being looked at in the wrong spot

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agovtysh: Add back in some missing ospf6 commands
Donald Sharp [Fri, 28 Apr 2017 00:19:36 +0000 (20:19 -0400)]
vtysh: Add back in some missing ospf6 commands

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agobgpd: Allow old vpnv4 commands to compile
Donald Sharp [Thu, 27 Apr 2017 20:08:36 +0000 (16:08 -0400)]
bgpd: Allow old vpnv4 commands to compile

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agobgpd: Fix 'show .. bgp ... neighbors ' command
Donald Sharp [Thu, 27 Apr 2017 17:13:30 +0000 (13:13 -0400)]
bgpd: Fix 'show .. bgp ... neighbors ' command

The 'show ip bgp neighbors swp31s0' command was not
working properly.  This fixes that issue.

This command still has issues that need to be investigated
but for the moment this gets the command working in the
form that is needed.  More rework can come.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agobgpd: Make json output to be camelCase
Donald Sharp [Thu, 27 Apr 2017 15:03:25 +0000 (11:03 -0400)]
bgpd: Make json output to be camelCase

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agobgpd: Modify 'show ... bgp ... summary' to only display pertinent info
Donald Sharp [Thu, 27 Apr 2017 15:00:25 +0000 (11:00 -0400)]
bgpd: Modify 'show ... bgp ... summary' to only display pertinent info

Modify the 'show ... bgp ... summary' command when you are
looking at a afi( with no safi specified ) to only display
output for those safi's that have been configured.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
7 years agoMerge pull request #425 from opensourcerouting/bgpd-clear-fix
Donald Sharp [Fri, 28 Apr 2017 14:47:05 +0000 (10:47 -0400)]
Merge pull request #425 from opensourcerouting/bgpd-clear-fix

bgpd: fix "clear bgp" commands

7 years agoMerge pull request #424 from opensourcerouting/snap-fix-distfile
Donald Sharp [Fri, 28 Apr 2017 14:02:03 +0000 (10:02 -0400)]
Merge pull request #424 from opensourcerouting/snap-fix-distfile

More snapcraft cleanups

7 years agobgpd: fix "clear bgp" commands
Renato Westphal [Fri, 28 Apr 2017 13:22:28 +0000 (10:22 -0300)]
bgpd: fix "clear bgp" commands

The use of VTY_DECLVAR_CONTEXT(bgp, bgp) here is wrong as we are not
inside the "router bgp" configuration node. This was making the clear
commands always fail with a "Current configuration object was deleted
by another process" error, which doesn't make any sense.

Also, the bgp_clear() function will already check for us if the given
peer-group or neighbor exists or not, there's no need to duplicate this
logic here.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
7 years agosnapcraft: Clean up old no longer used configure flags
Martin Winter [Fri, 28 Apr 2017 10:11:51 +0000 (03:11 -0700)]
snapcraft: Clean up old no longer used configure flags

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
7 years agosnapcraft: Add support for extra version information
Martin Winter [Fri, 28 Apr 2017 06:41:04 +0000 (23:41 -0700)]
snapcraft: Add support for extra version information

- frr.version snap command will now show the contents of
  extra_version_info.txt in addition to the zebra --version output

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
7 years agosnapcraft: Fix missing files in "make dist" target
Martin Winter [Fri, 28 Apr 2017 06:26:20 +0000 (23:26 -0700)]
snapcraft: Fix missing files in "make dist" target

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
7 years agoUpdate Building_FRR_on_Ubuntu1604.md
Hung-Wei Chiu [Thu, 27 Apr 2017 03:22:15 +0000 (11:22 +0800)]
Update Building_FRR_on_Ubuntu1604.md

Fix typo

7 years agoUpdate Building_FRR_on_Ubuntu1604.md
Hung-Wei Chiu [Thu, 27 Apr 2017 03:10:36 +0000 (11:10 +0800)]
Update Building_FRR_on_Ubuntu1604.md

1.  Modify the configure prefix (since there some hard coded path in **/usr/lib/frr/fr**
2.  Install the systemd service config

7 years agoMerge pull request #413 from dwalton76/address-family-argv-argc-stable-30
Renato Westphal [Thu, 27 Apr 2017 12:21:20 +0000 (09:21 -0300)]
Merge pull request #413 from dwalton76/address-family-argv-argc-stable-30

Problem with DEFUNSH in vtysh, issue #358

7 years agoProblem with DEFUNSH in vtysh, issue #358
Daniel Walton [Wed, 26 Apr 2017 22:39:10 +0000 (22:39 +0000)]
Problem with DEFUNSH in vtysh, issue #358

Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
7 years agopimd: fix pimd crashes around pim rpf
Chirag Shah [Tue, 25 Apr 2017 05:32:23 +0000 (22:32 -0700)]
pimd: fix pimd crashes around pim rpf

During neighbor down event, all upstream entries rpf lookup may result
into nhop address with 0.0.0.0 and rpf interface info being NULL.
Put preventin check where rpf interface info is accessed.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agopimd: Fix WG/SGRpt & WG J/P processing
Chirag Shah [Fri, 21 Apr 2017 22:08:03 +0000 (15:08 -0700)]
pimd: Fix WG/SGRpt & WG J/P processing

During processing of Join/Prune,
for a S,G entry, current state is SGRpt, when only *,G is
received, need to clear SGRpt and add/inherit the *,G OIF to S,G so
it can forward traffic to downstream where *,G is received.
Upon receiving SGRpt prune remove the inherited *,G OIF.

Testing Done:
Trigger SPT switchover, *,G path received SGRpt later data
traffic stopped S,G ages out from LHR, sends only
*,G join to upstream, verified S,G entry inherit the OIF.
Upon receiving SGRpt deletes inherited oif and retains in SGRpt state.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agopimd: Enable igmp on igmp version change cli
Chirag Shah [Tue, 25 Apr 2017 05:01:34 +0000 (22:01 -0700)]
pimd: Enable igmp on igmp version change cli

Execute ip igmp version 3 under swp interface,
verified show running displayed 'ip igmp' configuration.
Continuous sending group membership, performed 'no ip igmp'
and verified, group membership flushed. Performed
'ip igmp version 3', verified 'show ip igmp groups'
displaying igmp membership re-populated.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
7 years agopimd: Pim Nexthop Tracking support with ECMP
Chirag Shah [Wed, 5 Apr 2017 20:14:12 +0000 (13:14 -0700)]
pimd: Pim Nexthop Tracking support with ECMP

In this patch, PIM nexthop tracking uses locally populated nexthop cached list
to determine ECMP based nexthop (w/ ECMP knob enabled), otherwise picks
the first nexthop as RPF.
Introduced '[no] ip pim ecmp' command to enable/disable PIM ECMP knob.
By default, PIM ECMP is disabled.
Intorudced '[no] ip pim ecmp rebalance' command to provide existing mcache
entry to switch new path based on hash chosen path.
Introduced, show command to display pim registered addresses and respective nexthops.
Introuduce, show command to find nexthop and out interface for (S,G) or (RP,G).
Re-Register an address with nexthop when Interface UP event received,
to ensure the PIM nexthop cache is updated (being PIM enabled).
During PIM neighbor UP, traverse all RPs and Upstreams nexthop and determine, if
any of nexthop's IPv4 address changes/resolves due to neigbor UP event.

Testing Done: Run various LHR, RP and FHR related cases to resolve RPF using
nexthop cache with ECMP knob disabled, performed interface/PIM neighbor flap events.
Executed pim-smoke with knob disabled.

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
(cherry picked from commit cba444817883b8b3b22a7ed9958dc9ed77f76230)

7 years agoMerge pull request #399 from donaldsharp/is_configured
Jafar Al-Gharaibeh [Tue, 25 Apr 2017 15:13:40 +0000 (10:13 -0500)]
Merge pull request #399 from donaldsharp/is_configured

ospfd: Remove unused function

7 years agoMerge pull request #403 from donaldsharp/nhrpd2
Russ White [Tue, 25 Apr 2017 14:24:23 +0000 (10:24 -0400)]
Merge pull request #403 from donaldsharp/nhrpd2

Nhrpd2