CLI Procedures - IPv6 Static Routes
This section includes some basic procedures for managing static routes using the CLI.
To show IPv6 static routes:
Run:
> show ipv6 route static
Output
Codes: C - Connected, S - Static, B - BGP, Rg - RIPng, A - Aggregate,
O - OSPFv3 IntraArea (IA - InterArea, E - External),
K - Kernel Remnant, H - Hidden, P - Suppressed
S 3100:55::1/64 is directly connected
S 3200::/64 is a blackhole route
S 3300:123::/64 is a blackhole route
S 3600:20:20:11::/64 is directly connected, eth3
To add an IPv6 static route:
Run:
> set ipv6 static-route <dest_ip> nexthop gateway <gw_ip> on > set ipv6 static-route <dest_ip> nexthop gateway <gw_ip> interface <gw_if> on
Parameter
|
Description
|
<dest_ip>
|
Destination IPv6 address
|
<gw_ip>
|
Next hop gateway IPv6 address
|
<gw_if>
|
Next hop gateway interface name
|
Example:
> set ipv6 static-route 3100:192::0/64 nexthop gateway 3900:172::1 on > set ipv6 static-route 3100:192::0/64 nexthop gateway 3900:172::1 interface eth3 on
To add an IPv6 static route with paths and priorities:
Run:
> set static-route <dest_ip> nexthop gateway <gw_ip> priority <p_val>
Parameter
|
Description
|
<dest_ip>
|
Destination IP address
|
<gw_ip>
|
Next hop gateway IP address
|
<p_val>
|
Integer between 1 and 8
Default - 1
|
Run this command for each path. Assign a priority value to each. You can define two or more paths using the same priority to specify a backup path with the same priority.
Example:
> set ipv6 static-route 3100:192::0/64 nexthop gateway 3900:172::1 priority 3 on
To add an IPv6 static route where packets are dropped:
Run:
> set ipv6 static-route <dest_ip> nexthop <mess_option>
Parameter
|
Description
|
<dest_ip>
|
Destination IP address
|
<mess_option>
|
Sets whether to send an error message
Allowed values:
Reject - Drops packets and sends an error message to the traffic source.Blackhole - Drops packets , but does not send an error message
|
Examples:
> set ipv6 static-route 3100:192::0/64 nexthop reject
> set ipv6 static-route 3100:192::0/64 nexthop blackhole
To delete an IPv6 route and all related paths:
Run:
> set ipv6 static-route <dest_ip> off
Example:
> set ipv6 static-route 3100:192::0/64 off
To delete a path only:
Run:
> set static-route <dest_ip> nexthop gateway <gw_ip> off
Parameter
|
Description
|
<dest_ip>
|
Destination IP address
|
<gw_ip>
|
Next hop gateway IP address or interface name
|
Example:
> set ipv6 static-route 3100:192::0/64 nexthop gateway 3900:172::1 off
|