From 610b53283ba6cb7994b84a4962cdec4d54f27216 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Fri, 24 May 2019 08:04:33 -0400 Subject: [PATCH] doc, tools: Update to code to show example MAX_FDS Place in the code the ability for end operators to know how to modify MAX_FDS so that they can run large scale operations. Signed-off-by: Donald Sharp --- doc/user/setup.rst | 35 ++++++++++++++++++++--------------- tools/etc/frr/daemons | 8 ++++++++ 2 files changed, 28 insertions(+), 15 deletions(-) diff --git a/doc/user/setup.rst b/doc/user/setup.rst index ffefe37905..2c9ca41762 100644 --- a/doc/user/setup.rst +++ b/doc/user/setup.rst @@ -6,8 +6,8 @@ Basic Setup After installing FRR, some basic configuration must be completed before it is ready to use. -Daemons File ------------- +Daemons Configuration File +-------------------------- After a fresh install, starting FRR will do nothing. This is because daemons must be explicitly enabled by editing a file in your configuration directory. This file is usually located at :file:`/etc/frr/daemons` and determines which @@ -34,19 +34,6 @@ systemd. The file initially looks like this: bfdd=no fabricd=no -To enable a particular daemon, simply change the corresponding 'no' to 'yes'. -Subsequent service restarts should start the daemon. - -Daemons Configuration File --------------------------- -There is another file that controls the default options passed to daemons when -starting FRR as a service. This file is located in your configuration -directory, usually at :file:`/etc/frr/daemons`. - -This file has several parts. Here is an example: - -:: - # # If this option is set the /etc/init.d/frr script automatically loads # the config via "vtysh -b" when the servers are started. @@ -71,6 +58,7 @@ This file has several parts. Here is an example: bfdd_options=" --daemon -A 127.0.0.1" fabricd_options=" --daemon -A 127.0.0.1" + #MAX_FDS=1024 # The list of daemons to watch is automatically generated by the init script. #watchfrr_options="" @@ -83,6 +71,13 @@ This file has several parts. Here is an example: Breaking this file down: +:: + + bgpd=yes + +To enable a particular daemon, simply change the corresponding 'no' to 'yes'. +Subsequent service restarts should start the daemon. + :: vtysh_enable=yes @@ -91,6 +86,16 @@ As the comment says, this causes :ref:`VTYSH ` to apply configuration when starting the daemons. This is useful for a variety of reasons touched on in the VTYSH documentation and should generally be enabled. +:: + + MAX_FDS=1024 + +This allows the operator to control the number of open file descriptors +each daemon is allowed to start with. The current assumed value on +most operating systems is 1024. If the operator plans to run bgp with +several thousands of peers than this is where we would modify FRR to +allow this to happen. + :: zebra_options=" -s 90000000 --daemon -A 127.0.0.1" diff --git a/tools/etc/frr/daemons b/tools/etc/frr/daemons index b920621d70..79c52d30d1 100644 --- a/tools/etc/frr/daemons +++ b/tools/etc/frr/daemons @@ -56,6 +56,14 @@ bfdd_options=" -A 127.0.0.1" fabricd_options="-A 127.0.0.1" vrrpd_options=" -A 127.0.0.1" +# +# This is the maximum number of FD's that will be available. +# Upon startup this is read by the control files and ulimit +# is called. Uncomment and use a reasonable value for your +# setup if you are expecting a large number of peers in +# say BGP. +#MAX_FDS=1024 + # The list of daemons to watch is automatically generated by the init script. #watchfrr_options="" -- 2.39.5