⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 iftab.5

📁 wireless tools: used to manipulate the Wireless Extensions. The Wireless Extensions is an interface
💻 5
字号:
.\" Jean II - HPL - 2004-2007.\" iftab.5.\".TH IFTAB 5 "26 February 2007" "wireless-tools" "Linux Programmer's Manual".\".\" NAME part.\".SH NAMEiftab \- static information about the network interfaces.\".\" DESCRIPTION part.\".SH DESCRIPTIONThe file.B /etc/iftabcontains descriptive information about the various network interfaces..B iftabis only used by the program.IR ifrename (8)to assign a consistent network interface name to each network interface..PP.B /etc/iftabdefines a set of.IR mappings .Each mapping contains an interface name and a set of selectors. Theselectors allow.B ifrenameto identify each network interface on the system. If a networkinterface matches all descriptors of a mapping,.B ifrenameattempt to change the name of the interface to the interface namegiven by the mapping..\".\" MAPPINGS part.\".SH MAPPINGSEach mapping is described on a separate line, it starts with an.IR "interface name" ,and contains a set of.IR descriptors ,separated by space or tabs..PPThe relationship between descriptors of a mapping is a.IR "logical and" .A mapping matches a network interface only is all the descriptorsmatch. If a network interface doesn't support a specific descriptor,it won't match any mappings using this descriptor..PPIf you want to use alternate descriptors for an interface name(logical or), specify two different mappings with the same interfacename (one on each line)..B Ifrenamealways use the first matching mapping starting from the.I endof.BR iftab ,therefore more restrictive mapping should be specified last..\".\" INTERFACE NAME part.\".SH INTERFACE NAMEThe first part of each mapping is an interface name. If a networkinterface matches all descriptors of a mapping,.B ifrenameattempt to change the name of the interface to the interface namegiven by the mapping..PPThe interface name of a mapping is either a plain interface name (such as.IR eth2 " or " wlan1 )or a interface name pattern containing a single wildcard (such as.IR eth* " or " wlan* ).In case of wildcard, the kernel replace the '*' with the lowestavailable integer making this interface name unique. Note thatwildcard is only supported for kernel 2.6.1 and 2.4.30 and later..PPIt is discouraged to try to map interfaces to default interfaces namessuch as.IR eth0 ", " wlan0 " or " ppp0 .The kernel use those as the default name for any new interface,therefore most likely an interface will already use this name andprevent ifrename to use it. Even if you use takeover, the interfacemay already be up in some cases. Not using those name will allow youto immediately spot unconfigured or new interfaces..brGood names are either totally unique and meaningfull,such as.IR mydsl " or " privatehub ,or use larger integer, such as.IR eth5 " or " wlan5 .The second type is usually easier to integrate in various network utilities..\".\" DESCRIPTORS part.\".SH DESCRIPTORSEach descriptor is composed of a descriptor name and descriptorvalue. Descriptors specify a static attribute of a network interface,the goal is to uniquely identify each piece of hardware..PPMost users will only use the.B macselector despite its potential problems, other selectors are for morespecialised setup. Most selectors accept a '*' in the selector valuefor wilcard matching, and most selectors are case insensitive..TP.BI mac " mac address"Matches the MAC Address of the interface with the specified MACaddress. The MAC address of the interface can be shown using.IR ifconfig (8)or.IR ip (8)..brThis is the most common selector, as most interfaces have a unique MACaddress allowing to identify network interfaces without ambiguity.However, some interfaces don't have a valid MAC address until they arebrought up, in such case using this selector is tricky or impossible..TP.BI arp " arp type"Matches the ARP Type (also called Link Type) of the interface with thespecified ARP type as a number. The ARP Type of the interface can beshown using.IR ifconfig (8)or.IR ip (8),the.B link/ethertype correspond to.B 1and the.B link/ieee802.11type correspond to.BR 801 ..brThis selector is useful when a driver create multiple networkinterfaces for a single network card..TP.BI driver " driver name"Matches the Driver Name of the interface with the specified drivername. The Driver Name of the interface can be shown using.IR "ethtool -i" (8)..TP.BI businfo " bus information"Matches the Bus Information of the interface with the specified businformation. The Bus Information of the interface can be shown using.IR "ethtool -i" (8)..TP.BI firmware " firmware revision"Matches the Firmware Revision of the interface with the firmwarerevision information. The Firmware Revision of the interface can beshown using.IR "ethtool -i" (8)..TP.BI baseaddress " base address"Matches the Base Address of the interface with the specified baseaddress. The Base Address of the interface can be shown using.IR ifconfig (8)..brBecause most cards use dynamic allocation of the Base Address, thisselector is only useful for ISA and EISA cards..TP.BI irq " irq line"Matches the IRQ Line (interrupt) of the interface with the specifiedIRQ line. The IRQ Line of the interface can be shown using.IR ifconfig (8)..brBecause there are IRQ Lines may be shared, this selector is usuallynot sufficient to uniquely identify an interface..TP.BI iwproto " wireless protocol"Matches the Wireless Protocol of the interface with the specifiedwireless protocol. The Wireless Protocol of the interface can be shownusing.IR iwconfig (8)or.IR iwgetid (8)..brThis selector is only supported on wireless interfaces and is notsufficient to uniquely identify an interface..TP.BI pcmciaslot " pcmcia slot"Matches the Pcmcia Socket number of the interface with the specifiedslot number. Pcmcia Socket number of the interface can be shownusing.IR "cardctl ident" (8)..brThis selector is usually only supported on 16 bits cards, for 32 bitscards it is advised to use the selector.BR businfo ..TP.BI prevname " previous interface name"Matches the name of the interface prior to renaming with the specifiedoldname..brThis selector should be avoided as the previous interface name mayvary depending on various condition. A system/kernel/driver update maychange the original name. Then, ifrename or another tool may rename itprior to the execution of this selector..TP.BI SYSFS{ filename } " value"Matches the content the sysfs attribute given by filename to thespecified value. For symlinks and parents directories, match theactual directory name of the sysfs attribute given by filename to thespecified value..brA list of the most useful sysfs attributes is given in the nextsection..\".\" SYSFS DESCRIPTORS part.\".SH SYSFS DESCRIPTORSSysfs attributes for a specific interface are located on most systemsin the directory named after that interface at.IR /sys/class/net/ .Most sysfs attribute are files, and their values can be read using.IR cat "(1) or " more (1).It is also possible to match attributes in subdirectories..PPSome sysfs attributes are symlinks, pointing to another directory insysfs. If the attribute filename is a symlink the sysfs attributeresolves to the name of the directory pointed by the symlink using.IR readlink (1).The location is a directory in the sysfs tree is also important. Ifthe attribute filename ends with.IR /.. ,the sysfs attribute resolves to the real name of the parent directoryusing.IR pwd (1)..PPThe sysfs filesystem is only supported with 2.6.X kernel and need tobe mounted (usually in .IR /sys ).sysfs selectors are not as efficient as other selectors, thereforethey should be avoided for maximum performance..PPThese are common sysfs attributes and their corresponding ifrenamedescriptors..TP.BI SYSFS{address} " value"Same as the.B macdescriptor..TP.BI SYSFS{type} " value"Same as the.B arpdescriptor..TP.BI SYSFS{device} " value"Valid only up to kernel 2.6.20. Same as the.B businfodescriptor..TP.BI SYSFS{..} " value"Valid only from kernel 2.6.21. Same as the.B businfodescriptor..TP.BI SYSFS{device/driver} " value"Valid only up to kernel 2.6.20. Same as the.B driverdescriptor..TP.BI SYSFS{../driver} " value"Valid only from kernel 2.6.21. Same as the.B driverdescriptor..TP.BI SYSFS{device/irq} " value"Valid only up to kernel 2.6.20. Same as the.B irqdescriptor..TP.BI SYSFS{../irq} " value"Valid only from kernel 2.6.21. Same as the.B irqdescriptor..\".\" EXAMPLES part.\".SH EXAMPLES# This is a comment.breth2		mac 08:00:09:DE:82:0E.breth3		driver wavelan interrupt 15 baseaddress 0x390.breth4		driver pcnet32 businfo 0000:02:05.0.brair*		mac 00:07:0E:* arp 1.brmyvpn	SYSFS{address} 00:10:83:* SYSFS{type} 1.brbcm*		SYSFS{device} 0000:03:00.0 SYSFS{device/driver} bcm43xx.brbcm*		SYSFS{..} 0000:03:00.0 SYSFS{../driver} bcm43xx.\".\" AUTHOR part.\".SH AUTHORJean Tourrilhes \- jt@hpl.hp.com.\".\" FILES part.\".SH FILES.I /etc/iftab.\".\" SEE ALSO part.\".SH SEE ALSO.BR ifrename (8),.BR ifconfig (8),.BR ip (8),.BR ethtool (8),.BR iwconfig (8).

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -