Skip to content

opx config route

Amy Buck edited this page Feb 21, 2019 · 13 revisions

COMMAND

opx-config-route — Creates and deletes static routes in the given namespace (VRF).

SYNOPSIS

opx-config-route [-h,--help] 
{create | delete | set}
[--vrf_name <vrf>]
[--ip_addr <ip_addr>]
[--dst <destination_address>]
[--nh_addr <next-hop_address>]
[--ifname <ifname>]
[--nh_ifindex <next-hop_ifindex>]
[--nh_vrf_name <next-hop_vrf_name] 

OPTIONS

Option Description
-h,--help Displays help text
--vrf_name <vrf> Existing VRF name
--ip_addr <ip_addr> Configures IPv4 or IPv6 address to an interface
--dst <destination_address> Destination route address
--nh_addr <next-hop_address> Next-hop addresses, separated by space
--ifname <ifname> Interface name
--nh_ifindex <next-hop_ifindex> Next-hop interface, separated by space
--nh_vrf_name <next-hop_vrf_name> VRF route leaking

EXIT STATUS

If an invalid address is specified, the exit status shall be 1.
Otherwise, the exit status is 0.

EXAMPLE

Create new static route

$ opx-config-route create --vrf_name default --dst 100.1.1.0/24 --nh_addr 10.1.1.1 10.1.1.2

Delete static route

$ opx-config-route delete --vrf_name default --dst 100.1.1.0/24

Configure IP to an interface in default VRF

$ opx-config-route create --ip_addr 10.1.1.3/24 --ifname e101-003-0

VRF route leaking

Inter-VRF route leaking allows you to leak static routes that you configure in a default or non-default VRF instance that is available to other VRF instances.

NOTE: OPX does not support specifying a next-hop IP address in the static route for leaking. Routes can be leaked by specifying the interface name in a static route.

Enable VRF route leaking

$ opx-config-route create --vrf_name blue --dst 11.1.1.0/24 --nh_vrf_name red --ifname v-e101-001-0

To view the static route, use opx-show-route --vrf_name blue.

Remove VRF route leak

$ opx-config-route delete --vrf_name blue --dst 11.1.1.0/24 --nh_vrf_name red

REPORT BUGS

To report any OPX software bugs, see Report bugs.

SEE ALSO

opx-show-route

Clone this wiki locally