Default Static Route#
Underlay Routing → DSDefault Static Routes
Static routes enable connectivity to remote network elements that do not have a routing protocol enabled to advertise routes. A static route is either configured with one or more next-hop IP addresses, or as a blackhole route. A blackhole route will attract traffic for the entire subnet, but will discard packets if no longer prefix match is available in the routing table.
Example: if all outbound traffic is meant to pass through a firewall device, a default static route (0.0.0.0/0) could be configured with the next-hop IP address of the firewall.
To set up static routes in the overlay, use
StaticRouteinstead.
Dependencies#
To configure this resource, the following resources must exist or be created alongside the DefaultStaticRoute
- The
DefaultRouterin which the static route will be configured
Referenced resources#
DefaultRouter#
Static route prefixes configured in the DefaultStaticRoute resource are only configured in the VRF of the linked DefaultRouter resource. The next-hop of the static routes should be reachable through a local interface (typically a DefaultInterface) configured in the same DefaultRouter.
TopoNode#
Optionally, a list of nodes can be provided on which the static route is deployed. EDA does not determine on which nodes the next-hop IP address is reachable through a local interface, but instead deploys the static route on ALL nodes that the DefaultRouter is configured on, if no nodes are specified.
Examples#
cat << 'EOF' | kubectl apply -f -
apiVersion: protocols.eda.nokia.com/v2
kind: DefaultStaticRoute
metadata:
namespace: eda
name: my-default-static-route
spec:
nexthopGroup:
blackhole: false
resolve: false
nexthops:
- resolve: false
ipPrefix: 172.16.0.2/31
prefixes:
- 10.0.1.0/24
defaultRouter: router-leaf-1
EOF
Custom Resource Definition#
To browse the Custom Resource Definition go to crd.eda.dev.
DefaultStaticRoute
SPEC
DefaultStaticRoute enables the configuration of static routes within a DefaultRouter. It allows specifying destination prefixes, route preference, and a nexthop group. This resource facilitates precise control over routing behavior, including options for BFD, route resolution, and blackholing traffic.
-
The name of the static route to configure on the device.
-
Reference to a DefaultRouter on which to configure the static routes.
-
Group of nexthops for the list of prefixes.
-
Enables BFD to the next-hops in the group. Local and Remote discriminator parameters have been deprecated at this level. Use Nexthop to set these parameters.
-
Defines whether BFD should be enabled towards the nexthops.
default: false -
Defines the local address to use when establishing the BFD session with the nexthop.
-
-
If set to true all traffic destined to the prefixes will be blackholed. If enabled, next-hops are ignored and this takes precedence.
default: false -
When enabled, the router will generate ICMP Unreachable messages for packets destined to the blackhole route.
-
Follow the resolution of another route. This setting is mutually exclusive with all other settings in the group.
-
Follow mode. Only "NextLongest" is supported, which means that the route will follow the next-hop-group of the next most specific matching route in the routing table.
enum: "NextLongest"
-
-
Ordered list of nexthops.
-
-
Enables BFD to the next-hops in the group. This overrides the configuration at the group.
-
Defines whether BFD should be enabled towards the nexthops.
default: false -
Defines the local address to use when establishing the BFD session with the nexthop.
-
Defines the local discriminator.
-
Defines the remote discriminator.
-
-
Address to use.
-
If set to true the next-hops can be destinations which are resolved in the route table. This overrides the configuration at the group.
default: false
-
-
-
If set to true the next-hops can be destinations which are resolved in the route table.
default: false
-
-
Defines the route preference.
-
List of destination prefixes and mask to use for the static routes.
STATUS
DefaultStaticRouteStatus defines the observed state of default static route
-
Indicates the health score of the static routes.
-
Indicates the reason for the health score.
-
The time when the state of the resource last changed.
-
Operational state of the static routes.