NSX CLI Guide

Associated Commands:

CLI Description Command

Display all OSPF routes in RIB


Display all OSPF routes in RIB.
get logical-router <dpd-uuid-lrouter-arg> route ospf

Display multicast routes


Display all the multicast learnt routes.
get logical-router <uuid> mroute <ip-address>

Display detailed information of an IPv4 route in RIB of a tier 0 logical router


Display the routing table for the specified logical router. You must specify a tier 0 service router in this command. Use the get logical-routers command to get a list of logical routers and their router types.

Optionally specify a prefix or IPv4 address to display only the route used for that network.

get logical-router <uuid> route [<prefix>]

Display detailed information of an IPv6 route in RIB of a tier 0 logical router


Display the routing table for the specified logical router. You must specify a tier 0 service router in this command. Use the get logical-routers command to get a list of logical routers and their router types.

Optionally specify a prefix or IPv6 address to display only the route used for that network.

get logical-router <uuid> route [<prefix>]

Display IPv4 BGP routes for a specified prefix in RIB


Display IPv4 BGP routes for a specified prefix in RIB.
get logical-router <uuid> route bgp [<prefix>]

Display IPv4 Connected routes for a specified prefix in RIB


Display IPv4 Connected routes for a specified prefix in RIB.
get logical-router <uuid> route connected [<prefix>]

Display IPv4 OSPF routes for a specified prefix in RIB


Display IPv4 OSPF routes for a specified prefix in RIB.
get logical-router <uuid> route ospf [<prefix>]

Display the multicast HA role.


Display the multicast HA role. Active - Multicast is running in Active mode. Standby - Multicast is running in Standby mode. None - Multicast is not running.
get logical-router <uuid> route static [<prefix>]

Display IPv4 Static routes for a specified prefix in RIB


Display IPv4 Static routes for a specified prefix in RIB.

get logical-router route static command also displays Tier 0 NAT, Tier 1 NAT, Tier 1 connected, Load balancer routes along with Tier 0 & Tier 1 static routes

get logical-router <uuid> route static [<prefix>]

Display specific IPv4 routes from all the logical routers


Display specific IPv4 routes from all the logical routers.
get logical-router routes <network-address> (Deprecated)

Display multicast routes


Display all the multicast learnt routes.
get mroute <ip-address>

Display detailed information of an IPv4 route in RIB


Display detailed information of an IPv4 route in RIB. Specify a prefix or IPv4 address to display only the route used for that network.
get route [<prefix>]

Display detailed information of an IPv6 route in RIB


Display detailed information of an IPv6 route in RIB. Specify a prefix or IPv6 address to display only the route used for that network.
get route [<prefix>]

Display IPv4 BGP routes for a specified prefix in RIB


Display IPv4 BGP routes for a specified prefix in RIB.
get route bgp [<prefix>]

Display IPv4 Connected routes for a specified prefix in RIB


Display IPv4 Connected routes for a specified prefix in RIB.
get route connected [<prefix>]

Display all OSPF routes in RIB


Display all OSPF routes in RIB.
get route ospf

Display IPv4 OSPF routes for a specified prefix in RIB


Display IPv4 OSPF routes for a specified prefix in RIB.
get route ospf [<prefix>]

Display a specific IPv4 route


Display the specified IPv4 route.
get route prefix <cidr-notation>

Display IPv4 Static routes for a specified prefix in RIB


Display IPv4 Static routes for a specified prefix in RIB.

get route static command also displays Tier 0 NAT, Tier 1 NAT, Tier 1 connected, Load balancer routes along with Tier 0 & Tier 1 static routes

get route static [<prefix>]

Display IPv4 routes


Display all configured IPv4 routes.
get routes

Add network route


Add a network route. You can also just set a gateway by specifying a prefix value of 0.0.0.0/0.
set route prefix <prefix> gateway <gateway-ip> [interface <interface-name>]

Total commands: 21