docs: add useful debug CLI
[vpp.git] / docs / reference / cmdreference / show / show.rst
1 .. _interface:
2
3 .. toctree::
4
5 .. note:: For a complete list of CLI Debug commands refer to the Debug CLI section of the `Source Code Documents <https://docs.fd.io/vpp/18.07/clicmd.html>`_ .
6
7 Show Bridge-Domain
8 ===================
9
10 `Show Bridge-Domain <../interface/hardware.html#show-bridge-domain>`_
11
12 Show Interface
13 ================
14
15 `Show Interface <../interface/basic.html#show-interface>`_
16
17 Show IP Arp
18 ============
19
20 Summary/Usage
21 ---------------
22
23 show ip arp
24
25 Description
26 ------------
27
28 Display all the IPv4 ARP entries.
29
30 Example Usage
31 --------------
32 Example of how to display the IPv4 ARP table:
33
34 .. code-block:: console
35
36    vpp# **show ip arp**
37        Time      FIB        IP4       Flags      Ethernet              Interface
38        346.3028   0       6.1.1.3            de:ad:be:ef:ba:be   GigabitEthernet2/0/0
39       3077.4271   0       6.1.1.4       S    de:ad:be:ef:ff:ff   GigabitEthernet2/0/0
40       2998.6409   1       6.2.2.3            de:ad:be:ef:00:01   GigabitEthernet2/0/0
41     Proxy arps enabled for:
42     Fib_index 0   6.0.0.1 - 6.0.0.11
43
44
45 Declaration and Implementation
46 -------------------------------
47
48 **Declaration:** show_ip4_arp_command (src/vnet/ethernet/arp.c line 1465)
49
50 **Implementation:** show_ip4_arp
51
52 Show IP Fib
53 =============
54
55 Summary/Usage
56 ---------------
57
58 show ip fib [summary] [table <*table-id*>] [index <*fib-id*>] [<*ip4-addr*>[/<*mask*>]] [mtrie] [detail]
59
60 Description
61 ------------
62
63 This command displays the IPv4 FIB Tables (VRF Tables) and the route entries for each table.
64
65 .. note::
66         This command will run for a long time when the FIB tables are comprised of millions of entries. For those senarios, consider displaying a single table or summary mode.
67
68 Example Usage
69 --------------
70 Example of how to display all the IPv4 FIB tables:
71
72 .. code-block:: console
73
74     vpp# **show ip fib**
75
76     ipv4-VRF:0, fib_index 0, flow hash: src dst sport dport proto
77     0.0.0.0/0
78       unicast-ip4-chain
79       [@0]: dpo-load-balance: [index:0 buckets:1 uRPF:0 to:[0:0]]
80       [0] [@0]: dpo-drop ip6
81     0.0.0.0/32
82       unicast-ip4-chain
83       [@0]: dpo-load-balance: [index:1 buckets:1 uRPF:1 to:[0:0]]
84       [0] [@0]: dpo-drop ip6
85     6.0.1.2/32
86       unicast-ip4-chain
87       [@0]: dpo-load-balance: [index:30 buckets:1 uRPF:29 to:[0:0]]
88       [0] [@3]: arp-ipv4: via 6.0.0.1 af_packet0
89     7.0.0.1/32
90       unicast-ip4-chain
91       [@0]: dpo-load-balance: [index:31 buckets:4 uRPF:30 to:[0:0]]
92       [0] [@3]: arp-ipv4: via 6.0.0.2 af_packet0
93       [1] [@3]: arp-ipv4: via 6.0.0.2 af_packet0
94       [2] [@3]: arp-ipv4: via 6.0.0.2 af_packet0
95       [3] [@3]: arp-ipv4: via 6.0.0.1 af_packet0
96     224.0.0.0/8
97       unicast-ip4-chain
98       [@0]: dpo-load-balance: [index:3 buckets:1 uRPF:3 to:[0:0]]
99       [0] [@0]: dpo-drop ip6
100     240.0.0.0/8
101       unicast-ip4-chain
102       [@0]: dpo-load-balance: [index:2 buckets:1 uRPF:2 to:[0:0]]
103       [0] [@0]: dpo-drop ip6
104     255.255.255.255/32
105       unicast-ip4-chain
106       [@0]: dpo-load-balance: [index:4 buckets:1 uRPF:4 to:[0:0]]
107       [0] [@0]: dpo-drop ip6
108     ipv4-VRF:7, fib_index 1, flow hash: src dst sport dport proto
109     0.0.0.0/0
110       unicast-ip4-chain
111       [@0]: dpo-load-balance: [index:12 buckets:1 uRPF:11 to:[0:0]]
112       [0] [@0]: dpo-drop ip6
113     0.0.0.0/32
114       unicast-ip4-chain
115       [@0]: dpo-load-balance: [index:13 buckets:1 uRPF:12 to:[0:0]]
116       [0] [@0]: dpo-drop ip6
117     172.16.1.0/24
118       unicast-ip4-chain
119       [@0]: dpo-load-balance: [index:17 buckets:1 uRPF:16 to:[0:0]]
120       [0] [@4]: ipv4-glean: af_packet0
121     172.16.1.1/32
122       unicast-ip4-chain
123       [@0]: dpo-load-balance: [index:18 buckets:1 uRPF:17 to:[1:84]]
124       [0] [@2]: dpo-receive: 172.16.1.1 on af_packet0
125     172.16.1.2/32
126       unicast-ip4-chain
127       [@0]: dpo-load-balance: [index:21 buckets:1 uRPF:20 to:[0:0]]
128       [0] [@5]: ipv4 via 172.16.1.2 af_packet0: IP4: 02:fe:9e:70:7a:2b -> 26:a5:f6:9c:3a:36
129     172.16.2.0/24
130       unicast-ip4-chain
131       [@0]: dpo-load-balance: [index:19 buckets:1 uRPF:18 to:[0:0]]
132       [0] [@4]: ipv4-glean: af_packet1
133     172.16.2.1/32
134       unicast-ip4-chain
135       [@0]: dpo-load-balance: [index:20 buckets:1 uRPF:19 to:[0:0]]
136       [0] [@2]: dpo-receive: 172.16.2.1 on af_packet1
137     224.0.0.0/8
138       unicast-ip4-chain
139       [@0]: dpo-load-balance: [index:15 buckets:1 uRPF:14 to:[0:0]]
140       [0] [@0]: dpo-drop ip6
141     240.0.0.0/8
142       unicast-ip4-chain
143       [@0]: dpo-load-balance: [index:14 buckets:1 uRPF:13 to:[0:0]]
144       [0] [@0]: dpo-drop ip6
145     255.255.255.255/32
146       unicast-ip4-chain
147       [@0]: dpo-load-balance: [index:16 buckets:1 uRPF:15 to:[0:0]]
148       [0] [@0]: dpo-drop ip6
149
150 Example of how to display a single IPv4 FIB table:
151
152 .. code-block:: console
153
154     vpp# **show ip fib table 7**
155
156     ipv4-VRF:7, fib_index 1, flow hash: src dst sport dport proto
157     0.0.0.0/0
158       unicast-ip4-chain
159       [@0]: dpo-load-balance: [index:12 buckets:1 uRPF:11 to:[0:0]]
160       [0] [@0]: dpo-drop ip6
161     0.0.0.0/32
162       unicast-ip4-chain
163       [@0]: dpo-load-balance: [index:13 buckets:1 uRPF:12 to:[0:0]]
164       [0] [@0]: dpo-drop ip6
165     172.16.1.0/24
166       unicast-ip4-chain
167       [@0]: dpo-load-balance: [index:17 buckets:1 uRPF:16 to:[0:0]]
168       [0] [@4]: ipv4-glean: af_packet0
169     172.16.1.1/32
170       unicast-ip4-chain
171       [@0]: dpo-load-balance: [index:18 buckets:1 uRPF:17 to:[1:84]]
172       [0] [@2]: dpo-receive: 172.16.1.1 on af_packet0
173     172.16.1.2/32
174       unicast-ip4-chain
175       [@0]: dpo-load-balance: [index:21 buckets:1 uRPF:20 to:[0:0]]
176       [0] [@5]: ipv4 via 172.16.1.2 af_packet0: IP4: 02:fe:9e:70:7a:2b -*> 26:a5:f6:9c:3a:36
177     172.16.2.0/24
178       unicast-ip4-chain
179       [@0]: dpo-load-balance: [index:19 buckets:1 uRPF:18 to:[0:0]]
180       [0] [@4]: ipv4-glean: af_packet1
181     172.16.2.1/32
182       unicast-ip4-chain
183       [@0]: dpo-load-balance: [index:20 buckets:1 uRPF:19 to:[0:0]]
184       [0] [@2]: dpo-receive: 172.16.2.1 on af_packet1
185     224.0.0.0/8
186       unicast-ip4-chain
187       [@0]: dpo-load-balance: [index:15 buckets:1 uRPF:14 to:[0:0]]
188       [0] [@0]: dpo-drop ip6
189     240.0.0.0/8
190       unicast-ip4-chain
191       [@0]: dpo-load-balance: [index:14 buckets:1 uRPF:13 to:[0:0]]
192       [0] [@0]: dpo-drop ip6
193     255.255.255.255/32
194       unicast-ip4-chain
195       [@0]: dpo-load-balance: [index:16 buckets:1 uRPF:15 to:[0:0]]
196       [0] [@0]: dpo-drop ip6
197
198 Example of how to display a summary of all IPv4 FIB tables:
199
200 .. code-block:: console
201
202     vpp# **show ip fib summary**
203
204     ipv4-VRF:0, fib_index 0, flow hash: src dst sport dport proto
205         Prefix length         Count
206                        0               1
207                        8               2
208                       32               4
209     ipv4-VRF:7, fib_index 1, flow hash: src dst sport dport proto
210         Prefix length         Count
211                        0               1
212                        8               2
213                       24               2
214                       32               4
215
216 Declaration and Implementation
217 -------------------------------
218
219 **Declaration:** ip4_show_fib_command (src/vnet/fib/ip4_fib.c line 873)
220
221 **Implementation:** ip4_show_fib
222
223 Show L2fib
224 ============
225
226 Summary/Usage
227 ------------------
228
229 show l2fib [all] | [bd_id <*nn*> | bd_index <*nn*>] [learn | add] | [raw]
230
231 Description
232 ------------
233
234 This command displays the MAC Address entries of the L2 FIB table. Output can be filtered to just get the number of MAC Addresses or display each MAC Address for all bridge domains or just a single bridge domain.
235
236 Example Usage
237 --------------
238 Example of how to display the number of MAC Address entries in the L2 FIB table:
239
240
241 .. code-block:: console
242
243     vpp# **show l2fib**
244
245     3 l2fib entries
246
247     Example of how to display all the MAC Address entries in the L2 FIB table:
248
249     vpp# **show l2fib all**
250
251         Mac Address     BD Idx           Interface           Index  static  filter  bvi  refresh  timestamp
252      52:54:00:53:18:33    1      GigabitEthernet0/8/0.200      3       0       0     0      0         0
253      52:54:00:53:18:55    1      GigabitEthernet0/8/0.200      3       1       0     0      0         0
254      52:54:00:53:18:77    1                 N/A                -1      1       1     0      0         0
255     3 l2fib entries
256
257 Declaration and Implementation
258 -------------------------------
259
260 **Declaration:** show_l2fib_cli (src/vnet/l2/l2_fib.c line 311)
261
262 **Implementation:** show_l2fib
263
264 Show Trace
265 ===========
266
267 Summary/Usage
268 --------------
269
270 show trace buffer [max COUNT]
271
272 Declaration and Implementation
273 ------------------------------
274
275 **Declaration:** show_trace_cli (src/vlib/trace.c line 347)
276
277 **Implementation:** cli_show_trace_buffer
278
279 Show Vhost-User
280 ================
281
282 `Show Vhost-User <../vhost/vhostuser.html#show-vhost-user>`_
283