Commit Graph

192 Commits

Author SHA1 Message Date
Ruben Kerkhof
0cff191d5c redhat: fix else cases in spec file
As pointed out during review, disable the options when the macros are
false.

Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
2d2ab69937 redhat: spec file: specify file only once
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
07a138ecab redhat: spec file: no need for custom attr for service file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
95624f7b34 redhat: add missing dependencies on chkconfig in spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
c88a52f4df redhat: remove a few superfluous Requires from spec file
rpm adds these automatically

Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
ccb9b8f6c0 redhat: remove a few superfluous BuildRequires from spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
501c136231 redhat: depend on info package instead of binary in specfile
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
fadbc6e7fe redhat: install-info is not called from %pre in spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
54c059f1cb redhat: remove wrong comment from spec file
systemd support needs watchfrr

Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
a999f98cc5 redhat: spec file: all supported Fedora versions use systemd
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
7ca1f62ca9 redhat: use default permissions for logrotate file in spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
6ad17a64c1 redhat: spec file: we ship only one logrotate file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
c9cad8766e redhat: be consistent in adding ./configure options in spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
c410a86130 redhat: use Github for SOURCE0 in spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
e1ff824635 redhat: Use https for URL in spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
150e7c7eb3 redhat: remove trailing whitespace from spec file
Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:52 +02:00
Ruben Kerkhof
fe99b0153a redhat: fix tabs vs spaces in spec file
rpmlint reports:
redhat/frr.spec:282: W: mixed-use-of-spaces-and-tabs (spaces: line 13, tab: line 282)

Signed-off-by: Ruben Kerkhof <ruben@rubenkerkhof.com>
2018-06-19 09:57:45 +02:00
Donald Sharp
5b7077e892 redhat: Fix old systems on upgrade path
Fix old systems in upgrade path to enable watchfrr when upgrading.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2018-05-30 07:53:28 -04:00
Donald Sharp
b13124f0f7 redhat: Make watchfrr the default
With systemd being the default on more systems now, lets
configure watchfrr to start else systemd systems on
redhat will not stay up for more than 1 minute.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2018-05-30 07:52:23 -04:00
Martin Winter
b4c554e24f redhat: Fix RPKI RPM build option
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2018-05-20 07:13:02 -07:00
Quentin Young
717b48667f doc: add "Getting Started" section
While we have docs on various pieces of the build system we don't have
any docs on how to actually get FRR running once it's installed, nor do
we have comprehensive documentation on the basic procedure for building
from source. This patch remedies both of those.

Also updated the services list in the docs and removed the SERVICES file
from the project root.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2018-05-16 20:24:15 +00:00
Quentin Young
aa64f37df7 *: clean up various top level stuff
* Updated README to point to new bug report location
* Updated README to point to community doc location
* Remove COMMUNITY.md
* Remove references to no longer extant docs in packaging files

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2018-05-08 16:05:11 -04:00
Donald Sharp
31649cb98b redhat, tools: Increase startup time out a bit
We have run across a few cases where the startup timeout is
ocurring on heavily loaded systems.  This is especially true
in simulation environments where the hypervisor load is
extremely high.

Modify the code base to give ourselves more time to startup.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2018-05-01 23:35:53 -04:00
Donald Sharp
1abe1280a0 redhat: PBR modifications to allow it to build properly
Add to the redhat build the PBR daemon and it's ancillary
files.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2018-04-06 13:22:43 -04:00
Donald Sharp
e5c83d9b31 pbrd: Add PBR to FRR
This is an implementation of PBR for FRR.

This implemenation uses a combination of rules and
tables to determine how packets will flow.

PBR introduces a new concept of 'nexthop-groups' to
specify a group of nexthops that will be used for
ecmp.  Nexthop-groups are specified on the cli via:

nexthop-group DONNA
  nexthop 192.168.208.1
  nexthop 192.168.209.1
  nexthop 192.168.210.1
!

PBR sees the nexthop-group and installs these as a default
route with these nexthops starting at table 10000
robot# show pbr nexthop-groups
Nexthop-Group: DONNA Table: 10001 Valid: 1 Installed: 1
	Valid: 1  nexthop 192.168.209.1
	Valid: 1  nexthop 192.168.210.1
	Valid: 1  nexthop 192.168.208.1

I have also introduced the ability to specify a table
in a 'show ip route table XXX' to see the specified tables.

robot# show ip route table 10001
Codes: K - kernel route, C - connected, S - static, R - RIP,
       O - OSPF, I - IS-IS, B - BGP, P - PIM, E - EIGRP, N - NHRP,
       T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP,
       F - PBR,
       > - selected route, * - FIB route

F>* 0.0.0.0/0 [0/0] via 192.168.208.1, enp0s8, 00:14:25
  *                 via 192.168.209.1, enp0s9, 00:14:25
  *                 via 192.168.210.1, enp0s10, 00:14:25

PBR tracks PBR-MAPS via the pbr-map command:

!
pbr-map EVA seq 10
  match src-ip 4.3.4.0/24
  set nexthop-group DONNA
!
pbr-map EVA seq 20
  match dst-ip 4.3.5.0/24
  set nexthop-group DONNA
!

pbr-maps can have 'match src-ip <prefix>' and 'match dst-ip <prefix>'
to affect decisions about incoming packets.  Additionally if you
only have one nexthop to use for a pbr-map you do not need
to setup a nexthop-group and can specify 'set nexthop XXXX'.

To apply the pbr-map to an incoming interface you do this:

interface enp0s10
 pbr-policy EVA
!

When a pbr-map is applied to interfaces it can be installed
into the kernel as a rule:

[sharpd@robot frr1]$ ip rule show
0:	from all lookup local
309:	from 4.3.4.0/24 iif enp0s10 lookup 10001
319:	from all to 4.3.5.0/24 iif enp0s10 lookup 10001
1000:	from all lookup [l3mdev-table]
32766:	from all lookup main
32767:	from all lookup default

[sharpd@robot frr1]$ ip route show table 10001
default proto pbr metric 20
	nexthop via 192.168.208.1 dev enp0s8 weight 1
	nexthop via 192.168.209.1 dev enp0s9 weight 1
	nexthop via 192.168.210.1 dev enp0s10 weight 1

The linux kernel now will use the rules and tables to properly
apply these policies.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2018-04-06 13:22:43 -04:00
Arthur Jones
a61bbca831 redhat: enable dist tarball to build in a chroot
When building the rpms, we can use a chroot (in my case docker) to
ensure that the BuildRequires are complete.  This test failed with
errors like:

    checking for CARES... no
    configure: error: trying to build nhrpd, but libcares not found. install c-ares and its -dev headers.
    error: Bad exit status from /var/tmp/rpm-tmp.FewvLf (%build)

This is due to a couple missing BuildRequires in the spec file.  Here, we
add those in for all RPM builds.

Testing done:

Ran a docker build on CentOS7 which succeeded.  Loaded the modules onto
CentOS6 to make sure they were at least valid there, that succeeded.

Issue: https://github.com/FRRouting/frr/issues/1930
Signed-off-by: Arthur Jones <arthur.jones@riverbed.com>
2018-03-19 11:37:58 -07:00
Martin Winter
c8cd451cab redhat: Add RPKI comment on build instructions
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2018-03-17 09:57:45 -07:00
Martin Winter
aaf38c9461 redhat: Add option to build with RPKI
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>

Conflicts:
	redhat/frr.spec.in
2018-03-17 09:56:33 -07:00
Martin Winter
32398f0168 tools: Add helper frr-reload shell script for clean error
Adding the shell script allows a clean error if frr-pythontools
is not installed.

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2018-03-14 17:31:29 -07:00
Martin Winter
78b4c54667
doc: Update CentOS6 doc to use puias repo for updated sphinx
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2018-03-13 17:11:23 -04:00
Quentin Young
e7cc2122de
redhat: update frr.spec for doc build changes
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2018-03-07 17:36:20 -05:00
Martin Winter
ccd40deece
redhat: Update CentOS6 to use python27-sphinx package
sphinx > 1.1 is needed which is provided by the non-standard
python27-sphinx for CentOS 6 / RedHat 6

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2018-03-02 01:57:43 -05:00
Martin Winter
609dee9d83
redhat: Update spec file for new rst documentation
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2018-03-02 01:57:42 -05:00
Donald Sharp
84b05ca193 redhat: Build with FPM
Build redhat rpm's with FPM.  It's a module so not
a bad idea.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2018-01-18 09:31:20 -05:00
Donald Sharp
8a71d93d85 sharpd: Add Super Happy Advanced Routing Protocol
Add a daemon that will allow us to test the zapi
as well as test route install/removal times from
the kernel.

The current commands are:

install route <starting ip address> nexthop <nexthop> (1-1000000)

This command starts installing at <starting ip address>/32
(1-100000) routes that it auto-increments by 1
Installation start time is noted in the log and finish
time is noted as well.

remove routes <starting ip address> (1-1000000)

This command removes routes at <starting ip address>/32
and removes (1-100000) routes created by the install route
command.

This code can be considered experimental and *is not*
something that should be run in a production environment.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-11-27 09:16:30 -05:00
Donald Sharp
01c37e583e redhat: Fix redhat startup to actually read in unified config
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-10-26 10:18:24 -04:00
Martin Winter
de481ae61f redhat: Fix doc by removing outdated package information and point to main doc/ directory for it
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2017-10-20 18:56:26 -07:00
Martin Winter
c88ca85d39 redhat: Fix rpm scripts to correctly restart daemons on upgrade
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2017-10-20 18:56:04 -07:00
Martin Winter
75429e11b9 redhat: Add fix to correct watchfrr config during upgrade
- /etc/frr/daemon is a config file and won't be replaced, do quick sed fix
- Updated changelog

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>

Conflicts:
	redhat/frr.spec.in
2017-10-20 18:55:30 -07:00
Martin Winter
486da96666 redhat: systemd file should not be executable
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2017-10-20 18:53:56 -07:00
Martin Winter
0012cfec07 redhat: Always reference main frr start/stop script in /usr/lib/frr
* Fixes issue where daemon default config tried to use /etc/init.d/frr script which doesn't exist on systemd systems

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>

Conflicts:
	redhat/daemons
2017-10-20 18:53:25 -07:00
Matthew Smith
398455d691 redhat: Set permissions on systemd service file
Systemd on CentOS 7.3 logs a warning about the execute bit being
set every time the frr service file is invoked by systemctl.
Modify the spec file to explicitly set the permissions to 644.

Signed-off-by: Matthew Smith <mgsmith@netgate.com>
2017-08-30 14:02:37 -05:00
David Lamparter
0ed9196b0c redhat: ship IRDP module
No point in configuring IRDP (it's always available on Linux), just ship
the module and let the user decide whether to enable it by way of module
loading.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-15 14:19:16 +02:00
David Lamparter
4e1fd26a5e Merge remote-tracking branch 'frr/master' into tcp-zebra 2017-08-09 20:42:27 +02:00
Donald Sharp
f790234f2f Merge pull request #892 from opensourcerouting/watchfrr-simplify
simplify watchfrr, add --terminal, improve startup logging
2017-08-09 14:32:44 -04:00
David Lamparter
d258b1df2b Merge pull request #883 from daveolson53/master
Switch to using syslog for logging as the default
2017-08-09 19:29:16 +02:00
David Lamparter
689f5a8c84 *: remove --enable-tcp-zebra, rework ZAPI path
This adds "@tcp" as new choice on the -z option present in zebra and the
protocol daemons.  The --enable-tcp-zebra option on configure is no
longer needed, both UNIX and TCP socket support is always available.

Note that @tcp should not be used by default (e.g. in an init script),
and --enable-tcp-zebra should never have been in any distro package
builds, because

**** TCP-ZEBRA IS A SECURITY PROBLEM ****

It allows arbitrary local users to mess with the routing table and
inject bogus data -- and also ZAPI is not designed to be robust against
attacks.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-08 11:14:05 +02:00
Brian Rak
5d82c57b76 rhel: Don't obsolete bird
The FRR RPM was obsoleting BIRD, which meant that as soon as you added a FRR RPM to a repository, you could no longer install BIRD.  This patch switches it over to Conflicts instead, which should be much nicer behavior
2017-08-07 14:37:21 -04:00
David Lamparter
27e295b591 tools: remove watchfrr -A/-a/-z from init scripts
These don't exist anymore.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-08-02 23:36:42 +02:00
David Lamparter
53d93be147 build: non-recursive auxiliary directories
Flatten {m4,pkgsrc,python,redhat,snapcraft}/Makefile.am into the main
one.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-31 23:03:30 +02:00