05-Layer 3—IP Routing Command Reference

HomeSupportSwitchesS6300 SeriesReference GuidesCommand ReferencesH3C S6300 Switch Series Command References-Release 243x-6W10005-Layer 3—IP Routing Command Reference
07-IPv6 static routing commands
Title Size Download
07-IPv6 static routing commands 54.71 KB

IPv6 static routing commands

delete ipv6 static-routes all

Use delete ipv6 static-routes all to delete all IPv6 static routes.

Syntax

delete ipv6 [ vpn-instance vpn-instance-name ] static-routes all

Views

System view

Default level

2: System level

Parameters

vpn-instance vpn-instance-name: Specifies a VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify this option, the command deletes all IPv6 static routes for the public network.

Usage guidelines

When you use this command, the system will prompt you to confirm the operation before deleting all the IPv6 static routes.

Examples

# Delete all IPv6 static routes.

<Sysname> system-view

[Sysname] delete ipv6 static-routes all

This will erase all IPv6 static routes and their configurations, you must reconfigure all static routes.

Are you sure?[Y/N]:y

Related commands

ipv6 route-static

display ipv6 route-static nib

Use display ipv6 route-static nib to display IPv6 static route next hop information.

Syntax

display ipv6 route-static nib [ nib-id ] [ verbose ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

nib-id: Specifies a NIB by its ID in the range of 1 to FFFFFFFF.

verbose: Displays detailed IPv6 static route next hop information. If you do not specify this keyword, the command displays brief IPv6 static route next hop information.

Examples

# Displays brief IPv6 static route next hop information.

<Sysname> display ipv6 route-static nib

Total number of nexthop(s): 35

 

      NibID: 0x21000000        Sequence: 0

       Type: 0x41               Flushed: Yes

   UserKey0: 0x0                VrfNthp: 0

   UserKey1: 0x0                Nexthop: 2::3

    IFIndex: 0x0              LocalAddr: ::

 

      NibID: 0x21000001        Sequence: 1

       Type: 0x41               Flushed: Yes

   UserKey0: 0x0                VrfNthp: 0

   UserKey1: 0x0                Nexthop: 3::4

    IFIndex: 0x0              LocalAddr: ::

 

...

Table 1 Command output

Field

Description

NibID

ID of the NIB.

Sequence

Sequence number of the NIB.

Type

Type of the NIB.

Flushed

Indicates whether the route with the NIB has been flushed to the FIB.

UserKey0

Reserved data 1.

UserKey1

Reserved data 2.

VrfNthp

Index of the VPN instance to which the next hop belongs.

Nexthop

Next hop address.

IFIndex

Interface index

LocalAddr

Local interface address.

 

# Displays detailed IPv6 static route next hop information.

<Sysname> display ipv6 route-static nib verbose

Total number of nexthop(s): 35

 

      NibID: 0x21000000        Sequence: 0

       Type: 0x41               Flushed: Yes

   UserKey0: 0x0                VrfNthp: 0

   UserKey1: 0x0                Nexthop: 2::3

    IFIndex: 0x0              LocalAddr: ::

     RefCnt: 1              FlushRefCnt: 0

       Flag: 0x12               Version: 1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 2::3

  RelyDepth: 2              RealNexthop: ::

  Interface: NULL0            LocalAddr: ::

  TunnelCnt: 0                      Vrf: default-vrf

   TunnelID: N/A

 

      NibID: 0x21000001        Sequence: 1

       Type: 0x41               Flushed: Yes

   UserKey0: 0x0                VrfNthp: 0

   UserKey1: 0x0                Nexthop: 3::4

    IFIndex: 0x0              LocalAddr: ::

     RefCnt: 1              FlushRefCnt: 0

       Flag: 0x12               Version: 1

 1 nexthop(s):

PrefixIndex: 0              OrigNexthop: 3::4

  RelyDepth: 1              RealNexthop: ::

  Interface: NULL0            LocalAddr: ::

  TunnelCnt: 0                      Vrf: default-vrf

   TunnelID: N/A

 

...

Table 2 Command output

Field

Description

x nexthop(s)

Number of next hops.

PrefixIndex

Prefix index of the next hop for an ECMP route.

Vrf

VPN instance name.

OrigNexthop

Original next hop.

RealNexthop

Real next hop.

Interface

Output interface.

localAddr

Local interface address.

RelyDepth

Recursion depth.

TunnelCnt

This field is not supported in the current software version.

Number of tunnels after route recursion.

TunnelID

This field is not supported in the current software version.

ID of the tunnel after route recursion.

RefCnt

Reference count of the next hop.

FlushRefCnt

Reference count of the next hop that is flushed to the FIB.

Flag

Flag of the next hop.

Version

Version of the next hop.

 

display ipv6 route-static routing-table

Use display ipv6 route-static routing-table to display IPv6 static routing table information.

Syntax

display ipv6 route-static routing-table [ vpn-instance vpn-instance-name ] [ ipv6-address prefix-length ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

vpn-instance vpn-instance-name: Specifies a VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify this option, the command displays IPv6 static routing table information for the public network.

ipv6-address: Specifies the destination IPv6 address.

prefix-length: Specifies the prefix length in the range of 0 to 128.

Examples

# Display IPv6 static routing table information.

<Sysname> display ipv6 route-static routing-table

Total number of routes: 5

 

Status: * - valid

 

*Destination: 1::1/128

       NibID: 0x21000000        NextHop: 2::2

   MainNibID: N/A             BkNextHop: N/A

     BkNibID: N/A             Interface: Ethernet2/1

     TableID: 0xa           BkInterface: N/A

        Flag: 0x80d0a          BfdSrcIp: N/A

     DbIndex: 0x3            BfdIfIndex: 0x0

        Type: Normal        BfdVrfIndex: 0

  TrackIndex: 0xffffffff          Label: NULL

  Preference: 60            vrfIndexDst: 0

    BfdMode: N/A            vrfIndexNH: 0

  Permanent: 0                     Tag: 0

 

*Destination: 1::1234/128

      NibID: 0x21000000        NextHop: 2::2

  MainNibID: N/A             BkNextHop: N/A

    BkNibID: N/A             Interface: NULL0

    TableID: 0xa           BkInterface: N/A

       Flag: 0x80d0a          BfdSrcIp: N/A

    DbIndex: 0x1            BfdIfIndex: 0x0

       Type: Normal        BfdVrfIndex: 0

 TrackIndex: 0xffffffff          Label: NULL

 Preference: 60            vrfIndexDst: 0

    BfdMode: N/A            vrfIndexNH: 0

  Permanent: 0                     Tag: 0

 

...

# Display information about the IPv6 static route with destination IPv6 address 1::1/128.

<Sysname> display ipv6 route-static routing-table 1::1 128

 

*Destination: 1::1/128

      NibID: 0x21000001        NextHop: 2::2

  MainNibID: N/A             BkNextHop: N/A

    BkNibID: N/A             Interface: Ethernet2/1

    TableID: 0xa           BkInterface: N/A

       Flag: 0x80d0b          BfdSrcIp: N/A

    DbIndex: 0x2            BfdIfIndex: 0x0

       Type: Normal        BfdVrfIndex: 0

 TrackIndex: 0xffffffff          Label: NULL

 Preference: 60            vrfIndexDst: 0

    BfdMode: N/A            vrfIndexNH: 0

  Permanent: 0                     Tag: 429496729

Table 3 Command output

Field

Description

destination

Destination address/prefix.

NibID

ID of the NIB.

MainNibID

ID of the primary next hop for static route FRR.

BkNibID

ID of the backup next hop for static route FRR.

NextHop

Next hop address.

BkNextHop

Backup next hop address.

Interface

Output interface of the route.

BkInterface

Backup output interface.

TableID

ID of the table to which the route belongs.

DbIndex

Index of the database to which the route belongs.

Type

Route type:

·     Normal.

·     DHCP.

·     NAT.

BfdSrcIp

Source IPv6 address of the indirect BFD session.

BfdIfIndex

Index of the interface where BFD is enabled.

BfdVrfIndex

Index of the VPN instance where BFD is enabled.

BfdMode

BFD session mode:

·     N/ANo BFD session is configured.

·     CtrlControl packet mode.

·     EchoEcho packet mode.

TrackIndex

NQA Track index.

vrfIndexDst

Index of the VPN instance to which the destination belongs.

vrfIndexNH

Index of the VPN instance to which the next hop belongs.

Permanent

Permanent static route flag. 1 indicates a permanent static route.

 

ipv6 route-static

Use ipv6 route-static to configure an IPv6 static route.

Use undo ipv6 route-static to remove an IPv6 static route.

Syntax

ipv6 route-static ipv6-address prefix-length { interface-type interface-number [ next-hop-address ] [ bfd { control-packet | echo-packet } | permanent ] | next-hop-address [ bfd control-packet bfd-source ipv6-address | permanent ] | vpn-instance d-vpn-instance-name next-hop-address [ bfd control-packet bfd-source ipv6-address | permanent ] } [ preference preference-value ] [ tag tag-value ] [ description description-text ]

undo ipv6 route-static ipv6-address prefix-length [ interface-type interface-number [ next-hop-address ] | next-hop-address | vpn-instance d-vpn-instance-name next-hop-address ] [ preference preference-value ]

ipv6 route-static vpn-instance s-vpn-instance-name ipv6-address prefix-length { interface-type interface-number [ next-hop-address ] [ bfd { control-packet | echo-packet } | permanent ] | next-hop-address [ public ] [ bfd control-packet bfd-source ipv6-address | permanent ] | vpn-instance d-vpn-instance-name next-hop-address [ bfd control-packet bfd-source ipv6-address | permanent ] } [ preference preference-value ] [ tag tag-value ] [ description description-text ]

undo ipv6 route-static vpn-instance s-vpn-instance-name ipv6-address prefix-length [ interface-type interface-number [ next-hop-address ] | next-hop-address [ public ] | vpn-instance d-vpn-instance-name next-hop-address ] [ preference preference-value ]

Default

No IPv6 static route is configured.

Views

System view

Default level

2: System level

Parameters

ipv6-address prefix-length: Specifies the IPv6 address and prefix length.

interface-type interface-number: Specifies an output interface by its type and number. If the output interface is an NBMA interface or broadcast interface and not a point-to-point (P2P) interface, the next hop address must be specified. Broadcast interfaces include Ethernet interfaces and VLAN interfaces.

next-hop-address: Specifies the next hop IPv6 address.

bfd: Enables BFD to detect reachability of the static route's next hop.

control-packet: Specifies the BFD control mode.

bfd-source ipv6-address: Specifies the source IPv6 address of BFD packets. As a best practice, specify the loopback interface address.

echo-packet: Specifies the BFD echo mode.

permanent: Specifies the IPv6 route as a permanent IPv6 static route. If the output interface is down, the permanent IPv6 static route is still active.

public: Indicates the next hop is on the public network.

vpn-instance d-vpn-instance-name: Specifies a destination VPN instance by its name, a case-sensitive string of 1 to 31 characters. If a destination VPN is specified, packets will search for the output interface based on the specified next hop (IPv6 address) for the static route.

preference preference-value: Specifies a preference for IPv6 static routes, in the range of 1 to 255. The default is 60.

tag tag-value: Sets a tag for marking the static route, in the range of 1 to 4294967295. The default is 0.

description description-text: Configures a description for the IPv6 static route, which consists of 1 to 60 characters, including special characters such as the space, but excluding the question mark (?).

vpn-instance s-vpn-instance-name: Specifies a source VPN instance by its name, a case-sensitive string of 1 to 31 characters. Each VPN has its own routing table, and the configured static route is installed in the routing tables of the specified VPNs.

Usage guidelines

An IPv6 static route that has the destination address configured as ::/0 (a prefix length of 0) is the default IPv6 route. If the destination address of an IPv6 packet does not match any entry in the routing table, this default route is used to forward the packet.

If the output interface of an IPv6 static route is a broadcast interface, you must specify the next hop address. Broadcast interfaces include Ethernet interfaces and VLAN interfaces.

Follow these guidelines when you configure an IPv6 static route:

·     Enabling BFD for a flapping route could worsen the route flapping situation. Therefore, use it with caution. For more information about BFD, see High Availability Configuration Guide.

·     The next hop IPv6 address of echo packets must be a global unicast address.

·     Do not specify the permanent keyword together with the bfd or track keyword.

Examples

# Configure an IPv6 static route, with the destination address 1:1:2::/64 and next hop 1:1:3::1.

<Sysname> system-view

[Sysname] ipv6 route-static 1:1:2:: 64 1:1:3::1

Related commands

display ipv6 routing-table protocol

ipv6 route-static default-preference

Use ipv6 route-static default-preference to configure a default preference for IPv6 static routes.

Use undo ipv6 route-static default-preference to restore the default.

Syntax

ipv6 route-static default-preference default-preference-value

undo ipv6 route-static default-preference

Default

The default preference of IPv6 static routes is 60.

Views

System view

Predefined user roles

network-admin

Parameters

default-preference-value: Specifies a default preference for IPv6 static routes, in the range of 1 to 255.

Usage guidelines

If no preference is specified for an IPv6 static route, the default preference applies.

When the default preference is reconfigured, it applies only to newly added IPv6 static routes.

Examples

# Set a default preference of 120 for IPv6 static routes.

<Sysname> system-view

[Sysname] ipv6 route-static default-preference 120

Related commands

display ipv6 routing-table protocol

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become a Partner
  • Partner Resources
  • Partner Business Management
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网