]> git.proxmox.com Git - mirror_iproute2.git/blame - man/man8/bridge.8
iproute2: Fix some manpage typos
[mirror_iproute2.git] / man / man8 / bridge.8
CommitLineData
d04bc300
SH
1.TH BRIDGE 8 "1 August 2012" "iproute2" "Linux"
2.SH NAME
3bridge \- show / manipulate bridge addresses and devices
4.SH SYNOPSIS
5
6.ad l
7.in +8
8.ti -8
9.B bridge
10.RI "[ " OPTIONS " ] " OBJECT " { " COMMAND " | "
11.BR help " }"
12.sp
13
14.ti -8
15.IR OBJECT " := { "
aa2f1335 16.BR link " | " fdb " | " vlan " | " monitor " }"
d04bc300
SH
17.sp
18
19.ti -8
20.IR OPTIONS " := { "
21\fB\-V\fR[\fIersion\fR] |
aa2f1335
VY
22\fB\-s\fR[\fItatistics\fR] }
23
24.ti -8
25.BR "bridge link set"
26.B dev
27.IR DEV
28.IR " [ "
29.B cost
30.IR COST " ] [ "
31.B priority
32.IR PRIO " ] [ "
33.B state
34.IR STATE "] ["
35.BR guard " { " on " | " off " } ] [ "
36.BR hairpin " { " on " | " off " } ] [ "
37.BR fastleave " { " on " | " off " } ] [ "
38.BR root_block " { " on " | " off " } ] [ "
39.BR hwmode " { " vepa " | " veb " } ] "
40
41.ti -8
42.BR "bridge link" " [ " show " ] [ "
43.B dev
44.IR DEV " ]"
d04bc300
SH
45
46.ti -8
d611682a 47.BR "bridge fdb" " { " add " | " del " } "
d04bc300
SH
48.I LLADDR
49.B dev
50.IR DEV " { "
d611682a
JF
51.BR local " | " temp " } { "
52.BR self " } { " embedded " } "
d04bc300
SH
53
54.ti -8
55.BR "bridge fdb" " [ " show " ] [ "
56.B dev
57.IR DEV " ]"
58
ab938710
VY
59.ti -8
60.BR "bridge vlan" " { " add " | " del " } "
61.B dev
62.IR DEV
63.B vid
64.IR VID " [ "
65.BR pvid " ] [ " untagged " ] [ "
66.BR self " ] [ " master " ] "
67
68.ti -8
69.BR "bridge vlan" " [ " show " ] [ "
70.B dev
71.IR DEV " ]"
72
d04bc300
SH
73.ti -8
74.BR "bridge monitor" " [ " all " | " neigh " | " link " ]"
75
76.SH OPTIONS
77
78.TP
79.BR "\-V" , " -Version"
80print the version of the
81.B bridge
82utility and exit.
83
84.TP
85.BR "\-s" , " \-stats", " \-statistics"
49572501
KR
86output more information. If this option
87is given multiple times, the amount of information increases.
d04bc300
SH
88As a rule, the information is statistics or some time values.
89
90
91.SH BRIDGE - COMMAND SYNTAX
92
93.SS
94.I OBJECT
95
aa2f1335
VY
96.TP
97.B link
98- Bridge port.
99
d04bc300
SH
100.TP
101.B fdb
102- Forwarding Database entry.
103
ab938710
VY
104.TP
105.B vlan
106- VLAN filter list.
107
d04bc300
SH
108.SS
109.I COMMAND
110
111Specifies the action to perform on the object.
112The set of possible actions depends on the object type.
113As a rule, it is possible to
114.BR "add" , " delete"
115and
116.B show
117(or
118.B list
119) objects, but some objects do not allow all of these operations
120or have some additional commands. The
121.B help
122command is available for all objects. It prints
123out a list of available commands and argument syntax conventions.
124.sp
125If no command is given, some default command is assumed.
126Usually it is
127.B list
128or, if the objects of this class cannot be listed,
129.BR "help" .
130
aa2f1335
VY
131.SH bridge link - bridge port
132
133.B link
134objects correspond to the port devices of the bridge.
135
136.P
137The corresponding commands set and display port status and bridge specific
138attributes.
139
140.SS bridge link set - set bridge specific attributes on a port
141
142.TP
143.BI dev " NAME "
144interface name of the bridge port
145
146.TP
147.BI cost " COST "
148the STP path cost of the specified port.
149
150.TP
151.BI priority " PRIO "
152the STP port priority. The priority value is an unsigned 8-bit quantity
153(number between 0 and 255). This metric is used in the designated port an
154droot port selectio algorithms.
155
156.TP
157.BI state " STATE "
158the operation state of the port. This is primarily used by user space STP/RSTP
159implementation. The following is a list of valid values:
160
161.B 0
162- port is DISABLED. Make this port completely inactive.
163.sp
164
165.B 1
166- STP LISTENING state. Only valid if STP is enabled on the brige. In this
167state the port for list for STP BPDUs and drop all other traffic.
168.sp
169
170.B 2
171- STP LEARNING state. Only valid if STP is enabled on the bridge. In this
172state the port will accept traffic only for the purpose of updating MAC
173adress tables.
174.sp
175
176.B 3
177- STP FORWARDING state. Port is fully active.
178.sp
179
180.B 4
6274b0b7 181- STP BLOCKING state. Only valid if STP is enabled on the bridge. This state
aa2f1335
VY
182is used during the STP election process. In this state, port will only process
183STP BPDUs.
184.sp
185
186.TP
187.BR "guard on " or " guard off "
188Controls whether STP BPUDs will be processed by the bridge port. By default,
189the flag is turned off allowed BPDU processing. Turning this flag on will
190cause the port to stop processing STP BPDUs.
191
192.TP
193.BR "hairpin on " or " hairpin off "
194Controls whether traffic may be send back out of the port on which it was
195received. By default, this flag is turned off and the bridge will not forward
196traffic back out of the receiving port.
197
198.TP
199.BR "fastleave on " or " fastleave off "
200This flag allows the bridge to immediately stop multicast traffic on a port
6274b0b7 201that receives IGMP Leave message. It is only used with IGMP snooping is
aa2f1335
VY
202enabled on the bridge. By default the flag is off.
203
204.TP
205.BR "root_block on " or " root_block off "
206Controls whether a given port is allowed to become root port or not. Only used
207when STP is enabled on the bridge. By default the flag is off.
208
209.TP
210.BI hwmode
211Some network interface cards support HW bridge functionality and they may be
212configured in different modes. Currently support modes are:
213
214.B vepa
215- Data sent between HW ports is sent on the wire to the external
216switch.
217
218.B veb
219- bridging happens in hardware.
220
221.SS bridge link show - list bridge port configuration.
222
223This command displays the current bridge port configuration and flags.
224
d04bc300
SH
225.SH bridge fdb - forwarding database management
226
227.B fdb
228objects contain known Ethernet addresses on a link.
229
230.P
231The corresponding commands display fdb entries, add new entries,
232and delete old ones.
233
d611682a 234.SS bridge fdb add - add a new fdb entry
d04bc300 235
d611682a 236This command creates a new fdb entry.
d04bc300
SH
237
238.TP
239.BI "ADDRESS"
240the Ethernet MAC address.
241
242.TP
243.BI dev " NAME"
244the interface to which this address is associated.
245
d611682a
JF
246.B self
247- the address is associated with a software fdb (default)
248.sp
249
250.B embedded
251- the address is associated with an offloaded fdb
252.sp
253
d04bc300
SH
254.in -8
255
256.SS bridge fdb delete - delete a forwarding database entry
257This command removes an existing fdb entry.
258
259.PP
260The arguments are the same as with
261.BR "bridge fdb add" ,
262
263.SS bridge fdb show - list forwarding entries.
264
49572501 265This command displays the current forwarding table.
d04bc300
SH
266
267.PP
268With the
269.B -statistics
270option, the command becomes verbose. It prints out the last updated
271and last used time for each entry.
272
ab938710
VY
273.SH bridge vlan - VLAN filter list
274
275.B vlan
276objects contain known VLAN IDs for a link.
277
278.P
279The corresponding commands display vlan filter entries, add new entries,
280and delete old ones.
281
282.SS bridge vlan add - add a new vlan filter entry
283
284This command creates a new vlan filter entry.
285
286.TP
287.BI dev " NAME"
288the interface with which this vlan is associated.
289
290.TP
291.BI vid " VID"
292the VLAN ID that identifies the vlan.
293
294.TP
295.BI pvid
296the vlan specified is to be considered a PVID at ingress.
297Any untagged frames will be assigned to this VLAN.
298
299.TP
300.BI untagged
301the vlan specified is to be treated as untagged on egress.
302
303.TP
304.BI self
305the vlan is configured on the specified physical device. Required if the
306device is the bridge device.
307
308.TP
309.BI master
6274b0b7 310the vlan is configured on the software bridge (default).
ab938710
VY
311
312.SS bridge vlan delete - delete a forwarding database entry
313This command removes an existing fdb entry.
314
315.PP
316The arguments are the same as with
317.BR "bridge vlan add".
318The
319.BR "pvid " and " untagged"
320flags are ignored.
321
322.SS bridge vlan show - list vlan configuration.
323
324This command displays the current VLAN filter table.
325
d04bc300
SH
326.SH bridge monitor - state monitoring
327
328The
329.B bridge
330utility can monitor the state of devices and addresses
331continuously. This option has a slightly different format.
332Namely, the
333.B monitor
334command is the first in the command line and then the object list follows:
335
336.BR "bridge monitor" " [ " all " |"
49572501 337.IR OBJECT-LIST " ]"
d04bc300
SH
338
339.I OBJECT-LIST
340is the list of object types that we want to monitor.
341It may contain
342.BR link ", and " fdb "."
343If no
344.B file
345argument is given,
346.B bridge
347opens RTNETLINK, listens on it and dumps state changes in the format
348described in previous sections.
349
350.P
351If a file name is given, it does not listen on RTNETLINK,
352but opens the file containing RTNETLINK messages saved in binary format
353and dumps them. Such a history file can be generated with the
354
355
356.SH NOTES
357This command uses facilities added in Linux 3.0.
358
359Although the forwarding table is maintained on a per-bridge device basis
360the bridge device is not part of the syntax. This is a limitation of the
361underlying netlink neighbour message protocol. When displaying the
362forwarding table, entries for all bridges are displayed.
363Add/delete/modify commands determine the underlying bridge device
6274b0b7 364based on the bridge to which the corresponding ethernet device is attached.
d04bc300
SH
365
366
367.SH SEE ALSO
368.BR ip (8)
49572501 369.SH BUGS
d04bc300
SH
370.RB "Please direct bugreports and patches to: " <netdev@vger.kernel.org>
371
372.SH AUTHOR
373Original Manpage by Stephen Hemminger