Difference between revisions of "Help:Editing"

From ArchWiki
Jump to: navigation, search
(Undo revision 284772 by Pooryorick (talk), oops)
Line 1: Line 1:
[[Category:Wireless Networking]]
+
[[Category:Help]]
[[cs:Wireless Setup]]
+
[[cs:Help:Editing]]
[[de:(W)LAN_und_Arch_Linux]]
+
[[es:Help:Editing]]
[[el:Wireless Setup]]
+
[[fa:راهنما:ویرایش]]
[[es:Wireless Setup]]
+
[[fr:Aide:Redaction]]
[[fr:Wifi]]
+
[[it:Help:Editing]]
[[it:Wireless Setup]]
+
[[ja:Help:Editing]]
[[ja:Wireless Setup]]
+
[[pl:Help:Editing]]
[[nl:Wireless Setup]]
+
[[pt:Help:Editing]]
[[ro:Wireless]]
+
[[ru:Help:Editing]]
[[ru:Wireless Setup]]
+
[[sk:Help:Editing]]
[[th:Wireless Setup]]
+
[[sr:Help:Editing]]
[[tr:Kablosuz_bağlantı]]
+
[[tr:Wikiye yazı yazmak]]
[[zh-CN:Wireless Setup]]
+
[[uk:Help:Editing]]
 +
[[zh-CN:Help:Editing]]
 +
[[zh-TW:Help:Editing]]
 
{{Related articles start}}
 
{{Related articles start}}
{{Related|Network Configuration}}
+
{{Related|ArchWiki:About}}
{{Related|Software Access Point}}
+
{{Related|Help:Cheatsheet}}
{{Related|Ad-hoc networking}}
+
{{Related|Help:Style}}
{{Related|Internet Sharing}}
+
{{Related|Help:Reading}}
 +
{{Related|Help:Template}}
 +
{{Related|ArchWiki:Sandbox}}
 
{{Related articles end}}
 
{{Related articles end}}
  
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.
+
ArchWiki is powered by [http://www.mediawiki.org/wiki/MediaWiki MediaWiki], a free software wiki package written in PHP, originally designed for use on Wikipedia. This is a short tutorial about editing the [[AboutWiki|ArchWiki]]. More in-depth help can be found at [http://www.mediawiki.org/wiki/Help:Contents Help:Contents on MediaWiki] and [http://en.wikipedia.org/wiki/Help:Contents Help:Contents on Wikipedia].
  
== Device driver ==
+
You must be logged-in to edit pages. Visit [[Special:UserLogin]] to log in or create an account. To experiment with editing, please use the [[sandbox]]. For an overview of wiki markup,  see [[ArchWiki Cheatsheet]]. For wiki tasks, see [[ArchWiki:Tasks]].
  
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''.
+
Before editing or creating pages, users are encouraged to familiarize themselves with the general tone, layout, and style of existing articles. An effort should be made to maintain a level of consistency throughout the wiki. See [[Help:Reading]] for an overview of common stylistic conventions. See  [[Help:Style]] for more detail.
  
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]].
+
==Editing==
  
{{Note|
+
To begin editing a page, click the '''edit''' tab at the top of the page. Alternatively, users may edit a specific section of an article by clicking the '''edit''' link to the right of  the section heading. The ''Editing'' page will be displayed, which consists of the following elements:
* Udev is not perfect. If the proper module is not loaded by udev on boot, simply [[Kernel modules#Loading|load it manually]]. Note also that udev may occasionally load more than one driver for a device, and the resulting conflict will prevent successful configuration. Make sure to [[Kernel modules#Blacklisting|blacklist]] the unwanted module.
+
* The interface name for different drivers and chipsets will vary. Some examples are {{ic|wlan0}}, {{ic|eth1}}, and {{ic|ath0}}. See also [[Network Configuration#Device names]].
+
}}
+
  
{{Tip|Though not strictly required, it's a good idea to first install user-space tools mentioned in [[#Manual setup]], especially when some problem should appear.}}
+
* Edit toolbar (optional)
 +
* Edit box
 +
* Edit summary box
 +
* ''Save page'', ''Show preview'', ''Show changes'', and ''Cancel'' links
  
=== Check the driver status ===
+
The edit box will contain the '''wikitext''' (the editable source code from which the server produces the web page) for the current revision of the page or section. To perform an edit:
  
To check if the driver for your card has been loaded, check the output of {{ic|lspci -k}} command. You should see that some kernel driver is in use, for example:
+
# Modify the wikitext as needed (see [[#Formatting]] below for details).
 +
# Explain the edit in the '''Summary''' box (e.g. "fixed typo" or "added info on xyz" (see [[Wikipedia:Help:Edit summary|Help:Edit summary]] for details)). {{Note|'''All edits should be accompanied by a descriptive summary.''' The summary allows administrators and other maintainers to easily identify controversial edits and vandalism.}}
 +
# Use the '''Show preview''' button to facilitate proofreading and verify formatting before saving.  
 +
# Mark the edit as ''[[Wikipedia:Wikipedia:Minor edit|minor]]'' by checking the '''This is a minor edit''' box if the edit is superficial and indisputable.
 +
# Save changes by clicking '''Save page'''. If unsatisfied, click '''Cancel''' instead (or repeat the process until satisfied).
  
{{hc|$ lspci -k|<nowiki>
+
{{Note|If you are not going to use an external editor like vim, you may want to consider using [https://secure.wikimedia.org/wikipedia/en/wiki/User:Cacycle/wikEd wikEd], which adds syntax highlighting, regex search and replace and other nice features to the standard MediaWiki editor. The greasemonkey script works flawlessly with the ArchWiki.}}
06:00.0 Network controller: Intel Corporation WiFi Link 5100
+
Subsystem: Intel Corporation WiFi Link 5100 AGN
+
Kernel driver in use: iwlwifi
+
Kernel modules: iwlwifi
+
</nowiki>}}
+
  
{{Note|The internal Wi-Fi card in some laptops may actually be a USB device, so you should check these commands too:
+
{{Note|Articles should '''not''' be signed because they are ''shared'' works; one editor should not be singled out above others.}}
* {{ic|lsusb -v}}
+
* {{ic|<nowiki>dmesg | grep usbcore</nowiki>}}, you should see something like {{ic|usbcore: registered new interface driver rtl8187}} in the output
+
}}
+
  
Also check the output of {{ic|ip link}} command to see if a wireless interface (e.g. {{ic|wlan0}}, {{ic|wlp2s1}}, {{ic|ath0}}) was created. Then bring the interface up with {{ic|ip link set ''interface'' up}}. For example, assuming the interface is {{ic|wlan0}}:
+
===Reverting edits===
 +
If a page was edited incorrectly, the following procedures describe how to revert an article to a previous version. To revert a single edit:
  
# ip link set wlan0 up
+
#Click the '''history''' tab at the top of the page to be modified (beside the '''edit''' tab). A list of revisions is displayed.
 +
#Click the '''undo''' link to the right of the offending edit. An edit preview is displayed, showing the current revision on the left and the text to be saved on the right.
 +
#If satisfied, click the '''Save page''' button at the bottom of the page.
  
To verify that the interface is up, inspect the output of
+
The wiki page should now be back in its original state.
  
# ip addr show
+
Occasionally, it is necessary to revert several edits at once. To revert an article to a previous version:
  
which will look something like
+
#Click the '''history''' tab at the top of the page to be modified (beside the '''edit''' tab). A list of revisions is displayed.
 +
#View the desired revision (i.e. the last ''good'' version) by clicking on the appropriate timestamp. That revision is displayed.
 +
#If satisfied, click the '''edit''' tab at the top of the page. A warning is displayed: '''You are editing an out-of-date revision of this page.''' Simply click the '''Save page''' button to revert to this version.
  
...
+
{{Note|'''Avoid combining an undo and an edit!''' Revert the edit first, then make additional changes; do not edit the revision preview.}}
3: wlp0s20u14: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state DOWN mode DORMANT group default qlen 1000
+
    link/ether 00:a4:6f:c9:79:0f brd ff:ff:ff:ff:ff:ff
+
...
+
  
The {{ic|,UP,}} in {{ic|<BROADCAST,MULTICAST,UP,LOWER_UP>}} is what indicates the interface is up, not the later {{ic|state DOWN}}.
+
==Creating pages==
 +
Before creating a new page, please consider the following:
  
If you get this error message: {{ic|SIOCSIFFLAGS: No such file or directory}}, it most certainly means that your wireless chipset requires a firmware to function.
+
# ''Is your topic relevant to Arch Linux?'' Irrelevant or unhelpful articles will be deleted.
 +
# ''Is your topic of interest to others?'' Consider not only what you wish to write about, but also what others may wish to read. Personal notes belong on your ''user'' page.
 +
# ''Is your topic worthy of a new page?'' Search the wiki for similar articles. If they exist, consider improving or adding a section to an existing article instead.
 +
# ''Will your contribution be significant?'' Avoid creating stubs unless planning to expand them shortly thereafter.
  
{{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.}}
+
Creating a new page requires selection of a descriptive '''title''' and an appropriate '''category'''.
  
Check kernel messages for firmware being loaded:
+
Please read [[Article Naming Guidelines]] and [[Writing Short Article Names]] for article naming advice.
  
{{hc|$ dmesg <nowiki>|</nowiki> grep firmware|<nowiki>
+
# Titles should be capitalized appropriately: ''Title for New Page''; not ''Title for new page''.
[  7.148259] iwlwifi 0000:02:00.0: loaded firmware version 39.30.4.1 build 35138 op_mode iwldvm
+
# Do not include "Arch Linux" or variations in page titles. This is the Arch Linux wiki; it is assumed that articles will be related to Arch Linux. (e.g., ''Installing Openbox''; not ''Installing Openbox in Arch Linux'').
</nowiki>}}
+
  
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 idenfify the relevant message or further issues:
+
Visit the [[Table of Contents]] to help choose an appropriate category. Articles may belong to multiple categories.
  
{{hc|$ dmesg <nowiki>|</nowiki> grep iwlwifi|<nowiki>
+
To add a new page to some category (say "My New Page" to "Some Category") you need to:
[  12.342694] iwlwifi 0000:02:00.0: irq 44 for MSI/MSI-X
+
[  12.353466] iwlwifi 0000:02:00.0: loaded firmware version 39.31.5.1 build 35138 op_mode iwldvm
+
[  12.430317] iwlwifi 0000:02:00.0: CONFIG_IWLWIFI_DEBUG disabled
+
...
+
[  12.430341] iwlwifi 0000:02:00.0: Detected Intel(R) Corporation WiFi Link 5100 AGN, REV=0x6B
+
</nowiki>}}
+
  
If the kernel module is successfully loaded and the interface is up, you can skip the next section.
+
# Create a page with your new title by browsing to https://wiki.archlinux.org/index.php/My_New_Page (remember to replace "My_New_Page" with the intended title!)
 +
# Add {{ic|<nowiki>[[Category:Some Category]]</nowiki>}} to the '''''top of your page'''''
  
=== Installing driver/firmware ===
+
{{Note|'''Do not create uncategorized pages!''' All pages must belong to at least one category. If you cannot find a suitable category, consider creating a new one.}}
  
Check the following lists to discover if your card is supported:
+
==Formatting==
 +
Text formatting is accomplished with wiki markup whenever possible; learning HTML is not necessary. Various templates are also available for common formatting tasks; see [[Help:Template]] for information about templates. The [[ArchWiki Cheatsheet]] summarizes the most common formatting options.
  
* 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).
+
===Headings and subheadings===
* [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.
+
Headings and subheadings are an easy way to improve the organization of an article. If you can see distinct topics being discussed, you can break up an article by inserting a heading for each section. See [[Help:Style#Section headings]] and [[Effective Use of Headers]] for style information.
* The [http://wireless.kernel.org/en/users/Devices kernel page] additionally has a matrix of supported hardware.
+
  
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.
+
Headings must start from second level, and can be created like this:
  
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|ndiswrapper]].
+
==Second-level heading==
 +
===Third-level heading===
 +
====Fourth-level heading====
 +
=====Fifth-level heading=====
 +
======Sixth-level heading======
  
== Wireless management ==
+
{{Note|First-level headings are not allowed, their formatting is reserved for the article title.}}
  
Assuming that your drivers are installed and working properly, you will need to choose a method of managing your wireless connections. The following subsections will help you decide.
+
If an article has at least four headings, a table of contents (TOC) will be automatically generated. If this is not desired, place {{ic|<nowiki>__NOTOC__</nowiki>}} in the article. Try creating some headings in the [[Sandbox]] and see the effect on the TOC.
  
Procedure and tools required will depend on several factors:
+
===Line breaks===
* The desired nature of configuration management; from a completely manual command line procedure to an automated solution with graphical front-ends.
+
An empty line is used to start a new paragraph while single line breaks have no effect in regular paragraphs.
* The encryption type (or lack thereof) which protects the wireless network.
+
* The need for network profiles, if the computer will frequently change networks (such as a laptop).
+
  
{{Tip|
+
The HTML {{ic|<nowiki><br></nowiki>}} tag can be used to manually insert line breaks, but should be avoided. A manual break may be justified with other formatting elements, such as lists.
* Whatever is your choice, '''you should try to connect using the manual method first'''. This will help you understand the different steps that are required and troubleshoot possible problems.
+
* If possible (e.g. if you manage your Wi-Fi access point), try connecting with no encryption, to check that everything works. Then try using encryption, either WEP (simple to configure, but crackable in a matter of seconds), WPA or WPA2.
+
}}
+
  
The following table shows the different methods that can be used to activate and manage a wireless connection, depending on the encryption and management types, and the various tools that are required. Although there may be other possibilities, these are the most frequently used:
+
{|border=1 width="79%" class="wikitable"
 +
!wikitext!!rendering
 +
|-
 +
|
 +
This sentence
 +
is broken into
 +
three lines.
 +
|
 +
This sentence
 +
is broken into
 +
three lines.
 +
|-
 +
|
 +
This is paragraph number one.
 +
 +
This is paragraph number two.
 +
|
 +
This is paragraph number one.
  
{| class="wikitable" border="1"
+
This is paragraph number two.
! Management method || Interface activation || Wireless connection management <br>(/=alternatives) || Assigning IP address <br>(/=alternatives)
+
 
|-
 
|-
| [[#Manual setup|Manually managed]], <br>with no or WEP encryption || [[Core Utilities#ip|ip]] || {{Pkg|iw}} / [https://www.archlinux.org/packages/?name=wireless_tools iwconfig] || [[Core Utilities#ip|ip]] / {{Pkg|dhcpcd}} / {{Pkg|dhclient}}
+
|
 +
* This point <nowiki><br></nowiki> spans multiple lines
 +
* This point
 +
ends the list
 +
|
 +
* This point <br> spans multiple lines
 +
* This point
 +
ends the list
 
|-
 
|-
| [[#Manual setup|Manually managed]], <br>with WPA or WPA2 PSK encryption || [[Core Utilities#ip|ip]] || {{Pkg|iw}} / [https://www.archlinux.org/packages/?name=wireless_tools iwconfig] + [[WPA supplicant|wpa_supplicant]] || [[Core Utilities#ip|ip]] / {{Pkg|dhcpcd}} / {{Pkg|dhclient}}
 
|-
 
| [[#Automatic setup|Automatically managed]], <br>with network profiles support || colspan="3" align="center" | [[netctl]], [[Wicd]], [[NetworkManager]], etc.<br>
 
These tools pull in the required dependencies from the list of packages in the manual method.
 
 
|}
 
|}
  
=== Manual setup ===
+
See [[Help:Style#Blank_lines]] for information on the use of blank lines.
 
+
Just like other network interfaces, the wireless ones are controlled with {{ic|ip}} from the {{Pkg|iproute2}} package. The package {{Pkg|wireless_tools}} then provides a basic set of tools for managing the wireless connection, however, these tools are deprecated in favor of the {{Pkg|iw}} tool. If ''iw'' does not work with your card, you can use ''wireless_tools'', the table below gives an overview of comparable commands with both (see [http://wireless.kernel.org/en/users/Documentation/iw/replace-iwconfig] for more examples). Additionally, the {{Pkg|wpa_supplicant}} package is required for WPA/WPA2 encryption. These powerful user-space tools work extremely well and allow complete manual control of wireless connection.
+
 
+
{{Note|
+
* Examples in this section assume that your wireless device is {{ic|wlan0}} and that you are connecting to {{ic|''your_essid''}} wifi access point. Replace both accordingly.
+
* 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. ''iwlist''), will exit without error but not produce the correct output either, which can be confusing.
+
}}
+
  
{| class="wikitable" border="1"
+
===Bold and italics===
! ''iw'' command
+
'''Bold''' and ''italics'' are added by surrounding a word or phrase with two, three or five apostrophes ({{ic|'}}):
! ''wireless_tools'' command
+
{|border=1 width="79%" class="wikitable"
! Description
+
!wikitext!!rendering
 
|-
 
|-
| iw dev wlan0 link
+
|
| iwconfig wlan0
+
{{ic|<nowiki>''italics''</nowiki>}}
| Getting link status.
+
|
 +
''italics''
 
|-
 
|-
| iw dev wlan0 scan
+
|
| iwlist wlan0 scan
+
{{ic|<nowiki>'''bold'''</nowiki>}}
| Scanning for available access points.
+
|
 +
'''bold'''
 
|-
 
|-
| iw dev wlan0 set type ibss
+
|
| iwconfig wlan0 mode ad-hoc
+
{{ic|<nowiki>'''''bold and italics'''''</nowiki>}}
| Setting the operation mode to ''ad-hoc''.
+
|
 +
'''''bold and italics'''''
 
|-
 
|-
| iw dev wlan0 connect ''your_essid''
+
|}
| iwconfig wlan0 essid ''your_essid''
+
 
| Connecting to open network.
+
===Strike-out===
|-
+
Use strike-out text to show that the text no longer applies or has relevance.
| iw dev wlan0 connect ''your_essid'' 2432
+
 
| iwconfig wlan0 essid ''your_essid'' freq 2432M
+
{|border=1 width="79%" class="wikitable"
| Connecting to open network specifying channel.
+
!wikitext!!rendering
|-
+
| iw dev wlan0 connect ''your_essid'' key 0:''your_key''
+
| iwconfig wlan0 essid ''your_essid'' key ''your_key''
+
| Connecting to WEP encrypted network using hexadecimal key.
+
 
|-
 
|-
| iw dev wlan0 connect ''your_essid'' key 0:''your_key''
+
|
| iwconfig wlan0 essid ''your_essid'' key s:''your_key''
+
{{bc|<nowiki><s>Strike-out text</s></nowiki>}}
| Connecting to WEP encrypted network using ASCII key.
+
|
 +
<s>Strike-out text</s>
 
|-
 
|-
| iw dev wlan0 set power_save on
 
| iwconfig wlan0 power on
 
| Enabling power save.
 
 
|}
 
|}
  
{{Note|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 [[#Association]].}}
+
===Indenting===
 +
{{Note|Indenting should only be used for discussion pages, see [http://en.wikipedia.org/wiki/Wikipedia:Indentation Wikipedia:Indentation]}}
  
==== Getting some useful information ====
+
To indent text, place a colon ({{ic|:}}) at the beginning of a line. The more colons you put, the further indented the text will be. A newline marks the end of the indented paragraph.
  
{{Tip|See [http://wireless.kernel.org/en/users/Documentation/iw official documentation] of the ''iw'' tool for more examples.}}
+
{|border=1 width="79%" class="wikitable"
 +
!wikitext!!rendering
 +
|-
 +
|
 +
This is not indented at all.
 +
:This is indented slightly.
 +
::This is indented more.
 +
|
 +
This is not indented at all.
 +
:This is indented slightly.
 +
::This is indented more.
 +
|-
 +
|}
 +
=== Lists ===
  
* First you need to find the name of wireless interface. You can do it with following command:
+
====Bullet points====
 +
Bullet points have no apparent order of items.
 +
To insert a bullet, use an asterisk ({{ic|*}}). Multiple {{ic|*}}s will increase the level of indentation.
  
{{hc|$ iw dev|
+
{|border=1 width="79%" class="wikitable"
phy#0
+
!wikitext!!rendering
Interface '''wlan0'''
+
|-
ifindex 3
+
|
wdev 0x1
+
* First item
addr 12:34:56:78:9a:bc
+
* Second item
type managed
+
** Sub-item
channel 1 (2412 MHz), width: 40 MHz, center1: 2422 MHz
+
* Third item
}}
+
|
 +
* First item
 +
* Second item
 +
** Sub-item
 +
* Third item
 +
|-
 +
|}
  
* To check link status, use following command. Example output when not connected to an AP:
+
====Numbered lists====
 +
Numbered lists introduce numbering and thus order the list items. You should generally use unordered lists as long as the order in which items appear is not the primary concern.
 +
To create numbered lists, use the number sign or hash symbol ({{ic|#}}). Multiple {{ic|#}}s will increase the level of indentation.
  
{{hc|$ iw dev wlan0 link|
+
{|border=1 width="79%" class="wikitable"
Not connected.
+
!wikitext!!rendering
}}
+
|-
 +
|
 +
# First item
 +
# Second item
 +
## Sub-item
 +
# Third item
 +
|
 +
# First item
 +
# Second item
 +
## Sub-item
 +
# Third item
 +
|-
 +
|
 +
# First item
 +
# Second item
 +
#* Sub-item
 +
# Third item
 +
|
 +
# First item
 +
# Second item
 +
#* Sub-item
 +
# Third item
 +
|-
 +
|}
  
When connected to an AP, you will see something like:
+
====Definition lists====
 
+
Definition lists are defined with a leading semicolon ({{ic|;}}) and a colon ({{ic|:}}) following the term.  
{{hc|$ iw dev wlan0 link|
+
Connected to 12:34:56:78:9a:bc (on wlan0)
+
SSID: MyESSID
+
freq: 2412
+
RX: 33016518 bytes (152703 packets)
+
TX: 2024638 bytes (11477 packets)
+
signal: -53 dBm
+
tx bitrate: 150.0 MBit/s MCS 7 40MHz short GI
+
 
+
bss flags: short-preamble short-slot-time
+
dtim period: 1
+
beacon int: 100
+
}}
+
 
+
* You can get statistic information, such as the amount of tx/rx bytes, signal strength etc., with following command:
+
 
+
{{hc|$ iw dev wlan0 station dump|
+
Station 12:34:56:78:9a:bc (on wlan0)
+
inactive time: 1450 ms
+
rx bytes: 24668671
+
rx packets: 114373
+
tx bytes: 1606991
+
tx packets: 8557
+
tx retries: 623
+
tx failed: 1425
+
signal:  -52 dBm
+
signal avg: -53 dBm
+
tx bitrate: 150.0 MBit/s MCS 7 40MHz short GI
+
authorized: yes
+
authenticated: yes
+
preamble: long
+
WMM/WME: yes
+
MFP: no
+
TDLS peer: no
+
}}
+
 
+
 
+
==== Interface activation ====
+
 
+
''(Optional, but may be required)''
+
 
+
Some cards require that the kernel interface be activated before you can use the ''iw'' tool or ''wireless_tools'':
+
 
+
# ip link set wlan0 up
+
 
+
For details, see [[#Device driver|Device driver]]
+
 
+
 
+
==== Access point discovery ====
+
 
+
See what access points are available:
+
 
+
# iw dev wlan0 scan | less
+
 
+
{{Note|If it displays {{ic|Interface doesn't support scanning}}, then you probably forgot to install the firmware. In some cases this message is also displayed when not running ''iw'' as root.}}
+
 
+
The important points to check:
+
* '''SSID:''' the name of the network.
+
* '''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.
+
* '''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.
+
** If you see an {{ic|RSN}} information block, then the network is protected by [[Wikipedia:Robust Security Network|Robust Security Network]] protocol, also known as WPA2.
+
** If you see an {{ic|WPA}} information block, then the network is protected by [[Wikipedia:Wi-Fi Protected Access|Wi-Fi Protected Access]] protocol.
+
** In the {{ic|RSN}} and {{ic|WPA}} blocks you may find the following information:
+
*** '''Group cipher:''' value in TKIP, CCMP, both, others.
+
*** '''Pairwise ciphers:''' value in TKIP, CCMP, both, others. Not necessarily the same value than Group cipher.
+
*** '''Authentication suites:''' value in PSK, 802.1x, others. For home router, you'll 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). Find more details at [[Wikipedia:Authentication protocol]] and the sub-articles.
+
** If you do not see neither {{ic|RSN}} nor {{ic|WPA}} blocks but there is {{ic|Privacy}}, then WEP is used.
+
 
+
==== Operating mode ====
+
 
+
''(Optional, but may be required)''
+
 
+
At this step 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}}:
+
 
+
# iw dev wlan0 set type ibss
+
 
+
{{Note|Changing the operating mode on some cards might require the wireless interface to be ''down'' ({{ic|ip link set wlan0 down}}).}}
+
 
+
==== Association ====
+
 
+
Depending on the encryption, you need to associate your wireless device with the access point to use and pass the encryption key.
+
 
+
* '''No encryption'''
+
 
+
# iw dev wlan0 connect ''your_essid''
+
 
+
* '''WEP'''
+
 
+
using a hexadecimal or ASCII key (the format is distinguished automatically, because a WEP key has a fixed length):
+
 
+
# iw dev wlan0 connect ''your_essid'' key 0:''your_key''
+
 
+
using a hexadecimal or ASCII key, specifying the third set up key as default (keys are counted from zero, four are possible):
+
 
+
# iw dev wlan0 connect ''your_essid'' key d:2:''your_key''
+
 
+
* '''WPA/WPA2'''
+
 
+
You need to edit the {{ic|/etc/wpa_supplicant.conf}} file as described in [[WPA_Supplicant]] and according to what you got from [[#Access point discovery]]. Then, issue this command:
+
 
+
# wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf
+
 
+
This is assuming your device uses the {{ic|wext}} driver. If this does not work, you may need to adjust these options.
+
If connected successfully, continue in a new terminal (or quit {{ic|wpa_supplicant}} with {{ic|Ctrl+c}} and add the {{ic|-B}} switch to the above command to run it in the background). [[WPA_Supplicant]] contains more information and troubleshooting.
+
 
+
Regardless of the method used, you can check if you have associated successfully:
+
 
+
# iw dev wlan0 link
+
 
+
==== Getting an IP address ====
+
 
+
{{Note|See [[Network Configuration#Configure the IP address]] for more examples. This part is identical.}}
+
 
+
Finally, provide an IP address to the network interface. Simple examples are:
+
 
+
# dhcpcd wlan0
+
  
 +
{|border=1 width="79%" class="wikitable"
 +
!wikitext!!rendering
 +
|-
 +
|
 +
Definition lists:
 +
; Keyboard: Input device with buttons or keys
 +
; Mouse: Pointing device for two-dimensional input
 +
or
 +
; Keyboard
 +
: Input device with buttons or keys
 +
; Mouse
 +
: Pointing device for two-dimensional input
 +
|
 +
Definition lists:
 +
; Keyboard: Input device with buttons or keys
 +
; Mouse: Pointing device for two-dimensional input
 
or
 
or
 +
; Keyboard
 +
: Input device with buttons or keys
 +
; Mouse
 +
: Pointing device for two-dimensional input
 +
|-
 +
|
 +
Use additional colons if a definition has multiple definitions:
 +
; Term
 +
: First definition
 +
: Second definition
 +
|
 +
Use additional colons if a definition has multiple definitions:
 +
; Term
 +
: First definition
 +
: Second definition
 +
|-
 +
|}
  
# dhclient wlan0
+
Definition lists must not be simply used for formatting, see [http://www.w3.org/TR/html4/struct/lists.html#edef-DL W3's examples].
  
for DHCP, or
+
===Code===
 +
To add code to the wiki, use one of the [[Help:Template#Code formatting templates|code formatting templates]]. Alternatively, simply start each line with a single whitespace character.
  
# ip addr add 192.168.0.2/24 dev wlan0
+
See [[Help:Style#Code formatting templates]].
# ip route add default via 192.168.0.1
+
  
for static IP addressing.
+
===Tables===
 +
Used effectively, tables can help organize and summarize swaths of data. For advanced table syntax and formatting see [[Wikipedia:Help:Table|Help:Table]].
  
{{Tip|{{Pkg|dhcpcd}} contains a hook (enabled by default) to automatically launch [[WPA supplicant]] on wireless interfaces. It is started only if a configuration file at {{ic|/etc/wpa_supplicant.conf}} exists and no ''wpa_supplicant'' process is listening on that interface. In most cases, you do not need to create any [[#Manual wireless connection at boot using systemd and dhcpcd|custom service]], just enable {{ic|dhcpcd@''interface''}}.}}
+
{|border=1 width="79%" class="wikitable"
 
+
!wikitext!!rendering
==== Custom startup scripts/services ====
+
|-
 
+
|
Although the manual configuration method will help troubleshoot wireless problems, you will have to re-type every command each time you reboot. You can also quickly write a shell script to automate the whole process, which is still a quite convenient way of managing network connection while keeping full control over your configuration. You can find some examples in this section.
+
{{bc|<nowiki>
 
+
{| border="1"
===== Manual wireless connection at boot using systemd and dhcpcd =====
+
|+ Tabular data
 
+
! Distro !! Color
This example uses [[systemd]] for start up, [[WPA supplicant]] for connecting, and {{Pkg|dhcpcd}} for assigning an IP address.
+
|-
 
+
| Arch || Blue
{{Note|Make sure that {{Pkg|wpa_supplicant}} is installed and create {{ic|/etc/wpa_supplicant.conf}}. See [[WPA supplicant]] for details.}}
+
|-
 
+
| Gentoo || Purple
Create a systemd unit, e.g {{ic|/etc/systemd/system/network-wireless@.service}}:
+
|-
 
+
| Ubuntu || Orange
{{hc|/etc/systemd/system/network-wireless@.service|<nowiki>
+
|}
[Unit]
+
Description=Wireless network connectivity (%i)
+
Wants=network.target
+
Before=network.target
+
BindsTo=sys-subsystem-net-devices-%i.device
+
After=sys-subsystem-net-devices-%i.device
+
 
+
[Service]
+
Type=oneshot
+
RemainAfterExit=yes
+
 
+
ExecStart=/usr/bin/ip link set dev %i up
+
ExecStart=/usr/bin/wpa_supplicant -B -i %i -c /etc/wpa_supplicant.conf
+
ExecStart=/usr/bin/dhcpcd %i
+
 
+
ExecStop=/usr/bin/ip link set dev %i down
+
 
+
[Install]
+
WantedBy=multi-user.target
+
 
</nowiki>}}
 
</nowiki>}}
 
+
|
Enable the unit and start it, passing the name of the interface:
+
{| border="1"
 
+
|+ Tabular data
# systemctl enable network-wireless@wlan0.service
+
! Distro !! Color
# systemctl start network-wireless@wlan0.service
+
 
+
===== Systemd with wpa_supplicant and static IP =====
+
 
+
{{Note|Make sure that {{Pkg|wpa_supplicant}} is installed and create {{ic|/etc/wpa_supplicant.conf}}. See [[WPA supplicant]] for details.}}
+
 
+
First create configuration file for the [[systemd]] service, replace {{ic|''interface''}} with proper interface name:
+
 
+
{{hc|/etc/conf.d/network-wireless@''interface''|<nowiki>
+
address=192.168.0.10
+
netmask=24
+
broadcast=192.168.0.255
+
gateway=192.168.0.1
+
</nowiki>}}
+
 
+
Create a systemd unit file:
+
 
+
{{hc|/etc/systemd/system/network-wireless@.service|<nowiki>
+
[Unit]
+
Description=Wireless network connectivity (%i)
+
Wants=network.target
+
Before=network.target
+
BindsTo=sys-subsystem-net-devices-%i.device
+
After=sys-subsystem-net-devices-%i.device
+
 
+
[Service]
+
Type=oneshot
+
RemainAfterExit=yes
+
EnvironmentFile=/etc/conf.d/network-wireless@%i
+
 
+
ExecStart=/usr/bin/ip link set dev %i up
+
ExecStart=/usr/bin/wpa_supplicant -B -i %i -c /etc/wpa_supplicant.conf
+
ExecStart=/usr/bin/ip addr add ${address}/${netmask} broadcast ${broadcast} dev %i
+
ExecStart=/usr/bin/ip route add default via ${gateway}
+
 
+
ExecStop=/usr/bin/ip addr flush dev %i
+
ExecStop=/usr/bin/ip link set dev %i down
+
 
+
[Install]
+
WantedBy=multi-user.target
+
</nowiki>}}
+
 
+
Enable the unit and start it, passing the name of the interface:
+
 
+
# systemctl enable network-wireless@wlan0.service
+
# systemctl start network-wireless@wlan0.service
+
 
+
=== Automatic setup ===
+
 
+
There are many solutions to choose from, but remember that all of them are mutually exclusive; you should not run two daemons simultaneously. The following table compares the different connection managers, additional notes are in subsections below.
+
 
+
{| class="wikitable" border="1"
+
! Connection manager || Network <br>profiles <br>support || Roaming <br>(auto connect dropped <br>or changed location) || [[Wikipedia:point-to-point protocol|PPP]] support <br>(e.g. 3G modem) || Official <br>GUI || Console tools
+
 
|-
 
|-
| [[Connman]] || Yes || Yes || Yes || No || {{ic|connmanctl}}
+
| Arch || Blue
 
|-
 
|-
| [[Netctl]] || Yes || Yes || Yes || No || {{ic|netctl}},{{ic|wifi-menu}}
+
| Gentoo || Purple
 
|-
 
|-
| [[NetworkManager]] || Yes || Yes || Yes || Yes || {{ic|nmcli}}
+
| Ubuntu || Orange
 +
|}
 +
|-
 +
|
 +
{{bc|<nowiki>{| class="wikitable" border="1" cellpadding="5" cellspacing="0"
 +
! Filesystem !! Size !! Used !! Avail !! Use% !! Mounted on
 +
|-
 +
| rootfs || 922G || 463G || 413G || 53% || /
 +
|-
 +
| /dev || 1.9G || 0 || 1.9G || 0% || /dev
 +
|}</nowiki>}}
 +
|
 +
{| class="wikitable" border="1" cellpadding="5" cellspacing="0"
 +
! Filesystem !! Size !! Used !! Avail !! Use% !! Mounted on
 +
|-
 +
| rootfs || 922G || 463G || 413G || 53% || /
 +
|-
 +
| /dev || 1.9G || 0 || 1.9G || 0% || /dev
 +
|}
 
|-
 
|-
| [[Wicd]] || Yes || Yes || No || Yes || {{ic|wicd-curses}}
 
 
|}
 
|}
  
==== Netctl ====
+
==Links==
 
+
Links are essential to help readers navigate the site. In general, editors should ensure that every article contains ''outgoing'' links to other articles (avoid [[Special:DeadendPages|dead-end pages]]) and is referenced by ''incoming'' links from other articles (the [[Special:WhatLinksHere|what links here]] special page can be used to display incoming links).
''netctl'' is a replacement for ''netcfg'' designed to work with systemd. It uses a profile based setup and is capable of detection and connection to a wide range of network types. This is no harder than using graphical tools.
+
 
+
See: [[Netctl]]
+
 
+
==== Wicd ====
+
 
+
Wicd is a network manager that can handle both wireless and wired connections. It is written in Python and Gtk with fewer dependencies than NetworkManager, making it an ideal solution for lightweight desktop users. Wicd is available in the [[Official Repositories|official repositories]].
+
 
+
See: [[Wicd]]
+
 
+
{{Note|[[wicd]] may cause excessive dropped connections with some drivers, while [[NetworkManager]] might work better.}}
+
 
+
==== NetworkManager ====
+
 
+
NetworkManager is an advanced network management tool that is enabled by default in most popular GNU/Linux distributions. In addition to managing wired connections, NetworkManager provides worry-free wireless roaming with an easy-to-use GUI program for selecting your desired network.
+
 
+
See: [[NetworkManager]]
+
 
+
{{Note|GNOME's {{Pkg|network-manager-applet}} also works under [[Xfce]] if you install {{AUR|xfce4-xfapplet-plugin}} (available in the [[Arch User Repository|AUR]]) first. Additionally, there are applets available for [[KDE]].}}
+
 
+
==== WiFi Radar ====
+
 
+
WiFi Radar is a Python/PyGTK2 utility for managing wireless (and '''only''' wireless) profiles. It enables you to scan for available networks and create profiles for your preferred networks.
+
 
+
See: [[Wifi Radar]]
+
 
+
== Troubleshooting ==
+
 
+
This section contains general troubleshooting tips, not strictly related to problems with drivers or firmware. For such topics, see next section.
+
 
+
{{Out of date|Commands in following subsections need updating according to [[ArchWiki:Requests#wireless_tools_-.3E_iw|wireless_tools -> iw]] transition.}}
+
 
+
=== Rfkill caveat ===
+
 
+
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 {{Pkg|rfkill}}. Use ''rfkill'' to show the current status:
+
 
+
{{hc|# rfkill list|
+
0: phy0: Wireless LAN
+
Soft blocked: yes
+
Hard blocked: yes
+
}}
+
 
+
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:
+
 
+
# rfkill unblock wifi
+
 
+
{{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 modules|kernel module]].}}
+
 
+
More info: http://askubuntu.com/questions/62166/siocsifflags-operation-not-possible-due-to-rf-kill
+
 
+
=== Observing Logs ===
+
 
+
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
+
$ dmesg -w
+
while performing the action, e.g. the wireless association attempt.
+
 
+
When using a tool for network management, the same can be done for systemd with
+
# journalctl -f
+
 
+
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.
+
 
+
=== Power saving ===
+
 
+
See [[Power saving#Network interfaces]].
+
 
+
=== Failed to get IP address ===
+
 
+
* 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 your [[#Automatic setup|connection manager]]!
+
 
+
* 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 features:
+
 
+
# iwconfig wlan0 power off
+
 
+
* 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:
+
 
+
# iwconfig wlan0 channel auto
+
 
+
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.
+
 
+
=== Connection always times out ===
+
 
+
The driver may suffer from a lot of tx excessive retries and invalid misc errors for some unknown reason, resulting in a lot of packet loss and keep disconnecting, sometimes instantly. Following tips might be helpful.
+
 
+
==== Lowering the rate ====
+
 
+
Try setting lower rate, for example 5.5M:
+
 
+
# iwconfig wlan0 rate 5.5M auto
+
 
+
Fixed option should ensure that the driver does not change the rate on its own, thus making the connection a bit more stable:
+
 
+
# iwconfig wlan0 rate 5.5M fixed
+
 
+
==== Lowering the txpower ====
+
 
+
You can try lowering the transmit power as well. This may save power as well:
+
 
+
# iwconfig wlan0 txpower 5
+
 
+
Valid settings are from {{ic|0}} to {{ic|20}}, {{ic|auto}} and {{ic|off}}.
+
 
+
==== Setting rts and fragmentation thresholds ====
+
 
+
Default iwconfig options have rts and fragmentation thresholds off. These options are particularly useful when there are many adjacent APs or in a noisy environment.
+
 
+
The minimum value for fragmentation value is 256 and maximum is 2346. In many windows drivers the maximum is the default value:
+
 
+
# iwconfig wlan0 frag 2346
+
 
+
For rts minimum is 0, maximum is 2347. Once again windows drivers often use maximum as the default:
+
 
+
# iwconfig wlan0 rts 2347
+
 
+
=== Random disconnections ===
+
 
+
==== Cause #1 ====
+
 
+
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[http://us.generation-nt.com/answer/gentoo-user-wireless-deauthenticating-by-local-choice-help-204640041.html]. Try disabling the wireless card's power-saving features:
+
 
+
# iwconfig wlan0 power off
+
 
+
See [[Power saving]] for tips on how to make it permanent (just specify {{ic|off}} instead of {{ic|on}}).
+
 
+
If your card does not support {{ic|iwconfig wlan0 power off}}, check the '''BIOS''' for power management options. Disabling PCI-Express power management in the BIOS of a Lenovo W520 resolved this issue.
+
 
+
==== Cause #2 ====
+
 
+
If you are experiencing frequent disconnections and dmesg shows messages such as
+
 
+
{{ic|1=ieee80211 phy0: wlan0: No probe response from AP xx:xx:xx:xx:xx:xx after 500ms, disconnecting}}
+
 
+
try changing the channel bandwidth to {{ic|20MHz}} through your router's settings page.
+
 
+
== Troubleshooting drivers and firmware ==
+
 
+
This section covers methods and procedures for installing kernel modules and ''firmware'' for specific chipsets, that differ from generic method.
+
 
+
See [[Kernel modules]] for general informations on operations with modules.
+
 
+
=== Ralink ===
+
 
+
==== rt2x00 ====
+
 
+
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.
+
 
+
A list of devices supported by the modules is available at the project's [http://rt2x00.serialmonkey.com/wiki/index.php/Hardware homepage].
+
 
+
; Additional notes
+
* Since kernel 3.0, rt2x00 includes also these drivers: {{ic|rt2800pci}}, {{ic|rt2800usb}}.
+
* 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>.
+
* 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] available from Ralink.
+
 
+
==== rt3090 ====
+
 
+
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's not possible to use higher rate than 2Mb/s).
+
 
+
The best way is to use the {{AUR|rt3090}} driver from [[AUR]]. Make sure to [[Kernel modules#Blacklisting|blacklist]] the {{ic|rt2800pci}} module and setup the {{ic|rt3090sta}} module to [[Kernel modules#Loading|load]] at boot.
+
 
+
{{Note|This driver also works with rt3062 chipsets.}}
+
 
+
==== rt3290 ====
+
 
+
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].
+
 
+
==== rt3573 ====
+
 
+
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.
+
 
+
==== rt5572 ====
+
 
+
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].
+
 
+
=== Realtek ===
+
 
+
==== rtl8192cu ====
+
 
+
The driver is now in the kernel, but many users have reported being unable to make a connection although scanning for networks does work.
+
 
+
The {{AUR|dkms-8192cu}} package in the AUR may be a better choice for some users.
+
 
+
==== rtl8192e ====
+
 
+
The driver is part of the current kernel package. The module initialization may fail at boot giving this error message:
+
 
+
rtl819xE:ERR in CPUcheck_firmware_ready()
+
rtl819xE:ERR in init_firmware() step 2
+
rtl819xE:ERR!!! _rtl8192_up(): initialization is failed!
+
r8169 0000:03:00.0: eth0: link down
+
 
+
A workaround is to simply unload the module:
+
# modprobe -r r8192e_pci
+
and reload the module (after a pause):
+
# modprobe r8192e_pci
+
 
+
==== rtl8188eu ====
+
 
+
Some dongles, like the TP-Link TL-WN725N v2 (not sure, but it seems that uses the rtl8179 chipset), use chipsets compatible with this driver. In order to use it you have to install the {{AUR|dkms-8188eu}} package in the AUR.
+
 
+
=== Atheros ===
+
 
+
The [http://madwifi-project.org/ MadWifi team] currently maintains three different drivers for devices with Atheros chipset:
+
 
+
* {{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>.
+
* {{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)
+
* {{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.
+
 
+
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.
+
 
+
==== ath5k ====
+
 
+
External resources:
+
* http://wireless.kernel.org/en/users/Drivers/ath5k
+
* http://wiki.debian.org/ath5k
+
 
+
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#Options]] for details.
+
 
+
Some laptops may have problems with their wireless LED indicator flickering red and blue. To solve this problem, do:
+
 
+
# echo none > /sys/class/leds/ath5k-phy0::tx/trigger
+
# echo none > /sys/class/leds/ath5k-phy0::rx/trigger
+
 
+
For alternatives, see [https://bugzilla.redhat.com/show_bug.cgi?id=618232 this bug report].
+
 
+
==== ath9k ====
+
 
+
External resources:
+
* http://wireless.kernel.org/en/users/Drivers/ath9k
+
* http://wiki.debian.org/ath9k
+
 
+
In the unlikely event that you have stability issues that trouble you, you could try using the [http://wireless.kernel.org/en/users/Download compat-wireless] package.
+
An [https://lists.ath9k.org/mailman/listinfo/ath9k-devel ath9k mailing list] exists for support and development related discussions.
+
 
+
===== ASUS =====
+
 
+
With some ASUS laptops (tested with ASUS U32U series), it could help to add {{ic|1=options asus_nb_wmi wapf=1}} to {{ic|/etc/modprobe.d/asus_nb_wmi.conf}} to fix rfkill-related issues.
+
 
+
=== Intel ===
+
 
+
==== ipw2100 and ipw2200 ====
+
 
+
These modules are fully supported in the kernel, but they require additional firmware. Depending on which of the chipsets you have, [[pacman|install]] either {{Pkg|ipw2100-fw}} or {{Pkg|ipw2200-fw}}. Then [[Kernel modules#Manual module handling|reload]] the appropriate module.
+
 
+
{{Tip|You may use the following [[Kernel modules#Setting module options|module options]]:
+
* use the {{ic|1=rtap_iface=1}} option to enable the radiotap interface
+
* use the {{ic|1=led=1}} option to enable a front LED indicating when the wireless is connected or not
+
}}
+
 
+
==== iwlegacy ====
+
 
+
[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.
+
 
+
[[udev]] should load the driver automatically, otherwise load {{ic|iwl3945}} or {{ic|iwl4965}} manually. See [[Kernel modules#Loading]] for details.
+
 
+
==== iwlwifi ====
+
 
+
[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.
+
 
+
If you have problems connecting to networks in general or your link quality is very poor, try to disable 802.11n and enable software encryption:
+
 
+
{{hc|/etc/modprobe.d/iwlwifi.conf|<nowiki>options iwlwifi 11n_disable=1
+
options iwlwifi swcrypto=1</nowiki>}}
+
 
+
==== Disabling LED blink ====
+
 
+
{{Note|This works with the {{ic|iwlegacy}} and {{ic|iwlwifi}} drivers.}}
+
 
+
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]]:
+
 
+
{{hc|/etc/tmpfiles.d/phy0-led.conf|
+
w /sys/class/leds/phy0-led/trigger - - - - phy0radio
+
}}
+
 
+
Run {{ic|systemd-tmpfiles --create phy0-led.conf}} for the change to take effect, or reboot.
+
 
+
To see all the possible trigger values for this LED:
+
 
+
# cat /sys/class/leds/phy0-led/trigger
+
 
+
{{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.}}
+
 
+
==== Other Notes ====
+
 
+
* By default, {{ic|iwl3945}} is configured to only work with networks on channels 1-11. Higher frequency bands are not allowed in some parts of the world (e.g. the US). In the EU however, channels 12 and 13 are used quite commonly (and Japan allows for channel 14). To make {{ic|iwl3945}} scan for all channels, add {{ic|1=options cfg80211 ieee80211_regdom=EU}} to {{ic|/etc/modprobe.d/modprobe.conf}}. With {{ic|iwlist frequency}} you can check which channels are allowed.
+
* If you want to enable more channels on Intel Wifi 5100 (and quite possible other cards too), you can do that with the {{Pkg|crda}} package. After installing the package, edit {{ic|/etc/conf.d/wireless-regdom}} and uncomment the line where your country code is found. When executing {{ic|iwlist wlan0 channel}}, you should now have access to more channels (depending on your location).
+
  
=== Broadcom ===
+
===Internal links===
 +
You can extensively cross-reference wiki pages using internal links. You can add links to existing titles, and also to titles you think ought to exist in future.
  
See [[Broadcom wireless]].
+
To make a link to another page on the same wiki, just put the title in double square brackets.
  
=== Other drivers/devices ===
+
For example, if you want to make a link to, say, the [[pacman]] article, use:
 +
<nowiki>[[pacman]]</nowiki>
  
==== Tenda w322u ====
+
If you want to use words other than the article title as the text of the link, you can add an alternative name after the pipe "|" divider ({{ic|Shift}} + {{ic|\}} on English-layout and similar keyboards).
  
Treat this Tenda card as an {{ic|rt2870sta}} device. See [[#rt2x00]].
+
For example:
 +
View <nowiki>[[Arch Linux|this]]</nowiki> article...
  
==== orinoco ====
+
...is rendered as:
 +
:View [[Arch Linux|this]] article...
  
This should be a part of the kernel package and be installed already.
+
When you want to use the plural of an article title (or add any other suffix) for your link, you can add the extra letters directly outside the double square brackets.
  
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, [[Kernel modules#Blacklisting|blacklist]] {{ic|orinoco_cs}} first.
+
For example:
 +
makepkg is used in conjunction with <nowiki>[[PKGBUILD]]s</nowiki>.
  
==== prism54 ====
+
...is rendered as:
 +
:makepkg is used in conjunction with [[PKGBUILD]]s.
  
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.
+
====Links to sections of a document====
 +
To create a link to a section of a document, simply add a {{ic|#}} followed by the section's heading.
  
{{Note|There's also older, deprecated driver {{ic|prism54}}, which might conflict with the newer driver ({{ic|p54pci}} or {{ic|p54usb}}). Make sure to [[Kernel modules#Blacklisting|blacklist]] {{ic|prism54}}.}}
+
For example:
 +
<nowiki>[[Help:Editing#Links to sections of a document]]</nowiki>
  
==== ACX100/111 ====
+
...is rendered as:
 +
:[[Help:Editing#Links to sections of a document]]
  
{{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.}}
+
{{Tip|If linking to a section within the same page, the page name can be omitted (e.g. {{ic|<nowiki>[[#Links to sections of a document]]</nowiki>}}). Do not needlessly reformat same-page section links to hide the anchor symbol (e.g. {{ic|<nowiki>[[#Links to sections of a document|Links to sections of a document]]</nowiki>}}).}}
  
Packages: {{ic|tiacx}} {{ic|tiacx-firmware}} (deleted from official repositories and AUR)
+
===Interlanguage links===
 +
See [[Help:i18n#Interlanguage links]]
  
See [http://sourceforge.net/apps/mediawiki/acx100/index.php?title=Main_Page official wiki] for details.
+
===Interwiki links===
 +
So-called ''interwiki links'' can be used to easily link to articles in other external Wikis, like Wikipedia for example. The syntax for for this link type is the wiki name followed by a colon and the article you want to link to enclosed in double square brackets.
  
==== zd1211rw ====
+
If you want to link to the [[Wikipedia:Arch Linux]] article you can use the following:
 +
<nowiki>[[Wikipedia:Arch Linux]]</nowiki>
  
[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 [[pacman|install]] the firmware for the device, provided by the {{Pkg|zd1211-firmware}} package.
+
Or you can create a piped link with an alternate link label to the [[Wikipedia:Arch Linux|Arch Linux Wikipedia article]]:
 +
<nowiki>[[Wikipedia:Arch Linux|Arch Linux Wikipedia article]]</nowiki>
  
==== hostap_cs ====
+
{{Note|Using a piped link with an alternative link label should be reserved for abbreviating longer URLs.}}
  
[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.
+
See: [[Wikipedia:InterWikimedia links]]
  
{{Note|Make sure to [[Kernel_modules#Blacklisting|blacklist]] the {{ic|orinico_cs}} driver, it may cause problems.}}
+
===External links===
 +
If you want to link to an external site, just type the full URL for the page you want to link to.
 +
<nowiki>http://www.google.com/</nowiki>
  
=== ndiswrapper ===
+
It is often more useful to make the link display something other than the URL, so use one square bracket at each end, with the alternative title after the address separated by a '''space''' (''not'' a pipe). So if you want the link to appear as [http://www.google.com/ Google search engine], just type:
 +
<nowiki>[http://www.google.com/ Google search engine]</nowiki>
  
Ndiswrapper is a wrapper script that allows you to use some Windows drivers in Linux. See the compatibility list [http://ndiswrapper.sourceforge.net/mediawiki/index.php/List here]. You will need the {{ic|.inf}} and {{ic|.sys}} files from your Windows driver. Be sure to use drivers appropriate to your architecture (x86 vs. x86_64).
+
{{Note|If linking to another ArchWiki or Wikipedia page, '''use [[#Internal links]] or [[#Interwiki links]] rather than external links!''' That is, if your link starts with https://wiki.archlinux.org/ '''use an internal link;''' if your link starts with http://en.wikipedia.org/ '''use an interwiki link!'''}}
  
{{Tip|If you need to extract these files from an {{ic|*.exe}} file, you can use {{Pkg|cabextract}}.}}
+
==Redirects==
 +
To redirect automatically from one page to another, add {{ic|<nowiki>#REDIRECT</nowiki>}} and an internal link to the page to be redirected to at the beginning of a page.  
  
Follow these steps to configure ndiswrapper.
+
For example, you could redirect from "Cats" to "Cat":
 +
<nowiki>#REDIRECT [[Cat]]</nowiki>
  
1. Install the driver to {{ic|/etc/ndiswrapper/*}}
+
Thus, anyone typing either version in the search box will automatically go to "Cat".
# ndiswrapper -i filename.inf
+
2. List all installed drivers for ndiswrapper
+
$ ndiswrapper -l
+
3. Write the following configuration file:
+
{{hc|/etc/modprobe.d/ndiswrapper.conf|
+
ndiswrapper -m
+
depmod -a
+
}}
+
  
Now the ndiswrapper install is almost finished; follow the instructions on [[Kernel modules#Loading]] to automatically load the module at boot.
+
Note that redirects are resolved internally by the server and will not make it any slower to open an article.
  
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:
+
When redirecting an existing page A to page B, for example after merging the content of A into B, check if A has a talk page: if B does not have a talk page, move A's talk page there; otherwise merge A's talk page to B's. Then check if A's talk page is linked from some other page and fix any of those links so that they point to B's talk page. Finally, mark A's talk page for [[Template:Deletion|deletion]].
# modprobe ndiswrapper
+
# iwconfig
+
  
and ''wlan0'' should now exist. Check this page if you are having problems:
+
==Wiki variables, magic words, and templates==
[http://ndiswrapper.sourceforge.net/joomla/index.php?/component/option,com_openwiki/Itemid,33/id,installation/ Ndiswrapper installation wiki].
+
MediaWiki recognizes certain special strings within an article that alter standard behavior. For example, adding the word {{ic|<nowiki>__NOTOC__</nowiki>}} anywhere in an article will prevent generation of a table of contents. Similarly, the word {{ic|<nowiki>__TOC__</nowiki>}} can be used to alter the default position of the table of contents. See [http://www.mediawiki.org/wiki/Help:Magic_words Help:Magic words] for details.
  
=== compat-drivers-patched ===
+
Templates and variables are predefined portions of wikitext that can be inserted into an article to aid in formatting content.
  
{{Out of date|{{AUR|compat-drivers-patched}} has reached end-of-life, {{AUR|backports-patched}} should be used instead}}
+
Variables are defined by the system and can be used to display information about the current page, wiki, or date. For example, use {{ic|<nowiki>{{SITENAME}}</nowiki>}} to display the wiki's site name (which, on this wiki, is: '''''{{SITENAME}}'''''). To set an alternate title header for the current page, another wiki variable can be used: {{ic|<nowiki>{{DISPLAYTITLE:New Title}}</nowiki>}} (only capitalization changes are permitted).
  
Patched compat wireless drivers correct the "fixed-channel -1" issue, whilst providing better injection. Please install the {{AUR|compat-drivers-patched}} package from the [[Arch User Repository|AUR]].
+
Templates, on the other hand, are user-defined. The content of ''any'' page can be included in another page by adding {{ic|<nowiki>{{Namespace:Page Name}}</nowiki>}} to an article, but this is rarely used with pages outside the ''Template'' namespace. (If the namespace is omitted, ''Template'' is assumed.) For example, [[Template:Note]], which can be included in an article with the following wikitext:
  
{{AUR|compat-drivers-patched}} does not conflict with any other package and the modules built reside in {{ic|/usr/lib/modules/''your_kernel_version''/updates}}.
+
{{bc|<nowiki>{{Note|This is a note.}}</nowiki>}}
  
These patched drivers come from the [http://wireless.kernel.org/ Linux Wireless project] and support many of the above mentioned chips such as:
+
...is rendered as:
  
ath5k ath9k_htc carl9170 b43 zd1211rw rt2x00 wl1251 wl12xx ath6kl brcm80211
+
{{Note|This is a note.}}
  
Supported groups:
+
See [[Help:Template]] for more information.
  
atheros ath iwlagn rtl818x rtlwifi wl12xx atlxx bt
+
==Discussion pages==
 +
Discussion or "talk" pages are for communicating with other ArchWiki users.
  
It is also possible to build a specific module/driver or a group of drivers by editing the [[PKGBUILD]], particularly uncommenting the '''line #46'''. Here is an example of building the atheros group:
+
To discuss any page, go to that page and then click the "discussion" tab at the top of the page. Add a new comment at the end of the page or reply below an existing comment. Use [[#Indenting|indenting]] to format your discussion. Standard practice is to indent your reply one more level deep than the person to whom you are replying.  Further, you should insert your comment beneath the one to which you are replying, but below others who are doing the same.
  
scripts/driver-select atheros
+
Sign comments by typing {{ic|<nowiki>~~~~</nowiki>}} to insert your username and a timestamp. Avoid editing another user's comments.
  
Please read the package's [[PKGBUILD]] for any other possible modifications prior to compilation and installation.
+
Experiment by editing the [[Talk:Sandbox|talk page of the Sandbox]].
  
== See also ==
+
===User talk pages===
 +
Note the difference between a user page, and a user talk page.  Everyone may have a user talk page on which other people can leave public messages. If one does not exist for a particular user, you may create it so that you can leave a comment. If someone has left you a message on yours, you will see a note saying "You have new messages" with a link to your own user talk page: in this case you are supposed to reply on your own talk page ''beneath'' the original message with appropriate indentation. Please avoid replying to a discussion on a different talk page, for example the one of the user who contacted you, since such a style of communication creates disconnects with the flow of information regarding the subject at hand.
  
* [http://wireless.kernel.org/ The Linux Wireless project]
+
Do not edit a user's own page without permission (i.e. ''<nowiki>[[User:Name]]</nowiki>''); these serve as personal user spaces. The "user ''talk'' page" is the correct place for communicating (other than sending private email if the address is published).
* [http://aircrack-ng.org/doku.php?id=install_drivers Aircrack-ng guide on installing drivers]
+

Revision as of 02:26, 27 November 2013

ArchWiki is powered by MediaWiki, a free software wiki package written in PHP, originally designed for use on Wikipedia. This is a short tutorial about editing the ArchWiki. More in-depth help can be found at Help:Contents on MediaWiki and Help:Contents on Wikipedia.

You must be logged-in to edit pages. Visit Special:UserLogin to log in or create an account. To experiment with editing, please use the sandbox. For an overview of wiki markup, see ArchWiki Cheatsheet. For wiki tasks, see ArchWiki:Tasks.

Before editing or creating pages, users are encouraged to familiarize themselves with the general tone, layout, and style of existing articles. An effort should be made to maintain a level of consistency throughout the wiki. See Help:Reading for an overview of common stylistic conventions. See Help:Style for more detail.

Editing

To begin editing a page, click the edit tab at the top of the page. Alternatively, users may edit a specific section of an article by clicking the edit link to the right of the section heading. The Editing page will be displayed, which consists of the following elements:

  • Edit toolbar (optional)
  • Edit box
  • Edit summary box
  • Save page, Show preview, Show changes, and Cancel links

The edit box will contain the wikitext (the editable source code from which the server produces the web page) for the current revision of the page or section. To perform an edit:

  1. Modify the wikitext as needed (see #Formatting below for details).
  2. Explain the edit in the Summary box (e.g. "fixed typo" or "added info on xyz" (see Help:Edit summary for details)).
    Note: All edits should be accompanied by a descriptive summary. The summary allows administrators and other maintainers to easily identify controversial edits and vandalism.
  3. Use the Show preview button to facilitate proofreading and verify formatting before saving.
  4. Mark the edit as minor by checking the This is a minor edit box if the edit is superficial and indisputable.
  5. Save changes by clicking Save page. If unsatisfied, click Cancel instead (or repeat the process until satisfied).
Note: If you are not going to use an external editor like vim, you may want to consider using wikEd, which adds syntax highlighting, regex search and replace and other nice features to the standard MediaWiki editor. The greasemonkey script works flawlessly with the ArchWiki.
Note: Articles should not be signed because they are shared works; one editor should not be singled out above others.

Reverting edits

If a page was edited incorrectly, the following procedures describe how to revert an article to a previous version. To revert a single edit:

  1. Click the history tab at the top of the page to be modified (beside the edit tab). A list of revisions is displayed.
  2. Click the undo link to the right of the offending edit. An edit preview is displayed, showing the current revision on the left and the text to be saved on the right.
  3. If satisfied, click the Save page button at the bottom of the page.

The wiki page should now be back in its original state.

Occasionally, it is necessary to revert several edits at once. To revert an article to a previous version:

  1. Click the history tab at the top of the page to be modified (beside the edit tab). A list of revisions is displayed.
  2. View the desired revision (i.e. the last good version) by clicking on the appropriate timestamp. That revision is displayed.
  3. If satisfied, click the edit tab at the top of the page. A warning is displayed: You are editing an out-of-date revision of this page. Simply click the Save page button to revert to this version.
Note: Avoid combining an undo and an edit! Revert the edit first, then make additional changes; do not edit the revision preview.

Creating pages

Before creating a new page, please consider the following:

  1. Is your topic relevant to Arch Linux? Irrelevant or unhelpful articles will be deleted.
  2. Is your topic of interest to others? Consider not only what you wish to write about, but also what others may wish to read. Personal notes belong on your user page.
  3. Is your topic worthy of a new page? Search the wiki for similar articles. If they exist, consider improving or adding a section to an existing article instead.
  4. Will your contribution be significant? Avoid creating stubs unless planning to expand them shortly thereafter.

Creating a new page requires selection of a descriptive title and an appropriate category.

Please read Article Naming Guidelines and Writing Short Article Names for article naming advice.

  1. Titles should be capitalized appropriately: Title for New Page; not Title for new page.
  2. Do not include "Arch Linux" or variations in page titles. This is the Arch Linux wiki; it is assumed that articles will be related to Arch Linux. (e.g., Installing Openbox; not Installing Openbox in Arch Linux).

Visit the Table of Contents to help choose an appropriate category. Articles may belong to multiple categories.

To add a new page to some category (say "My New Page" to "Some Category") you need to:

  1. Create a page with your new title by browsing to https://wiki.archlinux.org/index.php/My_New_Page (remember to replace "My_New_Page" with the intended title!)
  2. Add [[Category:Some Category]] to the top of your page
Note: Do not create uncategorized pages! All pages must belong to at least one category. If you cannot find a suitable category, consider creating a new one.

Formatting

Text formatting is accomplished with wiki markup whenever possible; learning HTML is not necessary. Various templates are also available for common formatting tasks; see Help:Template for information about templates. The ArchWiki Cheatsheet summarizes the most common formatting options.

Headings and subheadings

Headings and subheadings are an easy way to improve the organization of an article. If you can see distinct topics being discussed, you can break up an article by inserting a heading for each section. See Help:Style#Section headings and Effective Use of Headers for style information.

Headings must start from second level, and can be created like this:

==Second-level heading==
===Third-level heading===
====Fourth-level heading====
=====Fifth-level heading=====
======Sixth-level heading======
Note: First-level headings are not allowed, their formatting is reserved for the article title.

If an article has at least four headings, a table of contents (TOC) will be automatically generated. If this is not desired, place __NOTOC__ in the article. Try creating some headings in the Sandbox and see the effect on the TOC.

Line breaks

An empty line is used to start a new paragraph while single line breaks have no effect in regular paragraphs.

The HTML <br> tag can be used to manually insert line breaks, but should be avoided. A manual break may be justified with other formatting elements, such as lists.

wikitext rendering
This sentence
is broken into
three lines.

This sentence is broken into three lines.

This is paragraph number one.

This is paragraph number two.

This is paragraph number one.

This is paragraph number two.

* This point <br> spans multiple lines
* This point
ends the list
  • This point
    spans multiple lines
  • This point

ends the list

See Help:Style#Blank_lines for information on the use of blank lines.

Bold and italics

Bold and italics are added by surrounding a word or phrase with two, three or five apostrophes ('):

wikitext rendering

''italics''

italics

'''bold'''

bold

'''''bold and italics'''''

bold and italics

Strike-out

Use strike-out text to show that the text no longer applies or has relevance.

wikitext rendering
<s>Strike-out text</s>

Strike-out text

Indenting

Note: Indenting should only be used for discussion pages, see Wikipedia:Indentation

To indent text, place a colon (:) at the beginning of a line. The more colons you put, the further indented the text will be. A newline marks the end of the indented paragraph.

wikitext rendering
This is not indented at all.
:This is indented slightly.
::This is indented more.

This is not indented at all.

This is indented slightly.
This is indented more.

Lists

Bullet points

Bullet points have no apparent order of items. To insert a bullet, use an asterisk (*). Multiple *s will increase the level of indentation.

wikitext rendering
* First item 
* Second item 
** Sub-item
* Third item 
  • First item
  • Second item
    • Sub-item
  • Third item

Numbered lists

Numbered lists introduce numbering and thus order the list items. You should generally use unordered lists as long as the order in which items appear is not the primary concern. To create numbered lists, use the number sign or hash symbol (#). Multiple #s will increase the level of indentation.

wikitext rendering
# First item 
# Second item 
## Sub-item
# Third item 
  1. First item
  2. Second item
    1. Sub-item
  3. Third item
# First item
# Second item
#* Sub-item
# Third item
  1. First item
  2. Second item
    • Sub-item
  3. Third item

Definition lists

Definition lists are defined with a leading semicolon (;) and a colon (:) following the term.

wikitext rendering
Definition lists:
; Keyboard: Input device with buttons or keys
; Mouse: Pointing device for two-dimensional input
or
; Keyboard
: Input device with buttons or keys
; Mouse
: Pointing device for two-dimensional input

Definition lists:

Keyboard
Input device with buttons or keys
Mouse
Pointing device for two-dimensional input

or

Keyboard
Input device with buttons or keys
Mouse
Pointing device for two-dimensional input
Use additional colons if a definition has multiple definitions:
; Term
: First definition
: Second definition

Use additional colons if a definition has multiple definitions:

Term
First definition
Second definition

Definition lists must not be simply used for formatting, see W3's examples.

Code

To add code to the wiki, use one of the code formatting templates. Alternatively, simply start each line with a single whitespace character.

See Help:Style#Code formatting templates.

Tables

Used effectively, tables can help organize and summarize swaths of data. For advanced table syntax and formatting see Help:Table.

wikitext rendering
{| border="1"
|+ Tabular data
! Distro !! Color
|-
| Arch || Blue
|-
| Gentoo || Purple
|-
| Ubuntu || Orange
|}
Tabular data
Distro Color
Arch Blue
Gentoo Purple
Ubuntu Orange
{| class="wikitable" border="1" cellpadding="5" cellspacing="0"
! Filesystem !! Size !! Used !! Avail !! Use% !! Mounted on
|-
| rootfs || 922G || 463G || 413G || 53% || /
|-
| /dev || 1.9G || 0 || 1.9G || 0% || /dev
|}
Filesystem Size Used Avail Use% Mounted on
rootfs 922G 463G 413G 53% /
/dev 1.9G 0 1.9G 0% /dev

Links

Links are essential to help readers navigate the site. In general, editors should ensure that every article contains outgoing links to other articles (avoid dead-end pages) and is referenced by incoming links from other articles (the what links here special page can be used to display incoming links).

Internal links

You can extensively cross-reference wiki pages using internal links. You can add links to existing titles, and also to titles you think ought to exist in future.

To make a link to another page on the same wiki, just put the title in double square brackets.

For example, if you want to make a link to, say, the pacman article, use:

[[pacman]]

If you want to use words other than the article title as the text of the link, you can add an alternative name after the pipe "|" divider (Shift + \ on English-layout and similar keyboards).

For example:

View [[Arch Linux|this]] article...

...is rendered as:

View this article...

When you want to use the plural of an article title (or add any other suffix) for your link, you can add the extra letters directly outside the double square brackets.

For example:

makepkg is used in conjunction with [[PKGBUILD]]s.

...is rendered as:

makepkg is used in conjunction with PKGBUILDs.

Links to sections of a document

To create a link to a section of a document, simply add a # followed by the section's heading.

For example:

[[Help:Editing#Links to sections of a document]]

...is rendered as:

Help:Editing#Links to sections of a document
Tip: If linking to a section within the same page, the page name can be omitted (e.g. [[#Links to sections of a document]]). Do not needlessly reformat same-page section links to hide the anchor symbol (e.g. [[#Links to sections of a document|Links to sections of a document]]).

Interlanguage links

See Help:i18n#Interlanguage links

Interwiki links

So-called interwiki links can be used to easily link to articles in other external Wikis, like Wikipedia for example. The syntax for for this link type is the wiki name followed by a colon and the article you want to link to enclosed in double square brackets.

If you want to link to the Wikipedia:Arch Linux article you can use the following:

[[Wikipedia:Arch Linux]]

Or you can create a piped link with an alternate link label to the Arch Linux Wikipedia article:

[[Wikipedia:Arch Linux|Arch Linux Wikipedia article]]
Note: Using a piped link with an alternative link label should be reserved for abbreviating longer URLs.

See: Wikipedia:InterWikimedia links

External links

If you want to link to an external site, just type the full URL for the page you want to link to.

http://www.google.com/

It is often more useful to make the link display something other than the URL, so use one square bracket at each end, with the alternative title after the address separated by a space (not a pipe). So if you want the link to appear as Google search engine, just type:

[http://www.google.com/ Google search engine]
Note: If linking to another ArchWiki or Wikipedia page, use #Internal links or #Interwiki links rather than external links! That is, if your link starts with https://wiki.archlinux.org/ use an internal link; if your link starts with http://en.wikipedia.org/ use an interwiki link!

Redirects

To redirect automatically from one page to another, add #REDIRECT and an internal link to the page to be redirected to at the beginning of a page.

For example, you could redirect from "Cats" to "Cat":

#REDIRECT [[Cat]]

Thus, anyone typing either version in the search box will automatically go to "Cat".

Note that redirects are resolved internally by the server and will not make it any slower to open an article.

When redirecting an existing page A to page B, for example after merging the content of A into B, check if A has a talk page: if B does not have a talk page, move A's talk page there; otherwise merge A's talk page to B's. Then check if A's talk page is linked from some other page and fix any of those links so that they point to B's talk page. Finally, mark A's talk page for deletion.

Wiki variables, magic words, and templates

MediaWiki recognizes certain special strings within an article that alter standard behavior. For example, adding the word __NOTOC__ anywhere in an article will prevent generation of a table of contents. Similarly, the word __TOC__ can be used to alter the default position of the table of contents. See Help:Magic words for details.

Templates and variables are predefined portions of wikitext that can be inserted into an article to aid in formatting content.

Variables are defined by the system and can be used to display information about the current page, wiki, or date. For example, use {{SITENAME}} to display the wiki's site name (which, on this wiki, is: ArchWiki). To set an alternate title header for the current page, another wiki variable can be used: {{DISPLAYTITLE:New Title}} (only capitalization changes are permitted).

Templates, on the other hand, are user-defined. The content of any page can be included in another page by adding {{Namespace:Page Name}} to an article, but this is rarely used with pages outside the Template namespace. (If the namespace is omitted, Template is assumed.) For example, Template:Note, which can be included in an article with the following wikitext:

{{Note|This is a note.}}

...is rendered as:

Note: This is a note.

See Help:Template for more information.

Discussion pages

Discussion or "talk" pages are for communicating with other ArchWiki users.

To discuss any page, go to that page and then click the "discussion" tab at the top of the page. Add a new comment at the end of the page or reply below an existing comment. Use indenting to format your discussion. Standard practice is to indent your reply one more level deep than the person to whom you are replying. Further, you should insert your comment beneath the one to which you are replying, but below others who are doing the same.

Sign comments by typing ~~~~ to insert your username and a timestamp. Avoid editing another user's comments.

Experiment by editing the talk page of the Sandbox.

User talk pages

Note the difference between a user page, and a user talk page. Everyone may have a user talk page on which other people can leave public messages. If one does not exist for a particular user, you may create it so that you can leave a comment. If someone has left you a message on yours, you will see a note saying "You have new messages" with a link to your own user talk page: in this case you are supposed to reply on your own talk page beneath the original message with appropriate indentation. Please avoid replying to a discussion on a different talk page, for example the one of the user who contacted you, since such a style of communication creates disconnects with the flow of information regarding the subject at hand.

Do not edit a user's own page without permission (i.e. [[User:Name]]); these serve as personal user spaces. The "user talk page" is the correct place for communicating (other than sending private email if the address is published).