https://wiki.archlinux.org/api.php?action=feedcontributions&user=LambToWolf&feedformat=atomArchWiki - User contributions [en]2024-03-29T04:42:07ZUser contributionsMediaWiki 1.41.0https://wiki.archlinux.org/index.php?title=Network_configuration/Wireless&diff=584407Network configuration/Wireless2019-10-04T17:38:05Z<p>LambToWolf: adding a title</p>
<hr />
<div>[[Category:Wireless networking]]<br />
[[Category:Network configuration]]<br />
[[cs:Wireless network configuration]]<br />
[[de:(W)LAN und Arch Linux]]<br />
[[el:Wireless network configuration]]<br />
[[es:Wireless network configuration]]<br />
[[fa:تنظیمات شبکه ی بی سیم]]<br />
[[fr:Wifi]]<br />
[[it:Wireless network configuration]]<br />
[[ja:ワイヤレス設定]]<br />
[[nl:Wireless network configuration]]<br />
[[pt:Wireless network configuration]]<br />
[[ru:Wireless network configuration]]<br />
[[th:Wireless network configuration]]<br />
[[zh-hans:Wireless network configuration]]<br />
{{Related articles start}}<br />
{{Related|Software access point}}<br />
{{Related|Ad-hoc networking}}<br />
{{Related|Internet sharing}}<br />
{{Related|Wireless bonding}}<br />
{{Related|Network Debugging}}<br />
{{Related|Bluetooth}}<br />
{{Related articles end}}<br />
{{Move|Network configuration/Wireless|Page depends on [[Network configuration]].|Talk:Network configuration#Moving Ethernet-specific sections to Wired subpage}}<br />
The main article on network configuration is [[Network configuration]].<br />
<br />
Configuring wireless is a two-part process; the first part is to identify and ensure the correct driver for your wireless device is installed (they are available on the installation media, but often have to be installed explicitly), and to configure the interface. The second is choosing a method of managing wireless connections. This article covers both parts, and provides additional links to wireless management tools.<br />
<br />
The [[#iw]] section describes how to manually manage your wireless network interface / your wireless LANs using {{Pkg|iw}}. The [[Network configuration#Network managers]] section describes several programs that can be used to automatically manage your wireless interface, some of which include a GUI and all of which include support for network profiles (useful when frequently switching wireless networks, like with laptops).<br />
<br />
== Device driver ==<br />
<br />
The default Arch Linux kernel is ''modular'', meaning many of the drivers for machine hardware reside on the hard drive and are available as [[Kernel modules|modules]]. At boot, [[udev]] takes an inventory of your hardware and loads appropriate modules (drivers) for your corresponding hardware, which will in turn allow creation of a network ''interface''.<br />
<br />
Some wireless chipsets also require firmware, in addition to a corresponding driver. Many firmware images are provided by the {{Pkg|linux-firmware}} package which is installed by default, however, proprietary firmware images are not included and have to be installed separately. This is described in [[#Installing driver/firmware]].<br />
<br />
{{Note|If the proper module is not loaded by udev on boot, simply [[Kernel modules#Manual module handling|load it manually]]. If udev loads more than one driver for a device, the resulting conflict may prevent successful configuration. Make sure to [[blacklist]] the unwanted module.}}<br />
<br />
=== Check the driver status ===<br />
<br />
To check if the driver for your card has been loaded, check the output of the {{ic|lspci -k}} or {{ic|lsusb -v}} command, depending on if the card is connected by PCI(e) or USB. You should see that some kernel driver is in use, for example:<br />
<br />
{{hc|$ lspci -k|<nowiki><br />
06:00.0 Network controller: Intel Corporation WiFi Link 5100<br />
Subsystem: Intel Corporation WiFi Link 5100 AGN<br />
Kernel driver in use: iwlwifi<br />
Kernel modules: iwlwifi<br />
</nowiki>}}<br />
<br />
{{Note|If the card is a USB device, running {{ic|dmesg {{!}} grep usbcore}} should give something like {{ic|usbcore: registered new interface driver rtl8187}} as output.}}<br />
<br />
Also check the output of the {{ic|ip link}} command to see if a wireless interface was created; usually the naming of the wireless [[network interfaces]] starts with the letter "w", e.g. {{ic|wlan0}} or {{ic|wlp2s0}}. Then bring the interface up with:<br />
<br />
# ip link set ''interface'' up<br />
<br />
For example, assuming the interface is {{ic|wlan0}}, this is {{ic|ip link set wlan0 up}}.<br />
<br />
If you get the error message {{ic|SIOCSIFFLAGS: No such file or directory}}, it most certainly means that your wireless chipset requires a firmware to function.<br />
<br />
Check kernel messages for firmware being loaded:<br />
<br />
{{hc|<nowiki>$ dmesg | grep firmware</nowiki>|<nowiki><br />
[ 7.148259] iwlwifi 0000:02:00.0: loaded firmware version 39.30.4.1 build 35138 op_mode iwldvm<br />
</nowiki>}}<br />
<br />
If there is no relevant output, check the messages for the full output for the module you identified earlier ({{ic|iwlwifi}} in this example) to identify the relevant message or further issues:<br />
<br />
{{hc|<nowiki>$ dmesg | grep iwlwifi</nowiki>|<nowiki><br />
[ 12.342694] iwlwifi 0000:02:00.0: irq 44 for MSI/MSI-X<br />
[ 12.353466] iwlwifi 0000:02:00.0: loaded firmware version 39.31.5.1 build 35138 op_mode iwldvm<br />
[ 12.430317] iwlwifi 0000:02:00.0: CONFIG_IWLWIFI_DEBUG disabled<br />
...<br />
[ 12.430341] iwlwifi 0000:02:00.0: Detected Intel(R) Corporation WiFi Link 5100 AGN, REV=0x6B<br />
</nowiki>}}<br />
<br />
If the kernel module is successfully loaded and the interface is up, you can skip the next section.<br />
<br />
=== Installing driver/firmware ===<br />
<br />
Check the following lists to discover if your card is supported:<br />
<br />
* See the table of [https://wireless.wiki.kernel.org/en/users/drivers existing Linux wireless drivers] and follow to the specific driver's page, which contains a list of supported devices. There is also a [https://wikidevi.com/wiki/List_of_Wi-Fi_Device_IDs_in_Linux List of Wi-Fi Device IDs in Linux].<br />
* The [https://help.ubuntu.com/community/WifiDocs/WirelessCardsSupported Ubuntu Wiki] has a good list of wireless cards and whether or not they are supported either in the Linux kernel or by a user-space driver (includes driver name).<br />
* [http://linux-wless.passys.nl/ Linux Wireless Support] and The Linux Questions' [http://www.linuxquestions.org/hcl/index.php?cat=10 Hardware Compatibility List] (HCL) also have a good database of kernel-friendly hardware.<br />
<br />
Note that some vendors ship products that may contain different chip sets, even if the product identifier is the same. Only the usb-id (for USB devices) or pci-id (for PCI devices) is authoritative.<br />
<br />
If your wireless card is listed above, follow the [[#Troubleshooting drivers and firmware]] subsection of this page, which contains information about installing drivers and firmware of some specific wireless cards. Then [[#Check the driver status|check the driver status]] again.<br />
<br />
If your wireless card is not listed above, it is likely supported only under Windows (some Broadcom, 3com, etc). For these, you can try to use [[#ndiswrapper]].<br />
<br />
== Utilities ==<br />
<br />
Just like other network interfaces, the wireless ones are controlled with ''ip'' from the {{Pkg|iproute2}} package.<br />
<br />
Managing a wireless connection requires a basic set of tools. Either use a [[network manager]] or use one of the following directly:<br />
<br />
{| class="wikitable"<br />
! Software !! Package !! [https://wireless.wiki.kernel.org/en/developers/documentation/wireless-extensions WEXT] !! [https://wireless.wiki.kernel.org/en/developers/documentation/nl80211 nl80211] !! WEP !! WPA/WPA2 !! [[Archiso]] [https://git.archlinux.org/archiso.git/tree/configs/releng/packages.x86_64]<br />
|-<br />
| [http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/Tools.html wireless_tools]<sup>1</sup> || {{pkg|wireless_tools}} || {{yes}} || {{no}} || {{Yes}} || {{No}} || {{Yes}}<br />
|-<br />
| [https://wireless.kernel.org/en/users/Documentation/iw iw] || {{Pkg|iw}} || {{No}} || {{Yes}} || {{Yes}} || {{No}} || {{Yes}}<br />
|-<br />
| [[WPA supplicant]] || {{Pkg|wpa_supplicant}} || {{Yes}} || {{Yes}} || {{Yes}} || {{Yes}} || {{Yes}}<br />
|-<br />
| [[iwd]] || {{Pkg|iwd}} || {{No}} || {{Yes}} || {{Yes}} || {{Yes}} || {{Yes}}<br />
|}<br />
<br />
# Deprecated.<br />
<br />
Note that some cards only support WEXT.<br />
<br />
=== iw and wireless_tools comparison ===<br />
<br />
The table below gives an overview of comparable commands for ''iw'' and ''wireless_tools''. See [http://wireless.kernel.org/en/users/Documentation/iw/replace-iwconfig iw replaces iwconfig] for more examples.<br />
<br />
{| class="wikitable"<br />
! ''iw'' command<br />
! ''wireless_tools'' command<br />
! Description<br />
|-<br />
| iw dev ''wlan0'' link<br />
| iwconfig ''wlan0''<br />
| Getting link status.<br />
|-<br />
| iw dev ''wlan0'' scan<br />
| iwlist ''wlan0'' scan<br />
| Scanning for available access points.<br />
|-<br />
| iw dev ''wlan0'' set type ibss<br />
| iwconfig ''wlan0'' mode ad-hoc<br />
| Setting the operation mode to ''ad-hoc''.<br />
|-<br />
| iw dev ''wlan0'' connect ''your_essid''<br />
| iwconfig ''wlan0'' essid ''your_essid''<br />
| Connecting to open network.<br />
|-<br />
| iw dev ''wlan0'' connect ''your_essid'' 2432<br />
| iwconfig ''wlan0'' essid ''your_essid'' freq 2432M<br />
| Connecting to open network specifying channel.<br />
|-<br />
| rowspan="2" | iw dev ''wlan0'' connect ''your_essid'' key 0:''your_key''<br />
| iwconfig ''wlan0'' essid ''your_essid'' key ''your_key''<br />
| Connecting to WEP encrypted network using hexadecimal key.<br />
|-<br />
| iwconfig ''wlan0'' essid ''your_essid'' key s:''your_key''<br />
| Connecting to WEP encrypted network using ASCII key.<br />
|-<br />
| iw dev ''wlan0'' set power_save on<br />
| iwconfig ''wlan0'' power on<br />
| Enabling power save.<br />
|}<br />
<br />
== iw ==<br />
<br />
{{Note|<br />
* Note that most of the commands have to be executed with [[Users and groups|root permissions]]. Executed with normal user rights, some of the commands (e.g. ''iw list''), will exit without error but not produce the correct output either, which can be confusing.<br />
* Depending on your hardware and encryption type, some of these steps may not be necessary. Some cards are known to require interface activation and/or access point scanning before being associated to an access point and being given an IP address. Some experimentation may be required. For instance, WPA/WPA2 users may try to directly activate their wireless network from step [[#Connect to an access point]].}}<br />
<br />
Examples in this section assume that your wireless device interface is {{ic|''interface''}} and that you are connecting to {{ic|''your_essid''}} wifi access point. Replace both accordingly.<br />
<br />
=== Get the name of the interface ===<br />
<br />
{{Tip|See [http://wireless.kernel.org/en/users/Documentation/iw official documentation] of the ''iw'' tool for more examples.}}<br />
<br />
To get the name of your wireless interface do:<br />
<br />
$ iw dev<br />
<br />
The name of the interface will be output after the word "Interface". For example, it is commonly {{ic|wlan0}}.<br />
<br />
=== Get the status of the interface ===<br />
<br />
To check link status, use following command.<br />
<br />
$ iw dev ''interface'' link<br />
<br />
You can get statistic information, such as the amount of tx/rx bytes, signal strength etc., with following command:<br />
<br />
$ iw dev ''interface'' station dump<br />
<br />
=== Activate the interface ===<br />
<br />
{{Tip|Usually this step is not required.}}<br />
<br />
Some cards require that the kernel interface be activated before you can use ''iw'' or ''wireless_tools'':<br />
<br />
# ip link set ''interface'' up<br />
<br />
{{Note|If you get errors like {{ic|RTNETLINK answers: Operation not possible due to RF-kill}}, make sure that hardware switch is ''on''. See [[#Rfkill caveat]] for details.}}<br />
<br />
To verify that the interface is up, inspect the output of the following command:<br />
<br />
{{hc|$ ip link show ''interface''|<br />
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state DOWN mode DORMANT group default qlen 1000<br />
link/ether 12:34:56:78:9a:bc brd ff:ff:ff:ff:ff:ff<br />
}}<br />
<br />
The {{ic|UP}} in {{ic|<BROADCAST,MULTICAST,UP,LOWER_UP>}} is what indicates the interface is up, not the later {{ic|state DOWN}}.<br />
<br />
=== Discover access points ===<br />
<br />
To see what access points are available:<br />
<br />
# iw dev ''interface'' scan | less<br />
<br />
{{Note|If it displays {{ic|Interface does not support scanning}}, then you probably forgot to install the firmware. In some cases this message is also displayed when not running ''iw'' as root.}}<br />
<br />
{{Tip|Depending on your location, you might need to set the correct [[#Respecting the regulatory domain|regulatory domain]] in order to see all available networks.}}<br />
<br />
The important points to check:<br />
* '''SSID:''' the name of the network.<br />
* '''Signal:''' is reported in a wireless power ratio in dBm (e.g. from -100 to 0). The closer the negative value gets to zero, the better the signal. Observing the reported power on a good quality link and a bad one should give an idea about the individual range. <br />
* '''Security:''' it is not reported directly, check the line starting with {{ic|capability}}. If there is {{ic|Privacy}}, for example {{ic|capability: ESS Privacy ShortSlotTime (0x0411)}}, then the network is protected somehow.<br />
** If you see an {{ic|RSN}} information block, then the network is protected by [[Wikipedia:IEEE 802.11i-2004|Robust Security Network]] protocol, also known as WPA2.<br />
** If you see an {{ic|WPA}} information block, then the network is protected by [[Wikipedia:Wi-Fi Protected Access|Wi-Fi Protected Access]] protocol.<br />
** In the {{ic|RSN}} and {{ic|WPA}} blocks you may find the following information:<br />
*** '''Group cipher:''' value in TKIP, CCMP, both, others.<br />
*** '''Pairwise ciphers:''' value in TKIP, CCMP, both, others. Not necessarily the same value than Group cipher.<br />
*** '''Authentication suites:''' value in PSK, 802.1x, others. For home router, you will usually find PSK (''i.e.'' passphrase). In universities, you are more likely to find 802.1x suite which requires login and password. Then you will need to know which key management is in use (e.g. EAP), and what encapsulation it uses (e.g. PEAP). See [[#WPA2 Enterprise]] and [[Wikipedia:Authentication protocol]] for details.<br />
** If you see neither {{ic|RSN}} nor {{ic|WPA}} blocks but there is {{ic|Privacy}}, then WEP is used.<br />
<br />
=== Set operating mode ===<br />
<br />
You might need to set the proper operating mode of the wireless card. More specifically, if you are going to connect an [[Ad-hoc networking|ad-hoc network]], you need to set the operating mode to {{ic|ibss}}:<br />
<br />
# iw dev ''interface'' set type ibss<br />
<br />
{{Note|Changing the operating mode on some cards might require the wireless interface to be ''down'' ({{ic|ip link set ''interface'' down}}).}}<br />
<br />
=== Connect to an access point ===<br />
<br />
Depending on the encryption, you need to associate your wireless device with the access point to use and pass the encryption key:<br />
<br />
* '''No encryption''' {{bc|# iw dev ''interface'' connect "''your_essid''"}}<br />
* '''WEP'''<br />
** using a hexadecimal or ASCII key (the format is distinguished automatically, because a WEP key has a fixed length): {{bc|# iw dev ''interface'' connect "''your_essid''" key 0:''your_key''}}<br />
** using a hexadecimal or ASCII key, specifying the third set up key as default (keys are counted from zero, four are possible): {{bc|# iw dev ''interface'' connect "''your_essid''" key d:2:''your_key''}}<br />
<br />
Regardless of the method used, you can check if you have associated successfully:<br />
<br />
# iw dev ''interface'' link<br />
<br />
== Wi-Fi Protected Access ==<br />
<br />
{{Expansion|Add [[Wikipedia:WPA3|WPA3]].}}<br />
<br />
=== WPA2 Personal ===<br />
<br />
WPA2 Personal, a.k.a. WPA2-PSK, is a mode of [[Wikipedia:Wi-Fi Protected_Access|Wi-Fi Protected Access]].<br />
<br />
You can authenticate to WPA2 Personal networks using [[WPA supplicant]] or [[iwd]], or connect using a [[network manager]]. If you only authenticated to the network, then to have a fully functional connection you will still need to assign the IP address(es) and routes either [[Network configuration#Static IP address|manually]] or using a [[DHCP]] client.<br />
<br />
{{Remove|Duplicates [[WPA supplicant]].}}<br />
<br />
The following method uses [[WPA supplicant]] to connect to a WPA2 Personal mode wireless router from the command line. It is particularly suitable for installing from the Arch linux ISO over wireless. All necessary commands are already included in the live session.<br />
<br />
First, encrypt the passphrase for your router:<br />
<br />
# wpa_passphrase ''my_essid'' ''my_passphrase'' > /etc/wpa_supplicant/''my_essid.conf''<br />
<br />
Before running wpa_supplicant in the background, test to make sure you get a connection:<br />
<br />
# wpa_supplicant -c /etc/wpa_supplicant/''my_essid.conf'' -i ''my_wireless_device''<br />
<br />
You might get some errors, but should see a "connected" message at the end. If so, <Ctrl>-c, and run wpa_supplicant in the background:<br />
<br />
# wpa_supplicant -B -c /etc/wpa_supplicant/''my_essid.conf'' -i ''my_wireless_device''<br />
<br />
You will still need to assign an IP address. If using DHCP:<br />
<br />
# dhclient ''my_wireless_device''<br />
<br />
That's it. Wireless networking should now be fully functional.<br />
<br />
=== WPA2 Enterprise ===<br />
<br />
''WPA2 Enterprise'' is a mode of [[Wikipedia:Wi-Fi_Protected_Access|Wi-Fi Protected Access]]. It provides better security and key management than ''WPA2 Personal'', and supports other enterprise-type functionality, such as VLANs and [[wikipedia:Network Access Protection|NAP]]. However, it requires an external authentication server, called [[wikipedia:RADIUS|RADIUS]] server to handle the authentication of users. This is in contrast to Personal mode which does not require anything beyond the wireless router or access points (APs), and uses a single passphrase or password for all users.<br />
<br />
The Enterprise mode enables users to log onto the Wi-Fi network with a username and password and/or a digital certificate. Since each user has a dynamic and unique encryption key, it also helps to prevent user-to-user snooping on the wireless network, and improves encryption strength.<br />
<br />
This section describes the configuration of [[List of applications#Network managers|network clients]] to connect to a wireless access point with WPA2 Enterprise mode. See [[Software access point#RADIUS]] for information on setting up an access point itself. <br />
<br />
{{Note|Enterprise mode requires a more complex client configuration, whereas Personal mode only requires entering a passphrase when prompted. Clients likely need to install the server’s CA certificate (plus per-user certificates if using EAP-TLS), and then manually configure the wireless security and 802.1X authentication settings.}}<br />
<br />
For a comparison of protocols see the following [http://deployingradius.com/documents/protocols/compatibility.html table].<br />
<br />
{{Warning|It is possible to use WPA2 Enterprise without the client checking the server CA certificate. However, you should always seek to do so, because without authenticating the access point the connection can be subject to a man-in-the-middle attack. This may happen because while the connection handshake itself may be encrypted, the most widely used setups transmit the password itself either in plain text or the easily breakable [[#MS-CHAPv2]]. Hence, the client might send the password to a malicious access point which then proxies the connection.}}<br />
<br />
==== eduroam ====<br />
<br />
[[Wikipedia:eduroam|eduroam]] is an international roaming service for users in research, higher education and further education, based on WPA2 Enterprise.<br />
<br />
{{Note|<br />
* Check connection details '''first''' with your institution before applying any profiles listed in this section. Example profiles are not guaranteed to work or match any security requirements.<br />
* When storing connection profiles unencrypted, it is recommended restrict read access to the root account by specifying {{ic|chmod 600 ''profile''}} as root.<br />
}}<br />
<br />
{{Tip|Configuration for [[NetworkManager]] and [[#wpa_supplicant]] can be generated with the [https://cat.eduroam.org/ eduroam Configuration Assistant Tool].}}<br />
<br />
==== Manual/automatic setup ====<br />
<br />
===== wpa_supplicant =====<br />
<br />
[[WPA supplicant#Advanced usage|WPA supplicant]] can be configured directly by its configuration file or using its CLI/GUI front ends and used in combination with a DHCP client. See the examples in {{ic|/usr/share/doc/wpa_supplicant/wpa_supplicant.conf}} for configuring the connection details.<br />
<br />
===== NetworkManager =====<br />
<br />
[[NetworkManager]] can generate WPA2 Enterprise profiles with [[NetworkManager#Front-ends|graphical front ends]]. ''nmcli'' and ''nmtui'' do not support this, but may use existing profiles.<br />
<br />
===== connman =====<br />
<br />
[[ConnMan]] needs a separate configuration file before [[ConnMan#Wi-Fi|connecting]] to the network. See {{man|5|connman-service.config}} and [[ConnMan#Connecting_to_eduroam_.28802.1X.29|Connman#Connecting to eduroam]] for details.<br />
<br />
===== netctl =====<br />
<br />
[[netctl]] supports [[#wpa_supplicant]] configuration through blocks included with {{ic|1=WPAConfigSection=}}. See {{man|5|netctl.profile}} for details.<br />
<br />
{{Warning|Special quoting rules apply: see the {{ic|''SPECIAL QUOTING RULES''}} section in {{man|5|netctl.profile}}.}}<br />
<br />
{{Tip|Custom certificates can be specified by adding the line {{ic|1='ca_cert="/path/to/special/certificate.cer"'}} in {{ic|WPAConfigSection}}.}}<br />
<br />
==== Troubleshooting ====<br />
<br />
===== MS-CHAPv2 =====<br />
<br />
WPA2-Enterprise wireless networks demanding MSCHAPv2 type-2 authentication with PEAP sometimes require {{Pkg|pptpclient}} in addition to the stock {{Pkg|ppp}} package. [[netctl]] seems to work out of the box without ppp-mppe, however. In either case, usage of MSCHAPv2 is discouraged as it is highly vulnerable, although using another method is usually not an option.<br />
<br />
== Tips and tricks ==<br />
<br />
=== Respecting the regulatory domain ===<br />
<br />
The [[wikipedia:IEEE_802.11#Regulatory_domains_and_legal_compliance|regulatory domain]], or "regdomain", is used to reconfigure wireless drivers to make sure that wireless hardware usage complies with local laws set by the FCC, ETSI and other organizations. Regdomains use [[wikipedia:ISO_3166-1_alpha-2|ISO 3166-1 alpha-2 country codes]]. For example, the regdomain of the United States would be "US", China would be "CN", etc.<br />
<br />
Regdomains affect the availability of wireless channels. In the 2.4GHz band, the allowed channels are 1-11 for the US, 1-14 for Japan, and 1-13 for most of the rest of the world. In the 5GHz band, the rules for allowed channels are much more complex. In either case, consult [[wikipedia:List_of_WLAN_channels|this list of WLAN channels]] for more detailed information.<br />
<br />
Regdomains also affect the limit on the [[wikipedia:Equivalent_isotropically_radiated_power|effective isotropic radiated power (EIRP)]] from wireless devices. This is derived from transmit power/"tx power", and is measured in [[wikipedia:DBm|dBm/mBm (1dBm=100mBm) or mW (log scale)]]. In the 2.4GHz band, the maximum is 30dBm in the US and Canada, 20dBm in most of Europe, and 20dB-30dBm for the rest of the world. In the 5GHz band, maximums are usually lower. Consult the [http://git.kernel.org/cgit/linux/kernel/git/linville/wireless-regdb.git/tree/db.txt wireless-regdb] for more detailed information (EIRP dBm values are in the second set of brackets for each line).<br />
<br />
Misconfiguring the regdomain can be useful - for example, by allowing use of an unused channel when other channels are crowded, or by allowing an increase in tx power to widen transmitter range. However, '''this is not recommended''' as it could break local laws and cause interference with other radio devices.<br />
<br />
To configure the regdomain, install {{Pkg|crda}} and reboot (to reload the {{ic|cfg80211}} module and all related drivers). Check the boot log to make sure that CRDA is being called by {{ic|cfg80211}}:<br />
<br />
$ dmesg | grep cfg80211<br />
<br />
The current regdomain can be set to the United States with:<br />
<br />
# iw reg set US<br />
<br />
And queried with:<br />
<br />
$ iw reg get<br />
<br />
{{Note|Your device may be set to country "00", which is the "world regulatory domain" and contains generic settings. If this cannot be unset, CRDA may be misconfigured.}}<br />
<br />
However, setting the regdomain may not alter your settings. Some devices have a regdomain set in firmware/EEPROM, which dictates the limits of the device, meaning that setting regdomain in software [http://wiki.openwrt.org/doc/howto/wireless.utilities#iw can only increase restrictions], not decrease them. For example, a CN device could be set in software to the US regdomain, but because CN has an EIRP maximum of 20dBm, the device will not be able to transmit at the US maximum of 30dBm.<br />
<br />
For example, to see if the regdomain is being set in firmware for an Atheros device:<br />
<br />
$ dmesg | grep ath:<br />
<br />
For other chipsets, it may help to search for "EEPROM", "regdomain", or simply the name of the device driver.<br />
<br />
To see if your regdomain change has been successful, and to query the number of available channels and their allowed transmit power:<br />
<br />
$ iw list | grep -A 15 Frequencies:<br />
<br />
A more permanent configuration of the regdomain can be achieved through editing {{ic|/etc/conf.d/wireless-regdom}} and uncommenting the appropriate domain.<br />
<br />
[[WPA supplicant]] can also use a regdomain in the {{ic|1=country=}} line of {{ic|/etc/wpa_supplicant/wpa_supplicant.conf}}.<br />
<br />
It is also possible to configure the [http://wireless.kernel.org/en/developers/Documentation/cfg80211 cfg80211] kernel module to use a specific regdomain by adding, for example, {{ic|1=options cfg80211 ieee80211_regdom=EU}} as [[Kernel_modules#Setting module options|module options]]. However, this is part of the [http://wireless.kernel.org/en/developers/Regulatory#The_ieee80211_regdom_module_parameter old regulatory implementation].<br />
<br />
For further information, read the [http://wireless.kernel.org/en/developers/Regulatory/ wireless.kernel.org regulatory documentation].<br />
<br />
== Troubleshooting ==<br />
<br />
This section contains general troubleshooting tips, not strictly related to problems with drivers or firmware. For such topics, see next section [[#Troubleshooting drivers and firmware]].<br />
<br />
=== Temporary internet access ===<br />
<br />
If you have problematic hardware and need internet access to, for example, download some software or get help in forums, you can make use of Android's built-in feature for internet sharing via USB cable. See [[Android tethering#USB tethering]] for more information.<br />
<br />
=== Rfkill caveat ===<br />
<br />
Many laptops have a hardware button (or switch) to turn off wireless card, however, the card can also be blocked by kernel. This can be handled by ''rfkill''. To show the current status:<br />
<br />
{{hc|# rfkill list|<br />
0: phy0: Wireless LAN<br />
Soft blocked: yes<br />
Hard blocked: yes<br />
}}<br />
<br />
If the card is ''hard-blocked'', use the hardware button (switch) to unblock it. If the card is not ''hard-blocked'' but ''soft-blocked'', use the following command:<br />
<br />
# rfkill unblock wifi<br />
<br />
{{Note|It is possible that the card will go from ''hard-blocked'' and ''soft-unblocked'' state into ''hard-unblocked'' and ''soft-blocked'' state by pressing the hardware button (i.e. the ''soft-blocked'' bit is just switched no matter what). This can be adjusted by tuning some options of the {{ic|rfkill}} [[kernel module]].}}<br />
<br />
Hardware buttons to toggle wireless cards are handled by a vendor specific [[kernel module]], frequently these are [https://lwn.net/Articles/391230/ WMI] modules. Particularly for very new hardware models, it happens that the model is not fully supported in the latest stable kernel yet. In this case it often helps to search the kernel bug tracker for information and report the model to the maintainer of the respective vendor kernel module, if it has not happened already. <br />
<br />
See also [http://askubuntu.com/questions/62166/siocsifflags-operation-not-possible-due-to-rf-kill].<br />
<br />
=== Observing Logs ===<br />
<br />
A good first measure to troubleshoot is to analyze the system's logfiles first. In order not to manually parse through them all, it can help to open a second terminal/console window and watch the kernels messages with <br />
$ dmesg -w<br />
while performing the action, e.g. the wireless association attempt. <br />
<br />
When using a tool for network management, the same can be done for systemd with <br />
# journalctl -f <br />
<br />
Frequently a wireless error is accompanied by a deauthentication with a particular reason code, for example: <br />
wlan0: deauthenticating from XX:XX:XX:XX:XX:XX by local choice (reason=3)<br />
<br />
Looking up [http://www.aboutcher.co.uk/2012/07/linux-wifi-deauthenticated-reason-codes/ the reason code] might give a first hint. Maybe it also helps you to look at the control message [https://wireless.wiki.kernel.org/en/developers/documentation/mac80211/auth-assoc-deauth flowchart], the journal messages will follow it. <br />
<br />
The individual tools used in this article further provide options for more detailed debugging output, which can be used in a second step of the analysis, if required.<br />
<br />
=== Power saving ===<br />
<br />
See [[Power saving#Network interfaces]].<br />
<br />
=== Failed to get IP address ===<br />
<br />
* If getting an IP address repeatedly fails using the default {{Pkg|dhcpcd}} client, try installing and using {{Pkg|dhclient}} instead. Do not forget to select ''dhclient'' as the primary DHCP client in the [[#Manual/automatic setup|connection manager]].<br />
<br />
* If you can get an IP address for a wired interface and not for a wireless interface, try disabling the wireless card's [[#Power saving|power saving]] features (specify {{ic|off}} instead of {{ic|on}}).<br />
<br />
* If you get a timeout error due to a ''waiting for carrier'' problem, then you might have to set the channel mode to {{ic|auto}} for the specific device:<br />
<br />
# iwconfig wlan0 channel auto<br />
<br />
Before changing the channel to auto, make sure your wireless interface is down. After it has successfully changed it, you can bring the interface up again and continue from there.<br />
<br />
=== Valid IP address but cannot resolve host ===<br />
<br />
If you are on a public wireless network that may have a [[wikipedia:Captive_portal|captive portal]], make sure to query an HTTP page (not an HTTPS page) from your web browser, as some captive portals only redirect HTTP.<br />
If this is not the issue, [[check if you can resolve domain names]], it may be necessary to use the DNS server advertised via DHCP.<br />
<br />
=== Setting RTS and fragmentation thresholds ===<br />
<br />
Wireless hardware disables RTS and fragmentation by default. These are two different methods of increasing throughput at the expense of bandwidth (i.e. reliability at the expense of speed). These are useful in environments with wireless noise or many adjacent access points, which may create interference leading to timeouts or failing connections. <br />
<br />
Packet fragmentation improves throughput by splitting up packets with size exceeding the fragmentation threshold. The maximum value (2346) effectively disables fragmentation since no packet can exceed it. The minimum value (256) maximizes throughput, but may carry a significant bandwidth cost.<br />
<br />
# iw phy0 set frag 512<br />
<br />
[[Wikipedia:IEEE 802.11 RTS/CTS|RTS]] improves throughput by performing a handshake with the access point before transmitting packets with size exceeding the RTS threshold. The maximum threshold (2347) effectively disables RTS since no packet can exceed it. The minimum threshold (0) enables RTS for all packets, which is probably excessive for most situations.<br />
<br />
# iw phy0 set rts 500<br />
<br />
{{Note|{{ic|phy0}} is the name of the wireless device as listed by {{ic|$ iw phy}}.}}<br />
<br />
=== Random disconnections ===<br />
<br />
==== Cause #1 ====<br />
<br />
If dmesg says {{ic|1=wlan0: deauthenticating from MAC by local choice (reason=3)}} and you lose your Wi-Fi connection, it is likely that you have a bit too aggressive power-saving on your Wi-Fi card. Try disabling the wireless card's [[#Power saving|power saving]] features (specify {{ic|off}} instead of {{ic|on}}).<br />
<br />
If your card does not support enabling/disabling power save mode, check the BIOS for power management options. Disabling PCI-Express power management in the BIOS of a Lenovo W520 resolved this issue.<br />
<br />
==== Cause #2 ====<br />
<br />
If you are experiencing frequent disconnections and dmesg shows messages such as <br />
<br />
{{ic|1=ieee80211 phy0: wlan0: No probe response from AP xx:xx:xx:xx:xx:xx after 500ms, disconnecting}}<br />
<br />
try changing the channel bandwidth to {{ic|20MHz}} through your router's settings page.<br />
<br />
==== Cause #3 ====<br />
<br />
On some laptop models with hardware rfkill switches (e.g., Thinkpad X200 series), due to wear or bad design, the switch (or its connection to the mainboard) might become loose over time resulting in seemingly random hardblocks/disconnects when you accidentally touch the switch or move the laptop.<br />
There is no software solution to this, unless your switch is electrical and the BIOS offers the option to disable the switch.<br />
If your switch is mechanical (most are), there are lots of possible solutions, most of which aim to disable the switch: Soldering the contact point on the mainboard/wifi-card, glueing or blocking the switch, using a screw nut to tighten the switch or removing it altogether.<br />
<br />
==== Cause #4 ====<br />
<br />
Another cause for frequent disconnects or a complete failure to connect may also be a sub-standard router, incomplete settings of the router, or interference by other wireless devices. <br />
<br />
To troubleshoot, first best try to connect to the router with no authentication. <br />
<br />
If that works, enable WPA/WPA2 again but choose fixed and/or limited router settings. For example: <br />
* If the router is considerably older than the wireless device you use for the client, test if it works with setting the router to one wireless mode <br />
* Disable mixed-mode authentication (e.g. only WPA2 with AES, or TKIP if the router is old) <br />
* Try a fixed/free channel rather than "auto" channel (maybe the router next door is old and interfering) <br />
* Disable [[Wikipedia:Wi-Fi Protected Setup|WPS]]<br />
* Disable {{ic|40MHz}} channel bandwidth (lower throughput but less likely collisions) <br />
* If the router has quality of service settings, check completeness of settings (e.g. Wi-Fi Multimedia (WMM) is part of optional QoS flow control. An erroneous router firmware may advertise its existence although the setting is not enabled)<br />
<br />
=== Wi-Fi networks invisible because of incorrect regulatory domain===<br />
<br />
If the computer's Wi-Fi channels do not match those of the user's country, that may result in some in-range Wi-Fi networks becoming invisible, because they use wireless channels that aren't allowed by default. The solution is to configure the regulatory domain correctly, see [[#Respecting the regulatory domain]].<br />
<br />
== Troubleshooting drivers and firmware ==<br />
<br />
This section covers methods and procedures for installing kernel modules and ''firmware'' for specific chipsets, that differ from generic method.<br />
<br />
See [[Kernel modules]] for general information on operations with modules.<br />
<br />
=== Ralink/Mediatek ===<br />
<br />
==== rt2x00 ====<br />
<br />
Unified driver for Ralink chipsets (it replaces {{ic|rt2500}}, {{ic|rt61}}, {{ic|rt73}}, etc). This driver has been in the Linux kernel since 2.6.24, you only need to load the right module for the chip: {{ic|rt2400pci}}, {{ic|rt2500pci}}, {{ic|rt2500usb}}, {{ic|rt61pci}} or {{ic|rt73usb}} which will autoload the respective {{ic|rt2x00}} modules too.<br />
<br />
A list of devices supported by the modules is available at the project's [https://web.archive.org/web/20150507023412/http://rt2x00.serialmonkey.com/wiki/index.php/Hardware homepage].<br />
<br />
; Additional notes<br />
* Since kernel 3.0, rt2x00 includes also these drivers: {{ic|rt2800pci}}, {{ic|rt2800usb}}.<br />
* Since kernel 3.0, the staging drivers {{ic|rt2860sta}} and {{ic|rt2870sta}} are replaced by the mainline drivers {{ic|rt2800pci}} and {{ic|rt2800usb}}<sup>[https://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=fefecc6989b4b24276797270c0e229c07be02ad3]</sup>.<br />
* Some devices have a wide range of options that can be configured with {{ic|iwpriv}}. These are documented in the [http://web.ralinktech.com/ralink/Home/Support/Linux.html source tarballs]{{Dead link|2018|08|15}} available from Ralink.<br />
<br />
==== rt3090 ====<br />
<br />
For devices which are using the rt3090 chipset it should be possible to use {{ic|rt2800pci}} driver, however, is not working with this chipset very well (e.g. sometimes it is not possible to use higher rate than 2Mb/s).<br />
<br />
==== rt3290 ====<br />
<br />
The rt3290 chipset is recognised by the kernel {{ic|rt2800pci}} module. However, some users experience problems and reverting to a patched Ralink driver seems to be beneficial in these [https://bbs.archlinux.org/viewtopic.php?id=161952 cases].<br />
<br />
==== rt3573 ====<br />
<br />
New chipset as of 2012. It may require proprietary drivers from Ralink. Different manufacturers use it, see the [https://bbs.archlinux.org/viewtopic.php?pid=1164228#p1164228 Belkin N750 DB wireless usb adapter] forums thread.<br />
<br />
==== rt5572 ====<br />
<br />
New chipset as of 2012 with support for 5 Ghz bands. It may require proprietary drivers from Ralink and some effort to compile them. At the time of writing a how-to on compilation is available for a DLINK DWA-160 rev. B2 [http://bernaerts.dyndns.org/linux/229-ubuntu-precise-dlink-dwa160-revb2 here].<br />
<br />
==== mt7612u ====<br />
<br />
New chipset as of 2014, released under their new commercial name Mediatek. It is an AC1200 or AC1300 chipset. Manufacturer provides drivers for Linux on their [https://www.mediatek.com/products/broadbandWifi/mt7612u support page]<br />
<br />
=== Realtek ===<br />
<br />
See [https://wikidevi.com/wiki/Realtek] for a list of Realtek chipsets and specifications.<br />
<br />
==== rtl8192cu ====<br />
<br />
The driver is now in the kernel, but many users have reported being unable to make a connection although scanning for networks does work.<br />
<br />
{{AUR|8192cu-dkms}} includes many patches, try this if it does not work fine with the driver in kernel.<br />
<br />
==== rtl8723ae/rtl8723be ====<br />
<br />
The {{ic|rtl8723ae}} and {{ic|rtl8723be}} modules are included in the mainline Linux kernel.<br />
<br />
Some users may encounter errors with powersave on this card. This is shown with occasional disconnects that are not recognized by high level network managers ([[netctl]], [[NetworkManager]]). This error can be confirmed by running {{ic|dmesg -w}} or {{ic|journalctl -f}} and looking for output related to powersave and the {{ic|rtl8723ae}}/{{ic|rtl8723be}} module. If you are having this issue, use the {{ic|1=fwlps=0}} kernel option, which should prevent the WiFi card from automatically sleeping and halting connection.<br />
<br />
{{hc|/etc/modprobe.d/rtl8723ae.conf|2=<br />
options rtl8723ae fwlps=0<br />
}}<br />
or<br />
{{hc|/etc/modprobe.d/rtl8723be.conf|2=<br />
options rtl8723be fwlps=0<br />
}}<br />
<br />
If you have poor signal, perhaps your device has only one physical antenna connected, and antenna autoselection is broken. You can force the choice of antenna with {{ic|1=ant_sel=1}} or {{ic|1=ant_sel=2}} kernel option. [https://bbs.archlinux.org/viewtopic.php?id=208472]<br />
<br />
==== rtl88xxau ====<br />
<br />
Realtek chipsets rtl8811au/rtl8812au/rtl8814au/rtl8821au designed for various USB adapters ranging from AC600 to AC1900.<br />
<br />
Several packages provide various kernel drivers:<br />
<br />
{| class="wikitable"<br />
! Chipset || Driver version || Package || Notes<br />
|-<br />
| rtl8811au, rtl8812au, rtl8814au and rtl8821au || 5.6.4.1 || {{AUR|rtl88xxau-aircrack-dkms-git}} || Aircrack-ng kernel module for 8811au, 8812au, 8814au and 8821au chipsets with monitor mode and injection support.<br />
|-<br />
| rtl8812au || 5.2.20 || {{AUR|rtl8812au-dkms-git}} || Latest official Realtek driver version for rtl8812au ''only''.<br />
|-<br />
| rtl8811au, rtl8812au and rtl8821au || 5.1.5 || {{AUR|rtl8821au-dkms-git}} || For rtl8812au versions 5.6.4.1 or 5.2.20 are recommended instead.<br />
|-<br />
| rtl8814au || 4.3.21 || {{AUR|rtl8814au-dkms-git}} || Possibly works for rtl8813au too. Reportedly has better performance than {{AUR|rtl88xxau-aircrack-dkms-git}}<br />
|}<br />
<br />
These require [[DKMS]] so make sure you have your proper kernel headers installed.<br />
<br />
==== rtl8822bu ====<br />
<br />
{{AUR|rtl8822bu-dkms-git}} provides a kernel module for the Realtek 8822bu chipset found in the Edimax EW7822ULC USB3 and Asus AC53 Nano USB 802.11ac adapter.<br />
<br />
This requires [[DKMS]], so make sure you have your proper kernel headers installed.<br />
<br />
==== rtl8xxxu ====<br />
<br />
{{Expansion|Specific issues with the mainline module and kernel versions should be stated.}}<br />
<br />
Issues with the {{ic|rtl8xxxu}} mainline kernel module may be solved by compiling a third-party module for the specific chipset. The source code can be found in [https://github.com/lwfinger?tab=repositories GitHub repositories].<br />
<br />
Some drivers may be already prepared in the AUR, e.g. {{AUR|rtl8723bu-git}} and {{AUR|rtl8723bu-git-dkms}}.<br />
<br />
=== Atheros ===<br />
<br />
The [http://madwifi-project.org/ MadWifi team] currently maintains three different drivers for devices with Atheros chipset:<br />
<br />
* {{ic|madwifi}} is an old, obsolete driver. Not present in Arch kernel since 2.6.39.1<sup>[https://mailman.archlinux.org/pipermail/arch-dev-public/2011-June/020669.html]</sup>.<br />
* {{ic|ath5k}} is newer driver, which replaces the {{ic|madwifi}} driver. Currently a better choice for some chipsets, but not all chipsets are supported (see below)<br />
* {{ic|ath9k}} is the newest of these three drivers, it is intended for newer Atheros chipsets. All of the chips with 802.11n capabilities are supported.<br />
<br />
There are some other drivers for some Atheros devices. See [http://wireless.kernel.org/en/users/Drivers/Atheros#PCI_.2F_PCI-E_.2F_AHB_Drivers Linux Wireless documentation] for details.<br />
<br />
==== ath5k ====<br />
<br />
External resources:<br />
* http://wireless.kernel.org/en/users/Drivers/ath5k<br />
* http://wiki.debian.org/ath5k<br />
<br />
If you find web pages randomly loading very slow, or if the device is unable to lease an IP address, try to switch from hardware to software encryption by loading the {{ic|ath5k}} module with {{ic|1=nohwcrypt=1}} option. See [[Kernel modules#Setting module options]] for details.<br />
<br />
Some laptops may have problems with their wireless LED indicator flickering red and blue. To solve this problem, do:<br />
<br />
# echo none > /sys/class/leds/ath5k-phy0::tx/trigger<br />
# echo none > /sys/class/leds/ath5k-phy0::rx/trigger<br />
<br />
For alternatives, see [https://bugzilla.redhat.com/show_bug.cgi?id=618232 this bug report].<br />
<br />
==== ath9k ====<br />
<br />
External resources:<br />
* http://wireless.kernel.org/en/users/Drivers/ath9k<br />
* http://wiki.debian.org/ath9k<br />
<br />
As of Linux 3.15.1, some users have been experiencing a decrease in bandwidth. In some cases this can fixed by editing {{ic|/etc/modprobe.d/ath9k.conf}} and adding the line:<br />
options ath9k nohwcrypt=1<br />
<br />
{{Note|Check with the command lsmod what module(-name) is in use and change it if named otherwise (e.g. ath9k_htc).}}<br />
<br />
In the unlikely event that you have stability issues that trouble you, you could try using the {{AUR|backports-patched}} package. An [https://lists.ath9k.org/mailman/listinfo/ath9k-devel ath9k mailing list] exists for support and development related discussions.<br />
<br />
===== Power saving =====<br />
<br />
Although [http://wireless.kernel.org/en/users/Documentation/dynamic-power-save Linux Wireless] says that dynamic power saving is enabled for Atheros ath9k single-chips newer than AR9280, for some devices (e.g. AR9285) {{Pkg|powertop}} might still report that power saving is disabled. In this case enable it manually.<br />
<br />
On some devices (e.g. AR9285), enabling the power saving might result in the following error:<br />
<br />
{{hc|# iw dev wlan0 set power_save on|<br />
command failed: Operation not supported (-95)<br />
}}<br />
<br />
The solution is to set the {{ic|1=ps_enable=1}} option for the {{ic|ath9k}} module:<br />
<br />
{{hc|/etc/modprobe.d/ath9k.conf|2=<br />
options ath9k ps_enable=1<br />
}}<br />
<br />
=== Intel ===<br />
<br />
==== ipw2100 and ipw2200 ====<br />
<br />
These modules are fully supported in the kernel, but they require additional firmware. Depending on which of the chipsets you have, [[install]] either {{Pkg|ipw2100-fw}} or {{Pkg|ipw2200-fw}}. Then [[Kernel modules#Manual module handling|reload]] the appropriate module.<br />
<br />
{{Tip|You may use the following [[Kernel modules#Setting module options|module options]]:<br />
* use the {{ic|1=rtap_iface=1}} option to enable the radiotap interface<br />
* use the {{ic|1=led=1}} option to enable a front LED indicating when the wireless is connected or not<br />
}}<br />
<br />
==== iwlegacy ====<br />
<br />
[http://wireless.kernel.org/en/users/Drivers/iwlegacy iwlegacy] is the wireless driver for Intel's 3945 and 4965 wireless chips. The firmware is included in the {{Pkg|linux-firmware}} package.<br />
<br />
[[udev]] should load the driver automatically, otherwise load {{ic|iwl3945}} or {{ic|iwl4965}} manually. See [[Kernel modules]] for details.<br />
<br />
If you have problems connecting to networks in general, random failures with your card on bootup or your link quality is very poor, try to disable 802.11n:<br />
<br />
{{hc|/etc/modprobe.d/iwl4965.conf|2=<br />
options iwl4965 11n_disable=1<br />
}}<br />
<br />
If the failures persist during bootup and you are using Nouveau driver, try [[Nouveau#Enable_early_KMS|enabling early KMS]] to prevent the conflict [https://bbs.archlinux.org/viewtopic.php?pid=1748667#p1748667].<br />
<br />
==== iwlwifi ====<br />
<br />
[http://wireless.kernel.org/en/users/Drivers/iwlwifi iwlwifi] is the wireless driver for Intel's current wireless chips, such as 5100AGN, 5300AGN, and 5350AGN. See the [http://wireless.kernel.org/en/users/Drivers/iwlwifi#Supported_Devices full list of supported devices]. The firmware is included in the {{Pkg|linux-firmware}} package. The {{Aur|linux-firmware-iwlwifi-git}} may contain some updates sooner.<br />
<br />
If you have problems connecting to networks in general or your link quality is very poor, try to disable 802.11n, and perhaps also enable software encryption:<br />
<br />
{{hc|/etc/modprobe.d/iwlwifi.conf|2=<br />
options iwlwifi 11n_disable=1 swcrypto=1<br />
}}<br />
<br />
If you have a problem with slow uplink speed in 802.11n mode, for example 20Mbps, try to enable antenna aggregation:<br />
<br />
{{hc|/etc/modprobe.d/iwlwifi.conf|2=<br />
options iwlwifi 11n_disable=8<br />
}}<br />
<br />
Do not be confused with the optiIOon name, when the value is set to {{ic|8}} it does not disable anything but re-enables transmission antenna aggregation.[http://forums.gentoo.org/viewtopic-t-996692.html?sid=81bdfa435c089360bdfd9368fe0339a9] [https://bugzilla.kernel.org/show_bug.cgi?id=81571]<br />
<br />
In case this does not work for you, you may try disabling [[Power saving#Network interfaces|power saving]] for your wireless adapter.<br />
<br />
[http://ubuntuforums.org/showthread.php?t=2183486&p=12845473#post12845473 Some] have never gotten this to work. [http://ubuntuforums.org/showthread.php?t=2205733&p=12935783#post12935783 Others] found salvation by disabling N in their router settings after trying everything. This is known to have be the only solution on more than one occasion. The second link there mentions a 5ghz option that might be worth exploring.<br />
<br />
===== Firmware stack traces =====<br />
You may have some issue where the driver outputs stack traces & errors, which can cause some stuttering.<br />
{{hc|dmesg|2=<br />
Microcode SW error detected. Restarting 0x2000000.<br />
}}<br />
To fix those errors, you may downgrade the package {{Pkg|linux-firmware}} or rename the last version of the firmware used by your device so that an older version is loaded (which keeps it out of pacman's ignored packages).<br />
<br />
===== Bluetooth coexistence =====<br />
<br />
If you have difficulty connecting a bluetooth headset and maintaining good downlink speed, try disabling bluetooth coexistence [https://wireless.wiki.kernel.org/en/users/Drivers/iwlwifi#wifibluetooth_coexistence]:<br />
<br />
{{hc|/etc/modprobe.d/iwlwifi.conf|2=<br />
options iwlwifi bt_coex_active=0<br />
}}<br />
<br />
==== Disabling LED blink ====<br />
<br />
{{Note|This works with the {{ic|iwlegacy}} and {{ic|iwlwifi}} drivers.}}<br />
<br />
The default settings on the module are to have the LED blink on activity. Some people find this extremely annoying. To have the LED on solid when Wi-Fi is active, you can use the [[systemd#Temporary files|systemd-tmpfiles]]:<br />
<br />
{{hc|/etc/tmpfiles.d/phy0-led.conf|<br />
w /sys/class/leds/phy0-led/trigger - - - - phy0radio<br />
}}<br />
<br />
Run {{ic|systemd-tmpfiles --create phy0-led.conf}} for the change to take effect, or reboot.<br />
<br />
To see all the possible trigger values for this LED:<br />
<br />
# cat /sys/class/leds/phy0-led/trigger<br />
<br />
{{Tip|If you do not have {{ic|/sys/class/leds/phy0-led}}, you may try to use the {{ic|1=led_mode="1"}} [[Kernel modules#Setting module options|module option]]. It should be valid for both {{ic|iwlwifi}} and {{ic|iwlegacy}} drivers.}}<br />
<br />
=== Broadcom ===<br />
<br />
See [[Broadcom wireless]].<br />
<br />
=== Other drivers/devices ===<br />
<br />
==== Tenda w322u ====<br />
<br />
Treat this Tenda card as an {{ic|rt2870sta}} device. See [[#rt2x00]].<br />
<br />
==== orinoco ====<br />
<br />
This should be a part of the kernel package and be installed already.<br />
<br />
Some Orinoco chipsets are Hermes II. You can use the {{ic|wlags49_h2_cs}} driver instead of {{ic|orinoco_cs}} and gain WPA support. To use the driver, [[blacklist]] {{ic|orinoco_cs}} first.<br />
<br />
==== prism54 ====<br />
<br />
The driver {{ic|p54}} is included in kernel, but you have to download the appropriate firmware for your card from [http://linuxwireless.org/en/users/Drivers/p54#firmware this site] and install it into the {{ic|/usr/lib/firmware}} directory.<br />
<br />
{{Note|There is also older, deprecated driver {{ic|prism54}}, which might conflict with the newer driver ({{ic|p54pci}} or {{ic|p54usb}}). Make sure to [[blacklist]] {{ic|prism54}}.}}<br />
<br />
==== ACX100/111 ====<br />
<br />
{{Warning|The drivers for these devices [https://mailman.archlinux.org/pipermail/arch-dev-public/2011-June/020669.html are broken] and do not work with newer kernel versions.}}<br />
<br />
Packages: {{ic|tiacx}} {{ic|tiacx-firmware}} (deleted from official repositories and AUR)<br />
<br />
See [http://sourceforge.net/apps/mediawiki/acx100/index.php?title=Main_Page official wiki]{{dead link|2018|09|23}} for details.<br />
<br />
==== zd1211rw ====<br />
<br />
[http://zd1211.wiki.sourceforge.net/ {{ic|zd1211rw}}] is a driver for the ZyDAS ZD1211 802.11b/g USB WLAN chipset, and it is included in recent versions of the Linux kernel. See [http://www.linuxwireless.org/en/users/Drivers/zd1211rw/devices] for a list of supported devices. You only need to [[install]] the firmware for the device, provided by the {{AUR|zd1211-firmware}} package.<br />
<br />
==== hostap_cs ====<br />
<br />
[http://hostap.epitest.fi/ Host AP] is a Linux driver for wireless LAN cards based on Intersil's Prism2/2.5/3 chipset. The driver is included in Linux kernel.<br />
<br />
{{Note|Make sure to [[blacklist]] the {{ic|orinico_cs}} driver, it may cause problems.}}<br />
<br />
=== ndiswrapper ===<br />
<br />
Ndiswrapper is a wrapper script that allows you to use some Windows drivers in Linux. You will need the {{ic|.inf}} and {{ic|.sys}} files from your Windows driver. <br />
{{Warning|Be sure to use drivers appropriate to your architecture (x86 vs. x86_64).}}<br />
<br />
{{Tip|If you need to extract these files from an {{ic|*.exe}} file, you can use {{Pkg|cabextract}}.}}<br />
<br />
Follow these steps to configure ndiswrapper.<br />
<br />
1. Install {{pkg|ndiswrapper-dkms}}<br />
<br />
2. Install the driver to {{ic|/etc/ndiswrapper/*}}<br />
# ndiswrapper -i filename.inf<br />
<br />
3. List all installed drivers for ndiswrapper<br />
$ ndiswrapper -l<br />
<br />
4. Let ndiswrapper write its configuration in {{ic|/etc/modprobe.d/ndiswrapper.conf}}:<br />
# ndiswrapper -m<br />
# depmod -a<br />
<br />
Now the ndiswrapper install is almost finished; follow the instructions on [[Kernel modules#Automatic module loading with systemd]] to automatically load the module at boot.<br />
<br />
The important part is making sure that ndiswrapper exists on this line, so just add it alongside the other modules. It would be best to test that ndiswrapper will load now, so:<br />
# modprobe ndiswrapper<br />
# iwconfig<br />
<br />
and ''wlan0'' should now exist. If you have problems, some help is available at:<br />
[http://sourceforge.net/p/ndiswrapper/ndiswrapper/HowTos/ ndiswrapper howto] and [http://sourceforge.net/p/ndiswrapper/ndiswrapper/FAQ/ ndiswrapper FAQ].<br />
<br />
=== backports-patched ===<br />
<br />
{{AUR|backports-patched}} provide drivers released on newer kernels backported for usage on older kernels. The project started since 2007 and was originally known as compat-wireless, evolved to compat-drivers and was recently renamed simply to backports. <br />
<br />
If you are using old kernel and have wireless issue, drivers in this package may help.<br />
<br />
== See also ==<br />
<br />
* [http://wireless.kernel.org/ The Linux Wireless project]<br />
* [http://aircrack-ng.org/doku.php?id=install_drivers Aircrack-ng guide on installing drivers]</div>LambToWolfhttps://wiki.archlinux.org/index.php?title=Network_configuration/Wireless&diff=584406Network configuration/Wireless2019-10-04T17:37:13Z<p>LambToWolf: How to fix "Microcode SW error detected. Restarting 0x2000000." errors with iwlwifi</p>
<hr />
<div>[[Category:Wireless networking]]<br />
[[Category:Network configuration]]<br />
[[cs:Wireless network configuration]]<br />
[[de:(W)LAN und Arch Linux]]<br />
[[el:Wireless network configuration]]<br />
[[es:Wireless network configuration]]<br />
[[fa:تنظیمات شبکه ی بی سیم]]<br />
[[fr:Wifi]]<br />
[[it:Wireless network configuration]]<br />
[[ja:ワイヤレス設定]]<br />
[[nl:Wireless network configuration]]<br />
[[pt:Wireless network configuration]]<br />
[[ru:Wireless network configuration]]<br />
[[th:Wireless network configuration]]<br />
[[zh-hans:Wireless network configuration]]<br />
{{Related articles start}}<br />
{{Related|Software access point}}<br />
{{Related|Ad-hoc networking}}<br />
{{Related|Internet sharing}}<br />
{{Related|Wireless bonding}}<br />
{{Related|Network Debugging}}<br />
{{Related|Bluetooth}}<br />
{{Related articles end}}<br />
{{Move|Network configuration/Wireless|Page depends on [[Network configuration]].|Talk:Network configuration#Moving Ethernet-specific sections to Wired subpage}}<br />
The main article on network configuration is [[Network configuration]].<br />
<br />
Configuring wireless is a two-part process; the first part is to identify and ensure the correct driver for your wireless device is installed (they are available on the installation media, but often have to be installed explicitly), and to configure the interface. The second is choosing a method of managing wireless connections. This article covers both parts, and provides additional links to wireless management tools.<br />
<br />
The [[#iw]] section describes how to manually manage your wireless network interface / your wireless LANs using {{Pkg|iw}}. The [[Network configuration#Network managers]] section describes several programs that can be used to automatically manage your wireless interface, some of which include a GUI and all of which include support for network profiles (useful when frequently switching wireless networks, like with laptops).<br />
<br />
== Device driver ==<br />
<br />
The default Arch Linux kernel is ''modular'', meaning many of the drivers for machine hardware reside on the hard drive and are available as [[Kernel modules|modules]]. At boot, [[udev]] takes an inventory of your hardware and loads appropriate modules (drivers) for your corresponding hardware, which will in turn allow creation of a network ''interface''.<br />
<br />
Some wireless chipsets also require firmware, in addition to a corresponding driver. Many firmware images are provided by the {{Pkg|linux-firmware}} package which is installed by default, however, proprietary firmware images are not included and have to be installed separately. This is described in [[#Installing driver/firmware]].<br />
<br />
{{Note|If the proper module is not loaded by udev on boot, simply [[Kernel modules#Manual module handling|load it manually]]. If udev loads more than one driver for a device, the resulting conflict may prevent successful configuration. Make sure to [[blacklist]] the unwanted module.}}<br />
<br />
=== Check the driver status ===<br />
<br />
To check if the driver for your card has been loaded, check the output of the {{ic|lspci -k}} or {{ic|lsusb -v}} command, depending on if the card is connected by PCI(e) or USB. You should see that some kernel driver is in use, for example:<br />
<br />
{{hc|$ lspci -k|<nowiki><br />
06:00.0 Network controller: Intel Corporation WiFi Link 5100<br />
Subsystem: Intel Corporation WiFi Link 5100 AGN<br />
Kernel driver in use: iwlwifi<br />
Kernel modules: iwlwifi<br />
</nowiki>}}<br />
<br />
{{Note|If the card is a USB device, running {{ic|dmesg {{!}} grep usbcore}} should give something like {{ic|usbcore: registered new interface driver rtl8187}} as output.}}<br />
<br />
Also check the output of the {{ic|ip link}} command to see if a wireless interface was created; usually the naming of the wireless [[network interfaces]] starts with the letter "w", e.g. {{ic|wlan0}} or {{ic|wlp2s0}}. Then bring the interface up with:<br />
<br />
# ip link set ''interface'' up<br />
<br />
For example, assuming the interface is {{ic|wlan0}}, this is {{ic|ip link set wlan0 up}}.<br />
<br />
If you get the error message {{ic|SIOCSIFFLAGS: No such file or directory}}, it most certainly means that your wireless chipset requires a firmware to function.<br />
<br />
Check kernel messages for firmware being loaded:<br />
<br />
{{hc|<nowiki>$ dmesg | grep firmware</nowiki>|<nowiki><br />
[ 7.148259] iwlwifi 0000:02:00.0: loaded firmware version 39.30.4.1 build 35138 op_mode iwldvm<br />
</nowiki>}}<br />
<br />
If there is no relevant output, check the messages for the full output for the module you identified earlier ({{ic|iwlwifi}} in this example) to identify the relevant message or further issues:<br />
<br />
{{hc|<nowiki>$ dmesg | grep iwlwifi</nowiki>|<nowiki><br />
[ 12.342694] iwlwifi 0000:02:00.0: irq 44 for MSI/MSI-X<br />
[ 12.353466] iwlwifi 0000:02:00.0: loaded firmware version 39.31.5.1 build 35138 op_mode iwldvm<br />
[ 12.430317] iwlwifi 0000:02:00.0: CONFIG_IWLWIFI_DEBUG disabled<br />
...<br />
[ 12.430341] iwlwifi 0000:02:00.0: Detected Intel(R) Corporation WiFi Link 5100 AGN, REV=0x6B<br />
</nowiki>}}<br />
<br />
If the kernel module is successfully loaded and the interface is up, you can skip the next section.<br />
<br />
=== Installing driver/firmware ===<br />
<br />
Check the following lists to discover if your card is supported:<br />
<br />
* See the table of [https://wireless.wiki.kernel.org/en/users/drivers existing Linux wireless drivers] and follow to the specific driver's page, which contains a list of supported devices. There is also a [https://wikidevi.com/wiki/List_of_Wi-Fi_Device_IDs_in_Linux List of Wi-Fi Device IDs in Linux].<br />
* The [https://help.ubuntu.com/community/WifiDocs/WirelessCardsSupported Ubuntu Wiki] has a good list of wireless cards and whether or not they are supported either in the Linux kernel or by a user-space driver (includes driver name).<br />
* [http://linux-wless.passys.nl/ Linux Wireless Support] and The Linux Questions' [http://www.linuxquestions.org/hcl/index.php?cat=10 Hardware Compatibility List] (HCL) also have a good database of kernel-friendly hardware.<br />
<br />
Note that some vendors ship products that may contain different chip sets, even if the product identifier is the same. Only the usb-id (for USB devices) or pci-id (for PCI devices) is authoritative.<br />
<br />
If your wireless card is listed above, follow the [[#Troubleshooting drivers and firmware]] subsection of this page, which contains information about installing drivers and firmware of some specific wireless cards. Then [[#Check the driver status|check the driver status]] again.<br />
<br />
If your wireless card is not listed above, it is likely supported only under Windows (some Broadcom, 3com, etc). For these, you can try to use [[#ndiswrapper]].<br />
<br />
== Utilities ==<br />
<br />
Just like other network interfaces, the wireless ones are controlled with ''ip'' from the {{Pkg|iproute2}} package.<br />
<br />
Managing a wireless connection requires a basic set of tools. Either use a [[network manager]] or use one of the following directly:<br />
<br />
{| class="wikitable"<br />
! Software !! Package !! [https://wireless.wiki.kernel.org/en/developers/documentation/wireless-extensions WEXT] !! [https://wireless.wiki.kernel.org/en/developers/documentation/nl80211 nl80211] !! WEP !! WPA/WPA2 !! [[Archiso]] [https://git.archlinux.org/archiso.git/tree/configs/releng/packages.x86_64]<br />
|-<br />
| [http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/Tools.html wireless_tools]<sup>1</sup> || {{pkg|wireless_tools}} || {{yes}} || {{no}} || {{Yes}} || {{No}} || {{Yes}}<br />
|-<br />
| [https://wireless.kernel.org/en/users/Documentation/iw iw] || {{Pkg|iw}} || {{No}} || {{Yes}} || {{Yes}} || {{No}} || {{Yes}}<br />
|-<br />
| [[WPA supplicant]] || {{Pkg|wpa_supplicant}} || {{Yes}} || {{Yes}} || {{Yes}} || {{Yes}} || {{Yes}}<br />
|-<br />
| [[iwd]] || {{Pkg|iwd}} || {{No}} || {{Yes}} || {{Yes}} || {{Yes}} || {{Yes}}<br />
|}<br />
<br />
# Deprecated.<br />
<br />
Note that some cards only support WEXT.<br />
<br />
=== iw and wireless_tools comparison ===<br />
<br />
The table below gives an overview of comparable commands for ''iw'' and ''wireless_tools''. See [http://wireless.kernel.org/en/users/Documentation/iw/replace-iwconfig iw replaces iwconfig] for more examples.<br />
<br />
{| class="wikitable"<br />
! ''iw'' command<br />
! ''wireless_tools'' command<br />
! Description<br />
|-<br />
| iw dev ''wlan0'' link<br />
| iwconfig ''wlan0''<br />
| Getting link status.<br />
|-<br />
| iw dev ''wlan0'' scan<br />
| iwlist ''wlan0'' scan<br />
| Scanning for available access points.<br />
|-<br />
| iw dev ''wlan0'' set type ibss<br />
| iwconfig ''wlan0'' mode ad-hoc<br />
| Setting the operation mode to ''ad-hoc''.<br />
|-<br />
| iw dev ''wlan0'' connect ''your_essid''<br />
| iwconfig ''wlan0'' essid ''your_essid''<br />
| Connecting to open network.<br />
|-<br />
| iw dev ''wlan0'' connect ''your_essid'' 2432<br />
| iwconfig ''wlan0'' essid ''your_essid'' freq 2432M<br />
| Connecting to open network specifying channel.<br />
|-<br />
| rowspan="2" | iw dev ''wlan0'' connect ''your_essid'' key 0:''your_key''<br />
| iwconfig ''wlan0'' essid ''your_essid'' key ''your_key''<br />
| Connecting to WEP encrypted network using hexadecimal key.<br />
|-<br />
| iwconfig ''wlan0'' essid ''your_essid'' key s:''your_key''<br />
| Connecting to WEP encrypted network using ASCII key.<br />
|-<br />
| iw dev ''wlan0'' set power_save on<br />
| iwconfig ''wlan0'' power on<br />
| Enabling power save.<br />
|}<br />
<br />
== iw ==<br />
<br />
{{Note|<br />
* Note that most of the commands have to be executed with [[Users and groups|root permissions]]. Executed with normal user rights, some of the commands (e.g. ''iw list''), will exit without error but not produce the correct output either, which can be confusing.<br />
* Depending on your hardware and encryption type, some of these steps may not be necessary. Some cards are known to require interface activation and/or access point scanning before being associated to an access point and being given an IP address. Some experimentation may be required. For instance, WPA/WPA2 users may try to directly activate their wireless network from step [[#Connect to an access point]].}}<br />
<br />
Examples in this section assume that your wireless device interface is {{ic|''interface''}} and that you are connecting to {{ic|''your_essid''}} wifi access point. Replace both accordingly.<br />
<br />
=== Get the name of the interface ===<br />
<br />
{{Tip|See [http://wireless.kernel.org/en/users/Documentation/iw official documentation] of the ''iw'' tool for more examples.}}<br />
<br />
To get the name of your wireless interface do:<br />
<br />
$ iw dev<br />
<br />
The name of the interface will be output after the word "Interface". For example, it is commonly {{ic|wlan0}}.<br />
<br />
=== Get the status of the interface ===<br />
<br />
To check link status, use following command.<br />
<br />
$ iw dev ''interface'' link<br />
<br />
You can get statistic information, such as the amount of tx/rx bytes, signal strength etc., with following command:<br />
<br />
$ iw dev ''interface'' station dump<br />
<br />
=== Activate the interface ===<br />
<br />
{{Tip|Usually this step is not required.}}<br />
<br />
Some cards require that the kernel interface be activated before you can use ''iw'' or ''wireless_tools'':<br />
<br />
# ip link set ''interface'' up<br />
<br />
{{Note|If you get errors like {{ic|RTNETLINK answers: Operation not possible due to RF-kill}}, make sure that hardware switch is ''on''. See [[#Rfkill caveat]] for details.}}<br />
<br />
To verify that the interface is up, inspect the output of the following command:<br />
<br />
{{hc|$ ip link show ''interface''|<br />
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state DOWN mode DORMANT group default qlen 1000<br />
link/ether 12:34:56:78:9a:bc brd ff:ff:ff:ff:ff:ff<br />
}}<br />
<br />
The {{ic|UP}} in {{ic|<BROADCAST,MULTICAST,UP,LOWER_UP>}} is what indicates the interface is up, not the later {{ic|state DOWN}}.<br />
<br />
=== Discover access points ===<br />
<br />
To see what access points are available:<br />
<br />
# iw dev ''interface'' scan | less<br />
<br />
{{Note|If it displays {{ic|Interface does not support scanning}}, then you probably forgot to install the firmware. In some cases this message is also displayed when not running ''iw'' as root.}}<br />
<br />
{{Tip|Depending on your location, you might need to set the correct [[#Respecting the regulatory domain|regulatory domain]] in order to see all available networks.}}<br />
<br />
The important points to check:<br />
* '''SSID:''' the name of the network.<br />
* '''Signal:''' is reported in a wireless power ratio in dBm (e.g. from -100 to 0). The closer the negative value gets to zero, the better the signal. Observing the reported power on a good quality link and a bad one should give an idea about the individual range. <br />
* '''Security:''' it is not reported directly, check the line starting with {{ic|capability}}. If there is {{ic|Privacy}}, for example {{ic|capability: ESS Privacy ShortSlotTime (0x0411)}}, then the network is protected somehow.<br />
** If you see an {{ic|RSN}} information block, then the network is protected by [[Wikipedia:IEEE 802.11i-2004|Robust Security Network]] protocol, also known as WPA2.<br />
** If you see an {{ic|WPA}} information block, then the network is protected by [[Wikipedia:Wi-Fi Protected Access|Wi-Fi Protected Access]] protocol.<br />
** In the {{ic|RSN}} and {{ic|WPA}} blocks you may find the following information:<br />
*** '''Group cipher:''' value in TKIP, CCMP, both, others.<br />
*** '''Pairwise ciphers:''' value in TKIP, CCMP, both, others. Not necessarily the same value than Group cipher.<br />
*** '''Authentication suites:''' value in PSK, 802.1x, others. For home router, you will usually find PSK (''i.e.'' passphrase). In universities, you are more likely to find 802.1x suite which requires login and password. Then you will need to know which key management is in use (e.g. EAP), and what encapsulation it uses (e.g. PEAP). See [[#WPA2 Enterprise]] and [[Wikipedia:Authentication protocol]] for details.<br />
** If you see neither {{ic|RSN}} nor {{ic|WPA}} blocks but there is {{ic|Privacy}}, then WEP is used.<br />
<br />
=== Set operating mode ===<br />
<br />
You might need to set the proper operating mode of the wireless card. More specifically, if you are going to connect an [[Ad-hoc networking|ad-hoc network]], you need to set the operating mode to {{ic|ibss}}:<br />
<br />
# iw dev ''interface'' set type ibss<br />
<br />
{{Note|Changing the operating mode on some cards might require the wireless interface to be ''down'' ({{ic|ip link set ''interface'' down}}).}}<br />
<br />
=== Connect to an access point ===<br />
<br />
Depending on the encryption, you need to associate your wireless device with the access point to use and pass the encryption key:<br />
<br />
* '''No encryption''' {{bc|# iw dev ''interface'' connect "''your_essid''"}}<br />
* '''WEP'''<br />
** using a hexadecimal or ASCII key (the format is distinguished automatically, because a WEP key has a fixed length): {{bc|# iw dev ''interface'' connect "''your_essid''" key 0:''your_key''}}<br />
** using a hexadecimal or ASCII key, specifying the third set up key as default (keys are counted from zero, four are possible): {{bc|# iw dev ''interface'' connect "''your_essid''" key d:2:''your_key''}}<br />
<br />
Regardless of the method used, you can check if you have associated successfully:<br />
<br />
# iw dev ''interface'' link<br />
<br />
== Wi-Fi Protected Access ==<br />
<br />
{{Expansion|Add [[Wikipedia:WPA3|WPA3]].}}<br />
<br />
=== WPA2 Personal ===<br />
<br />
WPA2 Personal, a.k.a. WPA2-PSK, is a mode of [[Wikipedia:Wi-Fi Protected_Access|Wi-Fi Protected Access]].<br />
<br />
You can authenticate to WPA2 Personal networks using [[WPA supplicant]] or [[iwd]], or connect using a [[network manager]]. If you only authenticated to the network, then to have a fully functional connection you will still need to assign the IP address(es) and routes either [[Network configuration#Static IP address|manually]] or using a [[DHCP]] client.<br />
<br />
{{Remove|Duplicates [[WPA supplicant]].}}<br />
<br />
The following method uses [[WPA supplicant]] to connect to a WPA2 Personal mode wireless router from the command line. It is particularly suitable for installing from the Arch linux ISO over wireless. All necessary commands are already included in the live session.<br />
<br />
First, encrypt the passphrase for your router:<br />
<br />
# wpa_passphrase ''my_essid'' ''my_passphrase'' > /etc/wpa_supplicant/''my_essid.conf''<br />
<br />
Before running wpa_supplicant in the background, test to make sure you get a connection:<br />
<br />
# wpa_supplicant -c /etc/wpa_supplicant/''my_essid.conf'' -i ''my_wireless_device''<br />
<br />
You might get some errors, but should see a "connected" message at the end. If so, <Ctrl>-c, and run wpa_supplicant in the background:<br />
<br />
# wpa_supplicant -B -c /etc/wpa_supplicant/''my_essid.conf'' -i ''my_wireless_device''<br />
<br />
You will still need to assign an IP address. If using DHCP:<br />
<br />
# dhclient ''my_wireless_device''<br />
<br />
That's it. Wireless networking should now be fully functional.<br />
<br />
=== WPA2 Enterprise ===<br />
<br />
''WPA2 Enterprise'' is a mode of [[Wikipedia:Wi-Fi_Protected_Access|Wi-Fi Protected Access]]. It provides better security and key management than ''WPA2 Personal'', and supports other enterprise-type functionality, such as VLANs and [[wikipedia:Network Access Protection|NAP]]. However, it requires an external authentication server, called [[wikipedia:RADIUS|RADIUS]] server to handle the authentication of users. This is in contrast to Personal mode which does not require anything beyond the wireless router or access points (APs), and uses a single passphrase or password for all users.<br />
<br />
The Enterprise mode enables users to log onto the Wi-Fi network with a username and password and/or a digital certificate. Since each user has a dynamic and unique encryption key, it also helps to prevent user-to-user snooping on the wireless network, and improves encryption strength.<br />
<br />
This section describes the configuration of [[List of applications#Network managers|network clients]] to connect to a wireless access point with WPA2 Enterprise mode. See [[Software access point#RADIUS]] for information on setting up an access point itself. <br />
<br />
{{Note|Enterprise mode requires a more complex client configuration, whereas Personal mode only requires entering a passphrase when prompted. Clients likely need to install the server’s CA certificate (plus per-user certificates if using EAP-TLS), and then manually configure the wireless security and 802.1X authentication settings.}}<br />
<br />
For a comparison of protocols see the following [http://deployingradius.com/documents/protocols/compatibility.html table].<br />
<br />
{{Warning|It is possible to use WPA2 Enterprise without the client checking the server CA certificate. However, you should always seek to do so, because without authenticating the access point the connection can be subject to a man-in-the-middle attack. This may happen because while the connection handshake itself may be encrypted, the most widely used setups transmit the password itself either in plain text or the easily breakable [[#MS-CHAPv2]]. Hence, the client might send the password to a malicious access point which then proxies the connection.}}<br />
<br />
==== eduroam ====<br />
<br />
[[Wikipedia:eduroam|eduroam]] is an international roaming service for users in research, higher education and further education, based on WPA2 Enterprise.<br />
<br />
{{Note|<br />
* Check connection details '''first''' with your institution before applying any profiles listed in this section. Example profiles are not guaranteed to work or match any security requirements.<br />
* When storing connection profiles unencrypted, it is recommended restrict read access to the root account by specifying {{ic|chmod 600 ''profile''}} as root.<br />
}}<br />
<br />
{{Tip|Configuration for [[NetworkManager]] and [[#wpa_supplicant]] can be generated with the [https://cat.eduroam.org/ eduroam Configuration Assistant Tool].}}<br />
<br />
==== Manual/automatic setup ====<br />
<br />
===== wpa_supplicant =====<br />
<br />
[[WPA supplicant#Advanced usage|WPA supplicant]] can be configured directly by its configuration file or using its CLI/GUI front ends and used in combination with a DHCP client. See the examples in {{ic|/usr/share/doc/wpa_supplicant/wpa_supplicant.conf}} for configuring the connection details.<br />
<br />
===== NetworkManager =====<br />
<br />
[[NetworkManager]] can generate WPA2 Enterprise profiles with [[NetworkManager#Front-ends|graphical front ends]]. ''nmcli'' and ''nmtui'' do not support this, but may use existing profiles.<br />
<br />
===== connman =====<br />
<br />
[[ConnMan]] needs a separate configuration file before [[ConnMan#Wi-Fi|connecting]] to the network. See {{man|5|connman-service.config}} and [[ConnMan#Connecting_to_eduroam_.28802.1X.29|Connman#Connecting to eduroam]] for details.<br />
<br />
===== netctl =====<br />
<br />
[[netctl]] supports [[#wpa_supplicant]] configuration through blocks included with {{ic|1=WPAConfigSection=}}. See {{man|5|netctl.profile}} for details.<br />
<br />
{{Warning|Special quoting rules apply: see the {{ic|''SPECIAL QUOTING RULES''}} section in {{man|5|netctl.profile}}.}}<br />
<br />
{{Tip|Custom certificates can be specified by adding the line {{ic|1='ca_cert="/path/to/special/certificate.cer"'}} in {{ic|WPAConfigSection}}.}}<br />
<br />
==== Troubleshooting ====<br />
<br />
===== MS-CHAPv2 =====<br />
<br />
WPA2-Enterprise wireless networks demanding MSCHAPv2 type-2 authentication with PEAP sometimes require {{Pkg|pptpclient}} in addition to the stock {{Pkg|ppp}} package. [[netctl]] seems to work out of the box without ppp-mppe, however. In either case, usage of MSCHAPv2 is discouraged as it is highly vulnerable, although using another method is usually not an option.<br />
<br />
== Tips and tricks ==<br />
<br />
=== Respecting the regulatory domain ===<br />
<br />
The [[wikipedia:IEEE_802.11#Regulatory_domains_and_legal_compliance|regulatory domain]], or "regdomain", is used to reconfigure wireless drivers to make sure that wireless hardware usage complies with local laws set by the FCC, ETSI and other organizations. Regdomains use [[wikipedia:ISO_3166-1_alpha-2|ISO 3166-1 alpha-2 country codes]]. For example, the regdomain of the United States would be "US", China would be "CN", etc.<br />
<br />
Regdomains affect the availability of wireless channels. In the 2.4GHz band, the allowed channels are 1-11 for the US, 1-14 for Japan, and 1-13 for most of the rest of the world. In the 5GHz band, the rules for allowed channels are much more complex. In either case, consult [[wikipedia:List_of_WLAN_channels|this list of WLAN channels]] for more detailed information.<br />
<br />
Regdomains also affect the limit on the [[wikipedia:Equivalent_isotropically_radiated_power|effective isotropic radiated power (EIRP)]] from wireless devices. This is derived from transmit power/"tx power", and is measured in [[wikipedia:DBm|dBm/mBm (1dBm=100mBm) or mW (log scale)]]. In the 2.4GHz band, the maximum is 30dBm in the US and Canada, 20dBm in most of Europe, and 20dB-30dBm for the rest of the world. In the 5GHz band, maximums are usually lower. Consult the [http://git.kernel.org/cgit/linux/kernel/git/linville/wireless-regdb.git/tree/db.txt wireless-regdb] for more detailed information (EIRP dBm values are in the second set of brackets for each line).<br />
<br />
Misconfiguring the regdomain can be useful - for example, by allowing use of an unused channel when other channels are crowded, or by allowing an increase in tx power to widen transmitter range. However, '''this is not recommended''' as it could break local laws and cause interference with other radio devices.<br />
<br />
To configure the regdomain, install {{Pkg|crda}} and reboot (to reload the {{ic|cfg80211}} module and all related drivers). Check the boot log to make sure that CRDA is being called by {{ic|cfg80211}}:<br />
<br />
$ dmesg | grep cfg80211<br />
<br />
The current regdomain can be set to the United States with:<br />
<br />
# iw reg set US<br />
<br />
And queried with:<br />
<br />
$ iw reg get<br />
<br />
{{Note|Your device may be set to country "00", which is the "world regulatory domain" and contains generic settings. If this cannot be unset, CRDA may be misconfigured.}}<br />
<br />
However, setting the regdomain may not alter your settings. Some devices have a regdomain set in firmware/EEPROM, which dictates the limits of the device, meaning that setting regdomain in software [http://wiki.openwrt.org/doc/howto/wireless.utilities#iw can only increase restrictions], not decrease them. For example, a CN device could be set in software to the US regdomain, but because CN has an EIRP maximum of 20dBm, the device will not be able to transmit at the US maximum of 30dBm.<br />
<br />
For example, to see if the regdomain is being set in firmware for an Atheros device:<br />
<br />
$ dmesg | grep ath:<br />
<br />
For other chipsets, it may help to search for "EEPROM", "regdomain", or simply the name of the device driver.<br />
<br />
To see if your regdomain change has been successful, and to query the number of available channels and their allowed transmit power:<br />
<br />
$ iw list | grep -A 15 Frequencies:<br />
<br />
A more permanent configuration of the regdomain can be achieved through editing {{ic|/etc/conf.d/wireless-regdom}} and uncommenting the appropriate domain.<br />
<br />
[[WPA supplicant]] can also use a regdomain in the {{ic|1=country=}} line of {{ic|/etc/wpa_supplicant/wpa_supplicant.conf}}.<br />
<br />
It is also possible to configure the [http://wireless.kernel.org/en/developers/Documentation/cfg80211 cfg80211] kernel module to use a specific regdomain by adding, for example, {{ic|1=options cfg80211 ieee80211_regdom=EU}} as [[Kernel_modules#Setting module options|module options]]. However, this is part of the [http://wireless.kernel.org/en/developers/Regulatory#The_ieee80211_regdom_module_parameter old regulatory implementation].<br />
<br />
For further information, read the [http://wireless.kernel.org/en/developers/Regulatory/ wireless.kernel.org regulatory documentation].<br />
<br />
== Troubleshooting ==<br />
<br />
This section contains general troubleshooting tips, not strictly related to problems with drivers or firmware. For such topics, see next section [[#Troubleshooting drivers and firmware]].<br />
<br />
=== Temporary internet access ===<br />
<br />
If you have problematic hardware and need internet access to, for example, download some software or get help in forums, you can make use of Android's built-in feature for internet sharing via USB cable. See [[Android tethering#USB tethering]] for more information.<br />
<br />
=== Rfkill caveat ===<br />
<br />
Many laptops have a hardware button (or switch) to turn off wireless card, however, the card can also be blocked by kernel. This can be handled by ''rfkill''. To show the current status:<br />
<br />
{{hc|# rfkill list|<br />
0: phy0: Wireless LAN<br />
Soft blocked: yes<br />
Hard blocked: yes<br />
}}<br />
<br />
If the card is ''hard-blocked'', use the hardware button (switch) to unblock it. If the card is not ''hard-blocked'' but ''soft-blocked'', use the following command:<br />
<br />
# rfkill unblock wifi<br />
<br />
{{Note|It is possible that the card will go from ''hard-blocked'' and ''soft-unblocked'' state into ''hard-unblocked'' and ''soft-blocked'' state by pressing the hardware button (i.e. the ''soft-blocked'' bit is just switched no matter what). This can be adjusted by tuning some options of the {{ic|rfkill}} [[kernel module]].}}<br />
<br />
Hardware buttons to toggle wireless cards are handled by a vendor specific [[kernel module]], frequently these are [https://lwn.net/Articles/391230/ WMI] modules. Particularly for very new hardware models, it happens that the model is not fully supported in the latest stable kernel yet. In this case it often helps to search the kernel bug tracker for information and report the model to the maintainer of the respective vendor kernel module, if it has not happened already. <br />
<br />
See also [http://askubuntu.com/questions/62166/siocsifflags-operation-not-possible-due-to-rf-kill].<br />
<br />
=== Observing Logs ===<br />
<br />
A good first measure to troubleshoot is to analyze the system's logfiles first. In order not to manually parse through them all, it can help to open a second terminal/console window and watch the kernels messages with <br />
$ dmesg -w<br />
while performing the action, e.g. the wireless association attempt. <br />
<br />
When using a tool for network management, the same can be done for systemd with <br />
# journalctl -f <br />
<br />
Frequently a wireless error is accompanied by a deauthentication with a particular reason code, for example: <br />
wlan0: deauthenticating from XX:XX:XX:XX:XX:XX by local choice (reason=3)<br />
<br />
Looking up [http://www.aboutcher.co.uk/2012/07/linux-wifi-deauthenticated-reason-codes/ the reason code] might give a first hint. Maybe it also helps you to look at the control message [https://wireless.wiki.kernel.org/en/developers/documentation/mac80211/auth-assoc-deauth flowchart], the journal messages will follow it. <br />
<br />
The individual tools used in this article further provide options for more detailed debugging output, which can be used in a second step of the analysis, if required.<br />
<br />
=== Power saving ===<br />
<br />
See [[Power saving#Network interfaces]].<br />
<br />
=== Failed to get IP address ===<br />
<br />
* If getting an IP address repeatedly fails using the default {{Pkg|dhcpcd}} client, try installing and using {{Pkg|dhclient}} instead. Do not forget to select ''dhclient'' as the primary DHCP client in the [[#Manual/automatic setup|connection manager]].<br />
<br />
* If you can get an IP address for a wired interface and not for a wireless interface, try disabling the wireless card's [[#Power saving|power saving]] features (specify {{ic|off}} instead of {{ic|on}}).<br />
<br />
* If you get a timeout error due to a ''waiting for carrier'' problem, then you might have to set the channel mode to {{ic|auto}} for the specific device:<br />
<br />
# iwconfig wlan0 channel auto<br />
<br />
Before changing the channel to auto, make sure your wireless interface is down. After it has successfully changed it, you can bring the interface up again and continue from there.<br />
<br />
=== Valid IP address but cannot resolve host ===<br />
<br />
If you are on a public wireless network that may have a [[wikipedia:Captive_portal|captive portal]], make sure to query an HTTP page (not an HTTPS page) from your web browser, as some captive portals only redirect HTTP.<br />
If this is not the issue, [[check if you can resolve domain names]], it may be necessary to use the DNS server advertised via DHCP.<br />
<br />
=== Setting RTS and fragmentation thresholds ===<br />
<br />
Wireless hardware disables RTS and fragmentation by default. These are two different methods of increasing throughput at the expense of bandwidth (i.e. reliability at the expense of speed). These are useful in environments with wireless noise or many adjacent access points, which may create interference leading to timeouts or failing connections. <br />
<br />
Packet fragmentation improves throughput by splitting up packets with size exceeding the fragmentation threshold. The maximum value (2346) effectively disables fragmentation since no packet can exceed it. The minimum value (256) maximizes throughput, but may carry a significant bandwidth cost.<br />
<br />
# iw phy0 set frag 512<br />
<br />
[[Wikipedia:IEEE 802.11 RTS/CTS|RTS]] improves throughput by performing a handshake with the access point before transmitting packets with size exceeding the RTS threshold. The maximum threshold (2347) effectively disables RTS since no packet can exceed it. The minimum threshold (0) enables RTS for all packets, which is probably excessive for most situations.<br />
<br />
# iw phy0 set rts 500<br />
<br />
{{Note|{{ic|phy0}} is the name of the wireless device as listed by {{ic|$ iw phy}}.}}<br />
<br />
=== Random disconnections ===<br />
<br />
==== Cause #1 ====<br />
<br />
If dmesg says {{ic|1=wlan0: deauthenticating from MAC by local choice (reason=3)}} and you lose your Wi-Fi connection, it is likely that you have a bit too aggressive power-saving on your Wi-Fi card. Try disabling the wireless card's [[#Power saving|power saving]] features (specify {{ic|off}} instead of {{ic|on}}).<br />
<br />
If your card does not support enabling/disabling power save mode, check the BIOS for power management options. Disabling PCI-Express power management in the BIOS of a Lenovo W520 resolved this issue.<br />
<br />
==== Cause #2 ====<br />
<br />
If you are experiencing frequent disconnections and dmesg shows messages such as <br />
<br />
{{ic|1=ieee80211 phy0: wlan0: No probe response from AP xx:xx:xx:xx:xx:xx after 500ms, disconnecting}}<br />
<br />
try changing the channel bandwidth to {{ic|20MHz}} through your router's settings page.<br />
<br />
==== Cause #3 ====<br />
<br />
On some laptop models with hardware rfkill switches (e.g., Thinkpad X200 series), due to wear or bad design, the switch (or its connection to the mainboard) might become loose over time resulting in seemingly random hardblocks/disconnects when you accidentally touch the switch or move the laptop.<br />
There is no software solution to this, unless your switch is electrical and the BIOS offers the option to disable the switch.<br />
If your switch is mechanical (most are), there are lots of possible solutions, most of which aim to disable the switch: Soldering the contact point on the mainboard/wifi-card, glueing or blocking the switch, using a screw nut to tighten the switch or removing it altogether.<br />
<br />
==== Cause #4 ====<br />
<br />
Another cause for frequent disconnects or a complete failure to connect may also be a sub-standard router, incomplete settings of the router, or interference by other wireless devices. <br />
<br />
To troubleshoot, first best try to connect to the router with no authentication. <br />
<br />
If that works, enable WPA/WPA2 again but choose fixed and/or limited router settings. For example: <br />
* If the router is considerably older than the wireless device you use for the client, test if it works with setting the router to one wireless mode <br />
* Disable mixed-mode authentication (e.g. only WPA2 with AES, or TKIP if the router is old) <br />
* Try a fixed/free channel rather than "auto" channel (maybe the router next door is old and interfering) <br />
* Disable [[Wikipedia:Wi-Fi Protected Setup|WPS]]<br />
* Disable {{ic|40MHz}} channel bandwidth (lower throughput but less likely collisions) <br />
* If the router has quality of service settings, check completeness of settings (e.g. Wi-Fi Multimedia (WMM) is part of optional QoS flow control. An erroneous router firmware may advertise its existence although the setting is not enabled)<br />
<br />
=== Wi-Fi networks invisible because of incorrect regulatory domain===<br />
<br />
If the computer's Wi-Fi channels do not match those of the user's country, that may result in some in-range Wi-Fi networks becoming invisible, because they use wireless channels that aren't allowed by default. The solution is to configure the regulatory domain correctly, see [[#Respecting the regulatory domain]].<br />
<br />
== Troubleshooting drivers and firmware ==<br />
<br />
This section covers methods and procedures for installing kernel modules and ''firmware'' for specific chipsets, that differ from generic method.<br />
<br />
See [[Kernel modules]] for general information on operations with modules.<br />
<br />
=== Ralink/Mediatek ===<br />
<br />
==== rt2x00 ====<br />
<br />
Unified driver for Ralink chipsets (it replaces {{ic|rt2500}}, {{ic|rt61}}, {{ic|rt73}}, etc). This driver has been in the Linux kernel since 2.6.24, you only need to load the right module for the chip: {{ic|rt2400pci}}, {{ic|rt2500pci}}, {{ic|rt2500usb}}, {{ic|rt61pci}} or {{ic|rt73usb}} which will autoload the respective {{ic|rt2x00}} modules too.<br />
<br />
A list of devices supported by the modules is available at the project's [https://web.archive.org/web/20150507023412/http://rt2x00.serialmonkey.com/wiki/index.php/Hardware homepage].<br />
<br />
; Additional notes<br />
* Since kernel 3.0, rt2x00 includes also these drivers: {{ic|rt2800pci}}, {{ic|rt2800usb}}.<br />
* Since kernel 3.0, the staging drivers {{ic|rt2860sta}} and {{ic|rt2870sta}} are replaced by the mainline drivers {{ic|rt2800pci}} and {{ic|rt2800usb}}<sup>[https://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=fefecc6989b4b24276797270c0e229c07be02ad3]</sup>.<br />
* Some devices have a wide range of options that can be configured with {{ic|iwpriv}}. These are documented in the [http://web.ralinktech.com/ralink/Home/Support/Linux.html source tarballs]{{Dead link|2018|08|15}} available from Ralink.<br />
<br />
==== rt3090 ====<br />
<br />
For devices which are using the rt3090 chipset it should be possible to use {{ic|rt2800pci}} driver, however, is not working with this chipset very well (e.g. sometimes it is not possible to use higher rate than 2Mb/s).<br />
<br />
==== rt3290 ====<br />
<br />
The rt3290 chipset is recognised by the kernel {{ic|rt2800pci}} module. However, some users experience problems and reverting to a patched Ralink driver seems to be beneficial in these [https://bbs.archlinux.org/viewtopic.php?id=161952 cases].<br />
<br />
==== rt3573 ====<br />
<br />
New chipset as of 2012. It may require proprietary drivers from Ralink. Different manufacturers use it, see the [https://bbs.archlinux.org/viewtopic.php?pid=1164228#p1164228 Belkin N750 DB wireless usb adapter] forums thread.<br />
<br />
==== rt5572 ====<br />
<br />
New chipset as of 2012 with support for 5 Ghz bands. It may require proprietary drivers from Ralink and some effort to compile them. At the time of writing a how-to on compilation is available for a DLINK DWA-160 rev. B2 [http://bernaerts.dyndns.org/linux/229-ubuntu-precise-dlink-dwa160-revb2 here].<br />
<br />
==== mt7612u ====<br />
<br />
New chipset as of 2014, released under their new commercial name Mediatek. It is an AC1200 or AC1300 chipset. Manufacturer provides drivers for Linux on their [https://www.mediatek.com/products/broadbandWifi/mt7612u support page]<br />
<br />
=== Realtek ===<br />
<br />
See [https://wikidevi.com/wiki/Realtek] for a list of Realtek chipsets and specifications.<br />
<br />
==== rtl8192cu ====<br />
<br />
The driver is now in the kernel, but many users have reported being unable to make a connection although scanning for networks does work.<br />
<br />
{{AUR|8192cu-dkms}} includes many patches, try this if it does not work fine with the driver in kernel.<br />
<br />
==== rtl8723ae/rtl8723be ====<br />
<br />
The {{ic|rtl8723ae}} and {{ic|rtl8723be}} modules are included in the mainline Linux kernel.<br />
<br />
Some users may encounter errors with powersave on this card. This is shown with occasional disconnects that are not recognized by high level network managers ([[netctl]], [[NetworkManager]]). This error can be confirmed by running {{ic|dmesg -w}} or {{ic|journalctl -f}} and looking for output related to powersave and the {{ic|rtl8723ae}}/{{ic|rtl8723be}} module. If you are having this issue, use the {{ic|1=fwlps=0}} kernel option, which should prevent the WiFi card from automatically sleeping and halting connection.<br />
<br />
{{hc|/etc/modprobe.d/rtl8723ae.conf|2=<br />
options rtl8723ae fwlps=0<br />
}}<br />
or<br />
{{hc|/etc/modprobe.d/rtl8723be.conf|2=<br />
options rtl8723be fwlps=0<br />
}}<br />
<br />
If you have poor signal, perhaps your device has only one physical antenna connected, and antenna autoselection is broken. You can force the choice of antenna with {{ic|1=ant_sel=1}} or {{ic|1=ant_sel=2}} kernel option. [https://bbs.archlinux.org/viewtopic.php?id=208472]<br />
<br />
==== rtl88xxau ====<br />
<br />
Realtek chipsets rtl8811au/rtl8812au/rtl8814au/rtl8821au designed for various USB adapters ranging from AC600 to AC1900.<br />
<br />
Several packages provide various kernel drivers:<br />
<br />
{| class="wikitable"<br />
! Chipset || Driver version || Package || Notes<br />
|-<br />
| rtl8811au, rtl8812au, rtl8814au and rtl8821au || 5.6.4.1 || {{AUR|rtl88xxau-aircrack-dkms-git}} || Aircrack-ng kernel module for 8811au, 8812au, 8814au and 8821au chipsets with monitor mode and injection support.<br />
|-<br />
| rtl8812au || 5.2.20 || {{AUR|rtl8812au-dkms-git}} || Latest official Realtek driver version for rtl8812au ''only''.<br />
|-<br />
| rtl8811au, rtl8812au and rtl8821au || 5.1.5 || {{AUR|rtl8821au-dkms-git}} || For rtl8812au versions 5.6.4.1 or 5.2.20 are recommended instead.<br />
|-<br />
| rtl8814au || 4.3.21 || {{AUR|rtl8814au-dkms-git}} || Possibly works for rtl8813au too. Reportedly has better performance than {{AUR|rtl88xxau-aircrack-dkms-git}}<br />
|}<br />
<br />
These require [[DKMS]] so make sure you have your proper kernel headers installed.<br />
<br />
==== rtl8822bu ====<br />
<br />
{{AUR|rtl8822bu-dkms-git}} provides a kernel module for the Realtek 8822bu chipset found in the Edimax EW7822ULC USB3 and Asus AC53 Nano USB 802.11ac adapter.<br />
<br />
This requires [[DKMS]], so make sure you have your proper kernel headers installed.<br />
<br />
==== rtl8xxxu ====<br />
<br />
{{Expansion|Specific issues with the mainline module and kernel versions should be stated.}}<br />
<br />
Issues with the {{ic|rtl8xxxu}} mainline kernel module may be solved by compiling a third-party module for the specific chipset. The source code can be found in [https://github.com/lwfinger?tab=repositories GitHub repositories].<br />
<br />
Some drivers may be already prepared in the AUR, e.g. {{AUR|rtl8723bu-git}} and {{AUR|rtl8723bu-git-dkms}}.<br />
<br />
=== Atheros ===<br />
<br />
The [http://madwifi-project.org/ MadWifi team] currently maintains three different drivers for devices with Atheros chipset:<br />
<br />
* {{ic|madwifi}} is an old, obsolete driver. Not present in Arch kernel since 2.6.39.1<sup>[https://mailman.archlinux.org/pipermail/arch-dev-public/2011-June/020669.html]</sup>.<br />
* {{ic|ath5k}} is newer driver, which replaces the {{ic|madwifi}} driver. Currently a better choice for some chipsets, but not all chipsets are supported (see below)<br />
* {{ic|ath9k}} is the newest of these three drivers, it is intended for newer Atheros chipsets. All of the chips with 802.11n capabilities are supported.<br />
<br />
There are some other drivers for some Atheros devices. See [http://wireless.kernel.org/en/users/Drivers/Atheros#PCI_.2F_PCI-E_.2F_AHB_Drivers Linux Wireless documentation] for details.<br />
<br />
==== ath5k ====<br />
<br />
External resources:<br />
* http://wireless.kernel.org/en/users/Drivers/ath5k<br />
* http://wiki.debian.org/ath5k<br />
<br />
If you find web pages randomly loading very slow, or if the device is unable to lease an IP address, try to switch from hardware to software encryption by loading the {{ic|ath5k}} module with {{ic|1=nohwcrypt=1}} option. See [[Kernel modules#Setting module options]] for details.<br />
<br />
Some laptops may have problems with their wireless LED indicator flickering red and blue. To solve this problem, do:<br />
<br />
# echo none > /sys/class/leds/ath5k-phy0::tx/trigger<br />
# echo none > /sys/class/leds/ath5k-phy0::rx/trigger<br />
<br />
For alternatives, see [https://bugzilla.redhat.com/show_bug.cgi?id=618232 this bug report].<br />
<br />
==== ath9k ====<br />
<br />
External resources:<br />
* http://wireless.kernel.org/en/users/Drivers/ath9k<br />
* http://wiki.debian.org/ath9k<br />
<br />
As of Linux 3.15.1, some users have been experiencing a decrease in bandwidth. In some cases this can fixed by editing {{ic|/etc/modprobe.d/ath9k.conf}} and adding the line:<br />
options ath9k nohwcrypt=1<br />
<br />
{{Note|Check with the command lsmod what module(-name) is in use and change it if named otherwise (e.g. ath9k_htc).}}<br />
<br />
In the unlikely event that you have stability issues that trouble you, you could try using the {{AUR|backports-patched}} package. An [https://lists.ath9k.org/mailman/listinfo/ath9k-devel ath9k mailing list] exists for support and development related discussions.<br />
<br />
===== Power saving =====<br />
<br />
Although [http://wireless.kernel.org/en/users/Documentation/dynamic-power-save Linux Wireless] says that dynamic power saving is enabled for Atheros ath9k single-chips newer than AR9280, for some devices (e.g. AR9285) {{Pkg|powertop}} might still report that power saving is disabled. In this case enable it manually.<br />
<br />
On some devices (e.g. AR9285), enabling the power saving might result in the following error:<br />
<br />
{{hc|# iw dev wlan0 set power_save on|<br />
command failed: Operation not supported (-95)<br />
}}<br />
<br />
The solution is to set the {{ic|1=ps_enable=1}} option for the {{ic|ath9k}} module:<br />
<br />
{{hc|/etc/modprobe.d/ath9k.conf|2=<br />
options ath9k ps_enable=1<br />
}}<br />
<br />
=== Intel ===<br />
<br />
==== ipw2100 and ipw2200 ====<br />
<br />
These modules are fully supported in the kernel, but they require additional firmware. Depending on which of the chipsets you have, [[install]] either {{Pkg|ipw2100-fw}} or {{Pkg|ipw2200-fw}}. Then [[Kernel modules#Manual module handling|reload]] the appropriate module.<br />
<br />
{{Tip|You may use the following [[Kernel modules#Setting module options|module options]]:<br />
* use the {{ic|1=rtap_iface=1}} option to enable the radiotap interface<br />
* use the {{ic|1=led=1}} option to enable a front LED indicating when the wireless is connected or not<br />
}}<br />
<br />
==== iwlegacy ====<br />
<br />
[http://wireless.kernel.org/en/users/Drivers/iwlegacy iwlegacy] is the wireless driver for Intel's 3945 and 4965 wireless chips. The firmware is included in the {{Pkg|linux-firmware}} package.<br />
<br />
[[udev]] should load the driver automatically, otherwise load {{ic|iwl3945}} or {{ic|iwl4965}} manually. See [[Kernel modules]] for details.<br />
<br />
If you have problems connecting to networks in general, random failures with your card on bootup or your link quality is very poor, try to disable 802.11n:<br />
<br />
{{hc|/etc/modprobe.d/iwl4965.conf|2=<br />
options iwl4965 11n_disable=1<br />
}}<br />
<br />
If the failures persist during bootup and you are using Nouveau driver, try [[Nouveau#Enable_early_KMS|enabling early KMS]] to prevent the conflict [https://bbs.archlinux.org/viewtopic.php?pid=1748667#p1748667].<br />
<br />
==== iwlwifi ====<br />
<br />
[http://wireless.kernel.org/en/users/Drivers/iwlwifi iwlwifi] is the wireless driver for Intel's current wireless chips, such as 5100AGN, 5300AGN, and 5350AGN. See the [http://wireless.kernel.org/en/users/Drivers/iwlwifi#Supported_Devices full list of supported devices]. The firmware is included in the {{Pkg|linux-firmware}} package. The {{Aur|linux-firmware-iwlwifi-git}} may contain some updates sooner.<br />
<br />
If you have problems connecting to networks in general or your link quality is very poor, try to disable 802.11n, and perhaps also enable software encryption:<br />
<br />
{{hc|/etc/modprobe.d/iwlwifi.conf|2=<br />
options iwlwifi 11n_disable=1 swcrypto=1<br />
}}<br />
<br />
If you have a problem with slow uplink speed in 802.11n mode, for example 20Mbps, try to enable antenna aggregation:<br />
<br />
{{hc|/etc/modprobe.d/iwlwifi.conf|2=<br />
options iwlwifi 11n_disable=8<br />
}}<br />
<br />
Do not be confused with the optiIOon name, when the value is set to {{ic|8}} it does not disable anything but re-enables transmission antenna aggregation.[http://forums.gentoo.org/viewtopic-t-996692.html?sid=81bdfa435c089360bdfd9368fe0339a9] [https://bugzilla.kernel.org/show_bug.cgi?id=81571]<br />
<br />
In case this does not work for you, you may try disabling [[Power saving#Network interfaces|power saving]] for your wireless adapter.<br />
<br />
[http://ubuntuforums.org/showthread.php?t=2183486&p=12845473#post12845473 Some] have never gotten this to work. [http://ubuntuforums.org/showthread.php?t=2205733&p=12935783#post12935783 Others] found salvation by disabling N in their router settings after trying everything. This is known to have be the only solution on more than one occasion. The second link there mentions a 5ghz option that might be worth exploring.<br />
<br />
You may have some issue where the driver outputs stack traces & errors, which can cause some stuttering.<br />
{{hc|dmesg|2=<br />
Microcode SW error detected. Restarting 0x2000000.<br />
}}<br />
To fix those errors, you may downgrade the package {{Pkg|linux-firmware}} or rename the last version of the firmware used by your device so that an older version is loaded (which keeps it out of pacman's ignored packages).<br />
<br />
===== Bluetooth coexistence =====<br />
<br />
If you have difficulty connecting a bluetooth headset and maintaining good downlink speed, try disabling bluetooth coexistence [https://wireless.wiki.kernel.org/en/users/Drivers/iwlwifi#wifibluetooth_coexistence]:<br />
<br />
{{hc|/etc/modprobe.d/iwlwifi.conf|2=<br />
options iwlwifi bt_coex_active=0<br />
}}<br />
<br />
==== Disabling LED blink ====<br />
<br />
{{Note|This works with the {{ic|iwlegacy}} and {{ic|iwlwifi}} drivers.}}<br />
<br />
The default settings on the module are to have the LED blink on activity. Some people find this extremely annoying. To have the LED on solid when Wi-Fi is active, you can use the [[systemd#Temporary files|systemd-tmpfiles]]:<br />
<br />
{{hc|/etc/tmpfiles.d/phy0-led.conf|<br />
w /sys/class/leds/phy0-led/trigger - - - - phy0radio<br />
}}<br />
<br />
Run {{ic|systemd-tmpfiles --create phy0-led.conf}} for the change to take effect, or reboot.<br />
<br />
To see all the possible trigger values for this LED:<br />
<br />
# cat /sys/class/leds/phy0-led/trigger<br />
<br />
{{Tip|If you do not have {{ic|/sys/class/leds/phy0-led}}, you may try to use the {{ic|1=led_mode="1"}} [[Kernel modules#Setting module options|module option]]. It should be valid for both {{ic|iwlwifi}} and {{ic|iwlegacy}} drivers.}}<br />
<br />
=== Broadcom ===<br />
<br />
See [[Broadcom wireless]].<br />
<br />
=== Other drivers/devices ===<br />
<br />
==== Tenda w322u ====<br />
<br />
Treat this Tenda card as an {{ic|rt2870sta}} device. See [[#rt2x00]].<br />
<br />
==== orinoco ====<br />
<br />
This should be a part of the kernel package and be installed already.<br />
<br />
Some Orinoco chipsets are Hermes II. You can use the {{ic|wlags49_h2_cs}} driver instead of {{ic|orinoco_cs}} and gain WPA support. To use the driver, [[blacklist]] {{ic|orinoco_cs}} first.<br />
<br />
==== prism54 ====<br />
<br />
The driver {{ic|p54}} is included in kernel, but you have to download the appropriate firmware for your card from [http://linuxwireless.org/en/users/Drivers/p54#firmware this site] and install it into the {{ic|/usr/lib/firmware}} directory.<br />
<br />
{{Note|There is also older, deprecated driver {{ic|prism54}}, which might conflict with the newer driver ({{ic|p54pci}} or {{ic|p54usb}}). Make sure to [[blacklist]] {{ic|prism54}}.}}<br />
<br />
==== ACX100/111 ====<br />
<br />
{{Warning|The drivers for these devices [https://mailman.archlinux.org/pipermail/arch-dev-public/2011-June/020669.html are broken] and do not work with newer kernel versions.}}<br />
<br />
Packages: {{ic|tiacx}} {{ic|tiacx-firmware}} (deleted from official repositories and AUR)<br />
<br />
See [http://sourceforge.net/apps/mediawiki/acx100/index.php?title=Main_Page official wiki]{{dead link|2018|09|23}} for details.<br />
<br />
==== zd1211rw ====<br />
<br />
[http://zd1211.wiki.sourceforge.net/ {{ic|zd1211rw}}] is a driver for the ZyDAS ZD1211 802.11b/g USB WLAN chipset, and it is included in recent versions of the Linux kernel. See [http://www.linuxwireless.org/en/users/Drivers/zd1211rw/devices] for a list of supported devices. You only need to [[install]] the firmware for the device, provided by the {{AUR|zd1211-firmware}} package.<br />
<br />
==== hostap_cs ====<br />
<br />
[http://hostap.epitest.fi/ Host AP] is a Linux driver for wireless LAN cards based on Intersil's Prism2/2.5/3 chipset. The driver is included in Linux kernel.<br />
<br />
{{Note|Make sure to [[blacklist]] the {{ic|orinico_cs}} driver, it may cause problems.}}<br />
<br />
=== ndiswrapper ===<br />
<br />
Ndiswrapper is a wrapper script that allows you to use some Windows drivers in Linux. You will need the {{ic|.inf}} and {{ic|.sys}} files from your Windows driver. <br />
{{Warning|Be sure to use drivers appropriate to your architecture (x86 vs. x86_64).}}<br />
<br />
{{Tip|If you need to extract these files from an {{ic|*.exe}} file, you can use {{Pkg|cabextract}}.}}<br />
<br />
Follow these steps to configure ndiswrapper.<br />
<br />
1. Install {{pkg|ndiswrapper-dkms}}<br />
<br />
2. Install the driver to {{ic|/etc/ndiswrapper/*}}<br />
# ndiswrapper -i filename.inf<br />
<br />
3. List all installed drivers for ndiswrapper<br />
$ ndiswrapper -l<br />
<br />
4. Let ndiswrapper write its configuration in {{ic|/etc/modprobe.d/ndiswrapper.conf}}:<br />
# ndiswrapper -m<br />
# depmod -a<br />
<br />
Now the ndiswrapper install is almost finished; follow the instructions on [[Kernel modules#Automatic module loading with systemd]] to automatically load the module at boot.<br />
<br />
The important part is making sure that ndiswrapper exists on this line, so just add it alongside the other modules. It would be best to test that ndiswrapper will load now, so:<br />
# modprobe ndiswrapper<br />
# iwconfig<br />
<br />
and ''wlan0'' should now exist. If you have problems, some help is available at:<br />
[http://sourceforge.net/p/ndiswrapper/ndiswrapper/HowTos/ ndiswrapper howto] and [http://sourceforge.net/p/ndiswrapper/ndiswrapper/FAQ/ ndiswrapper FAQ].<br />
<br />
=== backports-patched ===<br />
<br />
{{AUR|backports-patched}} provide drivers released on newer kernels backported for usage on older kernels. The project started since 2007 and was originally known as compat-wireless, evolved to compat-drivers and was recently renamed simply to backports. <br />
<br />
If you are using old kernel and have wireless issue, drivers in this package may help.<br />
<br />
== See also ==<br />
<br />
* [http://wireless.kernel.org/ The Linux Wireless project]<br />
* [http://aircrack-ng.org/doku.php?id=install_drivers Aircrack-ng guide on installing drivers]</div>LambToWolfhttps://wiki.archlinux.org/index.php?title=GNOME/Files&diff=582444GNOME/Files2019-09-15T20:38:43Z<p>LambToWolf: adding fix for thumbnail generation failing with a hardened kernel</p>
<hr />
<div>[[Category:File managers]]<br />
[[Category:GNOME]]<br />
[[ar:GNOME/Files]]<br />
[[de:Nautilus]]<br />
[[es:GNOME/Files]]<br />
[[ja:GNOME Files]]<br />
{{Related articles start}}<br />
{{Related|GNOME}}<br />
{{Related|File manager functionality}}<br />
{{Related|Nemo}}<br />
{{Related|Thunar}}<br />
{{Related|PCManFM}}<br />
{{Related articles end}}<br />
<br />
Files is the default file manager for [https://wiki.gnome.org/ GNOME]. Files attempts to provide a streamlined method to manage both files and applications.<br />
<br />
{{Note|Files was known as [https://wiki.gnome.org/Apps/Nautilus Nautilus] prior to version 3.6. The application was given new descriptive names, one for each supported language. The name ''Nautilus'' is still used in numerous places such as the executable name, some package names, some desktop entries, and some GSettings schemas.}} <br />
<br />
== Installation ==<br />
<br />
[[Install]] the {{Pkg|nautilus}} package. This package is part of the {{Grp|gnome}} group. See also [[File manager functionality#Additional features]].<br />
<br />
{{Note|Files does not depend on the {{Pkg|gnome-shell}} package, only requiring {{Pkg|gnome-desktop}}.}}<br />
<br />
=== Plugins ===<br />
<br />
Some programs can add extra functionality to Files. Here are a few packages in the official repositories that do just that.<br />
<br />
* {{App|Eiciel|Include extension which add graphical [[ACL]] editor into the file properties window.|http://rofi.roger-ferrer.org/eiciel/|{{AUR|eiciel}}}}<br />
* {{App|Folder Color|Change the color of each icon separately then you are easily notice the right folder!|http://foldercolor.tuxfamily.org/|{{AUR|folder-color-nautilus-bzr}}}}<br />
:{{Tip|This extension works only with these icon-themes which contain additional colored icons, eg:<br>{{AUR|numix-icon-theme-git}}, {{AUR|vibrancy-colors}}, {{AUR|vivacious-colors-icon-theme}}{{Broken package link|package not found}}, {{AUR|humanity-icon-theme}}, {{AUR|mint-x-icons}} }}<br />
* {{App|File Manager Actions|Configures programs to be launched when files are selected in Files|https://gitlab.gnome.org/GNOME/filemanager-actions|{{Pkg|filemanager-actions}}}}<br />
* {{App|Nautilus Admin|Add to menu: "Open as administrator" or "Edit as administrator"|https://bitbucket.org/brunonova/nautilus-admin|{{AUR|nautilus-admin}}}}<br />
* {{App|Nautilus Bluetooth|Add to menu: "Send via Bluetooth"|https://gitlab.gnome.org/madmurphy/nautilus-bluetooth/|{{AUR|nautilus-bluetooth}}}}<br />
* {{App|Nautilus Git|Nautilus/Nemo extension to add important information about the current git directory|https://github.com/bilelmoussaoui/nautilus-git|{{AUR|nautilus-ext-git}}}}<br />
* {{App|Nautilus Terminal|Terminal embedded in Files. It is always open in the current folder, and follows the navigation.|http://projects.flogisoft.com/nautilus-terminal/|{{Pkg|nautilus-terminal}}}}<br />
* {{App|Send to Menu|Files context menu for sending files.|https://gitlab.gnome.org/GNOME/nautilus-sendto|{{Pkg|nautilus-sendto}}}}<br />
* {{App|Seahorse Nautilus|PGP encryption and signing for Files|https://gitlab.gnome.org/GNOME/seahorse-nautilus|{{Pkg|seahorse-nautilus}}}}<br />
* {{App|File Roller|An application for browsing archives|https://wiki.gnome.org/Apps/FileRoller|{{Pkg|file-roller}}}}<br />
* {{App|Python bindings for the Nautilus Extension API|With these bindings, you can write extensions for the Nautilus in python.|https://wiki.gnome.org/Projects/NautilusPython|{{Pkg|python-nautilus}} or {{AUR|python2-nautilus}}}}<br />
<br />
If you wish to write new plugins, {{AUR|nextgen}} is a helper script that lets you set up easily new extension projects for Nautilus.<br />
<br />
== Configuration ==<br />
<br />
Files is simple to configure graphically, but not all options are available in the preferences menu. More options are available with ''dconf-editor'' under {{ic|org.gnome.nautilus}}.<br />
<br />
{{Note|If you are using Files outside of the GNOME desktop environment, you have to make sure that {{ic|/usr/lib/gsd-xsettings}} is running, otherwise the dconf settings are not applied in Files.}}<br />
<br />
=== Desktop Icons ===<br />
<br />
See [[GNOME#Icons on the Desktop]].<br />
<br />
=== Change default item view ===<br />
<br />
You can change the default view for the items by setting the {{ic|default-folder-viewer}} variable, e.g. for the list view:<br />
<br />
$ gsettings set org.gnome.nautilus.preferences default-folder-viewer 'list-view'<br />
<br />
=== Sort by type ===<br />
<br />
To sort files in all folders by type:<br />
<br />
$ gsettings set org.gnome.nautilus.preferences default-sort-order 'type'<br />
<br />
=== Remove folders from the places sidebar ===<br />
<br />
The displayed folders are specified in {{ic|~/.config/user-dirs.dirs}} and can be altered with any editor. An execution of {{ic|xdg-user-dirs-update}} will change them again, thus it may be advisable to set the file permissions to read-only.<br />
<br />
=== Always show text-entry location ===<br />
<br />
The standard Files toolbar shows a button bar interface for path navigation. To enter path locations using the ''keyboard'', you must expose the location text-entry field. This is done by pressing {{ic|Ctrl+l}}<br />
<br />
To make the location text-entry field always present, use ''gsettings'' as shown below: <br />
<br />
$ gsettings set org.gnome.nautilus.preferences always-use-location-entry true<br />
<br />
{{Note|After changing this setting, you will not be able to expose the button bar. Only when the setting is '''false''' can both forms of location navigation be employed.}}<br />
<br />
== Tips and tricks ==<br />
<br />
=== Thumbnails ===<br />
<br />
See [[File manager functionality#Thumbnail previews]].<br />
<br />
{{Note|On {{Pkg|linux-hardened}}, thumbnails generation fails (all thumbnails go in {{ic|~/.cache/thumbnails/fail/}}). This is due to unprivileged user namespace being disabled by default on this kernel for security reasons. Nautilus uses {{ic|bwrap}} (provided by {{Pkg|bubblewrap}}) to sandbox thumbnailers. You may decide to replace {{Pkg|bubblewrap}} with {{Pkg|bubblewrap-suid}}.<br />
See [[Security#Sandboxing_applications]] for more information.<br />
}}<br />
<br />
Sometimes video thumbnails are not shown. To solve it (as mentioned in [https://bbs.archlinux.org/viewtopic.php?id=168626 No video thumbnails on nautilus]), you must install {{Pkg|ffmpegthumbnailer}}, {{Pkg|gst-libav}}, {{Pkg|gst-plugins-ugly}}, and remove the content of {{ic|~/.cache/thumbnails/fail/}}.<br />
<br />
=== Create a new document from the right-click menu ===<br />
<br />
To get this option one has to create a {{ic|~/Templates/}} folder in your home folder and place an empty file inside the folder through your favorite Terminal by {{ic|touch ~/Templates/new}} or by using any other file manager. Then just restart Files.<br />
<br />
On non-English installations, the templates directory might have another name. One can find the actual directory with {{ic|xdg-user-dir TEMPLATES}}.<br />
<br />
The templates directory can be configure in {{ic|~/.config/user-dirs.dirs}}<br />
<br />
XDG_TEMPLATES_DIR="$HOME/some/path"<br />
<br />
=== Music files metadata in list view ===<br />
<br />
{{Note|The script linked to below is slightly modified to fix an error. The original can be found [http://bazaar.launchpad.net/~team1/+junk/devel/view/head:/bsc-v2.py here].}}<br />
<br />
GNOME Files lacks the ability to display metadata for music files in list view mode. A [[Python]] script is available which adds list view columns for the artist, album, track title, bit rate and more.<br />
<br />
To use the script you first need to [[install]] the following: {{AUR|python2-exiv2}}, {{Pkg|python2-mutagen}}, {{AUR|python2-nautilus}}, {{Pkg|python2-pillow}} and {{AUR|kaa-metadata}}.<br />
<br />
Once the dependencies are installed, save the [http://pastebin.com/zN69twVP bsc-v2.py] script to {{ic|~/.local/share/nautilus-python/extensions}} (create the directory if it does not exist) and restart Files.<br />
<br />
The new columns should now have been added. To enable them, navigate to Preferences -> List columns and tick the columns that you wish to use.<br />
<br />
=== Hiding files ===<br />
<br />
Like most other file managers GNOME Files hides files with names starting with a dot by default.<br />
<br />
GNOME Files additionally hides files when their names are listed in a {{ic|.hidden}} file in the same directory (one filename per line).<br />
<br />
=== Open current directory in Tilix ===<br />
<br />
If you're using {{Pkg|tilix}} terminal you can easily add "Open in Tilix" option to the context menu of GNOME Files by installing its optional dependency {{Pkg|python-nautilus}}.<br />
<br />
=== Open current directory in Visual Studio Code ===<br />
<br />
You can easily add "Open Code Here" to the context menu by using extension [https://github.com/cra0zy/code-nautilus]<br />
<br />
=== Add a Folder to Bookmarks ===<br />
<br />
To add a folder to your Bookmarks, simply press CTRL+D when you have the folder opened in Nautilus. Note that the list of bookmarks is shared with other Gnome-based graphical file managers (e.g. Nemo), so a folder added or removed from one will affect the bookmarks seen in the other.<br />
<br />
== Troubleshooting ==<br />
<br />
=== Files is no longer the default file manager ===<br />
<br />
This can be caused by the file association for directories being reset. Installing {{Pkg|anjuta}} tends to do this. <br />
<br />
To solve this, open Files, right-click on a folder, and choose ''Open With Other Application > Files > Select''. This will set the association for directories back to Files.<br />
<br />
If this does not solve the issue, see [[File manager functionality#Directories are not opened in the file manager]].<br />
<br />
=== Freezes for a few seconds after every copy operation ===<br />
<br />
In case you have {{Pkg|kdeconnect}} installed in your system, the problem might be caused by its file sharing module.<br />
Deactivate file sharing, and it should stop happening.</div>LambToWolfhttps://wiki.archlinux.org/index.php?title=GNOME/Files&diff=582316GNOME/Files2019-09-14T14:57:05Z<p>LambToWolf: note wasn't showing because of a typo</p>
<hr />
<div>[[Category:File managers]]<br />
[[Category:GNOME]]<br />
[[ar:GNOME/Files]]<br />
[[de:Nautilus]]<br />
[[es:GNOME/Files]]<br />
[[ja:GNOME Files]]<br />
{{Related articles start}}<br />
{{Related|GNOME}}<br />
{{Related|File manager functionality}}<br />
{{Related|Nemo}}<br />
{{Related|Thunar}}<br />
{{Related|PCManFM}}<br />
{{Related articles end}}<br />
<br />
Files is the default file manager for [https://wiki.gnome.org/ GNOME]. Files attempts to provide a streamlined method to manage both files and applications.<br />
<br />
{{Note|Files was known as [https://wiki.gnome.org/Apps/Nautilus Nautilus] prior to version 3.6. The application was given new descriptive names, one for each supported language. The name ''Nautilus'' is still used in numerous places such as the executable name, some package names, some desktop entries, and some GSettings schemas.}} <br />
<br />
== Installation ==<br />
<br />
[[Install]] the {{Pkg|nautilus}} package. This package is part of the {{Grp|gnome}} group. See also [[File manager functionality#Additional features]].<br />
<br />
{{Note|Files does not depend on the {{Pkg|gnome-shell}} package, only requiring {{Pkg|gnome-desktop}}.}}<br />
<br />
=== Plugins ===<br />
<br />
Some programs can add extra functionality to Files. Here are a few packages in the official repositories that do just that.<br />
<br />
* {{App|Eiciel|Include extension which add graphical [[ACL]] editor into the file properties window.|http://rofi.roger-ferrer.org/eiciel/|{{AUR|eiciel}}}}<br />
* {{App|Folder Color|Change the color of each icon separately then you are easily notice the right folder!|http://foldercolor.tuxfamily.org/|{{AUR|folder-color-nautilus-bzr}}}}<br />
:{{Tip|This extension works only with these icon-themes which contain additional colored icons, eg:<br>{{AUR|numix-icon-theme-git}}, {{AUR|vibrancy-colors}}, {{AUR|vivacious-colors-icon-theme}}{{Broken package link|package not found}}, {{AUR|humanity-icon-theme}}, {{AUR|mint-x-icons}} }}<br />
* {{App|File Manager Actions|Configures programs to be launched when files are selected in Files|https://gitlab.gnome.org/GNOME/filemanager-actions|{{Pkg|filemanager-actions}}}}<br />
* {{App|Nautilus Admin|Add to menu: "Open as administrator" or "Edit as administrator"|https://bitbucket.org/brunonova/nautilus-admin|{{AUR|nautilus-admin}}}}<br />
* {{App|Nautilus Bluetooth|Add to menu: "Send via Bluetooth"|https://gitlab.gnome.org/madmurphy/nautilus-bluetooth/|{{AUR|nautilus-bluetooth}}}}<br />
* {{App|Nautilus Git|Nautilus/Nemo extension to add important information about the current git directory|https://github.com/bilelmoussaoui/nautilus-git|{{AUR|nautilus-ext-git}}}}<br />
* {{App|Nautilus Terminal|Terminal embedded in Files. It is always open in the current folder, and follows the navigation.|http://projects.flogisoft.com/nautilus-terminal/|{{Pkg|nautilus-terminal}}}}<br />
* {{App|Send to Menu|Files context menu for sending files.|https://gitlab.gnome.org/GNOME/nautilus-sendto|{{Pkg|nautilus-sendto}}}}<br />
* {{App|Seahorse Nautilus|PGP encryption and signing for Files|https://gitlab.gnome.org/GNOME/seahorse-nautilus|{{Pkg|seahorse-nautilus}}}}<br />
* {{App|File Roller|An application for browsing archives|https://wiki.gnome.org/Apps/FileRoller|{{Pkg|file-roller}}}}<br />
* {{App|Python bindings for the Nautilus Extension API|With these bindings, you can write extensions for the Nautilus in python.|https://wiki.gnome.org/Projects/NautilusPython|{{Pkg|python-nautilus}} or {{AUR|python2-nautilus}}}}<br />
<br />
If you wish to write new plugins, {{AUR|nextgen}} is a helper script that lets you set up easily new extension projects for Nautilus.<br />
<br />
== Configuration ==<br />
<br />
Files is simple to configure graphically, but not all options are available in the preferences menu. More options are available with ''dconf-editor'' under {{ic|org.gnome.nautilus}}.<br />
<br />
{{Note|If you are using Files outside of the GNOME desktop environment, you have to make sure that {{ic|/usr/lib/gsd-xsettings}} is running, otherwise the dconf settings are not applied in Files.}}<br />
<br />
=== Desktop Icons ===<br />
<br />
See [[GNOME#Icons on the Desktop]].<br />
<br />
=== Change default item view ===<br />
<br />
You can change the default view for the items by setting the {{ic|default-folder-viewer}} variable, e.g. for the list view:<br />
<br />
$ gsettings set org.gnome.nautilus.preferences default-folder-viewer 'list-view'<br />
<br />
=== Sort by type ===<br />
<br />
To sort files in all folders by type:<br />
<br />
$ gsettings set org.gnome.nautilus.preferences default-sort-order 'type'<br />
<br />
=== Remove folders from the places sidebar ===<br />
<br />
The displayed folders are specified in {{ic|~/.config/user-dirs.dirs}} and can be altered with any editor. An execution of {{ic|xdg-user-dirs-update}} will change them again, thus it may be advisable to set the file permissions to read-only.<br />
<br />
=== Always show text-entry location ===<br />
<br />
The standard Files toolbar shows a button bar interface for path navigation. To enter path locations using the ''keyboard'', you must expose the location text-entry field. This is done by pressing {{ic|Ctrl+l}}<br />
<br />
To make the location text-entry field always present, use ''gsettings'' as shown below: <br />
<br />
$ gsettings set org.gnome.nautilus.preferences always-use-location-entry true<br />
<br />
{{Note|After changing this setting, you will not be able to expose the button bar. Only when the setting is '''false''' can both forms of location navigation be employed.}}<br />
<br />
== Tips and tricks ==<br />
<br />
=== Thumbnails ===<br />
<br />
See [[File manager functionality#Thumbnail previews]].<br />
<br />
{{Note|On {{Pkg|linux-hardened}}, thumbnails generation fails (all thumbnails go in {{ic|~/.cache/thumbnails/fail/}}). This is due to unprivileged user namespace disabled by default on this kernel for security reasons. Nautilus uses {{ic|bwrap}} (provided by {{Pkg|bubblewrap}}) to sandbox thumbnails generator for security reasons.<br />
See [[Security#Sandboxing_applications]] for more information.<br />
}}<br />
<br />
Sometimes video thumbnails are not shown. To solve it (as mentioned in [https://bbs.archlinux.org/viewtopic.php?id=168626 No video thumbnails on nautilus]), you must install {{Pkg|ffmpegthumbnailer}}, {{Pkg|gst-libav}}, {{Pkg|gst-plugins-ugly}}, and remove the content of {{ic|~/.cache/thumbnails/fail/}}.<br />
<br />
=== Create a new document from the right-click menu ===<br />
<br />
To get this option one has to create a {{ic|~/Templates/}} folder in your home folder and place an empty file inside the folder through your favorite Terminal by {{ic|touch ~/Templates/new}} or by using any other file manager. Then just restart Files.<br />
<br />
On non-English installations, the templates directory might have another name. One can find the actual directory with {{ic|xdg-user-dir TEMPLATES}}.<br />
<br />
The templates directory can be configure in {{ic|~/.config/user-dirs.dirs}}<br />
<br />
XDG_TEMPLATES_DIR="$HOME/some/path"<br />
<br />
=== Music files metadata in list view ===<br />
<br />
{{Note|The script linked to below is slightly modified to fix an error. The original can be found [http://bazaar.launchpad.net/~team1/+junk/devel/view/head:/bsc-v2.py here].}}<br />
<br />
GNOME Files lacks the ability to display metadata for music files in list view mode. A [[Python]] script is available which adds list view columns for the artist, album, track title, bit rate and more.<br />
<br />
To use the script you first need to [[install]] the following: {{AUR|python2-exiv2}}, {{Pkg|python2-mutagen}}, {{AUR|python2-nautilus}}, {{Pkg|python2-pillow}} and {{AUR|kaa-metadata}}.<br />
<br />
Once the dependencies are installed, save the [http://pastebin.com/zN69twVP bsc-v2.py] script to {{ic|~/.local/share/nautilus-python/extensions}} (create the directory if it does not exist) and restart Files.<br />
<br />
The new columns should now have been added. To enable them, navigate to Preferences -> List columns and tick the columns that you wish to use.<br />
<br />
=== Hiding files ===<br />
<br />
Like most other file managers GNOME Files hides files with names starting with a dot by default.<br />
<br />
GNOME Files additionally hides files when their names are listed in a {{ic|.hidden}} file in the same directory (one filename per line).<br />
<br />
=== Open current directory in Tilix ===<br />
<br />
If you're using {{Pkg|tilix}} terminal you can easily add "Open in Tilix" option to the context menu of GNOME Files by installing its optional dependency {{Pkg|python-nautilus}}.<br />
<br />
=== Open current directory in Visual Studio Code ===<br />
<br />
You can easily add "Open Code Here" to the context menu by using extension [https://github.com/cra0zy/code-nautilus]<br />
<br />
=== Add a Folder to Bookmarks ===<br />
<br />
To add a folder to your Bookmarks, simply press CTRL+D when you have the folder opened in Nautilus. Note that the list of bookmarks is shared with other Gnome-based graphical file managers (e.g. Nemo), so a folder added or removed from one will affect the bookmarks seen in the other.<br />
<br />
== Troubleshooting ==<br />
<br />
=== Files is no longer the default file manager ===<br />
<br />
This can be caused by the file association for directories being reset. Installing {{Pkg|anjuta}} tends to do this. <br />
<br />
To solve this, open Files, right-click on a folder, and choose ''Open With Other Application > Files > Select''. This will set the association for directories back to Files.<br />
<br />
If this does not solve the issue, see [[File manager functionality#Directories are not opened in the file manager]].<br />
<br />
=== Freezes for a few seconds after every copy operation ===<br />
<br />
In case you have {{Pkg|kdeconnect}} installed in your system, the problem might be caused by its file sharing module.<br />
Deactivate file sharing, and it should stop happening.</div>LambToWolfhttps://wiki.archlinux.org/index.php?title=GNOME/Files&diff=582314GNOME/Files2019-09-14T14:53:24Z<p>LambToWolf: linux hardened & thumbnail generation doesn't work by default</p>
<hr />
<div>[[Category:File managers]]<br />
[[Category:GNOME]]<br />
[[ar:GNOME/Files]]<br />
[[de:Nautilus]]<br />
[[es:GNOME/Files]]<br />
[[ja:GNOME Files]]<br />
{{Related articles start}}<br />
{{Related|GNOME}}<br />
{{Related|File manager functionality}}<br />
{{Related|Nemo}}<br />
{{Related|Thunar}}<br />
{{Related|PCManFM}}<br />
{{Related articles end}}<br />
<br />
Files is the default file manager for [https://wiki.gnome.org/ GNOME]. Files attempts to provide a streamlined method to manage both files and applications.<br />
<br />
{{Note|Files was known as [https://wiki.gnome.org/Apps/Nautilus Nautilus] prior to version 3.6. The application was given new descriptive names, one for each supported language. The name ''Nautilus'' is still used in numerous places such as the executable name, some package names, some desktop entries, and some GSettings schemas.}} <br />
<br />
== Installation ==<br />
<br />
[[Install]] the {{Pkg|nautilus}} package. This package is part of the {{Grp|gnome}} group. See also [[File manager functionality#Additional features]].<br />
<br />
{{Note|Files does not depend on the {{Pkg|gnome-shell}} package, only requiring {{Pkg|gnome-desktop}}.}}<br />
<br />
=== Plugins ===<br />
<br />
Some programs can add extra functionality to Files. Here are a few packages in the official repositories that do just that.<br />
<br />
* {{App|Eiciel|Include extension which add graphical [[ACL]] editor into the file properties window.|http://rofi.roger-ferrer.org/eiciel/|{{AUR|eiciel}}}}<br />
* {{App|Folder Color|Change the color of each icon separately then you are easily notice the right folder!|http://foldercolor.tuxfamily.org/|{{AUR|folder-color-nautilus-bzr}}}}<br />
:{{Tip|This extension works only with these icon-themes which contain additional colored icons, eg:<br>{{AUR|numix-icon-theme-git}}, {{AUR|vibrancy-colors}}, {{AUR|vivacious-colors-icon-theme}}{{Broken package link|package not found}}, {{AUR|humanity-icon-theme}}, {{AUR|mint-x-icons}} }}<br />
* {{App|File Manager Actions|Configures programs to be launched when files are selected in Files|https://gitlab.gnome.org/GNOME/filemanager-actions|{{Pkg|filemanager-actions}}}}<br />
* {{App|Nautilus Admin|Add to menu: "Open as administrator" or "Edit as administrator"|https://bitbucket.org/brunonova/nautilus-admin|{{AUR|nautilus-admin}}}}<br />
* {{App|Nautilus Bluetooth|Add to menu: "Send via Bluetooth"|https://gitlab.gnome.org/madmurphy/nautilus-bluetooth/|{{AUR|nautilus-bluetooth}}}}<br />
* {{App|Nautilus Git|Nautilus/Nemo extension to add important information about the current git directory|https://github.com/bilelmoussaoui/nautilus-git|{{AUR|nautilus-ext-git}}}}<br />
* {{App|Nautilus Terminal|Terminal embedded in Files. It is always open in the current folder, and follows the navigation.|http://projects.flogisoft.com/nautilus-terminal/|{{Pkg|nautilus-terminal}}}}<br />
* {{App|Send to Menu|Files context menu for sending files.|https://gitlab.gnome.org/GNOME/nautilus-sendto|{{Pkg|nautilus-sendto}}}}<br />
* {{App|Seahorse Nautilus|PGP encryption and signing for Files|https://gitlab.gnome.org/GNOME/seahorse-nautilus|{{Pkg|seahorse-nautilus}}}}<br />
* {{App|File Roller|An application for browsing archives|https://wiki.gnome.org/Apps/FileRoller|{{Pkg|file-roller}}}}<br />
* {{App|Python bindings for the Nautilus Extension API|With these bindings, you can write extensions for the Nautilus in python.|https://wiki.gnome.org/Projects/NautilusPython|{{Pkg|python-nautilus}} or {{AUR|python2-nautilus}}}}<br />
<br />
If you wish to write new plugins, {{AUR|nextgen}} is a helper script that lets you set up easily new extension projects for Nautilus.<br />
<br />
== Configuration ==<br />
<br />
Files is simple to configure graphically, but not all options are available in the preferences menu. More options are available with ''dconf-editor'' under {{ic|org.gnome.nautilus}}.<br />
<br />
{{Note|If you are using Files outside of the GNOME desktop environment, you have to make sure that {{ic|/usr/lib/gsd-xsettings}} is running, otherwise the dconf settings are not applied in Files.}}<br />
<br />
=== Desktop Icons ===<br />
<br />
See [[GNOME#Icons on the Desktop]].<br />
<br />
=== Change default item view ===<br />
<br />
You can change the default view for the items by setting the {{ic|default-folder-viewer}} variable, e.g. for the list view:<br />
<br />
$ gsettings set org.gnome.nautilus.preferences default-folder-viewer 'list-view'<br />
<br />
=== Sort by type ===<br />
<br />
To sort files in all folders by type:<br />
<br />
$ gsettings set org.gnome.nautilus.preferences default-sort-order 'type'<br />
<br />
=== Remove folders from the places sidebar ===<br />
<br />
The displayed folders are specified in {{ic|~/.config/user-dirs.dirs}} and can be altered with any editor. An execution of {{ic|xdg-user-dirs-update}} will change them again, thus it may be advisable to set the file permissions to read-only.<br />
<br />
=== Always show text-entry location ===<br />
<br />
The standard Files toolbar shows a button bar interface for path navigation. To enter path locations using the ''keyboard'', you must expose the location text-entry field. This is done by pressing {{ic|Ctrl+l}}<br />
<br />
To make the location text-entry field always present, use ''gsettings'' as shown below: <br />
<br />
$ gsettings set org.gnome.nautilus.preferences always-use-location-entry true<br />
<br />
{{Note|After changing this setting, you will not be able to expose the button bar. Only when the setting is '''false''' can both forms of location navigation be employed.}}<br />
<br />
== Tips and tricks ==<br />
<br />
=== Thumbnails ===<br />
<br />
See [[File manager functionality#Thumbnail previews]].<br />
<br />
{{Note|||On {{Pkg-linux-hardened}}, thumbnails generation fails (all thumbnails go in {{ic|~/.cache/thumbnails/fail/}}). This is due to unprivileged user namespace disabled by default on this kernel for security reasons. Nautilus uses {{ic|bwrap}} (provided by {{Pkg|bubblewrap}} to sandbox thumbnails generator for security reasons.<br />
See [[Security#Sandboxing_applications]] for more information.<br />
}}<br />
<br />
Sometimes video thumbnails are not shown. To solve it (as mentioned in [https://bbs.archlinux.org/viewtopic.php?id=168626 No video thumbnails on nautilus]), you must install {{Pkg|ffmpegthumbnailer}}, {{Pkg|gst-libav}}, {{Pkg|gst-plugins-ugly}}, and remove the content of {{ic|~/.cache/thumbnails/fail/}}.<br />
<br />
=== Create a new document from the right-click menu ===<br />
<br />
To get this option one has to create a {{ic|~/Templates/}} folder in your home folder and place an empty file inside the folder through your favorite Terminal by {{ic|touch ~/Templates/new}} or by using any other file manager. Then just restart Files.<br />
<br />
On non-English installations, the templates directory might have another name. One can find the actual directory with {{ic|xdg-user-dir TEMPLATES}}.<br />
<br />
The templates directory can be configure in {{ic|~/.config/user-dirs.dirs}}<br />
<br />
XDG_TEMPLATES_DIR="$HOME/some/path"<br />
<br />
=== Music files metadata in list view ===<br />
<br />
{{Note|The script linked to below is slightly modified to fix an error. The original can be found [http://bazaar.launchpad.net/~team1/+junk/devel/view/head:/bsc-v2.py here].}}<br />
<br />
GNOME Files lacks the ability to display metadata for music files in list view mode. A [[Python]] script is available which adds list view columns for the artist, album, track title, bit rate and more.<br />
<br />
To use the script you first need to [[install]] the following: {{AUR|python2-exiv2}}, {{Pkg|python2-mutagen}}, {{AUR|python2-nautilus}}, {{Pkg|python2-pillow}} and {{AUR|kaa-metadata}}.<br />
<br />
Once the dependencies are installed, save the [http://pastebin.com/zN69twVP bsc-v2.py] script to {{ic|~/.local/share/nautilus-python/extensions}} (create the directory if it does not exist) and restart Files.<br />
<br />
The new columns should now have been added. To enable them, navigate to Preferences -> List columns and tick the columns that you wish to use.<br />
<br />
=== Hiding files ===<br />
<br />
Like most other file managers GNOME Files hides files with names starting with a dot by default.<br />
<br />
GNOME Files additionally hides files when their names are listed in a {{ic|.hidden}} file in the same directory (one filename per line).<br />
<br />
=== Open current directory in Tilix ===<br />
<br />
If you're using {{Pkg|tilix}} terminal you can easily add "Open in Tilix" option to the context menu of GNOME Files by installing its optional dependency {{Pkg|python-nautilus}}.<br />
<br />
=== Open current directory in Visual Studio Code ===<br />
<br />
You can easily add "Open Code Here" to the context menu by using extension [https://github.com/cra0zy/code-nautilus]<br />
<br />
=== Add a Folder to Bookmarks ===<br />
<br />
To add a folder to your Bookmarks, simply press CTRL+D when you have the folder opened in Nautilus. Note that the list of bookmarks is shared with other Gnome-based graphical file managers (e.g. Nemo), so a folder added or removed from one will affect the bookmarks seen in the other.<br />
<br />
== Troubleshooting ==<br />
<br />
=== Files is no longer the default file manager ===<br />
<br />
This can be caused by the file association for directories being reset. Installing {{Pkg|anjuta}} tends to do this. <br />
<br />
To solve this, open Files, right-click on a folder, and choose ''Open With Other Application > Files > Select''. This will set the association for directories back to Files.<br />
<br />
If this does not solve the issue, see [[File manager functionality#Directories are not opened in the file manager]].<br />
<br />
=== Freezes for a few seconds after every copy operation ===<br />
<br />
In case you have {{Pkg|kdeconnect}} installed in your system, the problem might be caused by its file sharing module.<br />
Deactivate file sharing, and it should stop happening.</div>LambToWolf