Static routing configuration method

Configuration or delete static routes.

[no ] ip route ip-address

{mask | mask-length } { interfacce-name

|gateway-address } [ preference preference-value

][ reject | blackhole ]

【Parameter Description】

ip-address and mask for the destination IP address and mask, in dotted decimal notation, since the 32-bit mask is required to '1' must be consecutive, in dotted decimal notation mask may be a mask with a mask-length length instead of a mask length number of bits in the mask consecutive '1'.

interfacce-name specifies the name of the interface transmission route, gateway-address for the next hop IP address route (dotted decimal notation).

Priority for routing preference-value, ranging from 0 to 255.

reject indicate an unreachable route.

blackhole Indicates a blackhole route.

Default

Default can obtain the subnet by a subnet connected to the router destined. When configuring a static route if you do not specify a priority, the default is 60. If not specified as reject or blackhole, the default route will be reachable.

Command mode

Global Configuration Mode

【user's guidance】

Configuration Notes static route:

If the destination IP address and the mask are both 0.0.0.0, the default route, that is, when the routing table lookup, packet will be forwarded through the default route.

Of priority different configurations, flexible routing management strategies, such as configuring multiple routes to the same destination, if you specify the same priority, enables load sharing; if you specify different priorities, implement routing redundancy.

When configuring a static route, either specified transmission interface, or the next hop address, which method is employed in the end, according to the actual needs of the situation: Support for network address to link layer address resolution interface or the interface point , specifying the sending interface; an NBMA interface package X.25 or frame relay interfaces, dial-up ports, and support multipoint, then in addition to configuring IP routing, the need to establish a secondary link layer route, i.e. mapping IP addresses to link-layer address (e.g. dialermap ip, x.25 map ip or frame-relay map ip, etc.), this case? configured static route can not be specified transmission interface, next hop IP address should be configured .

Examples

Configuring the default route next hop is 129.102.0.2.

Quidway(config)#ip route 0.0.0.0 0.0.0.0 129.102.0.2

Guess you like

Origin blog.51cto.com/14748718/2480562