1 .TH BRIDGE 8 "1 August 2012" "iproute2" "Linux"
3 bridge \- show / manipulate bridge addresses and devices
10 .RI "[ " OPTIONS " ] " OBJECT " { " COMMAND " | "
16 .BR link " | " fdb " | " mdb " | " vlan " | " monitor " }"
21 \fB\-V\fR[\fIersion\fR] |
22 \fB\-s\fR[\fItatistics\fR] |
23 \fB\-n\fR[\fIetns\fR] name }
36 .BR guard " { " on " | " off " } ] [ "
37 .BR hairpin " { " on " | " off " } ] [ "
38 .BR fastleave " { " on " | " off " } ] [ "
39 .BR root_block " { " on " | " off " } ] [ "
40 .BR learning " { " on " | " off " } ] [ "
41 .BR learning_sync " { " on " | " off " } ] [ "
42 .BR flood " { " on " | " off " } ] [ "
43 .BR hwmode " { " vepa " | " veb " } ] [ "
44 .BR self " ] [ " master " ] "
47 .BR "bridge link" " [ " show " ] [ "
52 .BR "bridge fdb" " { " add " | " append " | " del " } "
56 .BR local " | " temp " } [ "
57 .BR self " ] [ " master " ] [ " router " ] [ " use " ] [ "
68 .BR "bridge fdb" " [ " show " ] [ "
73 .BR "bridge mdb" " { " add " | " del " } "
80 .BR permanent " | " temp " ] [ "
85 .BR "bridge mdb show " [ "
90 .BR "bridge vlan" " { " add " | " del " } "
95 .BR pvid " ] [ " untagged " ] [ "
96 .BR self " ] [ " master " ] "
99 .BR "bridge vlan" " [ " show " ] [ "
104 .BR "bridge monitor" " [ " all " | " neigh " | " link " | " mdb " ]"
109 .BR "\-V" , " -Version"
110 print the version of the
115 .BR "\-s" , " \-stats", " \-statistics"
116 output more information. If this option
117 is given multiple times, the amount of information increases.
118 As a rule, the information is statistics or some time values.
121 .BR "\-n" , " \-net" , " \-netns " <NETNS>
124 to the specified network namespace
126 Actually it just simplifies executing of:
131 .RI "[ " OPTIONS " ] " OBJECT " { " COMMAND " | "
137 .RI "-n[etns] " NETNS " [ " OPTIONS " ] " OBJECT " { " COMMAND " | "
141 .SH BRIDGE - COMMAND SYNTAX
152 - Forwarding Database entry.
156 - Multicast group database entry.
165 Specifies the action to perform on the object.
166 The set of possible actions depends on the object type.
167 As a rule, it is possible to
168 .BR "add" , " delete"
173 ) objects, but some objects do not allow all of these operations
174 or have some additional commands. The
176 command is available for all objects. It prints
177 out a list of available commands and argument syntax conventions.
179 If no command is given, some default command is assumed.
182 or, if the objects of this class cannot be listed,
185 .SH bridge link - bridge port
188 objects correspond to the port devices of the bridge.
191 The corresponding commands set and display port status and bridge specific
194 .SS bridge link set - set bridge specific attributes on a port
198 interface name of the bridge port
202 the STP path cost of the specified port.
205 .BI priority " PRIO "
206 the STP port priority. The priority value is an unsigned 8-bit quantity
207 (number between 0 and 255). This metric is used in the designated port an
208 droot port selectio algorithms.
212 the operation state of the port. This is primarily used by user space STP/RSTP
213 implementation. One may enter a lowercased port state name, or one of the
214 numbers below. Negative inputs are ignored, and unrecognized names return an
218 - port is DISABLED. Make this port completely inactive.
222 - STP LISTENING state. Only valid if STP is enabled on the brige. In this
223 state the port for list for STP BPDUs and drop all other traffic.
227 - STP LEARNING state. Only valid if STP is enabled on the bridge. In this
228 state the port will accept traffic only for the purpose of updating MAC
233 - STP FORWARDING state. Port is fully active.
237 - STP BLOCKING state. Only valid if STP is enabled on the bridge. This state
238 is used during the STP election process. In this state, port will only process
243 .BR "guard on " or " guard off "
244 Controls whether STP BPUDs will be processed by the bridge port. By default,
245 the flag is turned off allowed BPDU processing. Turning this flag on will
246 cause the port to stop processing STP BPDUs.
249 .BR "hairpin on " or " hairpin off "
250 Controls whether traffic may be send back out of the port on which it was
251 received. By default, this flag is turned off and the bridge will not forward
252 traffic back out of the receiving port.
255 .BR "fastleave on " or " fastleave off "
256 This flag allows the bridge to immediately stop multicast traffic on a port
257 that receives IGMP Leave message. It is only used with IGMP snooping is
258 enabled on the bridge. By default the flag is off.
261 .BR "root_block on " or " root_block off "
262 Controls whether a given port is allowed to become root port or not. Only used
263 when STP is enabled on the bridge. By default the flag is off.
266 .BR "learning on " or " learning off "
267 Controls whether a given port will learn MAC addresses from received traffic or
268 not. If learning if off, the bridge will end up flooding any traffic for which
269 it has no FDB entry. By default this flag is on.
272 .BR "learning_sync on " or " learning_sync off "
273 Controls whether a given port will sync MAC addresses learned on device port to
277 .BR "flooding on " or " flooding off "
278 Controls whether a given port will flood unicast traffic for which there is no FDB entry. By default this flag is on.
282 Some network interface cards support HW bridge functionality and they may be
283 configured in different modes. Currently support modes are:
286 - Data sent between HW ports is sent on the wire to the external
290 - bridging happens in hardware.
294 link setting is configured on specified physical device
298 link setting is configured on the software bridge (default)
301 .SS bridge link show - list bridge port configuration.
303 This command displays the current bridge port configuration and flags.
305 .SH bridge fdb - forwarding database management
308 objects contain known Ethernet addresses on a link.
311 The corresponding commands display fdb entries, add new entries,
315 .SS bridge fdb add - add a new fdb entry
317 This command creates a new fdb entry.
321 the Ethernet MAC address.
325 the interface to which this address is associated.
328 - the address is associated with the port drivers fdb. Usually hardware.
332 - the address is associated with master devices fdb. Usually software (default).
336 - the destination address is associated with a router.
337 Valid if the referenced device is a VXLAN type device and has
338 route shortcircuit enabled.
342 - the address is in use. User space can use this option to
343 indicate to the kernel that the fdb entry is in use.
347 The next command line parameters apply only
348 when the specified device
353 the IP address of the destination
354 VXLAN tunnel endpoint where the Ethernet MAC ADDRESS resides.
358 the VXLAN VNI Network Identifier (or VXLAN Segment ID)
359 to use to connect to the remote VXLAN tunnel endpoint.
360 If omitted the value specified at vxlan device creation
365 the UDP destination PORT number to use to connect to the
366 remote VXLAN tunnel endpoint.
367 If omitted the default value is used.
371 device name of the outgoing interface for the
372 VXLAN device driver to reach the
373 remote VXLAN tunnel endpoint.
375 .SS bridge fdb append - append a forwarding database entry
376 This command adds a new fdb entry with an already known
378 Valid only for multicast link layer addresses.
379 The command adds support for broadcast and multicast
380 Ethernet MAC addresses.
381 The Ethernet MAC address is added multiple times into
382 the forwarding database and the vxlan device driver
383 sends a copy of the data packet to each entry found.
386 The arguments are the same as with
387 .BR "bridge fdb add" ,
389 .SS bridge fdb delete - delete a forwarding database entry
390 This command removes an existing fdb entry.
393 The arguments are the same as with
394 .BR "bridge fdb add" ,
396 .SS bridge fdb show - list forwarding entries.
398 This command displays the current forwarding table.
403 option, the command becomes verbose. It prints out the last updated
404 and last used time for each entry.
406 .SH bridge mdb - multicast group database management
409 objects contain known IP multicast group addresses on a link.
412 The corresponding commands display mdb entries, add new entries,
415 .SS bridge mdb add - add a new multicast group database entry
417 This command creates a new mdb entry.
421 the interface where this group address is associated.
425 the port whose link is known to have members of this multicast group.
429 the IP multicast group address whose members reside on the link connected to
433 - the mdb entry is permanent
437 - the mdb entry is temporary (default)
442 the VLAN ID which is known to have members of this multicast group.
445 .SS bridge mdb delete - delete a multicast group database entry
446 This command removes an existing mdb entry.
449 The arguments are the same as with
450 .BR "bridge mdb add" .
452 .SS bridge mdb show - list multicast group database entries
454 This command displays the current multicast group membership table. The table
455 is populated by IGMP and MLD snooping in the bridge driver automatically. It
460 commands manually too.
464 the interface only whose entries should be listed. Default is to list all
470 option, the command becomes verbose. It prints out the ports known to have
473 .SH bridge vlan - VLAN filter list
476 objects contain known VLAN IDs for a link.
479 The corresponding commands display vlan filter entries, add new entries,
482 .SS bridge vlan add - add a new vlan filter entry
484 This command creates a new vlan filter entry.
488 the interface with which this vlan is associated.
492 the VLAN ID that identifies the vlan.
496 the vlan specified is to be considered a PVID at ingress.
497 Any untagged frames will be assigned to this VLAN.
501 the vlan specified is to be treated as untagged on egress.
505 the vlan is configured on the specified physical device. Required if the
506 device is the bridge device.
510 the vlan is configured on the software bridge (default).
512 .SS bridge vlan delete - delete a forwarding database entry
513 This command removes an existing fdb entry.
516 The arguments are the same as with
517 .BR "bridge vlan add".
519 .BR "pvid " and " untagged"
522 .SS bridge vlan show - list vlan configuration.
524 This command displays the current VLAN filter table.
526 .SH bridge monitor - state monitoring
530 utility can monitor the state of devices and addresses
531 continuously. This option has a slightly different format.
534 command is the first in the command line and then the object list follows:
536 .BR "bridge monitor" " [ " all " |"
540 is the list of object types that we want to monitor.
542 .BR link ", " fdb ", and " mdb "."
547 opens RTNETLINK, listens on it and dumps state changes in the format
548 described in previous sections.
551 If a file name is given, it does not listen on RTNETLINK,
552 but opens the file containing RTNETLINK messages saved in binary format
556 This command uses facilities added in Linux 3.0.
558 Although the forwarding table is maintained on a per-bridge device basis
559 the bridge device is not part of the syntax. This is a limitation of the
560 underlying netlink neighbour message protocol. When displaying the
561 forwarding table, entries for all bridges are displayed.
562 Add/delete/modify commands determine the underlying bridge device
563 based on the bridge to which the corresponding ethernet device is attached.
569 .RB "Please direct bugreports and patches to: " <netdev@vger.kernel.org>
572 Original Manpage by Stephen Hemminger