- Table of Contents
-
- H3C S6116 Ultra-Low Latency Switch Series Configuration Guide-Release 671x-6W100
- 00-Preface
- 01-Interface forwarding configuration
- 02-CLI configuration
- 03-RBAC configuration
- 04-Login management configuration
- 05-FTP and TFTP configuration
- 06-File system management configuration
- 07-Configuration file management configuration
- 08-Software upgrade configuration
- 09-Device management configuration
- 10-Tcl configuration
- 11-Bulk interface configuration
- 12-IP addressing configuration
- 13-IPv6 basics configuration
- 14-Static routing configuration
- 15-IPv6 static routing configuration
- 16-AAA configuration
- 17-Public key management
- 18-SSH configuration
- 19-System maintenance and debugging configuration
- 20-NTP configuration
- 21-SNMP configuration
- 22-RMON configuration
- 23-Event MIB configuration
- 24-Information center configuration
- 25-PTP configuration
- 26-Network synchronization configuration
- Related Documents
-
Title | Size | Download |
---|---|---|
14-Static routing configuration | 75.52 KB |
Restrictions and guidelines: Static routing configuration
Display and maintenance commands for static routing
Configuring static routing
About static routes
Static routes are manually configured. If a network's topology is simple, you only need to configure static routes for the network to work correctly.
Static routes cannot adapt to network topology changes. If a fault or a topological change occurs in the network, the network administrator must modify the static routes manually.
Restrictions and guidelines: Static routing configuration
You can specify only a management Ethernet interface for a static route as the output interface, and you cannot specify a service interface as the output interface.
Configuring a static route
1. Enter system view.
system-view
2. Configure a static route.
ip route-static dest-address { mask-length | mask } interface-type interface-number [ next-hop-address ] [ description text ]
ip route-static dest-address { mask-length | mask } next-hop-address
[ description text ]
By default, no static route is configured.
3. (Optional.) Configure the default preference for static routes.
ip route-static default-preference default-preference
The default setting is 60.
Deleting static routes
About this task
To delete a static route, use the undo ip route-static command. To delete all static routes including the default route, use the delete static-routes all command.
Procedure
1. Enter system view.
system-view
2. Delete all static routes.
delete static-routes all
CAUTION: Deleting all static routes with caution. This operation might cause network connectivity failure and packet forwarding failure. |
Display and maintenance commands for static routing
Execute display commands in any view.
Task |
Command |
Display static route next hop information. |
display route-static nib [ nib-id ] [ verbose ] |
Display static routing table information. |
display route-static routing-table [ ip-address { mask-length | mask } ] |
Configuring a default route
A default route is used to forward packets that do not match any specific routing entry in the routing table. Without a default route, packets that do not match any routing entries are discarded and an ICMP destination-unreachable packet is sent to the source.
A default route can be configured in either of the following ways:
· The network administrator can configure a default route with both destination and mask being 0.0.0.0. For more information, see "Configuring static routing."
· Some dynamic routing protocols can generate a default route. For example, an upstream router can generate a default route and advertise it to other routers. These routers install the default route with the next hop being the upstream router.
As shown in Figure 1, Device B is the next hop for packets from Device A to Device C, Device D, and Device E. You can configure a default route on Device A to replace the three static routes from Device A to Device C, Device D, and Device E, respectively. Then, packets that do not match any other routes will be forwarded based on the default route.
The next hop address, destination address, and subnet mask of the default route configured on Device A are 1.1.1.2, 0.0.0.0, and 0.0.0.0, respectively.
Figure 1 Configuring a default route