diff mbox series

[iproute] man: ip-route.8: Document nexthop limit

Message ID 20181112222101.9674-1-phil@nwl.cc
State Superseded, archived
Delegated to: stephen hemminger
Headers show
Series [iproute] man: ip-route.8: Document nexthop limit | expand

Commit Message

Phil Sutter Nov. 12, 2018, 10:21 p.m. UTC
Add a note to 'nexthop' description stating the maximum number of
nexthops per command and pointing at 'append' command as a workaround.

Signed-off-by: Phil Sutter <phil@nwl.cc>
---
 man/man8/ip-route.8.in | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

David Ahern Nov. 13, 2018, 12:37 a.m. UTC | #1
On 11/12/18 2:21 PM, Phil Sutter wrote:
> diff --git a/man/man8/ip-route.8.in b/man/man8/ip-route.8.in
> index a33ce1f0f4006..383178c11331e 100644
> --- a/man/man8/ip-route.8.in
> +++ b/man/man8/ip-route.8.in
> @@ -589,6 +589,13 @@ argument lists:
>  route reflecting its relative bandwidth or quality.
>  .in -8
>  
> +The internal buffer used in iproute2 limits the maximum number of nexthops to
> +be specified in one go. If only a gateway address is given, the current buffer
> +size allows for 144 IPv6 nexthops and 253 IPv4 ones. If more are required, they
> +may be added to the existing route using
> +.B "ip route append"
> +command.
> +

That is not true for IPv4. 'ip ro append' adds a new route after the
existing route - an entry that can not be hit unless all of the nexthops
in the first route are down. 'ip ro prepend' adds a new entry before the
existing one meaning it takes precedence over the existing entries.

For IPv6, 'append' and 'prepend' both add new nexthops to the existing
entry.
Phil Sutter Nov. 13, 2018, 12:37 p.m. UTC | #2
Hi David,

On Mon, Nov 12, 2018 at 04:37:48PM -0800, David Ahern wrote:
> On 11/12/18 2:21 PM, Phil Sutter wrote:
> > diff --git a/man/man8/ip-route.8.in b/man/man8/ip-route.8.in
> > index a33ce1f0f4006..383178c11331e 100644
> > --- a/man/man8/ip-route.8.in
> > +++ b/man/man8/ip-route.8.in
> > @@ -589,6 +589,13 @@ argument lists:
> >  route reflecting its relative bandwidth or quality.
> >  .in -8
> >  
> > +The internal buffer used in iproute2 limits the maximum number of nexthops to
> > +be specified in one go. If only a gateway address is given, the current buffer
> > +size allows for 144 IPv6 nexthops and 253 IPv4 ones. If more are required, they
> > +may be added to the existing route using
> > +.B "ip route append"
> > +command.
> > +
> 
> That is not true for IPv4. 'ip ro append' adds a new route after the
> existing route - an entry that can not be hit unless all of the nexthops
> in the first route are down. 'ip ro prepend' adds a new entry before the
> existing one meaning it takes precedence over the existing entries.

Oh, thanks for clarifying. I'll follow-up with a fixed version.

> For IPv6, 'append' and 'prepend' both add new nexthops to the existing
> entry.

'ip route prepend' is not even documented. :(

Thanks, Phil
Stephen Hemminger Nov. 14, 2018, 7:20 p.m. UTC | #3
On Mon, 12 Nov 2018 23:21:01 +0100
Phil Sutter <phil@nwl.cc> wrote:

> Add a note to 'nexthop' description stating the maximum number of
> nexthops per command and pointing at 'append' command as a workaround.
> 
> Signed-off-by: Phil Sutter <phil@nwl.cc>

Applied
diff mbox series

Patch

diff --git a/man/man8/ip-route.8.in b/man/man8/ip-route.8.in
index a33ce1f0f4006..383178c11331e 100644
--- a/man/man8/ip-route.8.in
+++ b/man/man8/ip-route.8.in
@@ -589,6 +589,13 @@  argument lists:
 route reflecting its relative bandwidth or quality.
 .in -8
 
+The internal buffer used in iproute2 limits the maximum number of nexthops to
+be specified in one go. If only a gateway address is given, the current buffer
+size allows for 144 IPv6 nexthops and 253 IPv4 ones. If more are required, they
+may be added to the existing route using
+.B "ip route append"
+command.
+
 .TP
 .BI scope " SCOPE_VAL"
 the scope of the destinations covered by the route prefix.