22-2
Defau
avoid too larg
Whe
in the routing table,
default route, the packet will be discarded and an ICMP Destination Unreachable or
Network Unreachable packet will be returned to the source.
gured or generated by some dynamic routing protocols, such as
Static Route Configuration
Conf
r
Before configuring a static route, perform the following tasks:
parameters of related interfaces
Configuring a Static Route
F
conf
ute:
lt Route
To
e a routing table, you can configure a default route.
n the destination address of a packet fails to match any entry
z
If there is default route in the routing table, the default route will be selected to forward the packet.
z
If there is no
A default route can be manually confi
OSPF and RIP.
igu ation Prerequisites
z
Configuring the physical
z
Configuring IP addresses for related interfaces
ollow these steps to
igure a static ro
Use the command...
Re
To do...
marks
Enter system view
system-view
—
Configure a static
route
length
} {
interface-type
interface-number
|
next-hop
} [
preference
preference-value
] [
reject
|
blackhole
]
[
detect-group group number
] [
description
text
]
By default, the system
can obtain the route to the
subnet directly connected
to the router.
ip route-static
ip-address
{
mask
|
mask-
Required
z
ip route-static
command to configure a default route by setting the destination IP address
terface on the local
switch.
Different preferences can be configured to implement flexible route management policies.
ssing
Auto Detect
.
Use the
and the mask to 0.0.0.0.
z
Avoid configuring the next hop address of a static route to the address of an in
z
z
For automatic detection information, refer to the part discu
Displaying and Maintaining Static Routes
To do...
Use the command...
Remarks
Display the current configuration
display current-configuration
Available in
any view
information