Debian Codegraph @

upstream/opensuse-leap-16-1/man8/ip-link.8

raw
1 .TH IP\-LINK 8 "13 Dec 2012" "iproute2" "Linux"
2 .SH "NAME"
3 ip-link \- network device configuration
4 .SH "SYNOPSIS"
5 .sp
6 .ad l
7 .in +8
8 .ti -8
9 .B ip link
10 .RI " { " COMMAND " | "
11 .BR help " }"
12 .sp
13
14 .ti -8
15 .BI "ip link add"
16 .RB "[ " link
17 .IR DEVICE " ]"
18 .RB "[ " name " ]"
19 .I NAME
20 .br
21 .RB "[ " txqueuelen
22 .IR PACKETS " ]"
23 .br
24 .RB "[ " address
25 .IR LLADDR " ]"
26 .RB "[ " broadcast
27 .IR LLADDR " ]"
28 .br
29 .RB "[ " mtu
30 .IR MTU " ]"
31 .RB "[ " index
32 .IR IDX " ]"
33 .br
34 .RB "[ " numtxqueues
35 .IR QUEUE_COUNT " ]"
36 .RB "[ " numrxqueues
37 .IR QUEUE_COUNT " ]"
38 .br
39 .RB "[ " gso_max_size
40 .IR BYTES " ]"
41 .RB "[ " gso_ipv4_max_size
42 .IR BYTES " ]"
43 .RB "[ " gso_max_segs
44 .IR SEGMENTS " ]"
45 .br
46 .RB "[ " gro_max_size
47 .IR BYTES " ]"
48 .RB "[ " gro_ipv4_max_size
49 .IR BYTES " ]"
50 .br
51 .RB "[ " netns " {"
52 .IR PID " | " NETNSNAME " | " NETNSFILE " } ]"
53 .br
54 .BI type " TYPE"
55 .RI "[ " ARGS " ]"
56
57 .ti -8
58 .BR "ip link delete " {
59 .IR DEVICE " | "
60 .BI "group " GROUP
61 }
62 .BI type " TYPE"
63 .RI "[ " ARGS " ]"
64
65 .ti -8
66 .BR "ip link" " { " set " | " change " } " {
67 .IR DEVICE " | "
68 .BI "group " GROUP
69 }
70 .br
71 .RB "[ { " up " | " down " } ]"
72 .br
73 .RB "[ " type
74 .IR "ETYPE TYPE_ARGS" " ]"
75 .br
76 .RB "[ " arp " { " on " | " off " } ]"
77 .br
78 .RB "[ " dynamic " { " on " | " off " } ]"
79 .br
80 .RB "[ " multicast " { " on " | " off " } ]"
81 .br
82 .RB "[ " allmulticast " { " on " | " off " } ]"
83 .br
84 .RB "[ " promisc " { " on " | " off " } ]"
85 .br
86 .RB "[ " protodown " { " on " | " off " } ]"
87 .br
88 .RB "[ " protodown_reason
89 .IR PREASON " { " on " | " off " } ]"
90 .br
91 .RB "[ " trailers " { " on " | " off " } ]"
92 .br
93 .RB "[ " txqueuelen
94 .IR PACKETS " ]"
95 .br
96 .RB "[ " gso_max_size
97 .IR BYTES " ]"
98 .RB "[ " gso_ipv4_max_size
99 .IR BYTES " ]"
100 .RB "[ " gso_max_segs
101 .IR SEGMENTS " ]"
102 .br
103 .RB "[ " gro_max_size
104 .IR BYTES " ]"
105 .RB "[ " gro_ipv4_max_size
106 .IR BYTES " ]"
107 .br
108 .RB "[ " name
109 .IR NEWNAME " ]"
110 .br
111 .RB "[ " address
112 .IR LLADDR " ]"
113 .br
114 .RB "[ " broadcast
115 .IR LLADDR " ]"
116 .br
117 .RB "[ " mtu
118 .IR MTU " ]"
119 .br
120 .RB "[ " netns " {"
121 .IR PID " | " NETNSNAME " | " NETNSFILE " } ]"
122 .br
123 .RB "[ " link-netnsid
124 .IR ID " ]"
125 .br
126 .RB "[ " alias
127 .IR NAME " ]"
128 .br
129 .RB "[ " vf
130 .IR NUM " ["
131 .B mac
132 .IR LLADDR " ]"
133 .br
134 .in +9
135 .RI "[ " VFVLAN-LIST " ]"
136 .br
137 .RB "[ " rate
138 .IR TXRATE " ]"
139 .br
140 .RB "[ " max_tx_rate
141 .IR TXRATE " ]"
142 .br
143 .RB "[ " min_tx_rate
144 .IR TXRATE " ]"
145 .br
146 .RB "[ " spoofchk " { " on " | " off " } ]"
147 .br
148 .RB "[ " query_rss " { " on " | " off " } ]"
149 .br
150 .RB "[ " state " { " auto " | " enable " | " disable " } ]"
151 .br
152 .RB "[ " trust " { " on " | " off " } ]"
153 .br
154 .RB "[ " node_guid " eui64 ]"
155 .br
156 .RB "[ " port_guid " eui64 ] ]"
157 .br
158 .in -9
159 .RB "[ { " xdp " | " xdpgeneric " | " xdpdrv " | " xdpoffload " } { " off " | "
160 .br
161 .in +8
162 .BR object
163 .IR FILE
164 .RB "[ { " section " | " program " } "
165 .IR NAME " ]"
166 .RB "[ " verbose " ] |"
167 .br
168 .BR pinned
169 .IR FILE " } ]"
170 .br
171 .in -8
172 .RB "[ " master
173 .IR DEVICE " ]"
174 .br
175 .RB "[ " nomaster " ]"
176 .br
177 .RB "[ " vrf
178 .IR NAME " ]"
179 .br
180 .RB "[ " addrgenmode " { " eui64 " | " none " | " stable_secret " | " random " } ]"
181 .br
182 .RB "[ " macaddr
183 .RI "[ " MACADDR " ]"
184 .br
185 .in +10
186 .RB "[ { " flush " | " add " | " del " } "
187 .IR MACADDR " ]"
188 .br
189 .RB "[ " set
190 .IR MACADDR " ] ]"
191 .br
192
193 .ti -8
194 .B ip link show
195 .RI "[ " DEVICE " | "
196 .B group
197 .IR GROUP " ] ["
198 .BR up " ] ["
199 .B master
200 .IR DEVICE " ] ["
201 .B type
202 .IR ETYPE " ] ["
203 .B vrf
204 .IR NAME " ] ["
205 .BR nomaster " ] ["
206 .BR novf " ]"
207
208 .ti -8
209 .B ip link xstats
210 .BI type " TYPE"
211 .RI "[ " ARGS " ]"
212
213 .ti -8
214 .B ip link afstats
215 .RB "[ " dev
216 .IR DEVICE " ]"
217
218 .ti -8
219 .B ip link help
220 .RI "[ " TYPE " ]"
221
222 .ti -8
223 .IR TYPE " := [ "
224 .BR amt " | "
225 .BR bareudp " |"
226 .BR bond " | "
227 .BR bridge " | "
228 .BR can " | "
229 .BR dsa " | "
230 .BR dummy " | "
231 .BR erspan " |"
232 .BR geneve " |"
233 .BR gre " |"
234 .BR gretap " |"
235 .BR gtp " |"
236 .BR hsr " | "
237 .BR ifb " | "
238 .BR ip6erspan " |"
239 .BR ip6gre " |"
240 .BR ip6gretap " |"
241 .BR ip6tnl " |"
242 .BR ipip " |"
243 .BR ipoib " |"
244 .BR ipvlan " |"
245 .BR ipvtap " |"
246 .BR lowpan " |"
247 .BR macsec " |"
248 .BR macvlan " | "
249 .BR macvtap " | "
250 .BR netdevsim " |"
251 .BR netkit " |"
252 .BR nlmon " |"
253 .BR pfcp " |"
254 .BR rmnet " |"
255 .BR sit " |"
256 .BR vcan " | "
257 .BR veth " | "
258 .BR virt_wifi " |"
259 .BR vlan " | "
260 .BR vrf " |"
261 .BR vti " |"
262 .BR vxcan " | "
263 .BR vxlan " |"
264 .BR xfrm " ]"
265
266 .ti -8
267 .IR ETYPE " := [ " TYPE " |"
268 .BR bridge_slave " | " bond_slave " ]"
269
270 .ti -8
271 .IR VFVLAN-LIST " := [ " VFVLAN-LIST " ] " VFVLAN
272
273 .ti -8
274 .IR VFVLAN " := "
275 .RB "[ " vlan
276 .IR VLANID " [ "
277 .B qos
278 .IR VLAN-QOS " ] ["
279 .B proto
280 .IR VLAN-PROTO " ] ]"
281 .in -8
282
283 .ti -8
284 .BI "ip link property add dev " DEVICE
285 .RB "[ " altname
286 .IR NAME " .. ]"
287
288 .ti -8
289 .BI "ip link property del dev " DEVICE
290 .RB "[ " altname
291 .IR NAME " .. ]"
292
293 .SH "DESCRIPTION"
294 .SS ip link add - add virtual link
295
296 .TP
297 .BI link " DEVICE "
298 specifies the physical device to act operate on.
299
300 .I NAME
301 specifies the name of the new virtual device.
302
303 .I TYPE
304 specifies the type of the new device.
305 .sp
306 Link types:
307
308 .in +8
309 .BR amt
310 - Automatic Multicast Tunneling (AMT)
311 .sp
312 .BR bareudp
313 - Bare UDP L3 encapsulation support
314 .sp
315 .B bond
316 - Bonding device
317 .sp
318 .B bridge
319 - Ethernet Bridge device
320 .sp
321 .B can
322 - Controller Area Network
323 .sp
324 .B dsa
325 - Distributed Switch Architecture
326 .sp
327 .B dummy
328 - Dummy network interface
329 .sp
330 .BR erspan
331 - Encapsulated Remote SPAN over GRE and IPv4
332 .sp
333 .B geneve
334 - GEneric NEtwork Virtualization Encapsulation
335 .sp
336 .B gre
337 - Virtual tunnel interface GRE over IPv4
338 .sp
339 .BR gretap
340 - Virtual L2 tunnel interface GRE over IPv4
341 .sp
342 .BR gtp
343 - GPRS Tunneling Protocol
344 .sp
345 .B hsr
346 - High-availability Seamless Redundancy device
347 .sp
348 .B ifb
349 - Intermediate Functional Block device
350 .sp
351 .BR ip6erspan
352 - Encapsulated Remote SPAN over GRE and IPv6
353 .sp
354 .BR ip6gre
355 - Virtual tunnel interface GRE over IPv6
356 .sp
357 .BR ip6gretap
358 - Virtual L2 tunnel interface GRE over IPv6
359 .sp
360 .BR ip6tnl
361 - Virtual tunnel interface IPv4|IPv6 over IPv6
362 .sp
363 .BR ipip
364 - Virtual tunnel interface IPv4 over IPv4
365 .sp
366 .B ipoib
367 - IP over Infiniband device
368 .sp
369 .BR ipvlan
370 - Interface for L3 (IPv6/IPv4) based VLANs
371 .sp
372 .BR ipvtap
373 - Interface for L3 (IPv6/IPv4) based VLANs and TAP
374 .sp
375 .BR lowpan
376 - Interface for 6LoWPAN (IPv6) over IEEE 802.15.4 / Bluetooth
377 .sp
378 .BR macsec
379 - Interface for IEEE 802.1AE MAC Security (MACsec)
380 .sp
381 .B macvlan
382 - Virtual interface base on link layer address (MAC)
383 .sp
384 .B macvtap
385 - Virtual interface based on link layer address (MAC) and TAP.
386 .sp
387 .BR netdevsim
388 - Interface for netdev API tests
389 .sp
390 .BR netkit
391 - BPF-programmable network device
392 .sp
393 .BR nlmon
394 - Netlink monitoring device
395 .sp
396 .BR pfcp
397 - Packet Forwarding Control Protocol device
398 .sp
399 .BR rmnet
400 - Qualcomm rmnet device
401 .sp
402 .BR sit
403 - Virtual tunnel interface IPv6 over IPv4
404 .sp
405 .B vcan
406 - Virtual Controller Area Network interface
407 .sp
408 .B veth
409 - Virtual ethernet interface
410 .sp
411 .BR virt_wifi
412 - rtnetlink wifi simulation device
413 .sp
414 .BR vlan
415 - 802.1q tagged virtual LAN interface
416 .sp
417 .BR vrf
418 - Interface for L3 VRF domains
419 .sp
420 .BR vti
421 - Virtual tunnel interface
422 .sp
423 .B vxcan
424 - Virtual Controller Area Network tunnel interface
425 .sp
426 .BR vxlan
427 - Virtual eXtended LAN
428 .sp
429 .BR xfrm
430 - Virtual xfrm interface
431 .sp
432 .in -8
433
434 .TP
435 .BI numtxqueues " QUEUE_COUNT "
436 specifies the number of transmit queues for new device.
437
438 .TP
439 .BI numrxqueues " QUEUE_COUNT "
440 specifies the number of receive queues for new device.
441
442 .TP
443 .BI gso_max_size " BYTES "
444 specifies the recommended maximum size of a Generic Segment Offload
445 packet the new device should accept. This is also used to enable BIG
446 TCP for IPv6 on this device when the size is greater than 65536.
447
448 .TP
449 .BI gso_ipv4_max_size " BYTES "
450 specifies the recommended maximum size of a IPv4 Generic Segment Offload
451 packet the new device should accept. This is especially used to enable
452 BIG TCP for IPv4 on this device by setting to a size greater than 65536.
453 Note that
454 .B gso_max_size
455 needs to be set to a size greater than or equal to
456 .B gso_ipv4_max_size
457 to really enable BIG TCP for IPv4.
458
459 .TP
460 .BI gso_max_segs " SEGMENTS "
461 specifies the recommended maximum number of a Generic Segment Offload
462 segments the new device should accept.
463
464 .TP
465 .BI gro_max_size " BYTES "
466 specifies the maximum size of a packet built by GRO stack on this
467 device. This is also used for BIG TCP to allow the size of a
468 merged IPv6 GSO packet on this device greater than 65536.
469
470 .TP
471 .BI gro_ipv4_max_size " BYTES "
472 specifies the maximum size of a IPv4 packet built by GRO stack on this
473 device. This is especially used for BIG TCP to allow the size of a
474 merged IPv4 GSO packet on this device greater than 65536.
475
476 .TP
477 .BI index " IDX "
478 specifies the desired index of the new virtual device. The link
479 creation fails, if the index is busy.
480
481 .TP
482 .B netns
483 .RI "{ " PID " | " NETNSNAME " | " NETNSFILE " }"
484 .br
485 create the device in the network namespace associated with process
486 .IR "PID " or
487 the name
488 .IR "NETNSNAME " or
489 the file
490 .IR "NETNSFILE".
491
492 .TP
493 VLAN Type Support
494 For a link of type
495 .I VLAN
496 the following additional arguments are supported:
497
498 .BI "ip link add
499 .BI link " DEVICE "
500 .BI name " NAME "
501 .B "type vlan"
502 [
503 .BI protocol " VLAN_PROTO "
504 ]
505 .BI id " VLANID "
506 [
507 .BR reorder_hdr " { " on " | " off " } "
508 ]
509 [
510 .BR gvrp " { " on " | " off " } "
511 ]
512 [
513 .BR mvrp " { " on " | " off " } "
514 ]
515 [
516 .BR loose_binding " { " on " | " off " } "
517 ]
518 [
519 .BR bridge_binding " { " on " | " off " } "
520 ]
521 [
522 .BI ingress-qos-map " QOS-MAP "
523 ]
524 [
525 .BI egress-qos-map " QOS-MAP "
526 ]
527
528 .in +8
529 .sp
530 .BI protocol " VLAN_PROTO "
531 - either 802.1Q or 802.1ad.
532
533 .BI id " VLANID "
534 - specifies the VLAN Identifier to use. Note that numbers with a leading " 0 " or " 0x " are interpreted as octal or hexadecimal, respectively.
535
536 .BR reorder_hdr " { " on " | " off " } "
537 - specifies whether ethernet headers are reordered or not (default is
538 .BR on ")."
539
540 .in +4
541 If
542 .BR reorder_hdr " is " on
543 then VLAN header will be not inserted immediately but only before
544 passing to the physical device (if this device does not support VLAN
545 offloading), the similar on the RX direction - by default the packet
546 will be untagged before being received by VLAN device. Reordering
547 allows one to accelerate tagging on egress and to hide VLAN header on
548 ingress so the packet looks like regular Ethernet packet, at the same
549 time it might be confusing for packet capture as the VLAN header does
550 not exist within the packet.
551
552 VLAN offloading can be checked by
553 .BR ethtool "(8):"
554 .in +4
555 .sp
556 .B ethtool -k
557 <phy_dev> |
558 .RB grep " tx-vlan-offload"
559 .sp
560 .in -4
561 where <phy_dev> is the physical device to which VLAN device is bound.
562 .in -4
563
564 .BR gvrp " { " on " | " off " } "
565 - specifies whether this VLAN should be registered using GARP VLAN
566 Registration Protocol.
567
568 .BR mvrp " { " on " | " off " } "
569 - specifies whether this VLAN should be registered using Multiple VLAN
570 Registration Protocol.
571
572 .BR loose_binding " { " on " | " off " } "
573 - specifies whether the VLAN device state is bound to the physical device state.
574
575 .BR bridge_binding " { " on " | " off " } "
576 - specifies whether the VLAN device link state tracks the state of bridge ports
577 that are members of the VLAN.
578
579 .BI ingress-qos-map " QOS-MAP "
580 - defines a mapping of VLAN header prio field to the Linux internal packet
581 priority on incoming frames. The format is FROM:TO with multiple mappings
582 separated by spaces.
583
584 .BI egress-qos-map " QOS-MAP "
585 - defines a mapping of Linux internal packet priority to VLAN header prio field
586 but for outgoing frames. The format is the same as for ingress-qos-map.
587 .in +4
588
589 Linux packet priority can be set by
590 .BR iptables "(8)":
591 .in +4
592 .sp
593 .B iptables
594 -t mangle -A POSTROUTING [...] -j CLASSIFY --set-class 0:4
595 .sp
596 .in -4
597 and this "4" priority can be used in the egress qos mapping to set
598 VLAN prio "5":
599 .sp
600 .in +4
601 .B ip
602 link set veth0.10 type vlan egress 4:5
603 .in -4
604 .in -4
605 .in -8
606
607 .TP
608 VXLAN Type Support
609 For a link of type
610 .I VXLAN
611 the following additional arguments are supported:
612
613 .BI "ip link add " DEVICE
614 .BI type " vxlan " id " VNI"
615 [
616 .BI dev " PHYS_DEV "
617 .RB " ] [ { " group " | " remote " } "
618 .I IPADDR
619 ] [
620 .B local
621 .RI "{ "IPADDR " | "any " } "
622 ] [
623 .BI ttl " TTL "
624 ] [
625 .BI tos " TOS "
626 ] [
627 .BI df " DF "
628 ] [
629 .BI flowlabel " FLOWLABEL "
630 ] [
631 .BI dstport " PORT "
632 ] [
633 .BI srcport " MIN MAX "
634 ] [
635 .RB [ no ] learning
636 ] [
637 .RB [ no ] proxy
638 ] [
639 .RB [ no ] rsc
640 ] [
641 .RB [ no ] l2miss
642 ] [
643 .RB [ no ] l3miss
644 ] [
645 .RB [ no ] udpcsum
646 ] [
647 .RB [ no ] udp6zerocsumtx
648 ] [
649 .RB [ no ] udp6zerocsumrx
650 ] [
651 .RB [ no ] localbypass
652 ] [
653 .BI ageing " SECONDS "
654 ] [
655 .BI maxaddress " NUMBER "
656 ] [
657 .RB [ no ] external
658 ] [
659 .B gbp
660 ] [
661 .B gpe
662 ] [
663 .RB [ no ] vnifilter
664 ]
665
666 .in +8
667 .sp
668 .BI id " VNI "
669 - specifies the VXLAN Network Identifier (or VXLAN Segment
670 Identifier) to use.
671
672 .BI dev " PHYS_DEV"
673 - specifies the physical device to use for tunnel endpoint communication.
674
675 .sp
676 .BI group " IPADDR"
677 - specifies the multicast IP address to join.
678 This parameter cannot be specified with the
679 .B remote
680 parameter.
681
682 .sp
683 .BI remote " IPADDR"
684 - specifies the unicast destination IP address to use in outgoing packets
685 when the destination link layer address is not known in the VXLAN device
686 forwarding database. This parameter cannot be specified with the
687 .B group
688 parameter.
689
690 .sp
691 .BI local " IPADDR"
692 - specifies the source IP address to use in outgoing packets.
693
694 .sp
695 .BI ttl " TTL"
696 - specifies the TTL value to use in outgoing packets.
697
698 .sp
699 .BI tos " TOS"
700 - specifies the TOS value to use in outgoing packets.
701
702 .sp
703 .BI df " DF"
704 - specifies the usage of the Don't Fragment flag (DF) bit in outgoing packets
705 with IPv4 headers. The value
706 .B inherit
707 causes the bit to be copied from the original IP header. The values
708 .B unset
709 and
710 .B set
711 cause the bit to be always unset or always set, respectively. By default, the
712 bit is not set.
713
714 .sp
715 .BI flowlabel " FLOWLABEL"
716 - specifies the flow label to use in outgoing packets.
717
718 .sp
719 .BI dstport " PORT"
720 - specifies the UDP destination port to communicate to the remote
721 VXLAN tunnel endpoint.
722
723 .sp
724 .BI srcport " MIN MAX"
725 - specifies the range of port numbers to use as UDP
726 source ports to communicate to the remote VXLAN tunnel endpoint.
727
728 .sp
729 .RB [ no ] learning
730 - specifies if unknown source link layer addresses and IP addresses
731 are entered into the VXLAN device forwarding database.
732
733 .sp
734 .RB [ no ] rsc
735 - specifies if route short circuit is turned on.
736
737 .sp
738 .RB [ no ] proxy
739 - specifies ARP proxy is turned on.
740
741 .sp
742 .RB [ no ] l2miss
743 - specifies if netlink LLADDR miss notifications are generated.
744
745 .sp
746 .RB [ no ] l3miss
747 - specifies if netlink IP ADDR miss notifications are generated.
748
749 .sp
750 .RB [ no ] udpcsum
751 - specifies if UDP checksum is calculated for transmitted packets over IPv4.
752
753 .sp
754 .RB [ no ] udp6zerocsumtx
755 - skip UDP checksum calculation for transmitted packets over IPv6.
756
757 .sp
758 .RB [ no ] udp6zerocsumrx
759 - allow incoming UDP packets over IPv6 with zero checksum field.
760
761 .sp
762 .RB [ no ] localbypass
763 - if FDB destination is local, with nolocalbypass set, forward encapsulated
764 packets to the userspace network stack. If there is a userspace process
765 listening for these packets, it will have a chance to process them. If
766 localbypass is active (default), bypass the kernel network stack and
767 inject the packets into the target VXLAN device, assuming one exists.
768
769 .sp
770 .BI ageing " SECONDS"
771 - specifies the lifetime in seconds of FDB entries learnt by the kernel.
772
773 .sp
774 .BI maxaddress " NUMBER"
775 - specifies the maximum number of FDB entries.
776
777 .sp
778 .RB [ no ] external
779 - specifies whether an external control plane
780 .RB "(e.g. " "ip route encap" )
781 or the internal FDB should be used.
782
783 .sp
784 .RB [ no ] vnifilter
785 - specifies whether the vxlan device is capable of vni filtering. Only works with a vxlan
786 device with external flag set. once enabled, bridge vni command is used to manage the
787 vni filtering table on the device. The device can only receive packets with vni's configured
788 in the vni filtering table.
789
790 .sp
791 .B gbp
792 - enables the Group Policy extension (VXLAN-GBP).
793
794 .in +4
795 Allows one to transport group policy context across VXLAN network peers.
796 If enabled, includes the mark of a packet in the VXLAN header for outgoing
797 packets and fills the packet mark based on the information found in the
798 VXLAN header for incoming packets.
799
800 Format of upper 16 bits of packet mark (flags);
801
802 .in +2
803 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
804 .br
805 |-|-|-|-|-|-|-|-|-|D|-|-|A|-|-|-|
806 .br
807 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
808
809 .B D :=
810 Don't Learn bit. When set, this bit indicates that the egress
811 VTEP MUST NOT learn the source address of the encapsulated frame.
812
813 .B A :=
814 Indicates that the group policy has already been applied to
815 this packet. Policies MUST NOT be applied by devices when the A bit is set.
816 .in -2
817
818 Format of lower 16 bits of packet mark (policy ID):
819
820 .in +2
821 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
822 .br
823 | Group Policy ID |
824 .br
825 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
826 .in -2
827
828 Example:
829 iptables -A OUTPUT [...] -j MARK --set-mark 0x800FF
830
831 .in -4
832
833 .sp
834 .B gpe
835 - enables the Generic Protocol extension (VXLAN-GPE). Currently, this is
836 only supported together with the
837 .B external
838 keyword.
839
840 .in -8
841
842 .TP
843 VETH, VXCAN Type Support
844 For a link of types
845 .I VETH/VXCAN
846 the following additional arguments are supported:
847
848 .BI "ip link add " DEVICE
849 .BR type " { " veth " | " vxcan " }"
850 [
851 .BR peer
852 .BI "name " NAME
853 ]
854
855 .in +8
856 .sp
857 .BR peer
858 .BI "name " NAME
859 - specifies the virtual pair device name of the
860 .I VETH/VXCAN
861 tunnel.
862
863 .in -8
864
865 .TP
866 netkit Type Support
867 For a link of type
868 .I netkit
869 the following additional arguments are supported:
870
871 .BI "ip link add " DEVICE
872 .BR type " netkit "
873 [
874 .BI mode " MODE "
875 ] [
876 .I "POLICY "
877 ] [
878 .BR peer
879 [
880 .I "POLICY "
881 ] [
882 .I "NAME "
883 ] ]
884
885 .in +8
886
887 .sp
888 .BI mode " MODE"
889 - specifies the operation mode of the netkit device with "l3" and "l2"
890 as possible values. Default option is "l3".
891
892 .sp
893 .I "POLICY"
894 - specifies the default device policy when no BPF programs are attached
895 with "forward" and "blackhole" as possible values. Default option is
896 "forward". Specifying policy before the peer option refers to the primary
897 device, after the peer option refers to the peer device.
898
899 .sp
900 .I "NAME"
901 - specifies the device name of the peer device.
902
903 .in -8
904
905 .TP
906 IPIP, SIT Type Support
907 For a link of type
908 .IR IPIP or SIT
909 the following additional arguments are supported:
910
911 .BI "ip link add " DEVICE
912 .BR type " { " ipip " | " sit " }"
913 .BI " remote " ADDR " local " ADDR
914 [
915 .BR encap " { " fou " | " gue " | " none " }"
916 ] [
917 .BR encap-sport " { " \fIPORT " | " auto " }"
918 ] [
919 .BI "encap-dport " PORT
920 ] [
921 .RB [ no ] encap-csum
922 ] [
923 .I " [no]encap-remcsum "
924 ] [
925 .I " mode " { ip6ip | ipip | mplsip | any } "
926 ] [
927 .BR external
928 ]
929
930 .in +8
931 .sp
932 .BI remote " ADDR "
933 - specifies the remote address of the tunnel.
934
935 .sp
936 .BI local " ADDR "
937 - specifies the fixed local address for tunneled packets.
938 It must be an address on another interface on this host.
939
940 .sp
941 .BR encap " { " fou " | " gue " | " none " }"
942 - specifies type of secondary UDP encapsulation. "fou" indicates
943 Foo-Over-UDP, "gue" indicates Generic UDP Encapsulation.
944
945 .sp
946 .BR encap-sport " { " \fIPORT " | " auto " }"
947 - specifies the source port in UDP encapsulation.
948 .IR PORT
949 indicates the port by number, "auto"
950 indicates that the port number should be chosen automatically
951 (the kernel picks a flow based on the flow hash of the
952 encapsulated packet).
953
954 .sp
955 .RB [ no ] encap-csum
956 - specifies if UDP checksums are enabled in the secondary
957 encapsulation.
958
959 .sp
960 .RB [ no ] encap-remcsum
961 - specifies if Remote Checksum Offload is enabled. This is only
962 applicable for Generic UDP Encapsulation.
963
964 .sp
965 .BI mode " { ip6ip | ipip | mplsip | any } "
966 - specifies mode in which device should run. "ip6ip" indicates
967 IPv6-Over-IPv4, "ipip" indicates "IPv4-Over-IPv4", "mplsip" indicates
968 MPLS-Over-IPv4, "any" indicates IPv6, IPv4 or MPLS Over IPv4. Supported for
969 SIT where the default is "ip6ip" and IPIP where the default is "ipip".
970 IPv6-Over-IPv4 is not supported for IPIP.
971
972 .sp
973 .BR external
974 - make this tunnel externally controlled
975 .RB "(e.g. " "ip route encap" ).
976
977 .in -8
978 .TP
979 GRE Type Support
980 For a link of type
981 .IR GRE " or " GRETAP
982 the following additional arguments are supported:
983
984 .BI "ip link add " DEVICE
985 .BR type " { " gre " | " gretap " }"
986 .BI " remote " ADDR " local " ADDR
987 [
988 .RB [ no ] "" [ i | o ] seq
989 ] [
990 .RB [ i | o ] key
991 .I KEY
992 |
993 .BR no [ i | o ] key
994 ] [
995 .RB [ no ] "" [ i | o ] csum
996 ] [
997 .BI ttl " TTL "
998 ] [
999 .BI tos " TOS "
1000 ] [
1001 .RB [ no ] pmtudisc
1002 ] [
1003 .RB [ no ] ignore-df
1004 ] [
1005 .BI dev " PHYS_DEV "
1006 ] [
1007 .BR encap " { " fou " | " gue " | " none " }"
1008 ] [
1009 .BR encap-sport " { " \fIPORT " | " auto " }"
1010 ] [
1011 .BI "encap-dport " PORT
1012 ] [
1013 .RB [ no ] encap-csum
1014 ] [
1015 .RB [ no ] encap-remcsum
1016 ] [
1017 .BR external
1018 ]
1019
1020 .in +8
1021 .sp
1022 .BI remote " ADDR "
1023 - specifies the remote address of the tunnel.
1024
1025 .sp
1026 .BI local " ADDR "
1027 - specifies the fixed local address for tunneled packets.
1028 It must be an address on another interface on this host.
1029
1030 .sp
1031 .RB [ no ] "" [ i | o ] seq
1032 - serialize packets.
1033 The
1034 .B oseq
1035 flag enables sequencing of outgoing packets.
1036 The
1037 .B iseq
1038 flag requires that all input packets are serialized.
1039
1040 .sp
1041 .RB [ i | o ] key
1042 .I KEY
1043 |
1044 .BR no [ i | o ] key
1045 - use keyed GRE with key
1046 .IR KEY ". "KEY
1047 is either a number or an IPv4 address-like dotted quad.
1048 The
1049 .B key
1050 parameter specifies the same key to use in both directions.
1051 The
1052 .BR ikey " and " okey
1053 parameters specify different keys for input and output.
1054
1055 .sp
1056 .RB [ no ] "" [ i | o ] csum
1057 - generate/require checksums for tunneled packets.
1058 The
1059 .B ocsum
1060 flag calculates checksums for outgoing packets.
1061 The
1062 .B icsum
1063 flag requires that all input packets have the correct
1064 checksum. The
1065 .B csum
1066 flag is equivalent to the combination
1067 .B "icsum ocsum" .
1068
1069 .sp
1070 .BI ttl " TTL"
1071 - specifies the TTL value to use in outgoing packets.
1072
1073 .sp
1074 .BI tos " TOS"
1075 - specifies the TOS value to use in outgoing packets.
1076
1077 .sp
1078 .RB [ no ] pmtudisc
1079 - enables/disables Path MTU Discovery on this tunnel.
1080 It is enabled by default. Note that a fixed ttl is incompatible
1081 with this option: tunneling with a fixed ttl always makes pmtu
1082 discovery.
1083
1084 .sp
1085 .RB [ no ] ignore-df
1086 - enables/disables IPv4 DF suppression on this tunnel.
1087 Normally datagrams that exceed the MTU will be fragmented; the presence
1088 of the DF flag inhibits this, resulting instead in an ICMP Unreachable
1089 (Fragmentation Required) message. Enabling this attribute causes the
1090 DF flag to be ignored.
1091
1092 .sp
1093 .BI dev " PHYS_DEV"
1094 - specifies the physical device to use for tunnel endpoint communication.
1095
1096 .sp
1097 .BR encap " { " fou " | " gue " | " none " }"
1098 - specifies type of secondary UDP encapsulation. "fou" indicates
1099 Foo-Over-UDP, "gue" indicates Generic UDP Encapsulation.
1100
1101 .sp
1102 .BR encap-sport " { " \fIPORT " | " auto " }"
1103 - specifies the source port in UDP encapsulation.
1104 .IR PORT
1105 indicates the port by number, "auto"
1106 indicates that the port number should be chosen automatically
1107 (the kernel picks a flow based on the flow hash of the
1108 encapsulated packet).
1109
1110 .sp
1111 .RB [ no ] encap-csum
1112 - specifies if UDP checksums are enabled in the secondary
1113 encapsulation.
1114
1115 .sp
1116 .RB [ no ] encap-remcsum
1117 - specifies if Remote Checksum Offload is enabled. This is only
1118 applicable for Generic UDP Encapsulation.
1119
1120 .sp
1121 .BR external
1122 - make this tunnel externally controlled
1123 .RB "(e.g. " "ip route encap" ).
1124
1125 .in -8
1126
1127 .TP
1128 IP6GRE/IP6GRETAP Type Support
1129 For a link of type
1130 .I IP6GRE/IP6GRETAP
1131 the following additional arguments are supported:
1132
1133 .BI "ip link add " DEVICE
1134 .BR type " { " ip6gre " | " ip6gretap " }"
1135 .BI remote " ADDR " local " ADDR"
1136 [
1137 .RB [ no ] "" [ i | o ] seq
1138 ] [
1139 .RB [ i | o ] key
1140 .I KEY
1141 |
1142 .BR no [ i | o ] key
1143 ] [
1144 .RB [ no ] "" [ i | o ] csum
1145 ] [
1146 .BI hoplimit " TTL "
1147 ] [
1148 .BI encaplimit " ELIM "
1149 ] [
1150 .BI tclass " TCLASS "
1151 ] [
1152 .BI flowlabel " FLOWLABEL "
1153 ] [
1154 .BI "dscp inherit"
1155 ] [
1156 .BI "[no]allow-localremote"
1157 ] [
1158 .BI dev " PHYS_DEV "
1159 ] [
1160 .RB external
1161 ]
1162
1163 .in +8
1164 .sp
1165 .BI remote " ADDR "
1166 - specifies the remote IPv6 address of the tunnel.
1167
1168 .sp
1169 .BI local " ADDR "
1170 - specifies the fixed local IPv6 address for tunneled packets.
1171 It must be an address on another interface on this host.
1172
1173 .sp
1174 .RB [ no ] "" [ i | o ] seq
1175 - serialize packets.
1176 The
1177 .B oseq
1178 flag enables sequencing of outgoing packets.
1179 The
1180 .B iseq
1181 flag requires that all input packets are serialized.
1182
1183 .sp
1184 .RB [ i | o ] key
1185 .I KEY
1186 |
1187 .BR no [ i | o ] key
1188 - use keyed GRE with key
1189 .IR KEY ". "KEY
1190 is either a number or an IPv4 address-like dotted quad.
1191 The
1192 .B key
1193 parameter specifies the same key to use in both directions.
1194 The
1195 .BR ikey " and " okey
1196 parameters specify different keys for input and output.
1197
1198 .sp
1199 .RB [ no ] "" [ i | o ] csum
1200 - generate/require checksums for tunneled packets.
1201 The
1202 .B ocsum
1203 flag calculates checksums for outgoing packets.
1204 The
1205 .B icsum
1206 flag requires that all input packets have the correct
1207 checksum. The
1208 .B csum
1209 flag is equivalent to the combination
1210 .BR "icsum ocsum" .
1211
1212 .sp
1213 .BI hoplimit " TTL"
1214 - specifies Hop Limit value to use in outgoing packets.
1215
1216 .sp
1217 .BI encaplimit " ELIM"
1218 - specifies a fixed encapsulation limit. Default is 4.
1219
1220 .sp
1221 .BI flowlabel " FLOWLABEL"
1222 - specifies a fixed flowlabel.
1223
1224 .sp
1225 .BI [no]allow-localremote
1226 - specifies whether to allow remote endpoint to have an address configured on
1227 local host.
1228
1229 .sp
1230 .BI tclass " TCLASS"
1231 - specifies the traffic class field on
1232 tunneled packets, which can be specified as either a two-digit
1233 hex value (e.g. c0) or a predefined string (e.g. internet).
1234 The value
1235 .B inherit
1236 causes the field to be copied from the original IP header. The
1237 values
1238 .BI "inherit/" STRING
1239 or
1240 .BI "inherit/" 00 ".." ff
1241 will set the field to
1242 .I STRING
1243 or
1244 .IR 00 ".." ff
1245 when tunneling non-IP packets. The default value is 00.
1246
1247 .sp
1248 .RB external
1249 - make this tunnel externally controlled (or not, which is the default).
1250 In the kernel, this is referred to as collect metadata mode. This flag is
1251 mutually exclusive with the
1252 .BR remote ,
1253 .BR local ,
1254 .BR seq ,
1255 .BR key,
1256 .BR csum,
1257 .BR hoplimit,
1258 .BR encaplimit,
1259 .BR flowlabel " and " tclass
1260 options.
1261
1262 .in -8
1263
1264 .TP
1265 IPoIB Type Support
1266 For a link of type
1267 .I IPoIB
1268 the following additional arguments are supported:
1269
1270 .BI "ip link add " DEVICE " name " NAME
1271 .BR "type ipoib " [ " pkey \fIPKEY" " ] [ " mode " \fIMODE \fR]"
1272
1273 .in +8
1274 .sp
1275 .BI pkey " PKEY "
1276 - specifies the IB P-Key to use.
1277
1278 .BI mode " MODE "
1279 - specifies the mode (datagram or connected) to use.
1280
1281 .TP
1282 ERSPAN Type Support
1283 For a link of type
1284 .I ERSPAN/IP6ERSPAN
1285 the following additional arguments are supported:
1286
1287 .BI "ip link add " DEVICE
1288 .BR type " { " erspan " | " ip6erspan " }"
1289 .BI remote " ADDR " local " ADDR " seq
1290 .RB key
1291 .I KEY
1292 .BR erspan_ver " \fIversion "
1293 [
1294 .BR erspan " \fIIDX "
1295 ] [
1296 .BR erspan_dir " { " \fIingress " | " \fIegress " }"
1297 ] [
1298 .BR erspan_hwid " \fIhwid "
1299 ] [
1300 .BI "[no]allow-localremote"
1301 ] [
1302 .RB external
1303 ]
1304
1305 .in +8
1306 .sp
1307 .BI remote " ADDR "
1308 - specifies the remote address of the tunnel.
1309
1310 .sp
1311 .BI local " ADDR "
1312 - specifies the fixed local address for tunneled packets.
1313 It must be an address on another interface on this host.
1314
1315 .sp
1316 .BR erspan_ver " \fIversion "
1317 - specifies the ERSPAN version number.
1318 .IR version
1319 indicates the ERSPAN version to be created: 0 for version 0 type I,
1320 1 for version 1 (type II) or 2 for version 2 (type III).
1321
1322 .sp
1323 .BR erspan " \fIIDX "
1324 - specifies the ERSPAN v1 index field.
1325 .IR IDX
1326 indicates a 20 bit index/port number associated with the ERSPAN
1327 traffic's source port and direction.
1328
1329 .sp
1330 .BR erspan_dir " { " \fIingress " | " \fIegress " }"
1331 - specifies the ERSPAN v2 mirrored traffic's direction.
1332
1333 .sp
1334 .BR erspan_hwid " \fIhwid "
1335 - an unique identifier of an ERSPAN v2 engine within a system.
1336 .IR hwid
1337 is a 6-bit value for users to configure.
1338
1339 .sp
1340 .BI [no]allow-localremote
1341 - specifies whether to allow remote endpoint to have an address configured on
1342 local host.
1343
1344 .sp
1345 .BR external
1346 - make this tunnel externally controlled (or not, which is the default).
1347 In the kernel, this is referred to as collect metadata mode. This flag is
1348 mutually exclusive with the
1349 .BR remote ,
1350 .BR local ,
1351 .BR erspan_ver ,
1352 .BR erspan ,
1353 .BR erspan_dir " and " erspan_hwid
1354 options.
1355
1356 .in -8
1357
1358 .TP
1359 GENEVE Type Support
1360 For a link of type
1361 .I GENEVE
1362 the following additional arguments are supported:
1363
1364 .BI "ip link add " DEVICE
1365 .BI type " geneve " id " VNI " remote " IPADDR"
1366 [
1367 .BI ttl " TTL "
1368 ] [
1369 .BI tos " TOS "
1370 ] [
1371 .BI df " DF "
1372 ] [
1373 .BI flowlabel " FLOWLABEL "
1374 ] [
1375 .BI dstport " PORT"
1376 ] [
1377 .RB [ no ] external
1378 ] [
1379 .RB [ no ] udpcsum
1380 ] [
1381 .RB [ no ] udp6zerocsumtx
1382 ] [
1383 .RB [ no ] udp6zerocsumrx
1384 ] [
1385 .B innerprotoinherit
1386 ]
1387
1388 .in +8
1389 .sp
1390 .BI id " VNI "
1391 - specifies the Virtual Network Identifier to use.
1392
1393 .sp
1394 .BI remote " IPADDR"
1395 - specifies the unicast destination IP address to use in outgoing packets.
1396
1397 .sp
1398 .BI ttl " TTL"
1399 - specifies the TTL value to use in outgoing packets. "0" or "auto" means
1400 use whatever default value, "inherit" means inherit the inner protocol's
1401 ttl. Default option is "0".
1402
1403 .sp
1404 .BI tos " TOS"
1405 - specifies the TOS value to use in outgoing packets.
1406
1407 .sp
1408 .BI df " DF"
1409 - specifies the usage of the Don't Fragment flag (DF) bit in outgoing packets
1410 with IPv4 headers. The value
1411 .B inherit
1412 causes the bit to be copied from the original IP header. The values
1413 .B unset
1414 and
1415 .B set
1416 cause the bit to be always unset or always set, respectively. By default, the
1417 bit is not set.
1418
1419 .sp
1420 .BI flowlabel " FLOWLABEL"
1421 - specifies the flow label to use in outgoing packets.
1422
1423 .sp
1424 .BI dstport " PORT"
1425 - select a destination port other than the default of 6081.
1426
1427 .sp
1428 .RB [ no ] external
1429 - make this tunnel externally controlled (or not, which is the default). This
1430 flag is mutually exclusive with the
1431 .BR id ,
1432 .BR remote ,
1433 .BR ttl ,
1434 .BR tos " and " flowlabel
1435 options.
1436
1437 .sp
1438 .RB [ no ] udpcsum
1439 - specifies if UDP checksum is calculated for transmitted packets over IPv4.
1440
1441 .sp
1442 .RB [ no ] udp6zerocsumtx
1443 - skip UDP checksum calculation for transmitted packets over IPv6.
1444
1445 .sp
1446 .RB [ no ] udp6zerocsumrx
1447 - allow incoming UDP packets over IPv6 with zero checksum field.
1448
1449 .sp
1450 .B innerprotoinherit
1451 - use IPv4/IPv6 as inner protocol instead of Ethernet.
1452
1453 .in -8
1454
1455 .TP
1456 Bareudp Type Support
1457 For a link of type
1458 .I Bareudp
1459 the following additional arguments are supported:
1460
1461 .BI "ip link add " DEVICE
1462 .BI type " bareudp " dstport " PORT " ethertype " PROTO"
1463 [
1464 .BI srcportmin " PORT "
1465 ] [
1466 .RB [ no ] multiproto
1467 ]
1468
1469 .in +8
1470 .sp
1471 .BI dstport " PORT"
1472 - specifies the destination port for the UDP tunnel.
1473
1474 .sp
1475 .BI ethertype " PROTO"
1476 - specifies the ethertype of the L3 protocol being tunnelled.
1477 .B ethertype
1478 can be given as plain Ethernet protocol number or using the protocol name
1479 ("ipv4", "ipv6", "mpls_uc", etc.).
1480
1481 .sp
1482 .BI srcportmin " PORT"
1483 - selects the lowest value of the UDP tunnel source port range.
1484
1485 .sp
1486 .RB [ no ] multiproto
1487 - activates support for protocols similar to the one
1488 .RB "specified by " ethertype .
1489 When
1490 .B ethertype
1491 is "mpls_uc" (that is, unicast MPLS), this allows the tunnel to also handle
1492 multicast MPLS.
1493 When
1494 .B ethertype
1495 is "ipv4", this allows the tunnel to also handle IPv6. This option is disabled
1496 by default.
1497
1498 .TP
1499 AMT Type Support
1500 For a link of type
1501 .I AMT
1502 the following additional arguments are supported:
1503
1504 .BI "ip link add " DEVICE
1505 .BI type " AMT " discovery " IPADDR " mode " { " gateway " | " relay " } "
1506 .BI local " IPADDR " dev " PHYS_DEV " [
1507 .BI relay_port " PORT " ]
1508 [
1509 .BI gateway_port " PORT " ]
1510 [
1511 .BI max_tunnels " NUMBER "
1512 ]
1513
1514 .in +8
1515 .sp
1516 .BI discovery " IPADDR"
1517 - specifies the unicast discovery IP address to use to find remote IP address.
1518
1519 .BR mode " { " gateway " | " relay " } "
1520 - specifies the role of AMT, Gateway or Relay
1521
1522 .BI local " IPADDR "
1523 - specifies the source IP address to use in outgoing packets.
1524
1525 .BI dev " PHYS_DEV "
1526 - specifies the underlying physical interface from which transform traffic
1527 is sent and received.
1528
1529 .BI relay_port " PORT "
1530 - specifies the UDP Relay port to communicate to the Relay.
1531
1532 .BI gateway_port " PORT "
1533 - specifies the UDP Gateway port to communicate to the Gateway.
1534
1535 .BI max_tunnels " NUMBER "
1536 - specifies the maximum number of tunnels.
1537
1538 .in -8
1539
1540 .TP
1541 MACVLAN and MACVTAP Type Support
1542 For a link of type
1543 .I MACVLAN
1544 or
1545 .I MACVTAP
1546 the following additional arguments are supported:
1547
1548 .BI "ip link add link " DEVICE " name " NAME
1549 .BR type " { " macvlan " | " macvtap " } "
1550 .BR mode " { " private " | " vepa " | " bridge " | " passthru
1551 .RB " [ " nopromisc " ] | " source " [ " nodst " ] } "
1552 .RB " [ " bcqueuelen " { " LENGTH " } ] "
1553 .RB " [ " bclim " " LIMIT " ] "
1554
1555 .in +8
1556 .sp
1557 .BR type " { " macvlan " | " macvtap " } "
1558 - specifies the link type to use.
1559 .BR macvlan " creates just a virtual interface, while "
1560 .BR macvtap " in addition creates a character device "
1561 .BR /dev/tapX " to be used just like a " tuntap " device."
1562
1563 .B mode private
1564 - Do not allow communication between
1565 .B macvlan
1566 instances on the same physical interface, even if the external switch supports
1567 hairpin mode.
1568
1569 .B mode vepa
1570 - Virtual Ethernet Port Aggregator mode. Data from one
1571 .B macvlan
1572 instance to the other on the same physical interface is transmitted over the
1573 physical interface. Either the attached switch needs to support hairpin mode,
1574 or there must be a TCP/IP router forwarding the packets in order to allow
1575 communication. This is the default mode.
1576
1577 .B mode bridge
1578 - In bridge mode, all endpoints are directly connected to each other,
1579 communication is not redirected through the physical interface's peer.
1580
1581 .BR mode " " passthru " [ " nopromisc " ] "
1582 - This mode gives more power to a single endpoint, usually in
1583 .BR macvtap " mode. It is not allowed for more than one endpoint on the same "
1584 physical interface. All traffic will be forwarded to this endpoint, allowing
1585 virtio guests to change MAC address or set promiscuous mode in order to bridge
1586 the interface or create vlan interfaces on top of it. By default, this mode
1587 forces the underlying interface into promiscuous mode. Passing the
1588 .BR nopromisc " flag prevents this, so the promisc flag may be controlled "
1589 using standard tools.
1590
1591 .BR mode " " source " [ " nodst " ] "
1592 - allows one to set a list of allowed mac address, which is used to match
1593 against source mac address from received frames on underlying interface. This
1594 allows creating mac based VLAN associations, instead of standard port or tag
1595 based. The feature is useful to deploy 802.1x mac based behavior,
1596 where drivers of underlying interfaces doesn't allows that. By default, packets
1597 are also considered (duplicated) for destination-based MACVLAN. Passing the
1598 .BR nodst " flag stops matching packets from also going through the "
1599 destination-based flow.
1600
1601 .BR bcqueuelen " { " LENGTH " } "
1602 - Set the length of the RX queue used to process broadcast and multicast packets.
1603 .BR LENGTH " must be a positive integer in the range [0-4294967295]."
1604 Setting a length of 0 will effectively drop all broadcast/multicast traffic.
1605 If not specified the macvlan driver default (1000) is used.
1606 Note that all macvlans that share the same underlying device are using the same
1607 .RB "queue. The parameter here is a " request ", the actual queue length used"
1608 will be the maximum length that any macvlan interface has requested.
1609 When listing device parameters both the bcqueuelen parameter
1610 as well as the actual used bcqueuelen are listed to better help
1611 the user understand the setting.
1612
1613 .BR bclim " " LIMIT
1614 - Set the threshold for broadcast queueing.
1615 .BR LIMIT " must be a 32-bit integer."
1616 Setting this to -1 disables broadcast queueing altogether. Otherwise
1617 a multicast address will be queued as broadcast if the number of devices
1618 using it is greater than the given value.
1619 .in -8
1620
1621 .TP
1622 High-availability Seamless Redundancy (HSR) Support
1623 For a link of type
1624 .I HSR
1625 the following additional arguments are supported:
1626
1627 .BI "ip link add link " DEVICE " name " NAME " type hsr"
1628 .BI slave1 " SLAVE1-IF " slave2 " SLAVE2-IF "
1629 .RB [ " interlink"
1630 .IR INTERLINK-IF " ] "
1631 .RB [ " supervision"
1632 .IR ADDR-BYTE " ] ["
1633 .BR version " { " 0 " | " 1 " } ["
1634 .BR proto " { " 0 " | " 1 " } ]"
1635
1636 .in +8
1637 .sp
1638 .BR type " hsr "
1639 - specifies the link type to use, here HSR.
1640
1641 .BI slave1 " SLAVE1-IF "
1642 - Specifies the physical device used for the first of the two ring ports.
1643
1644 .BI slave2 " SLAVE2-IF "
1645 - Specifies the physical device used for the second of the two ring ports.
1646
1647 .BI interlink " INTERLINK-IF"
1648 - The interlink device bound to the HSR network to connect SAN device(s).
1649
1650 .BI supervision " ADDR-BYTE"
1651 - The last byte of the multicast address used for HSR supervision frames.
1652 Default option is "0", possible values 0-255.
1653
1654 .BR version " { " 0 " | " 1 " }"
1655 - Selects the protocol version of the interface. Default option is "0", which
1656 corresponds to the 2010 version of the HSR standard. Option "1" activates the
1657 2012 version.
1658
1659 .BR proto " { " 0 " | " 1 " }"
1660 - Selects the protocol at the interface. Default option is "0", which
1661 corresponds to the HSR standard. Option "1" activates the Parallel
1662 Redundancy Protocol (PRP).
1663 .
1664 .in -8
1665
1666 .TP
1667 BRIDGE Type Support
1668 For a link of type
1669 .I BRIDGE
1670 the following additional arguments are supported:
1671
1672 .BI "ip link add " DEVICE " type bridge "
1673 [
1674 .BI ageing_time " AGEING_TIME "
1675 ] [
1676 .BI group_fwd_mask " MASK "
1677 ] [
1678 .BI group_address " ADDRESS "
1679 ] [
1680 .BI forward_delay " FORWARD_DELAY "
1681 ] [
1682 .BI hello_time " HELLO_TIME "
1683 ] [
1684 .BI max_age " MAX_AGE "
1685 ] [
1686 .BI stp_state " STP_STATE "
1687 ] [
1688 .BI mst_enabled " MST_ENABLED "
1689 ] [
1690 .BI priority " PRIORITY "
1691 ] [
1692 .BI no_linklocal_learn " NO_LINKLOCAL_LEARN "
1693 ] [
1694 .BI fdb_max_learned " FDB_MAX_LEARNED "
1695 ] [
1696 .BI vlan_filtering " VLAN_FILTERING "
1697 ] [
1698 .BI vlan_protocol " VLAN_PROTOCOL "
1699 ] [
1700 .BI vlan_default_pvid " VLAN_DEFAULT_PVID "
1701 ] [
1702 .BI vlan_stats_enabled " VLAN_STATS_ENABLED "
1703 ] [
1704 .BI vlan_stats_per_port " VLAN_STATS_PER_PORT "
1705 ] [
1706 .BI mcast_snooping " MULTICAST_SNOOPING "
1707 ] [
1708 .BI mcast_vlan_snooping " MULTICAST_VLAN_SNOOPING "
1709 ] [
1710 .BI mcast_router " MULTICAST_ROUTER "
1711 ] [
1712 .BI mcast_query_use_ifaddr " MCAST_QUERY_USE_IFADDR "
1713 ] [
1714 .BI mcast_querier " MULTICAST_QUERIER "
1715 ] [
1716 .BI mcast_hash_elasticity " HASH_ELASTICITY "
1717 ] [
1718 .BI mcast_hash_max " HASH_MAX "
1719 ] [
1720 .BI mcast_last_member_count " LAST_MEMBER_COUNT "
1721 ] [
1722 .BI mcast_startup_query_count " STARTUP_QUERY_COUNT "
1723 ] [
1724 .BI mcast_last_member_interval " LAST_MEMBER_INTERVAL "
1725 ] [
1726 .BI mcast_membership_interval " MEMBERSHIP_INTERVAL "
1727 ] [
1728 .BI mcast_querier_interval " QUERIER_INTERVAL "
1729 ] [
1730 .BI mcast_query_interval " QUERY_INTERVAL "
1731 ] [
1732 .BI mcast_query_response_interval " QUERY_RESPONSE_INTERVAL "
1733 ] [
1734 .BI mcast_startup_query_interval " STARTUP_QUERY_INTERVAL "
1735 ] [
1736 .BI mcast_stats_enabled " MCAST_STATS_ENABLED "
1737 ] [
1738 .BI mcast_igmp_version " IGMP_VERSION "
1739 ] [
1740 .BI mcast_mld_version " MLD_VERSION "
1741 ] [
1742 .BI nf_call_iptables " NF_CALL_IPTABLES "
1743 ] [
1744 .BI nf_call_ip6tables " NF_CALL_IP6TABLES "
1745 ] [
1746 .BI nf_call_arptables " NF_CALL_ARPTABLES "
1747 ]
1748
1749 .in +8
1750 .sp
1751 .BI ageing_time " AGEING_TIME "
1752 - configure the bridge's FDB entries ageing time, ie the number of
1753 seconds a MAC address will be kept in the FDB after a packet has been
1754 received from that address. after this time has passed, entries are
1755 cleaned up.
1756
1757 .BI group_fwd_mask " MASK "
1758 - set the group forward mask. This is the bitmask that is applied to
1759 decide whether to forward incoming frames destined to link-local
1760 addresses, ie addresses of the form 01:80:C2:00:00:0X (defaults to 0,
1761 ie the bridge does not forward any link-local frames).
1762
1763 .BI group_address " ADDRESS "
1764 - set the MAC address of the multicast group this bridge uses for STP.
1765 The address must be a link-local address in standard Ethernet MAC
1766 address format, ie an address of the form 01:80:C2:00:00:0X, with X
1767 in [0, 4..f].
1768
1769 .BI forward_delay " FORWARD_DELAY "
1770 - set the forwarding delay in seconds, ie the time spent in LISTENING
1771 state (before moving to LEARNING) and in LEARNING state (before
1772 moving to FORWARDING). Only relevant if STP is enabled. Valid values
1773 are between 2 and 30.
1774
1775 .BI hello_time " HELLO_TIME "
1776 - set the time in seconds between hello packets sent by the bridge,
1777 when it is a root bridge or a designated bridges.
1778 Only relevant if STP is enabled. Valid values are between 1 and 10.
1779
1780 .BI max_age " MAX_AGE "
1781 - set the hello packet timeout, ie the time in seconds until another
1782 bridge in the spanning tree is assumed to be dead, after reception of
1783 its last hello message. Only relevant if STP is enabled. Valid values
1784 are between 6 and 40.
1785
1786 .BI stp_state " STP_STATE "
1787 - turn spanning tree protocol on
1788 .RI ( STP_STATE " > 0) "
1789 or off
1790 .RI ( STP_STATE " == 0). "
1791 for this bridge.
1792
1793 .BI mst_enabled " MST_ENABLED "
1794 - turn multiple spanning tree (MST) support on
1795 .RI ( MST_ENABLED " > 0) "
1796 or off
1797 .RI ( MST_ENABLED " == 0). "
1798 When enabled, sets of VLANs can be associated with multiple spanning
1799 tree instances (MSTIs), and STP states for each port can be controlled
1800 on a per-MSTI basis. Note: no implementation of the MSTP protocol is
1801 provided, only the primitives needed to implement it. To avoid
1802 interfering with the legacy per-VLAN STP states, this setting can only
1803 be changed when no bridge VLANs are configured.
1804
1805 .BI priority " PRIORITY "
1806 - set this bridge's spanning tree priority, used during STP root
1807 bridge election.
1808 .I PRIORITY
1809 is a 16bit unsigned integer.
1810
1811 .BI no_linklocal_learn " NO_LINKLOCAL_LEARN "
1812 - turn link-local learning on
1813 .RI ( NO_LINKLOCAL_LEARN " == 0) "
1814 or off
1815 .RI ( NO_LINKLOCAL_LEARN " > 0). "
1816 When disabled, the bridge will not learn from link-local frames (default:
1817 enabled).
1818
1819 .BI fdb_max_learned " FDB_MAX_LEARNED "
1820 - set the maximum number of learned FDB entries. If
1821 .RI ( FDB_MAX_LEARNED " == 0) "
1822 the feature is disabled. Default is
1823 .BR 0 .
1824 .I FDB_MAX_LEARNED
1825 is a 32bit unsigned integer.
1826
1827 .BI vlan_filtering " VLAN_FILTERING "
1828 - turn VLAN filtering on
1829 .RI ( VLAN_FILTERING " > 0) "
1830 or off
1831 .RI ( VLAN_FILTERING " == 0). "
1832 When disabled, the bridge will not consider the VLAN tag when handling packets.
1833
1834 .BR vlan_protocol " { " 802.1Q " | " 802.1ad " } "
1835 - set the protocol used for VLAN filtering.
1836
1837 .BI vlan_default_pvid " VLAN_DEFAULT_PVID "
1838 - set the default PVID (native/untagged VLAN ID) for this bridge.
1839
1840 .BI vlan_stats_enabled " VLAN_STATS_ENABLED "
1841 - enable
1842 .RI ( VLAN_STATS_ENABLED " == 1) "
1843 or disable
1844 .RI ( VLAN_STATS_ENABLED " == 0) "
1845 per-VLAN stats accounting.
1846
1847 .BI vlan_stats_per_port " VLAN_STATS_PER_PORT "
1848 - enable
1849 .RI ( VLAN_STATS_PER_PORT " == 1) "
1850 or disable
1851 .RI ( VLAN_STATS_PER_PORT " == 0) "
1852 per-VLAN per-port stats accounting. Can be changed only when there are no port VLANs configured.
1853
1854 .BI mcast_snooping " MULTICAST_SNOOPING "
1855 - turn multicast snooping on
1856 .RI ( MULTICAST_SNOOPING " > 0) "
1857 or off
1858 .RI ( MULTICAST_SNOOPING " == 0). "
1859
1860 .BI mcast_vlan_snooping " MULTICAST_VLAN_SNOOPING "
1861 - turn multicast VLAN snooping on
1862 .RI ( MULTICAST_VLAN_SNOOPING " > 0) "
1863 or off
1864 .RI ( MULTICAST_VLAN_SNOOPING " == 0). "
1865
1866 .BI mcast_router " MULTICAST_ROUTER "
1867 - set bridge's multicast router if IGMP snooping is enabled.
1868 .I MULTICAST_ROUTER
1869 is an integer value having the following meaning:
1870 .in +8
1871 .sp
1872 .B 0
1873 - disabled.
1874
1875 .B 1
1876 - automatic (queried).
1877
1878 .B 2
1879 - permanently enabled.
1880 .in -8
1881
1882 .BI mcast_query_use_ifaddr " MCAST_QUERY_USE_IFADDR "
1883 - whether to use the bridge's own IP address as source address for IGMP queries
1884 .RI ( MCAST_QUERY_USE_IFADDR " > 0) "
1885 or the default of 0.0.0.0
1886 .RI ( MCAST_QUERY_USE_IFADDR " == 0). "
1887
1888 .BI mcast_querier " MULTICAST_QUERIER "
1889 - enable
1890 .RI ( MULTICAST_QUERIER " > 0) "
1891 or disable
1892 .RI ( MULTICAST_QUERIER " == 0) "
1893 IGMP querier, ie sending of multicast queries by the bridge (default: disabled).
1894
1895 .BI mcast_querier_interval " QUERIER_INTERVAL "
1896 - interval between queries sent by other routers. if no queries are seen
1897 after this delay has passed, the bridge will start to send its own queries
1898 (as if
1899 .BI mcast_querier
1900 was enabled).
1901
1902 .BI mcast_hash_elasticity " HASH_ELASTICITY "
1903 - set multicast database hash elasticity, ie the maximum chain length
1904 in the multicast hash table (defaults to 4).
1905
1906 .BI mcast_hash_max " HASH_MAX "
1907 - set maximum size of multicast hash table (defaults to 512,
1908 value must be a power of 2).
1909
1910 .BI mcast_last_member_count " LAST_MEMBER_COUNT "
1911 - set multicast last member count, ie the number of queries the bridge
1912 will send before stopping forwarding a multicast group after a "leave"
1913 message has been received (defaults to 2).
1914
1915 .BI mcast_last_member_interval " LAST_MEMBER_INTERVAL "
1916 - interval between queries to find remaining members of a group,
1917 after a "leave" message is received.
1918
1919 .BI mcast_startup_query_count " STARTUP_QUERY_COUNT "
1920 - set the number of IGMP queries to send during startup phase (defaults to 2).
1921
1922 .BI mcast_startup_query_interval " STARTUP_QUERY_INTERVAL "
1923 - interval between queries in the startup phase.
1924
1925 .BI mcast_query_interval " QUERY_INTERVAL "
1926 - interval between queries sent by the bridge after the end of the
1927 startup phase.
1928
1929 .BI mcast_query_response_interval " QUERY_RESPONSE_INTERVAL "
1930 - set the Max Response Time/Maximum Response Delay for IGMP/MLD
1931 queries sent by the bridge.
1932
1933 .BI mcast_membership_interval " MEMBERSHIP_INTERVAL "
1934 - delay after which the bridge will leave a group,
1935 if no membership reports for this group are received.
1936
1937 .BI mcast_stats_enabled " MCAST_STATS_ENABLED "
1938 - enable
1939 .RI ( MCAST_STATS_ENABLED " > 0) "
1940 or disable
1941 .RI ( MCAST_STATS_ENABLED " == 0) "
1942 multicast (IGMP/MLD) stats accounting.
1943
1944 .BI mcast_igmp_version " IGMP_VERSION "
1945 - set the IGMP version.
1946
1947 .BI mcast_mld_version " MLD_VERSION "
1948 - set the MLD version.
1949
1950 .BI nf_call_iptables " NF_CALL_IPTABLES "
1951 - enable
1952 .RI ( NF_CALL_IPTABLES " > 0) "
1953 or disable
1954 .RI ( NF_CALL_IPTABLES " == 0) "
1955 iptables hooks on the bridge.
1956
1957 .BI nf_call_ip6tables " NF_CALL_IP6TABLES "
1958 - enable
1959 .RI ( NF_CALL_IP6TABLES " > 0) "
1960 or disable
1961 .RI ( NF_CALL_IP6TABLES " == 0) "
1962 ip6tables hooks on the bridge.
1963
1964 .BI nf_call_arptables " NF_CALL_ARPTABLES "
1965 - enable
1966 .RI ( NF_CALL_ARPTABLES " > 0) "
1967 or disable
1968 .RI ( NF_CALL_ARPTABLES " == 0) "
1969 arptables hooks on the bridge.
1970
1971
1972 .in -8
1973
1974 .TP
1975 MACsec Type Support
1976 For a link of type
1977 .I MACsec
1978 the following additional arguments are supported:
1979
1980 .BI "ip link add link " DEVICE " name " NAME " type macsec"
1981 [ [
1982 .BI address " <lladdr>"
1983 ]
1984 .BI port " PORT"
1985 |
1986 .BI sci " SCI"
1987 ] [
1988 .BI cipher " CIPHER_SUITE"
1989 ] [
1990 .BR icvlen " { "
1991 .IR 8..16 " } ] ["
1992 .BR encrypt " {"
1993 .BR on " | " off " } ] [ "
1994 .BR send_sci " { " on " | " off " } ] ["
1995 .BR end_station " { " on " | " off " } ] ["
1996 .BR scb " { " on " | " off " } ] ["
1997 .BR protect " { " on " | " off " } ] ["
1998 .BR replay " { " on " | " off " }"
1999 .BR window " { "
2000 .IR 0..2^32-1 " } ] ["
2001 .BR validate " { " strict " | " check " | " disabled " } ] ["
2002 .BR encodingsa " { "
2003 .IR 0..3 " } ]"
2004
2005 .in +8
2006 .sp
2007 .BI address " <lladdr> "
2008 - sets the system identifier component of secure channel for this MACsec device.
2009
2010 .sp
2011 .BI port " PORT "
2012 - sets the port number component of secure channel for this MACsec
2013 device, in a range from 1 to 65535 inclusive. Numbers with a leading "
2014 0 " or " 0x " are interpreted as octal and hexadecimal, respectively.
2015
2016 .sp
2017 .BI sci " SCI "
2018 - sets the secure channel identifier for this MACsec device.
2019 .I SCI
2020 is a 64bit wide number in hexadecimal format.
2021
2022 .sp
2023 .BI cipher " CIPHER_SUITE "
2024 - defines the cipher suite to use.
2025
2026 .sp
2027 .BI icvlen " LENGTH "
2028 - sets the length of the Integrity Check Value (ICV).
2029
2030 .sp
2031 .BR "encrypt on " or " encrypt off"
2032 - switches between authenticated encryption, or authenticity mode only.
2033
2034 .sp
2035 .BR "send_sci on " or " send_sci off"
2036 - specifies whether the SCI is included in every packet,
2037 or only when it is necessary.
2038
2039 .sp
2040 .BR "end_station on " or " end_station off"
2041 - sets the End Station bit.
2042
2043 .sp
2044 .BR "scb on " or " scb off"
2045 - sets the Single Copy Broadcast bit.
2046
2047 .sp
2048 .BR "protect on " or " protect off"
2049 - enables MACsec protection on the device.
2050
2051 .sp
2052 .BR "replay on " or " replay off"
2053 - enables replay protection on the device.
2054
2055 .in +8
2056
2057 .sp
2058 .BI window " SIZE "
2059 - sets the size of the replay window.
2060
2061 .in -8
2062
2063 .sp
2064 .BR "validate strict " or " validate check " or " validate disabled"
2065 - sets the validation mode on the device.
2066
2067 .sp
2068 .BI encodingsa " AN "
2069 - sets the active secure association for transmission.
2070
2071 .in -8
2072
2073 .TP
2074 VRF Type Support
2075 For a link of type
2076 .I VRF
2077 the following additional arguments are supported:
2078
2079 .BI "ip link add " DEVICE " type vrf table " TABLE
2080
2081 .in +8
2082 .sp
2083 .BR table " table id associated with VRF device"
2084
2085 .in -8
2086
2087 .TP
2088 RMNET Type Support
2089 For a link of type
2090 .I RMNET
2091 the following additional arguments are supported:
2092
2093 .BI "ip link add link " DEVICE " name " NAME " type rmnet mux_id " MUXID
2094
2095 .in +8
2096 .sp
2097 .BI mux_id " MUXID "
2098 - specifies the mux identifier for the rmnet device, possible values 1-254.
2099
2100 .in -8
2101
2102 .TP
2103 XFRM Type Support
2104 For a link of type
2105 .I XFRM
2106 the following additional arguments are supported:
2107
2108 .BI "ip link add " DEVICE " type xfrm dev " PHYS_DEV " [ if_id " IF_ID " ]"
2109 .BR "[ external ]"
2110
2111 .in +8
2112 .sp
2113 .BI dev " PHYS_DEV "
2114 - specifies the underlying physical interface from which transform traffic is sent and received.
2115
2116 .sp
2117 .BI if_id " IF-ID "
2118 - specifies the hexadecimal lookup key used to send traffic to and from specific xfrm
2119 policies. Policies must be configured with the same key. If not set, the key defaults to
2120 0 and will match any policies which similarly do not have a lookup key configuration.
2121
2122 .sp
2123 .BI external
2124 - make this device externally controlled. This flag is mutually exclusive with the
2125 .BR dev " and " if_id
2126 options.
2127
2128 .in -8
2129
2130 .TP
2131 GTP Type Support
2132 For a link of type
2133 .I GTP
2134 the following additional arguments are supported:
2135
2136 .BI "ip link add " DEVICE " type gtp role " ROLE " hsize " HSIZE
2137
2138 .in +8
2139 .sp
2140 .BI role " ROLE "
2141 - specifies the role of the GTP device, either sgsn or ggsn
2142
2143 .sp
2144 .BI hsize " HSIZE "
2145 - specifies size of the hashtable which stores PDP contexts
2146
2147 .sp
2148 .BI restart_count " RESTART_COUNT "
2149 - GTP instance restart counter
2150
2151 .TP
2152 PFCP Type Support
2153 For a link of type
2154 .I PFCP
2155 no additional arguments are supported
2156
2157 .in -8
2158
2159 .SS ip link delete - delete virtual link
2160
2161 .TP
2162 .BI dev " DEVICE "
2163 specifies the virtual device to act operate on.
2164
2165 .TP
2166 .BI group " GROUP "
2167 specifies the group of virtual links to delete. Group 0 is not allowed to be
2168 deleted since it is the default group.
2169
2170 .TP
2171 .BI type " TYPE "
2172 specifies the type of the device.
2173
2174 .SS ip link set - change device attributes
2175
2176 .PP
2177 .B Warning:
2178 If multiple parameter changes are requested,
2179 .B ip
2180 aborts immediately after any of the changes have failed.
2181 This is the only case when
2182 .B ip
2183 can move the system to an unpredictable state. The solution
2184 is to avoid changing several parameters with one
2185 .B ip link set
2186 call.
2187 The modifier
2188 .B change
2189 is equivalent to
2190 .BR "set" .
2191
2192
2193 .TP
2194 .BI dev " DEVICE "
2195 .I DEVICE
2196 specifies network device to operate on. When configuring SR-IOV
2197 Virtual Function (VF) devices, this keyword should specify the
2198 associated Physical Function (PF) device.
2199
2200 .TP
2201 .BI group " GROUP "
2202 .I GROUP
2203 has a dual role: If both group and dev are present, then move the device to the
2204 specified group. If only a group is specified, then the command operates on
2205 all devices in that group.
2206
2207 .TP
2208 .BR up " and " down
2209 change the state of the device to
2210 .B UP
2211 or
2212 .BR "DOWN" .
2213
2214 .TP
2215 .BR "arp on " or " arp off"
2216 change the
2217 .B NOARP
2218 flag on the device.
2219
2220 .TP
2221 .BR "multicast on " or " multicast off"
2222 change the
2223 .B MULTICAST
2224 flag on the device.
2225
2226 .TP
2227 .BR "allmulticast on " or " allmulticast off"
2228 change the
2229 .B ALLMULTI
2230 flag on the device. When enabled, instructs network driver to retrieve all
2231 multicast packets from the network to the kernel for further processing.
2232
2233 .TP
2234 .BR "promisc on " or " promisc off"
2235 change the
2236 .B PROMISC
2237 flag on the device. When enabled, activates promiscuous operation of the
2238 network device.
2239
2240 .TP
2241 .BR "trailers on " or " trailers off"
2242 change the
2243 .B NOTRAILERS
2244 flag on the device,
2245 .B NOT
2246 used by the Linux and exists for BSD compatibility.
2247
2248 .TP
2249 .BR "protodown on " or " protodown off"
2250 change the
2251 .B PROTODOWN
2252 state on the device. Indicates that a protocol error has been detected
2253 on the port. Switch drivers can react to this error by doing a phys
2254 down on the switch port.
2255
2256 .TP
2257 .BR "protodown_reason PREASON on " or " off"
2258 set
2259 .B PROTODOWN
2260 reasons on the device. protodown reason bit names can be enumerated under
2261 /etc/iproute2/protodown_reasons.d/. possible reasons bits 0-31
2262
2263 .TP
2264 .BR "dynamic on " or " dynamic off"
2265 change the
2266 .B DYNAMIC
2267 flag on the device. Indicates that address can change when interface
2268 goes down (currently
2269 .B NOT
2270 used by the Linux).
2271
2272 .TP
2273 .BI name " NAME"
2274 change the name of the device. This operation is not
2275 recommended if the device is running or has some addresses
2276 already configured.
2277
2278 .TP
2279 .BI txqueuelen " NUMBER"
2280 .TP
2281 .BI txqlen " NUMBER"
2282 change the transmit queue length of the device.
2283
2284 .TP
2285 .BI mtu " NUMBER"
2286 change the
2287 .I MTU
2288 of the device.
2289
2290 .TP
2291 .BI address " LLADDRESS"
2292 change the station address of the interface.
2293
2294 .TP
2295 .BI broadcast " LLADDRESS"
2296 .TP
2297 .BI brd " LLADDRESS"
2298 .TP
2299 .BI peer " LLADDRESS"
2300 change the link layer broadcast address or the peer address when
2301 the interface is
2302 .IR "POINTOPOINT" .
2303
2304 .TP
2305 .B netns
2306 .RI "{ " PID " | " NETNSNAME " | " NETNSFILE " }"
2307 .br
2308 move the device to the network namespace associated with process
2309 .IR "PID " or
2310 the name
2311 .IR "NETNSNAME " or
2312 the file
2313 .IR "NETNSFILE".
2314
2315 Some devices are not allowed to change network namespace: loopback, bridge,
2316 wireless. These are network namespace local devices. In such case
2317 .B ip
2318 tool will return "Invalid argument" error. It is possible to find out
2319 if device is local to a single network namespace by checking
2320 .B netns-local
2321 flag in the output of the
2322 .BR ethtool ":"
2323
2324 .in +8
2325 .B ethtool -k
2326 .I DEVICE
2327 .in -8
2328
2329 To change network namespace for wireless devices the
2330 .B iw
2331 tool can be used. But it allows one to change network namespace only for
2332 physical devices and by process
2333 .IR PID .
2334
2335 .TP
2336 .BI alias " NAME"
2337 give the device a symbolic name for easy reference.
2338
2339 .TP
2340 .BI group " GROUP"
2341 specify the group the device belongs to.
2342 The available groups are listed in
2343 .BR /usr/share/iproute2/group " or " /etc/iproute2/group
2344 (has precedence if exists).
2345
2346 .TP
2347 .BI vf " NUM"
2348 specify a Virtual Function device to be configured. The associated PF device
2349 must be specified using the
2350 .B dev
2351 parameter.
2352
2353 .in +8
2354 .BI mac " LLADDRESS"
2355 - change the station address for the specified VF. The
2356 .B vf
2357 parameter must be specified.
2358
2359 .sp
2360 .BI vlan " VLANID"
2361 - change the assigned VLAN for the specified VF. When specified, all traffic
2362 sent from the VF will be tagged with the specified VLAN ID. Incoming traffic
2363 will be filtered for the specified VLAN ID, and will have all VLAN tags
2364 stripped before being passed to the VF. Setting this parameter to 0 disables
2365 VLAN tagging and filtering. The
2366 .B vf
2367 parameter must be specified.
2368
2369 .sp
2370 .BI qos " VLAN-QOS"
2371 - assign VLAN QOS (priority) bits for the VLAN tag. When specified, all VLAN
2372 tags transmitted by the VF will include the specified priority bits in the
2373 VLAN tag. If not specified, the value is assumed to be 0. Both the
2374 .B vf
2375 and
2376 .B vlan
2377 parameters must be specified. Setting both
2378 .B vlan
2379 and
2380 .B qos
2381 as 0 disables VLAN tagging and filtering for the VF.
2382
2383 .sp
2384 .BI proto " VLAN-PROTO"
2385 - assign VLAN PROTOCOL for the VLAN tag, either 802.1Q or 802.1ad.
2386 Setting to 802.1ad, all traffic sent from the VF will be tagged with
2387 VLAN S-Tag. Incoming traffic will have VLAN S-Tags stripped before
2388 being passed to the VF. Setting to 802.1ad also enables an option to
2389 concatenate another VLAN tag, so both S-TAG and C-TAG will be
2390 inserted/stripped for outgoing/incoming traffic, respectively. If not
2391 specified, the value is assumed to be 802.1Q. Both the
2392 .B vf
2393 and
2394 .B vlan
2395 parameters must be specified.
2396
2397 .sp
2398 .BI rate " TXRATE"
2399 -- change the allowed transmit bandwidth, in Mbps, for the specified VF.
2400 Setting this parameter to 0 disables rate limiting.
2401 .B vf
2402 parameter must be specified.
2403 Please use new API
2404 .B "max_tx_rate"
2405 option instead.
2406
2407 .sp
2408 .BI max_tx_rate " TXRATE"
2409 - change the allowed maximum transmit bandwidth, in Mbps, for the
2410 specified VF. Setting this parameter to 0 disables rate limiting.
2411 .B vf
2412 parameter must be specified.
2413
2414 .sp
2415 .BI min_tx_rate " TXRATE"
2416 - change the allowed minimum transmit bandwidth, in Mbps, for the specified VF.
2417 Minimum TXRATE should be always <= Maximum TXRATE.
2418 Setting this parameter to 0 disables rate limiting.
2419 .B vf
2420 parameter must be specified.
2421
2422 .sp
2423 .BI spoofchk " on|off"
2424 - turn packet spoof checking on or off for the specified VF.
2425 .sp
2426 .BI query_rss " on|off"
2427 - toggle the ability of querying the RSS configuration of a specific
2428 VF. VF RSS information like RSS hash key may be considered sensitive
2429 on some devices where this information is shared between VF and PF
2430 and thus its querying may be prohibited by default.
2431 .sp
2432 .BI state " auto|enable|disable"
2433 - set the virtual link state as seen by the specified VF. Setting to
2434 auto means a reflection of the PF link state, enable lets the VF to
2435 communicate with other VFs on this host even if the PF link state is
2436 down, disable causes the HW to drop any packets sent by the VF.
2437 .sp
2438 .BI trust " on|off"
2439 - trust the specified VF user. This enables that VF user can set a
2440 specific feature which may impact security and/or
2441 performance. (e.g. VF multicast promiscuous mode)
2442 .sp
2443 .BI node_guid " eui64"
2444 - configure node GUID for Infiniband VFs.
2445 .sp
2446 .BI port_guid " eui64"
2447 - configure port GUID for Infiniband VFs.
2448 .in -8
2449
2450 .TP
2451 .B xdp object "|" pinned "|" off
2452 set (or unset) a XDP ("eXpress Data Path") BPF program to run on every
2453 packet at driver level.
2454 .B ip link
2455 output will indicate a
2456 .B xdp
2457 flag for the networking device. If the driver does not have native XDP
2458 support, the kernel will fall back to a slower, driver-independent "generic"
2459 XDP variant. The
2460 .B ip link
2461 output will in that case indicate
2462 .B xdpgeneric
2463 instead of
2464 .B xdp
2465 only. If the driver does have native XDP support, but the program is
2466 loaded under
2467 .B xdpgeneric object "|" pinned
2468 then the kernel will use the generic XDP variant instead of the native one.
2469 .B xdpdrv
2470 has the opposite effect of requestsing that the automatic fallback to the
2471 generic XDP variant be disabled and in case driver is not XDP-capable error
2472 should be returned.
2473 .B xdpdrv
2474 also disables hardware offloads.
2475 .B xdpoffload
2476 in ip link output indicates that the program has been offloaded to hardware
2477 and can also be used to request the "offload" mode, much like
2478 .B xdpgeneric
2479 it forces program to be installed specifically in HW/FW of the apater.
2480
2481 .B off
2482 (or
2483 .B none
2484 )
2485 - Detaches any currently attached XDP/BPF program from the given device.
2486
2487 .BI object " FILE "
2488 - Attaches a XDP/BPF program to the given device. The
2489 .I FILE
2490 points to a BPF ELF file (f.e. generated by LLVM) that contains the BPF
2491 program code, map specifications, etc. If a XDP/BPF program is already
2492 attached to the given device, an error will be thrown. If no XDP/BPF
2493 program is currently attached, the device supports XDP and the program
2494 from the BPF ELF file passes the kernel verifier, then it will be attached
2495 to the device. If the option
2496 .I -force
2497 is passed to
2498 .B ip
2499 then any prior attached XDP/BPF program will be atomically overridden and
2500 no error will be thrown in this case. If no
2501 .B section
2502 option is passed, then the default section name ("prog") will be assumed,
2503 otherwise the provided section name will be used. If no
2504 .B verbose
2505 option is passed, then a verifier log will only be dumped on load error.
2506 See also
2507 .B EXAMPLES
2508 section for usage examples.
2509
2510 .BI section " NAME "
2511 - Specifies a section name that contains the BPF program code. If no section
2512 name is specified, the default one ("prog") will be used. This option is
2513 to be passed with the
2514 .B object
2515 option.
2516
2517 .BI program " NAME "
2518 - Specifies the BPF program name that need to be attached. When the program
2519 name is specified, the section name parameter will be ignored. This option
2520 only works when iproute2 build with
2521 .B libbpf
2522 support.
2523
2524 .BI verbose
2525 - Act in verbose mode. For example, even in case of success, this will
2526 print the verifier log in case a program was loaded from a BPF ELF file.
2527
2528 .BI pinned " FILE "
2529 - Attaches a XDP/BPF program to the given device. The
2530 .I FILE
2531 points to an already pinned BPF program in the BPF file system. The option
2532 .B section
2533 doesn't apply here, but otherwise semantics are the same as with the option
2534 .B object
2535 described already.
2536
2537 .TP
2538 .BI master " DEVICE"
2539 set master device of the device (enslave device).
2540
2541 .TP
2542 .BI nomaster
2543 unset master device of the device (release device).
2544
2545 .TP
2546 .BI addrgenmode " eui64|none|stable_secret|random"
2547 set the IPv6 address generation mode
2548
2549 .I eui64
2550 - use a Modified EUI-64 format interface identifier
2551
2552 .I none
2553 - disable automatic address generation
2554
2555 .I stable_secret
2556 - generate the interface identifier based on a preset
2557 /proc/sys/net/ipv6/conf/{default,DEVICE}/stable_secret
2558
2559 .I random
2560 - like stable_secret, but auto-generate a new random secret if none is set
2561
2562 .TP
2563 .BR "link-netnsid "
2564 set peer netnsid for a cross-netns interface
2565
2566 .TP
2567 .BI type " ETYPE TYPE_ARGS"
2568 Change type-specific settings. For a list of supported types and arguments refer
2569 to the description of
2570 .B "ip link add"
2571 above. In addition to that, it is possible to manipulate settings to slave
2572 devices:
2573
2574 .TP
2575 Bridge Slave Support
2576 For a link with master
2577 .B bridge
2578 the following additional arguments are supported:
2579
2580 .B "ip link set type bridge_slave"
2581 [
2582 .B fdb_flush
2583 ] [
2584 .BI state " STATE"
2585 ] [
2586 .BI priority " PRIO"
2587 ] [
2588 .BI cost " COST"
2589 ] [
2590 .BR guard " { " on " | " off " }"
2591 ] [
2592 .BR hairpin " { " on " | " off " }"
2593 ] [
2594 .BR fastleave " { " on " | " off " }"
2595 ] [
2596 .BR root_block " { " on " | " off " }"
2597 ] [
2598 .BR learning " { " on " | " off " }"
2599 ] [
2600 .BR flood " { " on " | " off " }"
2601 ] [
2602 .BR proxy_arp " { " on " | " off " }"
2603 ] [
2604 .BR proxy_arp_wifi " { " on " | " off " }"
2605 ] [
2606 .BI mcast_router " MULTICAST_ROUTER"
2607 ] [
2608 .BR mcast_fast_leave " { " on " | " off "}"
2609 ] [
2610 .BR bcast_flood " { " on " | " off " }"
2611 ] [
2612 .BR mcast_flood " { " on " | " off " }"
2613 ] [
2614 .BR mcast_to_unicast " { " on " | " off " }"
2615 ] [
2616 .BR group_fwd_mask " MASK"
2617 ] [
2618 .BR neigh_suppress " { " on " | " off " }"
2619 ] [
2620 .BR neigh_vlan_suppress " { " on " | " off " }"
2621 ] [
2622 .BR vlan_tunnel " { " on " | " off " }"
2623 ] [
2624 .BR isolated " { " on " | " off " }"
2625 ] [
2626 .BR locked " { " on " | " off " }"
2627 ] [
2628 .BR mab " { " on " | " off " }"
2629 ] [
2630 .BR backup_port " DEVICE"
2631 ] [
2632 .BR nobackup_port
2633 ] [
2634 .BR backup_nhid " NHID"
2635 ]
2636
2637 .in +8
2638 .sp
2639 .B fdb_flush
2640 - flush bridge slave's fdb dynamic entries.
2641
2642 .BI state " STATE"
2643 - Set port state.
2644 .I STATE
2645 is a number representing the following states:
2646 .BR 0 " (disabled),"
2647 .BR 1 " (listening),"
2648 .BR 2 " (learning),"
2649 .BR 3 " (forwarding),"
2650 .BR 4 " (blocking)."
2651
2652 .BI priority " PRIO"
2653 - set port priority (allowed values are between 0 and 63, inclusively).
2654
2655 .BI cost " COST"
2656 - set port cost (allowed values are between 1 and 65535, inclusively).
2657
2658 .BR guard " { " on " | " off " }"
2659 - block incoming BPDU packets on this port.
2660
2661 .BR hairpin " { " on " | " off " }"
2662 - enable hairpin mode on this port. This will allow incoming packets on this
2663 port to be reflected back.
2664
2665 .BR fastleave " { " on " | " off " }"
2666 - enable multicast fast leave on this port.
2667
2668 .BR root_block " { " on " | " off " }"
2669 - block this port from becoming the bridge's root port.
2670
2671 .BR learning " { " on " | " off " }"
2672 - allow MAC address learning on this port.
2673
2674 .BR flood " { " on " | " off " }"
2675 - open the flood gates on this port, i.e. forward all unicast frames to this
2676 port also. Requires
2677 .BR proxy_arp " and " proxy_arp_wifi
2678 to be turned off.
2679
2680 .BR proxy_arp " { " on " | " off " }"
2681 - enable proxy ARP on this port.
2682
2683 .BR proxy_arp_wifi " { " on " | " off " }"
2684 - enable proxy ARP on this port which meets extended requirements by IEEE
2685 802.11 and Hotspot 2.0 specifications.
2686
2687 .BI mcast_router " MULTICAST_ROUTER"
2688 - configure this port for having multicast routers attached. A port with a
2689 multicast router will receive all multicast traffic.
2690 .I MULTICAST_ROUTER
2691 may be either
2692 .B 0
2693 to disable multicast routers on this port,
2694 .B 1
2695 to let the system detect the presence of routers (this is the default),
2696 .B 2
2697 to permanently enable multicast traffic forwarding on this port or
2698 .B 3
2699 to enable multicast routers temporarily on this port, not depending on incoming
2700 queries.
2701
2702 .BR mcast_fast_leave " { " on " | " off " }"
2703 - this is a synonym to the
2704 .B fastleave
2705 option above.
2706
2707 .BR bcast_flood " { " on " | " off " }"
2708 - controls flooding of broadcast traffic on the given port. By default
2709 this flag is on.
2710
2711 .BR mcast_flood " { " on " | " off " }"
2712 - controls whether a given port will flood multicast traffic for which
2713 there is no MDB entry. By default this flag is on.
2714
2715 .BR mcast_to_unicast " { " on " | " off " }"
2716 - controls whether a given port will replicate packets using unicast
2717 instead of multicast. By default this flag is off.
2718
2719 .BI group_fwd_mask " MASK "
2720 - set the group forward mask. This is the bitmask that is applied to
2721 decide whether to forward incoming frames destined to link-local
2722 addresses, ie addresses of the form 01:80:C2:00:00:0X (defaults to
2723 0, ie the bridge does not forward any link-local frames coming on
2724 this port).
2725
2726 .BR neigh_suppress " { " on " | " off " }"
2727 - controls whether neigh discovery (arp and nd) proxy and suppression
2728 is enabled on the port. By default this flag is off.
2729
2730 .BR neigh_vlan_suppress " { " on " | " off " }"
2731 - controls whether per-VLAN neigh discovery (arp and nd) proxy and suppression
2732 is enabled on the port. When on, the \fBbridge link\fR option
2733 \fBneigh_suppress\fR has no effect and the per-VLAN state is set using the
2734 \fBbridge vlan\fR option \fBneigh_suppress\fR. By default this flag is off.
2735
2736 .BR vlan_tunnel " { " on " | " off " }"
2737 - controls whether vlan to tunnel mapping is enabled on the port. By
2738 default this flag is off.
2739
2740 .BR locked " { " on " | " off " }"
2741 - controls whether a port is locked or not. When locked, non-link-local frames
2742 received through the port are dropped unless an FDB entry with the MAC source
2743 address points to the port. The common use case is IEEE 802.1X where hosts can
2744 authenticate themselves by exchanging EAPOL frames with an authenticator. After
2745 authentication is complete, the user space control plane can install a matching
2746 FDB entry to allow traffic from the host to be forwarded by the bridge. When
2747 learning is enabled on a locked port, the
2748 .B no_linklocal_learn
2749 bridge option needs to be on to prevent the bridge from learning from received
2750 EAPOL frames. By default this flag is off.
2751
2752 .BR mab " { " on " | " off " }"
2753 - controls whether MAC Authentication Bypass (MAB) is enabled on the port or
2754 not. MAB can only be enabled on a locked port that has learning enabled. When
2755 enabled, FDB entries are learned from received traffic and have the "locked"
2756 FDB flag set. The flag can only be set by the kernel and it indicates that the
2757 FDB entry cannot be used to authenticate the corresponding host. User space can
2758 decide to authenticate the host by replacing the FDB entry and clearing the
2759 "locked" FDB flag. Locked FDB entries can roam to unlocked (authorized) ports
2760 in which case the "locked" flag is cleared. FDB entries cannot roam to locked
2761 ports regardless of MAB being enabled or not. Therefore, locked FDB entries are
2762 only created if an FDB entry with the given {MAC, VID} does not already exist.
2763 This behavior prevents unauthenticated hosts from disrupting traffic destined
2764 to already authenticated hosts. Locked FDB entries act like regular dynamic
2765 entries with respect to forwarding and aging. By default this flag is off.
2766
2767 .BI backup_port " DEVICE"
2768 - if the port loses carrier all traffic will be redirected to the
2769 configured backup port
2770
2771 .BR nobackup_port
2772 - removes the currently configured backup port
2773
2774 .BI backup_nhid " NHID"
2775 - the FDB nexthop object ID (see \fBip-nexthop\fR(8)) to attach to packets
2776 being redirected to a backup port that has VLAN tunnel mapping enabled (via the
2777 \fBvlan_tunnel\fR option). Setting a value of 0 (default) has the effect of not
2778 attaching any ID.
2779
2780 .in -8
2781
2782 .TP
2783 Bonding Slave Support
2784 For a link with master
2785 .B bond
2786 the following additional arguments are supported:
2787
2788 .B "ip link set type bond_slave"
2789 [
2790 .BI queue_id " ID"
2791 ] [
2792 .BI prio " PRIORITY"
2793 ]
2794
2795 .in +8
2796 .sp
2797 .BI queue_id " ID"
2798 - set the slave's queue ID (a 16bit unsigned value).
2799
2800 .sp
2801 .BI prio " PRIORITY"
2802 - set the slave's priority for active slave re-selection during failover
2803 (a 32bit signed value). This option only valid for active-backup(1),
2804 balance-tlb (5) and balance-alb (6) mode.
2805
2806 .in -8
2807
2808 .TP
2809 MACVLAN and MACVTAP Support
2810 Modify list of allowed macaddr for link in source mode.
2811
2812 .B "ip link set type { macvlan | macvap } "
2813 [
2814 .BI macaddr " " "" COMMAND " " MACADDR " ..."
2815 ]
2816
2817 Commands:
2818 .in +8
2819 .B add
2820 - add MACADDR to allowed list
2821 .sp
2822 .B set
2823 - replace allowed list
2824 .sp
2825 .B del
2826 - remove MACADDR from allowed list
2827 .sp
2828 .B flush
2829 - flush whole allowed list
2830 .sp
2831 .in -8
2832
2833 Update the broadcast/multicast queue length.
2834
2835 .B "ip link set type { macvlan | macvap } "
2836 [
2837 .BI bcqueuelen " LENGTH "
2838 ]
2839 [
2840 .BI bclim " LIMIT "
2841 ]
2842
2843 .in +8
2844 .BI bcqueuelen " LENGTH "
2845 - Set the length of the RX queue used to process broadcast and multicast packets.
2846 .IR LENGTH " must be a positive integer in the range [0-4294967295]."
2847 Setting a length of 0 will effectively drop all broadcast/multicast traffic.
2848 If not specified the macvlan driver default (1000) is used.
2849 Note that all macvlans that share the same underlying device are using the same
2850 .RB "queue. The parameter here is a " request ", the actual queue length used"
2851 will be the maximum length that any macvlan interface has requested.
2852 When listing device parameters both the bcqueuelen parameter
2853 as well as the actual used bcqueuelen are listed to better help
2854 the user understand the setting.
2855
2856 .BI bclim " LIMIT "
2857 - Set the threshold for broadcast queueing.
2858 .IR LIMIT " must be a 32-bit integer."
2859 Setting this to -1 disables broadcast queueing altogether. Otherwise
2860 a multicast address will be queued as broadcast if the number of devices
2861 using it is greater than the given value.
2862 .in -8
2863
2864 .TP
2865 DSA user port support
2866 For a link having the DSA user port type, the following additional arguments
2867 are supported:
2868
2869 .B "ip link set type dsa "
2870 [
2871 .BI conduit " DEVICE"
2872 ]
2873
2874 .in +8
2875 .sp
2876 .BI conduit " DEVICE"
2877 - change the DSA conduit (host network interface) responsible for handling the
2878 locally terminated traffic for the given DSA switch user port. For a
2879 description of which network interfaces are suitable for serving as conduit
2880 interfaces of this user port, please see
2881 https://docs.kernel.org/networking/dsa/configuration.html#affinity-of-user-ports-to-cpu-ports
2882 as well as what is supported by the driver in use.
2883
2884 .sp
2885 .BI master " DEVICE"
2886 - this is a synonym for "conduit".
2887
2888 .in -8
2889
2890 .SS ip link show - display device attributes
2891
2892 .TP
2893 .BI dev " NAME " (default)
2894 .I NAME
2895 specifies the network device to show.
2896
2897 .TP
2898 .BI group " GROUP "
2899 .I GROUP
2900 specifies what group of devices to show.
2901
2902 .TP
2903 .B up
2904 only display running interfaces.
2905
2906 .TP
2907 .BI master " DEVICE "
2908 .I DEVICE
2909 specifies the master device which enslaves devices to show.
2910
2911 .TP
2912 .BI vrf " NAME "
2913 .I NAME
2914 specifies the VRF which enslaves devices to show.
2915
2916 .TP
2917 .BI type " TYPE "
2918 .I TYPE
2919 specifies the type of devices to show.
2920
2921 Note that the type name is not checked against the list of supported types -
2922 instead it is sent as-is to the kernel. Later it is used to filter the returned
2923 interface list by comparing it with the relevant attribute in case the kernel
2924 didn't filter already. Therefore any string is accepted, but may lead to empty
2925 output.
2926
2927 .TP
2928 .B nomaster
2929 only show devices with no master
2930
2931 .TP
2932 .B novf
2933 only show devices with no VF info
2934
2935 .SS ip link xstats - display extended statistics
2936
2937 .TP
2938 .BI type " TYPE "
2939 .I TYPE
2940 specifies the type of devices to display extended statistics for.
2941
2942 .SS ip link afstats - display address-family specific statistics
2943
2944 .TP
2945 .BI dev " DEVICE "
2946 .I DEVICE
2947 specifies the device to display address-family statistics for.
2948
2949 .SS ip link help - display help
2950
2951 .PP
2952 .I "TYPE"
2953 specifies which help of link type to display.
2954
2955 .SS
2956 .I GROUP
2957 may be a number or a string from
2958 .BR /usr/share/iproute2/group " or " /etc/iproute2/group
2959 which can be manually filled and has precedence if exists.
2960
2961 .SH "EXAMPLES"
2962 .PP
2963 ip link show
2964 .RS 4
2965 Shows the state of all network interfaces on the system.
2966 .RE
2967 .PP
2968 ip link show type bridge
2969 .RS 4
2970 Shows the bridge devices.
2971 .RE
2972 .PP
2973 ip link show type vlan
2974 .RS 4
2975 Shows the vlan devices.
2976 .RE
2977 .PP
2978 ip link show master br0
2979 .RS 4
2980 Shows devices enslaved by br0
2981 .RE
2982 .PP
2983 ip link set dev ppp0 mtu 1400
2984 .RS 4
2985 Change the MTU the ppp0 device.
2986 .RE
2987 .PP
2988 ip link add link eth0 name eth0.10 type vlan id 10
2989 .RS 4
2990 Creates a new vlan device eth0.10 on device eth0.
2991 .RE
2992 .PP
2993 ip link delete dev eth0.10
2994 .RS 4
2995 Removes vlan device.
2996 .RE
2997
2998 ip link help gre
2999 .RS 4
3000 Display help for the gre link type.
3001 .RE
3002 .PP
3003 ip link add name tun1 type ipip remote 192.168.1.1
3004 local 192.168.1.2 ttl 225 encap gue encap-sport auto
3005 encap-dport 5555 encap-csum encap-remcsum
3006 .RS 4
3007 Creates an IPIP that is encapsulated with Generic UDP Encapsulation,
3008 and the outer UDP checksum and remote checksum offload are enabled.
3009 .RE
3010 .PP
3011 ip link set dev eth0 xdp obj prog.o
3012 .RS 4
3013 Attaches a XDP/BPF program to device eth0, where the program is
3014 located in prog.o, section "prog" (default section). In case a
3015 XDP/BPF program is already attached, throw an error.
3016 .RE
3017 .PP
3018 ip -force link set dev eth0 xdp obj prog.o sec foo
3019 .RS 4
3020 Attaches a XDP/BPF program to device eth0, where the program is
3021 located in prog.o, section "foo". In case a XDP/BPF program is
3022 already attached, it will be overridden by the new one.
3023 .RE
3024 .PP
3025 ip -force link set dev eth0 xdp pinned /sys/fs/bpf/foo
3026 .RS 4
3027 Attaches a XDP/BPF program to device eth0, where the program was
3028 previously pinned as an object node into BPF file system under
3029 name foo.
3030 .RE
3031 .PP
3032 ip link set dev eth0 xdp off
3033 .RS 4
3034 If a XDP/BPF program is attached on device eth0, detach it and
3035 effectively turn off XDP for device eth0.
3036 .RE
3037 .PP
3038 ip link add link wpan0 lowpan0 type lowpan
3039 .RS 4
3040 Creates a 6LoWPAN interface named lowpan0 on the underlying
3041 IEEE 802.15.4 device wpan0.
3042 .RE
3043 .PP
3044 ip link add dev ip6erspan11 type ip6erspan seq key 102
3045 local fc00:100::2 remote fc00:100::1
3046 erspan_ver 2 erspan_dir ingress erspan_hwid 17
3047 .RS 4
3048 Creates a IP6ERSPAN version 2 interface named ip6erspan00.
3049 .RE
3050 .PP
3051 ip link set dev swp0 type dsa conduit eth1
3052 .RS 4
3053 Changes the conduit interface of the swp0 user port to eth1.
3054 .RE
3055
3056 .SH SEE ALSO
3057 .br
3058 .BR ip (8),
3059 .BR ip-netns (8),
3060 .BR ethtool (8),
3061 .BR iptables (8)
3062
3063 .SH AUTHOR
3064 Original Manpage by Michail Litvak <[email protected]>