- Table of Contents
-
- 06-Layer 3 - IP Services Command Reference
- 00-Preface
- 01-ARP Commands
- 02-IP Addressing Commands
- 03-DHCP Commands
- 04-DNS Commands
- 05-NAT Commands
- 06-IP Forwarding Basics Commands
- 07-Adjacency Table Commands
- 08-IP Performance Optimization Commands
- 09-UDP Helper Commands
- 10-IPv6 Basics Commands
- 11-DHCPv6 Commands
- 12-IPv6 DNS Commands
- 13-Tunneling Commands
- Related Documents
-
Title | Size | Download |
---|---|---|
06-IP Forwarding Basics Commands | 84.87 KB |
IP forwarding basics commands
display fib
Syntax
display fib [ multiple-topology topology-name | vpn-instance vpn-instance-name ] [ acl acl-number | ip-prefix ip-prefix-name ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default level
1: Monitor level
Parameters
multiple-topology topology-name: Displays the FIB entries of a specified topology. topology-name is a case-sensitive string of 1 to 31 characters. Without this argument, the command displays the FIB entries of the global topology.
vpn-instance vpn-instance-name: Displays the FIB entries of the specified VPN. The vpn-instance-name argument is a case-sensitive string of 1 to 31 characters. Without this option specified, the FIB entries of the public network are displayed.
acl acl-number: Displays FIB entries matching a specified ACL numbered from 2000 to 2999. If the specified ACL does not exist, all FIB entries are displayed.
ip-prefix ip-prefix-name: Displays FIB entries matching a specified IP prefix list, a string of 1 to 19 characters. If the specified IP prefix list does not exist, all FIB entries are displayed.
|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.
begin: Displays the first line that matches the specified regular expression and all lines that follow.
exclude: Displays all lines that do not match the specified regular expression.
include: Displays all lines that match the specified regular expression.
regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.
Description
Use the display fib command to display FIB entries. If no parameters are specified, all FIB entries are displayed.
Examples
# Display all FIB entries.
<Sysname> display fib
Destination count: 4 FIB entry count: 4
Flag:
U:Useable G:Gateway H:Host B:Blackhole D:Dynamic S:Static
R:Relay
Destination/Mask Nexthop Flag OutInterface InnerLabel Token
10.2.0.0/16 10.2.1.1 U GE3/0/1 Null Invalid
10.2.1.1/32 127.0.0.1 UH InLoop0 Null Invalid
127.0.0.0/8 127.0.0.1 U InLoop0 Null Invalid
127.0.0.1/32 127.0.0.1 UH InLoop0 Null Invalid
# Display FIB entries matching ACL 2000.
<Sysname> system-view
[Sysname] acl number 2000
[Sysname-acl-basic-2000] rule permit source 10.2.0.0 0.0.255.255
[Sysname-acl-basic-2000] display fib acl 2000
Destination count: 2 FIB entry count: 2
Flag:
U:Useable G:Gateway H:Host B:Blackhole D:Dynamic S:Static
R:Relay
Destination/Mask Nexthop Flag OutInterface InnerLabel Token
10.2.0.0/16 10.2.1.1 U GE3/0/1 Null Invalid
10.2.1.1/32 127.0.0.1 UH InLoop0 Null Invalid
# Display all entries that contain the string 127 and start from the first one.
<Sysname> display fib | begin 127
Flag:
U:Useable G:Gateway H:Host B:Blackhole D:Dynamic S:Static
R:Relay
Destination/Mask Nexthop Flag OutInterface InnerLabel Token
10.2.1.1/32 127.0.0.1 UH InLoop0 Null Invalid
127.0.0.0/8 127.0.0.1 U InLoop0 Null Invalid
127.0.0.1/32 127.0.0.1 UH InLoop0 Null Invalid
# Display FIB information matching the IP prefix list abc0.
<Sysname> system-view
[Sysname] ip ip-prefix abc0 permit 10.2.0.0 16
[Sysname] display fib ip-prefix abc0
Destination count: 1 FIB entry count: 1
Flag:
U:Useable G:Gateway H:Host B:Blackhole D:Dynamic S:Static
R:Relay
Destination/Mask Nexthop Flag OutInterface InnerLabel Token
10.2.0.0/16 10.2.1.1 U GE3/0/1 Null Invalid
Field |
Description |
Destination count |
Total number of destination addresses |
FIB entry count |
Total number of FIB entries |
Destination/Mask |
Destination address/length of mask |
Nexthop |
Next hop address |
Flag |
Flags of routes: · U—Usable route · G—Gateway route · H—Host route · B—Blackhole route · D—Dynamic route · S—Static route · R—Relay route |
OutInterface |
Outbound interface |
InnerLabel |
Inner label |
Token |
Link-state packet (LSP) index number |
display fib ip-address
Syntax
display fib [ multiple-topology topology-name | vpn-instance vpn-instance-name ] ip-address [ mask | mask-length ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default level
1: Monitor level
Parameters
multiple-topology topology-name: Displays the FIB entries of a specified topology. topology-name is a case-sensitive string of 1 to 31 characters. Without this argument, the command displays the FIB entries of the global topology.
vpn-instance vpn-instance-name: Displays the FIB entries of the specified VPN. The vpn-instance-name argument is a case-sensitive string of 1 to 31 characters. Without this option specified, FIB entries of the public network are displayed.
ip-address: Destination IP address, in dotted decimal notation.
mask: IP address mask.
mask-length: Length of IP address mask.
|: Filters command output by specifying a regular expression. For more information about regular expressions, see Fundamentals Configuration Guide.
begin: Displays the first line that matches the specified regular expression and all lines that follow.
exclude: Displays all lines that do not match the specified regular expression.
include: Displays all lines that match the specified regular expression.
regular-expression: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.
Description
Use the display fib ip-address command to display FIB entries that match the specified destination IP address.
If no mask or mask length is specified, the FIB entry that matches the destination IP address and has the longest mask is displayed; if the mask or mask length is specified, the FIB entries that exactly match the specified destination IP address and mask are displayed.
Examples
# Display the FIB entry that matches the destination IP address of 10.2.1.1 and has the longest mask.
<Sysname> display fib 10.2.1.1
Destination count: 1 FIB entry count: 1
Flag:
U:Useable G:Gateway H:Host B:Blackhole D:Dynamic S:Static
R:Relay
Destination/Mask Nexthop Flag OutInterface InnerLabel Token
10.2.1.1/32 127.0.0.1 UH InLoop0 Null Invalid
For the output description, see Table 1.