0001 What: /sys/class/net/<iface>/name_assign_type
0002 Date: July 2014
0003 KernelVersion: 3.17
0004 Contact: netdev@vger.kernel.org
0005 Description:
0006 Indicates the name assignment type. Possible values are:
0007
0008 == ==========================================================
0009 1 enumerated by the kernel, possibly in an unpredictable way
0010 2 predictably named by the kernel
0011 3 named by userspace
0012 4 renamed
0013 == ==========================================================
0014
0015 What: /sys/class/net/<iface>/addr_assign_type
0016 Date: July 2010
0017 KernelVersion: 3.2
0018 Contact: netdev@vger.kernel.org
0019 Description:
0020 Indicates the address assignment type. Possible values are:
0021
0022 == =============================
0023 0 permanent address
0024 1 randomly generated
0025 2 stolen from another device
0026 3 set using dev_set_mac_address
0027 == =============================
0028
0029 What: /sys/class/net/<iface>/addr_len
0030 Date: April 2005
0031 KernelVersion: 2.6.12
0032 Contact: netdev@vger.kernel.org
0033 Description:
0034 Indicates the hardware address size in bytes.
0035 Values vary based on the lower-level protocol used by the
0036 interface (Ethernet, FDDI, ATM, IEEE 802.15.4...). See
0037 include/uapi/linux/if_*.h for actual values.
0038
0039 What: /sys/class/net/<iface>/address
0040 Date: April 2005
0041 KernelVersion: 2.6.12
0042 Contact: netdev@vger.kernel.org
0043 Description:
0044 Hardware address currently assigned to this interface.
0045 Format is a string, e.g: 00:11:22:33:44:55 for an Ethernet MAC
0046 address.
0047
0048 What: /sys/class/net/<bridge iface>/bridge/group_fwd_mask
0049 Date: January 2012
0050 KernelVersion: 3.2
0051 Contact: netdev@vger.kernel.org
0052 Description:
0053 Bitmask to allow forwarding of link local frames with address
0054 01-80-C2-00-00-0X on a bridge device. Only values that set bits
0055 not matching BR_GROUPFWD_RESTRICTED in net/bridge/br_private.h
0056 allowed.
0057 Default value 0 does not forward any link local frames.
0058
0059 Restricted bits:
0060
0061 == ========================================================
0062 0 01-80-C2-00-00-00 Bridge Group Address used for STP
0063 1 01-80-C2-00-00-01 (MAC Control) 802.3 used for MAC PAUSE
0064 2 01-80-C2-00-00-02 (Link Aggregation) 802.3ad
0065 == ========================================================
0066
0067 Any values not setting these bits can be used. Take special
0068 care when forwarding control frames e.g. 802.1X-PAE or LLDP.
0069
0070 What: /sys/class/net/<iface>/broadcast
0071 Date: April 2005
0072 KernelVersion: 2.6.12
0073 Contact: netdev@vger.kernel.org
0074 Description:
0075 Hardware broadcast address for this interface. Format is a
0076 string, e.g: ff:ff:ff:ff:ff:ff for an Ethernet broadcast MAC
0077 address.
0078
0079 What: /sys/class/net/<iface>/carrier
0080 Date: April 2005
0081 KernelVersion: 2.6.12
0082 Contact: netdev@vger.kernel.org
0083 Description:
0084 Indicates the current physical link state of the interface.
0085 Posssible values are:
0086
0087 == =====================
0088 0 physical link is down
0089 1 physical link is up
0090 == =====================
0091
0092 Note: some special devices, e.g: bonding and team drivers will
0093 allow this attribute to be written to force a link state for
0094 operating correctly and designating another fallback interface.
0095
0096 What: /sys/class/net/<iface>/dev_id
0097 Date: April 2008
0098 KernelVersion: 2.6.26
0099 Contact: netdev@vger.kernel.org
0100 Description:
0101 Indicates the device unique identifier. Format is an hexadecimal
0102 value. This is used to disambiguate interfaces which might be
0103 stacked (e.g: VLAN interfaces) but still have the same MAC
0104 address as their parent device.
0105
0106 What: /sys/class/net/<iface>/dev_port
0107 Date: February 2014
0108 KernelVersion: 3.15
0109 Contact: netdev@vger.kernel.org
0110 Description:
0111 Indicates the port number of this network device, formatted
0112 as a decimal value. Some NICs have multiple independent ports
0113 on the same PCI bus, device and function. This attribute allows
0114 userspace to distinguish the respective interfaces.
0115
0116 Note: some device drivers started to use 'dev_id' for this
0117 purpose since long before 3.15 and have not adopted the new
0118 attribute ever since. To query the port number, some tools look
0119 exclusively at 'dev_port', while others only consult 'dev_id'.
0120 If a network device has multiple client adapter ports as
0121 described in the previous paragraph and does not set this
0122 attribute to its port number, it's a kernel bug.
0123
0124 What: /sys/class/net/<iface>/dormant
0125 Date: March 2006
0126 KernelVersion: 2.6.17
0127 Contact: netdev@vger.kernel.org
0128 Description:
0129 Indicates whether the interface is in dormant state. Possible
0130 values are:
0131 0: interface is not dormant
0132 1: interface is dormant
0133
0134 This attribute can be used by supplicant software to signal that
0135 the device is not usable unless some supplicant-based
0136 authentication is performed (e.g: 802.1x). 'link_mode' attribute
0137 will also reflect the dormant state.
0138
0139 What: /sys/class/net/<iface>/testing
0140 Date: April 2002
0141 KernelVersion: 5.8
0142 Contact: netdev@vger.kernel.org
0143 Description:
0144 Indicates whether the interface is under test. Possible
0145 values are:
0146
0147 == =============================
0148 0 interface is not being tested
0149 1 interface is being tested
0150 == =============================
0151
0152 When an interface is under test, it cannot be expected
0153 to pass packets as normal.
0154
0155 What: /sys/class/net/<iface>/duplex
0156 Date: October 2009
0157 KernelVersion: 2.6.33
0158 Contact: netdev@vger.kernel.org
0159 Description:
0160 Indicates the interface latest or current duplex value. Possible
0161 values are:
0162
0163 ==== ===========
0164 half half duplex
0165 full full duplex
0166 ==== ===========
0167
0168 Note: This attribute is only valid for interfaces that implement
0169 the ethtool get_link_ksettings method (mostly Ethernet).
0170
0171 What: /sys/class/net/<iface>/flags
0172 Date: April 2005
0173 KernelVersion: 2.6.12
0174 Contact: netdev@vger.kernel.org
0175 Description:
0176 Indicates the interface flags as a bitmask in hexadecimal. See
0177 include/uapi/linux/if.h for a list of all possible values and
0178 the flags semantics.
0179
0180 What: /sys/class/net/<iface>/ifalias
0181 Date: September 2008
0182 KernelVersion: 2.6.28
0183 Contact: netdev@vger.kernel.org
0184 Description:
0185 Indicates/stores an interface alias name as a string. This can
0186 be used for system management purposes.
0187
0188 What: /sys/class/net/<iface>/ifindex
0189 Date: April 2005
0190 KernelVersion: 2.6.12
0191 Contact: netdev@vger.kernel.org
0192 Description:
0193 Indicates the system-wide interface unique index identifier as a
0194 decimal number. This attribute is used for mapping an interface
0195 identifier to an interface name. It is used throughout the
0196 networking stack for specifying the interface specific
0197 requests/events.
0198
0199 What: /sys/class/net/<iface>/iflink
0200 Date: April 2005
0201 KernelVersion: 2.6.12
0202 Contact: netdev@vger.kernel.org
0203 Description:
0204 Indicates the system-wide interface unique index identifier a
0205 the interface is linked to. Format is decimal. This attribute is
0206 used to resolve interfaces chaining, linking and stacking.
0207 Physical interfaces have the same 'ifindex' and 'iflink' values.
0208
0209 What: /sys/class/net/<iface>/link_mode
0210 Date: March 2006
0211 KernelVersion: 2.6.17
0212 Contact: netdev@vger.kernel.org
0213 Description:
0214 Indicates the interface link mode, as a decimal number. This
0215 attribute should be used in conjunction with 'dormant' attribute
0216 to determine the interface usability. Possible values:
0217
0218 == =================
0219 0 default link mode
0220 1 dormant link mode
0221 == =================
0222
0223 What: /sys/class/net/<iface>/mtu
0224 Date: April 2005
0225 KernelVersion: 2.6.12
0226 Contact: netdev@vger.kernel.org
0227 Description:
0228 Indicates the interface currently configured MTU value, in
0229 bytes, and in decimal format. Specific values depends on the
0230 lower-level interface protocol used. Ethernet devices will show
0231 a 'mtu' attribute value of 1500 unless changed.
0232
0233 What: /sys/class/net/<iface>/netdev_group
0234 Date: January 2011
0235 KernelVersion: 2.6.39
0236 Contact: netdev@vger.kernel.org
0237 Description:
0238 Indicates the interface network device group, as a decimal
0239 integer. Default value is 0 which corresponds to the initial
0240 network devices group. The group can be changed to affect
0241 routing decisions (see: net/ipv4/fib_rules and
0242 net/ipv6/fib6_rules.c).
0243
0244 What: /sys/class/net/<iface>/operstate
0245 Date: March 2006
0246 KernelVersion: 2.6.17
0247 Contact: netdev@vger.kernel.org
0248 Description:
0249 Indicates the interface RFC2863 operational state as a string.
0250
0251 Possible values are:
0252
0253 "unknown", "notpresent", "down", "lowerlayerdown", "testing",
0254 "dormant", "up".
0255
0256 What: /sys/class/net/<iface>/phys_port_id
0257 Date: July 2013
0258 KernelVersion: 3.12
0259 Contact: netdev@vger.kernel.org
0260 Description:
0261 Indicates the interface unique physical port identifier within
0262 the NIC, as a string.
0263
0264 What: /sys/class/net/<iface>/phys_port_name
0265 Date: March 2015
0266 KernelVersion: 4.0
0267 Contact: netdev@vger.kernel.org
0268 Description:
0269 Indicates the interface physical port name within the NIC,
0270 as a string.
0271
0272 What: /sys/class/net/<iface>/speed
0273 Date: October 2009
0274 KernelVersion: 2.6.33
0275 Contact: netdev@vger.kernel.org
0276 Description:
0277 Indicates the interface latest or current speed value. Value is
0278 an integer representing the link speed in Mbits/sec.
0279
0280 Note: this attribute is only valid for interfaces that implement
0281 the ethtool get_link_ksettings method (mostly Ethernet).
0282
0283 What: /sys/class/net/<iface>/tx_queue_len
0284 Date: April 2005
0285 KernelVersion: 2.6.12
0286 Contact: netdev@vger.kernel.org
0287 Description:
0288 Indicates the interface transmit queue len in number of packets,
0289 as an integer value. Value depend on the type of interface,
0290 Ethernet network adapters have a default value of 1000 unless
0291 configured otherwise
0292
0293 What: /sys/class/net/<iface>/type
0294 Date: April 2005
0295 KernelVersion: 2.6.12
0296 Contact: netdev@vger.kernel.org
0297 Description:
0298 Indicates the interface protocol type as a decimal value. See
0299 include/uapi/linux/if_arp.h for all possible values.
0300
0301 What: /sys/class/net/<iface>/phys_switch_id
0302 Date: November 2014
0303 KernelVersion: 3.19
0304 Contact: netdev@vger.kernel.org
0305 Description:
0306 Indicates the unique physical switch identifier of a switch this
0307 port belongs to, as a string.
0308
0309 What: /sys/class/net/<iface>/phydev
0310 Date: May 2017
0311 KernelVersion: 4.13
0312 Contact: netdev@vger.kernel.org
0313 Description:
0314 Symbolic link to the PHY device this network device is attached
0315 to.
0316
0317 What: /sys/class/net/<iface>/carrier_changes
0318 Date: Mar 2014
0319 KernelVersion: 3.15
0320 Contact: netdev@vger.kernel.org
0321 Description:
0322 32-bit unsigned integer counting the number of times the link has
0323 seen a change from UP to DOWN and vice versa
0324
0325 What: /sys/class/net/<iface>/carrier_up_count
0326 Date: Jan 2018
0327 KernelVersion: 4.16
0328 Contact: netdev@vger.kernel.org
0329 Description:
0330 32-bit unsigned integer counting the number of times the link has
0331 been up
0332
0333 What: /sys/class/net/<iface>/carrier_down_count
0334 Date: Jan 2018
0335 KernelVersion: 4.16
0336 Contact: netdev@vger.kernel.org
0337 Description:
0338 32-bit unsigned integer counting the number of times the link has
0339 been down
0340
0341 What: /sys/class/net/<iface>/threaded
0342 Date: Jan 2021
0343 KernelVersion: 5.12
0344 Contact: netdev@vger.kernel.org
0345 Description:
0346 Boolean value to control the threaded mode per device. User could
0347 set this value to enable/disable threaded mode for all napi
0348 belonging to this device, without the need to do device up/down.
0349
0350 Possible values:
0351 == ==================================
0352 0 threaded mode disabled for this dev
0353 1 threaded mode enabled for this dev
0354 == ==================================