The following commands are specific to the routing context within the Netsh environment.

To view the command syntax, click a command:

Add commands

Delete commands

Set commands

Show commands

Netsh commands for routing IP

The following entries provide details for each command.

dump

Displays the configuration of the remote access server in script form.

Syntax

dump

Remarks

  • You can dump the contents of the current configuration to a file that can be used to restore altered configuration settings.

Example

The following command saves the current configuration as a script in the routingipcfg.dmp file.

dump > routingipcfg.dmp

reset

Resets IP routing to a clean state.

Syntax

reset

update

Updates autostatic routes on the specified interface.

Syntax

update

[name=] InterfaceName

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface on which you want to update autostatic routes.

add boundary

Adds a multicast scope boundary on an interface.

Syntax

add boundary

[name=] InterfaceName

[grpaddr=] IPAddress

[grpmask=] SubnetMask

or

add boundary

[name=] Name

[scopename=] ScopeName

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface on which you want to add the boundary.
[grpaddr=] IPAddress


Specifies the multicast group address of the boundary to add.
[grpmask=] SubnetMask


Specifies the subnet mask of the boundary address to add.
[scopename=] ScopeName


Specifies the name of the multicast scope to bound.

Examples

The following shows two different examples of adding a multicast scope boundary.

add boundary name=Internal grpaddr=239.0.0.1 grpmask=255.255.255.255

add boundary name="Local Area Connection" scopename="My Mcast Scope"

add filter

Adds a packet filter to the specified interface.

Syntax

add filter

[name=] InterfaceName

[filtertype=] {input | output | dial}

[srcaddr=] IPAddress

[srcmask=] SubnetMask

[dstaddr=] IPAddress

[dstmask=] SubnetMask

{[proto=] any | [proto=] {tcp | tcp-est | udp} [srcport=] Port [dstport=] Port [proto=] icmp [type=] ICMPTypeField [code=] ICMPCodeField}

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface on which you want to add the filter.
[filtertype=] {input | output | dial}


Required. Specifies the type of packet filter. The input parameter specifies the filter being modified filters input. The output parameter specifies the filter being modified filters output. The dial parameter specifies the filter being modified filters a dial-up interface connection.
[srcaddr=] IPAddress


Required. Specifies the source address field of the packet to be filtered.
[srcmask=] SubnetMask


Required. Specifies the source subnet mask of the packet to be filtered. An address and mask of all zeros means ANY.
[dstaddr=] IPAddress


Required. Specifies the destination address field of the packet to be filtered.
[dstmask=] SubnetMask


Required. Specifies the destination subnet mask of the packet to be filtered.
[proto=] any | [proto=] {tcp | tcp-est | udp}


Required. Specifies the protocol type for the packet to be filtered.
[srcport=] Port


Specifies the source port field of the packet to be filtered. A value of zero means ANY.
[dstport=] Port


Specifies the destination port field of the packet to be filtered. A value of zero means ANY.
[type=] ICMPTypeField


Specifies the ICMP type field of the packet to be filtered. A value of 255 means ANY.
[code=] ICMPCodeField


Specifies the ICMP code field of the packet to be filtered. A value of 255 means ANY.

Examples

The following shows two different examples of adding a packet filter.

add filter name="Virtual Private Connection" filtertype=input

srcaddr=0.0.0.0 srcmask=255.255.255.255 dstaddr=169.254.0.0

dstmask=255.255.0.0 proto=any

add filter "Virtual Private Connection" input 0.0.0.0 0.0.0.0

169.254.0.0 255.255.0.0 any

add interface

Adds IP forwarding on an interface and enables or disables IP forwarding.

Syntax

add interface

[name=] InterfaceName

[[state=] enable | disable]

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface on which you want to set IP forwarding.
[[state=] enable | disable]


The enable parameter enables the IP interface as you add it. The disable parameter disables the IP interface as you add it.

Example

The following adds and enables IP forwarding on an interface.

add interface name="Local Area Connection" state=enable

add persistentroute

Adds a persistent static route on the specified interface.

Syntax

add persistentroute

[dest=] IPAddress

[mask=] SubnetMask

[name=] InterfaceName

[[nhop]=IPAddress]

[[proto=] static | nondod]

[[metric=] RouteMetric]

[[view=] unicast | multicast | both]

Parameters

[dest=] IPAddress


Required. Specifies the destination address for the specified route.
[mask=] SubnetMask


Required. Specifies the subnet mask for the destination address.
[name=] InterfaceName


Required. Specifies, by name, the interface where the route is to be added.
[[nhop]=IPAddress]


Specifies the next hop address for the route. For routes over point-to-point interface, this value should not be specified.
[[proto=] static | nondod]


Specifies the demand-dial connection state. The static parameter specifies demand-dial connections are triggered. The nondod parameter specifies demand-dial connections are not triggered.
[[metric=] RouteMetric]


Specifies the route metric.
[[view=] unicast | multicast | both]


Specifies valid traffic for the route. The unicast parameter specifies the route is valid for unicast traffic only. The multicast parameter specifies the route is valid for multicast traffic only. The both parameter specifies the route is valid for both unicast and multicast traffic. The default value is both.

Example

The following adds a persistent static route on the specified interface.

add persistentroute 192.168.1.0 255.255.255.0 "Virtual Private Connection"

add preferenceforprotocol

Adds a preference level to a specified routing protocol.

Syntax

add preferenceforprotocol

[proto=] autostatic | local | netmgmt | nondod | ospf | rip | static

[preflevel=] PreferenceLevel

Parameters

[proto=] autostatic | local | netmgmt | nondod | ospf | rip | static


Required. Specifies the routing protocol for which a preference level is set. The autostatic parameter adds an autostatic routing preference. The local parameter adds a local routing preference. The netmgmt parameter adds a routing preference for a network management protocol. The nondod parameter adds a preference for a routing protocol not able to use demand-dial. The ospf parameter adds a routing protocol preference for Open Shortest Path First (OSPF). The rip parameter adds a routing preference for Routing Information Protocol (RIP). The static parameter adds a static routing preference.
[preflevel=] PreferenceLevel


Required. Specifies the preference level.

Example

The following adds a preference level of 10 for the RIP routing protocol.

add preferenceforprotocol proto=rip preflevel=10

add rtmroute

Adds a non-persistent network management route for the specified interface or next hop count.

Syntax

add rtmroute [dest=] IPAddress

[mask=] SubnetMask

[name=] InterfaceName

[[nhop]=IPAddress]

[[proto=] static | nondod]

[[metric=] RouteMetric]

[[view=] unicast | multicast | both]

Parameters

[dest=] IPAddress


Required. Specifies the destination address for the specified route.
[mask=] SubnetMask


Required. Specifies the subnet mask for the destination address.
[nameorindex=] InterfaceName


Required. Specifies, by name, the interface where the route is to be added.
[[nhop]=IPAddress]


Specifies the next hop address for the route. For routes over point-to-point interface, this value should not be specified.
[[metric=] RouteMetric]


Specifies the route metric.
[[view=] unicast | multicast | both]


Specifies valid traffic for the route. The unicast parameter specifies the route is valid for unicast traffic only. The multicast parameter specifies the route is valid for multicast traffic only. The both parameter specifies the route is valid for both unicast and multicast traffic. The default value is both.

Example

The following adds a non-persistent network management route to the specified interface.

add rtmroute 192.168.1.0 255.255.255.0 "Virtual Private Connection"

add scope

Adds a multicast scope to the IP routing configuration.

Syntax

add scope

[grpaddr=] IPAddress

[grpmask=] SubnetMask

[scopename=] ScopeName

Parameters

[grpaddr=] IPAddress


Required. Specifies the multicast scope or group IP address.
[grpmask=] SubnetMask


Required. Specifies the subnet mask of the multicast scope address.
[scopename=] ScopeName


Required. Specifies the name of the multicast scope to be added.

Example

The following adds the specified multicast scope.

add scope 239.1.1.1 255.255.255.224 "My Multicast Scope"

delete boundary

Deletes a multicast scope boundary from an interface.

Syntax

delete boundary

[name=] InterfaceName

[grpaddr=] IPAddress

[grpmask=] SubnetMask

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface on which you want to delete the boundary.
[grpaddr=] IPAddress


Specifies the multicast group address of the boundary to delete.
[grpmask=] SubnetMask


Specifies the subnet mask of the boundary address to delete.
[scopename=] ScopeName


Specifies the name of the bounded multicast scope.

Examples

The following shows two different examples of deleting a multicast scope boundary.

delete boundary "Local Area Connection" 239.2.2.2 255.255.255.255

delete boundary "Local Area Connection" "My Mcast Scope"

delete filter

Deletes a packet filter from the specified interface.

Syntax

delete filter

[name=] InterfaceName

[filtertype=] {input | output | dial}

[srcaddr=] IPAddress

[srcmask=] SubnetMask

[dstaddr=] IPAddress

[dstmask=] SubnetMask

{[proto=] any | [proto=] {tcp | tcp-est | udp}

[srcport=] Port

[dstport=] Port

[proto=] icmp

[type=] ICMPTypeField

[code=] ICMPCodeField}

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface from which you want to delete the filter.
[filtertype=] {input | output | dial}


Required. Specifies the type of packet filter. The input parameter specifies the filter being modified filters input. The output parameter specifies the filter being modified filters output. The dial parameter specifies the filter being modified filters a dial-up interface connection.
[srcaddr=] IPAddress


Required. Specifies the source address field of the packet to be filtered.
[srcmask=] SubnetMask


Required. Specifies the source subnet mask of the packet to be filtered. An address and mask of all zeros means ANY.
[dstaddr=] IPAddress


Required. Specifies the destination address field of the packet to be filtered.
[dstmask=] SubnetMask


Required. Specifies the destination subnet mask of the packet to be filtered.
[proto=] any | [proto=] {tcp | tcp-est | udp}


Required. Specifies the protocol type for the packet to be filtered.
[srcport=] Port


Specifies the source port field of the packet to be filtered. A value of zero means ANY.
[dstport=] Port


Specifies the destination port field of the packet to be filtered. A value of zero means ANY.
[type=] ICMPTypeField


Specifies the ICMP type field of the packet to be filtered. A value of 255 means ANY.
[code=] ICMPCodeField


Specifies the Internet Control Message Protocol (ICMP) code field of the packet to be filtered. A value of 255 means ANY.

Examples

The following shows two different examples of adding a packet filter.

delete filter name="Virtual Private Connection" filtertype=input

srcaddr=0.0.0.0 srcmask=255.255.255.255 dstaddr=169.254.0.0

dstmask=255.255.0.0 proto=any

delete filter "Virtual Private Connection" input 0.0.0.0 0.0.0.0

169.254.0.0 255.255.0.0 any

delete interface

Removes IP forwarding from an interface.

Syntax

delete interface

[name=] InterfaceName

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface from which you want to delete IP forwarding.

Example

The following removes IP forwarding from the specified interface.

delete interface name="Local Area Connection"

delete persistentroute

Deletes a persistent static route from the specified interface.

Syntax

delete persistentroute

[dest=] IPAddress

[mask=] SubnetMask

[name=] InterfaceName

[[nhop]=IPAddress]

Parameters

[dest=] IPAddress


Required. Specifies the destination address for the specified route.
[mask=] SubnetMask


Required. Specifies the subnet mask for the destination address.
[name=] InterfaceName


Required. Specifies, by name, the interface from which the route is to be deleted.
[[nhop]=IPAddress]


Specifies the next hop address for the route. For routes over point-to-point interface, this value should not be specified.

Example

The following removes a persistent static route from the specified interface.

delete persistentroute 192.168.1.0 255.255.255.0 "Dial-up Connection"

delete preferenceforprotocol

Deletes a preference level from a specified routing protocol.

Syntax

delete preferenceforprotocol

[proto=] autostatic | local | netmgmt | nondod | ospf | rip | static

Parameters

[proto=] autostatic | local | netmgmt | nondod | ospf | rip | static


Required. Specifies the routing protocol for which a preference level is set. The autostatic parameter deletes an autostatic routing preference. The local parameter deletes a local routing preference. The netmgmt parameter deletes a routing preference for a network management protocol. The nondod parameter deletes a preference for a routing protocol not able to use demand-dial. The ospf parameter deletes a routing protocol preference for OSPF. The rip parameter deletes a routing preference for RIP. The static parameter deletes a static routing preference.

Example

The following removes the preference level from the RIP routing protocol.

delete preferenceforprotocol proto=rip

delete rtmroute

Deletes a non-persistent network management route from the specified interface or next hop count.

Syntax

delete rtmroute

[dest=] IPAddress

[mask=] SubnetMask

[name=] InterfaceName

[[nhop]=IPAddress]

Parameters

[dest=] IPAddress


Required. Specifies the destination address for the specified route.
[mask=] SubnetMask


Required. Specifies the subnet mask for the destination address.
[nameorindex=] InterfaceName


Required. Specifies, by name, the interface from which the route is to be removed.
[[nhop]=IPAddress]


Specifies the next hop address for the route. For routes over point-to-point interface, this value should not be specified.

Example

The following deletes a non-persistent static route from the specified interface and next hop address.

delete rtmroute 192.168.1.0 255.255.255.0 "Virtual Private Connection" nhop=10.0.0.1

delete scope

Deletes a multicast scope from the IP routing configuration.

Syntax

delete scope

[grpaddr=] IPAddress

[grpmask=] SubnetMask

or

delete scope

[scopename=] ScopeName

Parameters

[grpaddr=] IPAddress


Required. Specifies the multicast scope or group IP address.
[grpmask=] SubnetMask


Required. Specifies the subnet mask of the multicast scope address.
[scopename=] ScopeName


Required. Specifies the name of the multicast scope to be added.

Example

The following deletes the specified multicast scope.

delete scope 239.1.1.1 255.255.255.224 "My Multicast Scope"

set filter

Changes the default action for the filter type or fragment check setting for the specified interface.

Syntax

set filter

[name=] InterfaceName

[[filtertype=] {input | output | dial}

[action=] {drop | forward}]

[[fragcheck=] {enable | disable}]

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface for which you want to set the filter.
[[filtertype=] {input | output | dial} [action=] {drop | forward}]


Required. Specifies the type of packet filter. The input parameter specifies the filter being modified filters input. The output parameter specifies the filter being modified filters output. The dial parameter specifies the filter being modified filters a dial-up interface connection. The action parameter specifies the action to be taken when a packet does not match any filter.
[[fragcheck=] {enable | disable}]


Required. Specifies the source subnet mask of the packet to be filtered. An address and mask of all zeros means ANY.

Examples

The following shows two different examples of setting filter action.

set filter name="Dial-up Connection" filtertype=dial action =forward

set filter name="Virtual Private Connection" fragcheck=disable

set interface

Sets IP forwarding on the specified interface.

Syntax

set interface

[name=] InterfaceName

[[state=] {enable | disable}]

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface from which you want to set IP forwarding.
[[state=] {enable | disable}]


The enable parameter enables the IP interface. The disable parameter disables the IP interface.

Example

The following sets IP forwarding on the specified interface.

set interface "Local Area Connection"

set loglevel

Sets the global logging level.

Syntax

set loglevel

[loglevel=] {none | error | warn | info}

Parameters

[loglevel=] {none | error | warn | info}


Required. The none parameter turns off logging. The error parameter sets the logging level to log errors only. The warn parameter sets the logging level to include warning messages. The info parameter sets the logging level to include informational messages.

Example

The following sets global logging to log errors only.

set loglevel loglevel=error

set persistentroute

Modifies a persistent static route on the specified interface.

Syntax

set persistentroute

[dest=] IPAddress

[mask=] SubnetMask

[name=] InterfaceName

[[nhop]=IPAddress]

[[proto=] static | nondod]

[[metric=] RouteMetric]

[[view=] unicast | multicast | both]

Parameters

[dest=] IPAddress


Required. Specifies the destination address for the specified route.
[mask=] SubnetMask


Required. Specifies the subnet mask for the destination address.
[name=] InterfaceName


Required. Specifies, by name, the interface where the route is to be added.
[[nhop]=IPAddress]


Specifies the next hop address for the route. For routes over point-to-point interface, this value should not be specified.
[[proto=] static | nondod]


Specifies the demand-dial connection state. The static parameter specifies demand-dial connections are triggered. The nondod parameter specifies demand-dial connections are not triggered.
[[metric=] RouteMetric]


Specifies the route metric.
[[view=] unicast | multicast | both]


Specifies valid traffic for the route. The unicast parameter specifies the route is valid for unicast traffic only. The multicast parameter specifies the route is valid for multicast traffic only. The both parameter specifies the route is valid for both unicast and multicast traffic. The default value is both.

Example

The following modifies a persistent static route on the specified interface.

set persistentroute 192.168.1.0 255.255.255.0 "Virtual Private Connection"

set preferenceforprotocol

Sets a new preference level to a specified routing protocol.

Syntax

set preferenceforprotocol

[proto=] autostatic | local | netmgmt | nondod | ospf | rip | static [preflevel=] PreferenceLevel

Parameters

[proto=] autostatic | local | netmgmt | nondod | ospf | rip | static


Required. Specifies the routing protocol for which a preference level is set. The autostatic parameter adds an autostatic routing preference. The local parameter adds a local routing preference. The netmgmt parameter adds a routing preference for a network management protocol. The nondod parameter adds a preference for a routing protocol not able to use demand-dial. The ospf parameter adds a routing protocol preference for OSPF. The rip parameter adds a routing preference for RIP. The static parameter adds a static routing preference.
[preflevel=] PreferenceLevel


Required. Specifies the preference level.

Example

The following sets a preference level of 20 for the RIP routing protocol.

set preferenceforprotocol proto=rip preflevel=20

set rtmroute

Modifies a non-persistent network management route for the specified interface or next hop count.

Syntax

add rtmroute

[dest=] IPAddress

[mask=] SubnetMask

[name=] InterfaceName

[[nhop]=IPAddress]

[[proto=] static | nondod]

[[metric=] RouteMetric]

[[view=] unicast | multicast | both]

Parameters

[dest=] IPAddress


Required. Specifies the destination address for the specified route.
[mask=] SubnetMask


Required. Specifies the subnet mask for the destination address.
[nameorindex=] InterfaceName


Required. Specifies, by name, the interface where the route is to be added.
[[nhop]=IPAddress]


Specifies the next hop address for the route. For routes over point-to-point interface, this value should not be specified.
[[metric=] RouteMetric]


Specifies the route metric.
[[view=] unicast | multicast | both]


Specifies valid traffic for the route. The unicast parameter specifies the route is valid for unicast traffic only. The multicast parameter specifies the route is valid for multicast traffic only. The both parameter specifies the route is valid for both unicast and multicast traffic. The default value is both.

Example

The following sets a non-persistent network management route for the specified interface.

set rtmroute 192.168.1.0 255.255.255.0 "Virtual Private Connection"

set scope

Sets the name of a multicast scope.

Syntax

set scope

[grpaddr=] IPAddress

[grpmask=] SubnetMask

[scopename=] ScopeName

Parameters

[grpaddr=] IPAddress


Required. Specifies the multicast scope or group IP address.
[grpmask=] SubnetMask


Required. Specifies the subnet mask of the multicast scope address.
[scopename=] ScopeName


Required. Specifies the name of the multicast scope.

Example

The following sets the multicast scope to the specified name.

set scope 239.1.1.1 255.255.255.224 "My Multicast Scope"

set updateroutes

Updates the routing information for the specified interface.

Syntax

set updateroutes

[name=] InterfaceName

Parameters

[name=] InterfaceName


Required. Specifies, by name, the interface for which to update routing information. If no interface is specified, all interfaces are updated.

Example

The following updates routing information for all interfaces.

set updateroutes

show boundary

Displays the configured multicast scope boundaries.

Syntax

show boundary

show boundarystats

Displays the current IP multicast boundaries.

Syntax

show boundarystats

[rr=] RefreshRate

Parameters

[rr=] RefreshRate


Specifies the refresh rate time, in seconds.

Example

The following shows the current IP multicast boundary statistics and refreshes the display every 3 seconds until CTRL+C is entered to exit the display cycle.

show boundarystats rr=3

show filter

Displays packet filter information for the specified interface.

Syntax

show filter

[name=] InterfaceName

Parameters

[name=] InterfaceName


Specifies, by name, the interface for which to display filter information. If no interface is specified, filter information for all interfaces is displayed.

Examples

The following shows two different examples of displaying filter information.

show filter

show filter name="Local Area Connection"

show interface

Displays interface information for the specified interface. Used without parameters, show interface displays configuration information for all interfaces.

Syntax

show interface

[name=] InterfaceName

Parameters

[name=] InterfaceName


Specifies, by name, the interface for which you want to display information. The InterfaceName parameter must match the name of the interface as specified in Network Connections. If InterfaceName contains spaces, use quotation marks around the text (for example, "Interface Name").

Examples

The following shows two different examples of displaying interface information.

show interface

show interface name="Local Area Connection"

show loglevel

Displays global logging level information such as whether logging is turned off and whether errors, warnings, and informational messages are being logged.

Syntax

show loglevel

show mfe

Displays multicast forwarding entries (MFE).

Syntax

show mfe

[[grpaddr=] IPAddress

[grpmask=] SubnetMask]

[[srcaddr=] IPAddress

[srcmask=] SubnetMask]

[[type=] {active | negative | both}]

[[rr=] RefreshRate]

Parameters

[[grpaddr=] IPAddress


Specifies the group IP address for the start of the range.
[grpmask=] SubnetMask]


Specifies the subnet mask associated with the group IP address.
[[srcaddr=] IPAddress


Specifies the source IP address of the start of the range.
[srcmask=] SubnetMask]


Specifies the subnet mask associated with the source IP address.
[[type=] {active | negative | both}]


Specifies the type of multicast forwarding entry. The active parameter specifies displaying active MFE only. The negative parameter specifies displaying negative MFE only. The both parameter specifies displaying both active and negative MFE. The default value is both.
[[rr=] RefreshRate]


Specifies the refresh rate in seconds.

Examples

The following shows two different examples of displaying multicast forwarding entries.

show mfe

show mfe grpaddr=239.0.0.1 mask=255.255.255.255

show mfestats

Displays multicast forwarding entry (MFE) statistics.

Syntax

show mfe

[[grpaddr=] IPAddress

[grpmask=] SubnetMask]

[[srcaddr=] IPAddress

[srcmask=] SubnetMask]

[[type=] {active | negative | both}]

[[stats=] all]

[[rr=] RefreshRate]

Parameters

[[grpaddr=] IPAddress


Specifies the group IP address for the start of the range.
[grpmask=] SubnetMask]


Specifies the subnet mask associated with the group IP address.
[[srcaddr=] IPAddress


Specifies the source IP address of the start of the range.
[srcmask=] SubnetMask]


Specifies the subnet mask associated with the source IP address.
[[type=] {active | negative | both}]


Specifies the type of multicast forwarding entry. The active parameter specifies displaying active MFE only. The negative parameter specifies displaying negative MFE only. The both parameter specifies displaying both active and negative MFE. The default value is both.
[[stats=] all]


Specify all to show all detailed MFE statistics.
[[rr=] RefreshRate]


Specifies the refresh rate for MFE statistics in seconds.

Examples

The following shows two different examples of displaying multicast forwarding entry statistics.

show mfestats

show mfestats grpaddr=239.0.0.1 mask=255.255.255.255

show persistentroutes

Displays information about persistent static routes for the specified interface.

Syntax

show persistentroutes

[name=] InterfaceName

Parameters

[name=] InterfaceName


Specifies, by name, the interface for which to display persistent static route information. If no interface is specified, information for all interfaces is displayed.

Examples

The following shows two different examples of displaying interface information.

show persistentroutes

show persistentroutes name="Local Area Connection"

show preferenceforprotocol

Displays preference levels for all protocols.

Syntax

show preferenceforprotocol

show protocol

Displays all configured IP protocols.

Syntax

show protocol

show rtmdestinations

Displays destinations in the routing table.

Syntax

show rtmdestinations

[[operator=] {matching | shorterthan | longerthan}]

[[dest=] IPAddress

[mask=] SubnetMask]

[[view=] unicast | multicast | both]

[[proto=] autostatic | local | netmgmt | nondod | rip | static]

Parameters

[[operator=] {matching | shorterthan | longerthan}]


Specifies the operator for the destination address. The matching parameter specifies displaying routes matching the specified destination. The shorterthan parameter specifies displaying routes less than the destination. The longerthan parameter specifies displaying routes longer than the destination.
[[dest=] IPAddress


Specifies the address of the destination.
[mask=] SubnetMask]


Specifies the subnet mask for the destination address.
[[view=] unicast | multicast | both]


Specifies the type of traffic viewed. The unicast parameter specifies displaying only routes used for unicast traffic. The multicast parameter specifies displaying only routes used for multicast traffic. The both parameter specifies displaying routes used for both unicast and multicast traffic. The default value is both.
[proto=] autostatic | local | netmgmt | nondod | rip | static]


Specifies displaying routes added by a specific routing protocol. The autostatic parameter displays only autostatic protocol routes. The local parameter displays only local protocol routes. The netmgmt parameter displays only network management protocol routes. The nondod parameter displays only routes not able to use demand-dial. The rip parameter displays only RIP protocol routes. The static parameter displays only static protocol routes.

Examples

The following displays all prefixes in the routing table.

show rtmdestinations

The following displays all prefixes shorter than 10.0.0.1.

show rtmdestinations sh 10.0.0.1

The following displays all prefixes in the 172.0.0.0/8 subtree.

show rtmdestinations lo 172/8

show rtmroutes

Displays routes in the routing table.

Syntax

show rtmroutes

[[operator=] {matching | shorterthan | longerthan}]

[[dest=] IPAddress

[mask=] SubnetMask]

[[view=] unicast | multicast | both]

[[proto=] autostatic | local | netmgmt | nondod | rip | static]

Parameters

[[operator=] {matching | shorterthan | longerthan}]


Specifies the operator for the destination address. The matching parameter specifies displaying routes matching the specified destination. The shorterthan parameter specifies displaying routes less than the destination. The longerthan parameter specifies displaying routes longer than the destination.
[[dest=] IPAddress


Specifies the address of the destination.
[mask=] SubnetMask]


Specifies the subnet mask for the destination address.
[[view=] unicast | multicast | both]


Specifies the type of traffic viewed. The unicast parameter specifies displaying only routes used for unicast traffic. The multicast parameter specifies displaying only routes used for multicast traffic. The both parameter specifies displaying routes used for both unicast and multicast traffic. The default value is both.
[proto=] autostatic | local | netmgmt | nondod | rip | static]


Specifies displaying routes added by a specific routing protocol. The autostatic parameter displays only autostatic protocol routes. The local parameter displays only local protocol routes. The netmgmt parameter displays only network management protocol routes. The nondod parameter displays only routes not able to use demand-dial. The rip parameter displays only RIP protocol routes. The static parameter displays only static protocol routes.

Examples

The following displays all routes in the routing table.

show rtmroutes

The following displays all routes shorter than 10.0.0.1.

show rtmroutes sh 10.0.0.1

The following displays all routes in the 172.0.0.0/8 subtree.

show rtmroutes lo 172/8

show scope

Displays the multicast scopes configured on the router.

Syntax

show scope