1 .TH DEVLINK\-TRAP 8 "2 August 2019" "iproute2" "Linux"
3 devlink-trap \- devlink trap configuration
18 \fB\-v\fR[\fIerbose\fR] |
19 \fB\-s\fR[\fItatistics\fR] }
22 .B "devlink trap show"
28 .BI "devlink trap set " DEV " trap " TRAP
29 .RB "[ " action " { " trap " | " drop " | " mirror " } ]"
32 .B "devlink trap group show"
38 .BI "devlink trap group set " DEV " group " GROUP
39 .RB "[ " action " { " trap " | " drop " | " mirror " } ]"
43 .RB "[ " nopolicer " ]"
46 .BI "devlink trap policer set " DEV " policer " POLICER
56 .SS devlink trap show - display available packet traps and their attributes
60 - specifies the devlink device from which to show packet traps.
61 If this argument is omitted all packet traps of all devices are listed.
65 - specifies the packet trap.
66 Only applicable if a devlink device is also specified.
68 .SS devlink trap set - set attributes of a packet trap
72 - specifies the devlink device the packet trap belongs to.
76 - specifies the packet trap.
79 .BR action " { " trap " | " drop " | " mirror " } "
83 - the sole copy of the packet is sent to the CPU.
86 - the packet is dropped by the underlying device and a copy is not sent to the CPU.
89 - the packet is forwarded by the underlying device and a copy is sent to the CPU.
91 .SS devlink trap group show - display available packet trap groups and their attributes
95 - specifies the devlink device from which to show packet trap groups.
96 If this argument is omitted all packet trap groups of all devices are listed.
100 - specifies the packet trap group.
101 Only applicable if a devlink device is also specified.
103 .SS devlink trap group set - set attributes of a packet trap group
107 - specifies the devlink device the packet trap group belongs to.
111 - specifies the packet trap group.
114 .BR action " { " trap " | " drop " | " mirror " } "
115 packet trap action. The action is set for all the packet traps member in the
116 trap group. The actions of non-drop traps cannot be changed and are thus
120 .BI policer " POLICER"
121 packet trap policer. The policer to bind to the packet trap group. A value of
122 "0" will unbind the currently bound policer.
126 Unbind packet trap policer from the packet trap group.
128 .SS devlink trap policer set - set attributes of packet trap policer
132 - specifies the devlink device the packet trap policer belongs to.
135 .BI "policer " POLICER
136 - specifies the packet trap policer.
140 - packet trap policer rate in packets per second.
144 - packet trap policer burst size in packets.
150 List available packet traps.
153 devlink trap group show
155 List available packet trap groups.
158 devlink -vs trap show pci/0000:01:00.0 trap source_mac_is_multicast
160 Show attributes and statistics of a specific packet trap.
163 devlink -s trap group show pci/0000:01:00.0 group l2_drops
165 Show attributes and statistics of a specific packet trap group.
168 devlink trap set pci/0000:01:00.0 trap source_mac_is_multicast action trap
170 Set the action of a specific packet trap to 'trap'.
173 devlink trap policer show
175 List available packet trap policers.
178 devlink -s trap policer show pci/0000:01:00.0 policer 1
180 Show attributes and statistics of a specific packet trap policer.
183 devlink trap policer set pci/0000:01:00.0 policer 1 rate 1000 burst 128
185 Set the rate and burst size of a specific packet trap policer.
191 .BR devlink-monitor (8),
195 Ido Schimmel <idosch@mellanox.com>