From 62f8241b09228a66916480731c0291dbd5a1aa24 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Fri, 16 Apr 2021 19:23:25 +0200 Subject: vrf: dynamic routing is now supported - document this --- docs/configuration/vrf/index.rst | 163 ++++----------------------------------- 1 file changed, 17 insertions(+), 146 deletions(-) (limited to 'docs/configuration/vrf/index.rst') diff --git a/docs/configuration/vrf/index.rst b/docs/configuration/vrf/index.rst index 244784de..cd7f3d54 100644 --- a/docs/configuration/vrf/index.rst +++ b/docs/configuration/vrf/index.rst @@ -14,7 +14,6 @@ in the very least need different default gateways. different then they are implemented and handled right now - please feedback via a task created in Phabricator_. - Configuration ============= @@ -58,157 +57,29 @@ itself needs to be assigned to an interface. Routing ------- -Static -^^^^^^ - -Static routes are manually configured routes, which, in general, cannot be -updated dynamically from information VyOS learns about the network topology from -other routing protocols. However, if a link fails, the router will remove -routes, including static routes, from the :abbr:`RIPB (Routing Information -Base)` that used this interface to reach the next hop. In general, static -routes should only be used for very simple network topologies, or to override -the behavior of a dynamic routing protocol for a small number of routes. The -collection of all routes the router has learned from its configuration or from -its dynamic routing protocols is stored in the RIB. Unicast routes are directly -used to determine the forwarding table used for unicast packet forwarding. - -Static Routes -""""""""""""" - -.. cfgcmd:: set protocols vrf static route next-hop
- - Configure next-hop `
` for an IPv4 static route in the VRF identified - by ``. Multiple static routes can be created. - -.. cfgcmd:: set protocols vrf static route next-hop
- disable - - Disable IPv4 static route entry in the VRF identified by `` - -.. cfgcmd:: set protocols vrf static route next-hop
- distance - - Defines next-hop distance for this route, routes with smaller administrative - distance are elected prior those with a higher distance. - - Range is 1 to 255, default is 1. - -.. cfgcmd:: set protocols vrf static route6 next-hop
- - Configure next-hop `
` for an IPv6 static route in the VRF identified - by ``. Multiple IPv6 static routes can be created. - -.. cfgcmd:: set protocols vrf static route6 next-hop
- disable - - Disable IPv6 static route entry in the VRF identified by ``. - -.. cfgcmd:: set protocols vrf static route6 next-hop
- distance - - Defines next-hop distance for this route, routes with smaller administrative - distance are elected prior those with a higher distance. - - Range is 1 to 255, default is 1. - - .. note:: Routes with a distance of 255 are effectively disabled and not - installed into the kernel. - - -Leaking -""""""" - -.. cfgcmd:: set protocols vrf static route next-hop
- vrf - - Use this command if you have shared services or routes that should be shared - between multiple VRF instances. This will add an IPv4 route to VRF `` - routing table to reach a `` via a next-hop gatewys `
` in - a different VRF or leak it into the default VRF. - -.. cfgcmd:: set protocols vrf static route6 next-hop
- vrf - - Use this command if you have shared services or routes that should be shared - between multiple VRF instances. This will add an IPv6 route to VRF `` - routing table to reach a `` via a next-hop gatewys `
` in - a different VRF or leak it into the default VRF. - - -Interface Routes -"""""""""""""""" - -.. cfgcmd:: set protocols vrf static route - interface - - Allows you to configure the next-hop interface for an interface-based IPv4 - static route. `` will be the next-hop interface where trafic is - routed for the given ``. - -.. cfgcmd:: set protocols vrf static route - interface disable - - Disables interface-based IPv4 static route. - -.. cfgcmd:: set protocols vrf static route - interface distance - - Defines next-hop distance for this route, routes with smaller administrative - distance are elected prior those with a higher distance. - - Range is 1 to 255, default is 1. - -.. cfgcmd:: set protocols vrf static route6 - interface - - Allows you to configure the next-hop interface for an interface-based IPv6 - static route. `` will be the next-hop interface where trafic is - routed for the given ``. - -.. cfgcmd:: set protocols vrf static route6 - interface disable - - Disables interface-based IPv6 static route. - -.. cfgcmd:: set protocols vrf static route6 - interface distance - - Defines next-hop distance for this route, routes with smaller administrative - distance are elected prior those with a higher distance. - - Range is 1 to 255, default is 1. - -Blackhole -""""""""" - -.. cfgcmd:: set protocols vrf static route blackhole - - Use this command to configure a "black-hole" route on the router. A - black-hole route is a route for which the system silently discard packets - that are matched. This prevents networks leaking out public interfaces, but - it does not prevent them from being used as a more specific route inside your - network. - -.. cfgcmd:: set protocols vrf static route blackhole distance - +.. note:: VyOS 1.4 (sagitta) introduced dynamic routing support for VRFs. - Defines blackhole distance for this route, routes with smaller administrative - distance are elected prior those with a higher distance. +Currently dynamic routing is supported for the following protocols: -.. cfgcmd:: set protocols vrf static route6 blackhole +- :ref:`routing-bgp` +- :ref:`routing-isis` +- :ref:`routing-ospf` +- :ref:`routing-static` - Use this command to configure a "black-hole" route on the router. A - black-hole route is a route for which the system silently discard packets - that are matched. This prevents networks leaking out public interfaces, but - it does not prevent them from being used as a more specific route inside your - network. +The CLI configuration the same as mentioned in above articles. The only +difference is, that each routing protocol used, must be prefixed with the `vrf +name ` command. -.. cfgcmd:: set protocols vrf static route6 blackhole distance - +Example +^^^^^^^ - Defines blackhole distance for this route, routes with smaller administrative - distance are elected prior those with a higher distance. +The following commands would be required to set options ofr a given dynamic +routing protocol inside a given vrf: +- :ref:`routing-bgp`: ``set vrf name protocols bgp ...`` +- :ref:`routing-isis`: ``set vrf name protocols isis ...`` +- :ref:`routing-ospf`: ``set vrf name protocols ospf ...`` +- :ref:`routing-static`: ``set vrf name protocols static ...`` Operation ========= -- cgit v1.2.3