https://wiki.archlinux.org/api.php?action=feedcontributions&user=Arnix&feedformat=atom
ArchWiki - User contributions [en]
2024-03-28T19:04:59Z
User contributions
MediaWiki 1.41.0
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32105
Official Installation Guide (正體中文)
2007-11-08T23:48:01Z
<p>Arnix: /* 在安裝之前 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux 是個專為 i686 微處理器最佳化過的 linux 套件發行版。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
Arch 的特點是快速、輕巧、可塑性高和簡易。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做最佳化,所以你可在每個 CPU cycle 內得到所能提供的最大的效用。與 RedHat 等其他的 Linux 發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡化設計也讓使用者可以輕易地擴充並整合成您需要的系統。<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - pacman - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件建立系統 (Arch Build System - ABS) 來簡化套件的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。所有的動作都在相當簡單與清楚中完成。<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集,它們由AL的開發者維護。同時數以千計的額外套件則由社群中可信的成員向AUR提出,如果他們認為合適的話。<br />
<br />
為了達到簡單與輕巧的目的,一般 linux 系統相對上沒有用的部份會被省略,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。有 Man pages 就夠了…<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,Arch Linux 0.8 (Voodoo) 當然地,預設使用 2.6 版的 Linux 核心,並支援 EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM、以及加密的檔案系統。<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
由於 Arch Linux 針對 i686 指令集的處理器做了最佳化,因此無法在任何等級較低或不相容的 x86 CPU 上運行(例如 i386、i486、i586)。 必須 Pentium II 或 AMD K6-2 以上的處理器才行。x86-64 架構也在正式的支援範圍中。<br />
<br />
另有由社群推動的計畫,提供了於 i586 及 ppc 架構使用的套件。詳情請見本站文件。<br />
<br />
在安裝 Arch Linux 之前,您需要決定將採取何種的安裝方式。 針對光碟安裝,Arch Linux 提供了兩種不同的可開機 ISO 映像檔。<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
如果您的電腦未配備光碟機,自然地您就裝不下去了。<br />
<br />
現在就去取得一份可開機的 Arch 安裝光碟,不論是從 mirror 網站下載最新的 ISOs 然後燒出來,還是請人幫你複製都可以。或者您也可以由 OSDisc 線上訂購,幾乎全球都能出貨。<br />
<br />
此外您無需耽心在安裝時使用舊版的 ISO,只要您有寬頻網路可以用,一旦您裝好了基礎系統,要升級到最新版本就非常簡單了。<br />
<br />
在安裝期間使用 PPP 撥接上網,現在已經有支援了。 ppp 工具軟體、rp-pppoe 以及 ISDN 需要用到的工具都已包含在安裝光碟之中。<br />
<br />
2007.08 版 ISOs 執行起來和已經裝好的 arch 系統類似。以下是它的主要特點: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* 完整支援 /etc/rc.d/ and /etc/rc.conf <br />
* 完整支援 arch network , 包含 ssh,telnet and portmap 服<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* 包含 links 及 naim 以便連上際網路。<br />
* 完整支援 kexec<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* 關於您系統及Linux 的知識,尤其是關於您硬體的知識。<br />
* Arch Linux 安裝媒體 (見 the mirror list)<br />
* 一部 i686 或 x86-64 架構電腦 (PPro、Pentium 2 以上,Athlon/Duron等等。注意 AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 不在支援之列。)<br />
* 128 MB RAM<br />
* 有一些時間可以用<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''組態設定檔的列表'''<br />
* Setup相關的組態設定檔:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
'''LOCALE'''<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
'''HARDWARECLOCK'''<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
'''TIMEZONE'''<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
'''KEYMAP'''<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
'''CONSOLEFONT'''<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
'''CONSOLEMAP'''<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
'''USECOLOR'''<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
'''MOD_AUTOLOAD'''<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
'''MOD_BLACKLIST'''<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
'''MODULES'''<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
'''USELVM'''<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
'''HOSTNAME'''<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
'''INTERFACES'''<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
'''ROUTES'''<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
'''NET_PROFILES'''<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
'''DAEMONS'''<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32103
Official Installation Guide (正體中文)
2007-11-08T23:35:24Z
<p>Arnix: /* 在安裝之前 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux 是個專為 i686 微處理器最佳化過的 linux 套件發行版。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
Arch 的特點是快速、輕巧、可塑性高和簡易。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做最佳化,所以你可在每個 CPU cycle 內得到所能提供的最大的效用。與 RedHat 等其他的 Linux 發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡化設計也讓使用者可以輕易地擴充並整合成您需要的系統。<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - pacman - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件建立系統 (Arch Build System - ABS) 來簡化套件的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。所有的動作都在相當簡單與清楚中完成。<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集,它們由AL的開發者維護。同時數以千計的額外套件則由社群中可信的成員向AUR提出,如果他們認為合適的話。<br />
<br />
為了達到簡單與輕巧的目的,一般 linux 系統相對上沒有用的部份會被省略,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。有 Man pages 就夠了…<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,Arch Linux 0.8 (Voodoo) 當然地,預設使用 2.6 版的 Linux 核心,並支援 EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM、以及加密的檔案系統。<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
由於 Arch Linux 針對 i686 指令集的處理器做了最佳化,因此無法在任何等級較低或不相容的 x86 CPU 上運行(例如 i386、i486、i586)。 必須 Pentium II 或 AMD K6-2 以上的處理器才行。x86-64 架構也在正式的支援範圍中。<br />
<br />
另有由社群推動的計畫,提供了於 i586 及 ppc 架構使用的套件。詳情請見本站文件。<br />
<br />
在安裝 Arch Linux 之前,您需要決定將採取何種的安裝方式。 針對光碟安裝,Arch Linux 提供了兩種不同的可開機 ISO 映像檔。<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
如果您的電腦未配備光碟機,自然地您就裝不下去了。<br />
<br />
現在就去取得一份可開機的 Arch 安裝光碟,不論是從 mirror 網站下載最新的 ISOs 然後燒出來,還是請人幫你複製都可以。或者您也可以由 OSDisc 線上訂購,幾乎全球都能出貨。<br />
<br />
此外您無需耽心在安裝時使用舊版的 ISO,只要您有寬頻網路可以用,一旦您裝好了基礎系統,要升級到最新版本就非常簡單了。<br />
<br />
在安裝期間使用 PPP 撥接上網,現在已經有支援了。 ppp 工具軟體、rp-pppoe 以及 ISDN 需要用到的工具都已包含在安裝光碟之中。<br />
<br />
2007.08 版 ISOs 執行起來和已經裝好的 arch 系統類似。以下是它的主要特點: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* 完整支援 /etc/rc.d/ and /etc/rc.conf <br />
* 完整支援 arch network , 包含 ssh,telnet and portmap 服<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux 安裝媒體 (見 the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* 有一點時間可以用<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''組態設定檔的列表'''<br />
* Setup相關的組態設定檔:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
'''LOCALE'''<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
'''HARDWARECLOCK'''<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
'''TIMEZONE'''<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
'''KEYMAP'''<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
'''CONSOLEFONT'''<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
'''CONSOLEMAP'''<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
'''USECOLOR'''<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
'''MOD_AUTOLOAD'''<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
'''MOD_BLACKLIST'''<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
'''MODULES'''<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
'''USELVM'''<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
'''HOSTNAME'''<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
'''INTERFACES'''<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
'''ROUTES'''<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
'''NET_PROFILES'''<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
'''DAEMONS'''<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32101
Official Installation Guide (正體中文)
2007-11-08T23:30:10Z
<p>Arnix: /* 在安裝之前 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux 是個專為 i686 微處理器最佳化過的 linux 套件發行版。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
Arch 的特點是快速、輕巧、可塑性高和簡易。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做最佳化,所以你可在每個 CPU cycle 內得到所能提供的最大的效用。與 RedHat 等其他的 Linux 發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡化設計也讓使用者可以輕易地擴充並整合成您需要的系統。<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - pacman - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件建立系統 (Arch Build System - ABS) 來簡化套件的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。所有的動作都在相當簡單與清楚中完成。<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集,它們由AL的開發者維護。同時數以千計的額外套件則由社群中可信的成員向AUR提出,如果他們認為合適的話。<br />
<br />
為了達到簡單與輕巧的目的,一般 linux 系統相對上沒有用的部份會被省略,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。有 Man pages 就夠了…<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,Arch Linux 0.8 (Voodoo) 當然地,預設使用 2.6 版的 Linux 核心,並支援 EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM、以及加密的檔案系統。<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
由於 Arch Linux 針對 i686 指令集的處理器做了最佳化,因此無法在任何等級較低或不相容的 x86 CPU 上運行(例如 i386、i486、i586)。 必須 Pentium II 或 AMD K6-2 以上的處理器才行。x86-64 架構也在正式的支援範圍中。<br />
<br />
另有由社群推動的計畫,提供了於 i586 及 ppc 架構使用的套件。詳情請見本站文件。<br />
<br />
在安裝 Arch Linux 之前,您需要決定將採取何種的安裝方式。 針對光碟安裝,Arch Linux 提供了兩種不同的可開機 ISO 映像檔。<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
如果您的電腦未配備光碟機,自然地您就裝不下去了。<br />
<br />
現在就去取得一份可開機的 Arch 安裝光碟,不論是從 mirror 網站下載最新的 ISOs 然後燒出來,還是請人幫你複製都可以。或者您也可以由 OSDisc 線上訂購,幾乎全球都能出貨。<br />
<br />
此外您無需耽心在安裝時使用舊版的 ISO,只要您有寬頻網路可以用,一旦您裝好了基礎系統,要升級到最新版本就非常簡單了。<br />
<br />
在安裝期間使用 PPP 撥接上網,現在已經有支援了。 ppp 工具軟體、rp-pppoe 以及 ISDN 需要用到的工具都已包含在安裝光碟之中。<br />
<br />
2007.08 Isos 執行起來和已經裝好的 arch 系統類似。以下是它的主要特點: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''組態設定檔的列表'''<br />
* Setup相關的組態設定檔:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
'''LOCALE'''<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
'''HARDWARECLOCK'''<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
'''TIMEZONE'''<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
'''KEYMAP'''<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
'''CONSOLEFONT'''<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
'''CONSOLEMAP'''<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
'''USECOLOR'''<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
'''MOD_AUTOLOAD'''<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
'''MOD_BLACKLIST'''<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
'''MODULES'''<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
'''USELVM'''<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
'''HOSTNAME'''<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
'''INTERFACES'''<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
'''ROUTES'''<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
'''NET_PROFILES'''<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
'''DAEMONS'''<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32100
Official Installation Guide (正體中文)
2007-11-08T23:20:21Z
<p>Arnix: /* 在安裝之前 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux 是個專為 i686 微處理器最佳化過的 linux 套件發行版。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
Arch 的特點是快速、輕巧、可塑性高和簡易。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做最佳化,所以你可在每個 CPU cycle 內得到所能提供的最大的效用。與 RedHat 等其他的 Linux 發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡化設計也讓使用者可以輕易地擴充並整合成您需要的系統。<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - pacman - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件建立系統 (Arch Build System - ABS) 來簡化套件的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。所有的動作都在相當簡單與清楚中完成。<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集,它們由AL的開發者維護。同時數以千計的額外套件則由社群中可信的成員向AUR提出,如果他們認為合適的話。<br />
<br />
為了達到簡單與輕巧的目的,一般 linux 系統相對上沒有用的部份會被省略,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。有 Man pages 就夠了…<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,Arch Linux 0.8 (Voodoo) 當然地,預設使用 2.6 版的 Linux 核心,並支援 EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM、以及加密的檔案系統。<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
由於 Arch Linux 針對 i686 指令集的處理器做了最佳化,因此無法在任何等級較低或不相容的 x86 CPU 上運行(例如 i386、i486、i586)。 必須 Pentium II 或 AMD K6-2 以上的處理器才行。x86-64 架構也在正式的支援範圍中。<br />
<br />
另有由社群推動的計畫,提供了於 i586 及 ppc 架構使用的套件。詳情請見本站文件。<br />
<br />
在安裝 Arch Linux 之前,您需要決定將採取何種的安裝方式。 針對光碟安裝,Arch Linux 提供了兩種不同的可開機 ISO 映像檔。<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
如果您的電腦未配備光碟機,自然地您就裝不下去了。<br />
<br />
現在就去取得一份可開機的 Arch 安裝光碟,不論是從 mirror 網站下載最新的 ISOs 然後燒出來,還是請人幫你複製都可以。或者您也可以由 OSDisc 線上訂購,幾乎全球都能出貨。<br />
<br />
此外您無需耽心在安裝時使用舊版的 ISO,只要您有寬頻網路可以用,一旦您基礎系統裝好,要升級到最新版本是再簡單不過的事了。<br />
<br />
在安裝期間使用 PPP 撥接上網,現在已經有支援了。 ppp 工具軟體、rp-pppoe 以及 ISDN 需要用到的工具都已包含在安裝光碟之中。<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''組態設定檔的列表'''<br />
* Setup相關的組態設定檔:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
'''LOCALE'''<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
'''HARDWARECLOCK'''<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
'''TIMEZONE'''<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
'''KEYMAP'''<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
'''CONSOLEFONT'''<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
'''CONSOLEMAP'''<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
'''USECOLOR'''<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
'''MOD_AUTOLOAD'''<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
'''MOD_BLACKLIST'''<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
'''MODULES'''<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
'''USELVM'''<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
'''HOSTNAME'''<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
'''INTERFACES'''<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
'''ROUTES'''<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
'''NET_PROFILES'''<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
'''DAEMONS'''<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32096
Official Installation Guide (正體中文)
2007-11-08T22:52:17Z
<p>Arnix: /* 在安裝之前 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux 是個專為 i686 微處理器最佳化過的 linux 套件發行版。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
Arch 的特點是快速、輕巧、可塑性高和簡易。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做最佳化,所以你可在每個 CPU cycle 內得到所能提供的最大的效用。與 RedHat 等其他的 Linux 發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡化設計也讓使用者可以輕易地擴充並整合成您需要的系統。<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - pacman - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件建立系統 (Arch Build System - ABS) 來簡化套件的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。所有的動作都在相當簡單與清楚中完成。<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集,它們由AL的開發者維護。同時數以千計的額外套件則由社群中可信的成員向AUR提出,如果他們認為合適的話。<br />
<br />
為了達到簡單與輕巧的目的,一般 linux 系統相對上沒有用的部份會被省略,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。有 Man pages 就夠了…<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,Arch Linux 0.8 (Voodoo) 當然地,預設使用 2.6 版的 Linux 核心,並支援 EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM、以及加密的檔案系統。<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
由於 Arch Linux 針對 i686 指令集的處理器做了最佳化,因此無法在任何等級較低或不相容的 x86 CPU 上運行(例如 i386、i486、i586)。 必須 Pentium II 或 AMD K6-2 以上的處理器才行。x86-64 架構也在正式的支援範圍中。<br />
<br />
另有由社群推動的計畫,提供了於 i586 及 ppc 架構使用的套件。詳情請見本站文件。<br />
<br />
在安裝 Arch Linux 之前,您需要決定將採取何種的安裝方式。 針對光碟安裝,Arch Linux 提供了兩種不同的可開機 ISO 映像檔。<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''組態設定檔的列表'''<br />
* Setup相關的組態設定檔:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
'''LOCALE'''<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
'''HARDWARECLOCK'''<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
'''TIMEZONE'''<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
'''KEYMAP'''<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
'''CONSOLEFONT'''<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
'''CONSOLEMAP'''<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
'''USECOLOR'''<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
'''MOD_AUTOLOAD'''<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
'''MOD_BLACKLIST'''<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
'''MODULES'''<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
'''USELVM'''<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
'''HOSTNAME'''<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
'''INTERFACES'''<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
'''ROUTES'''<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
'''NET_PROFILES'''<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
'''DAEMONS'''<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32093
Official Installation Guide (正體中文)
2007-11-08T22:31:17Z
<p>Arnix: /* Arch Linux 是什麼 ? */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux 是個專為 i686 微處理器最佳化過的 linux 套件發行版。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
Arch 的特點是快速、輕巧、可塑性高和簡易。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做最佳化,所以你可在每個 CPU cycle 內得到所能提供的最大的效用。與 RedHat 等其他的 Linux 發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡化設計也讓使用者可以輕易地擴充並整合成您需要的系統。<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - pacman - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件建立系統 (Arch Build System - ABS) 來簡化套件的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。所有的動作都在相當簡單與清楚中完成。<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集,它們由AL的開發者維護。同時數以千計的額外套件則由社群中可信的成員向AUR提出,如果他們認為合適的話。<br />
<br />
為了達到簡單與輕巧的目的,一般 linux 系統相對上沒有用的部份會被省略,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。有 Man pages 就夠了…<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,Arch Linux 0.8 (Voodoo) 當然地,預設使用 2.6 版的 Linux 核心,並支援 EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM、以及加密的檔案系統。<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''組態設定檔的列表'''<br />
* Setup相關的組態設定檔:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
'''LOCALE'''<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
'''HARDWARECLOCK'''<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
'''TIMEZONE'''<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
'''KEYMAP'''<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
'''CONSOLEFONT'''<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
'''CONSOLEMAP'''<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
'''USECOLOR'''<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
'''MOD_AUTOLOAD'''<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
'''MOD_BLACKLIST'''<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
'''MODULES'''<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
'''USELVM'''<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
'''HOSTNAME'''<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
'''INTERFACES'''<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
'''ROUTES'''<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
'''NET_PROFILES'''<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
'''DAEMONS'''<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32087
Official Installation Guide (正體中文)
2007-11-08T21:49:41Z
<p>Arnix: /* 各種組態設定檔 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''組態設定檔的列表'''<br />
* Setup相關的組態設定檔:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
'''LOCALE'''<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
'''HARDWARECLOCK'''<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
'''TIMEZONE'''<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
'''KEYMAP'''<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
'''CONSOLEFONT'''<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
'''CONSOLEMAP'''<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
'''USECOLOR'''<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
'''MOD_AUTOLOAD'''<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
'''MOD_BLACKLIST'''<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
'''MODULES'''<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
'''USELVM'''<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
'''HOSTNAME'''<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
'''INTERFACES'''<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
'''ROUTES'''<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
'''NET_PROFILES'''<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
'''DAEMONS'''<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32085
Official Installation Guide (正體中文)
2007-11-08T21:46:05Z
<p>Arnix: /* System Configuration */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32084
Official Installation Guide (正體中文)
2007-11-08T21:44:58Z
<p>Arnix: Undo revision 32083 by Arnix (Talk)</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32083
Official Installation Guide (正體中文)
2007-11-08T21:41:45Z
<p>Arnix: /* System Configuration */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==系統組態設定==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===各種組態設定檔===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
本地化<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
硬體時鐘<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
時區<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
鍵盤對應表<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
控制台字型<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
使用彩色<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
核心模組<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
使用LVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
主機名稱<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
網路介面<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
路由設定<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
系統服務<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
警告: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32081
Official Installation Guide (正體中文)
2007-11-08T21:29:02Z
<p>Arnix: </p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===Arch Linux 是什麼 ?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32079
Official Installation Guide (正體中文)
2007-11-08T21:26:37Z
<p>Arnix: /* 通用安裝程序 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===什麼是 Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap(載入一份非美式的鍵盤配置表)<br />
#Running Setup(執行 Setup)<br />
#Configure Network (FTP Install only)(設定網路 ( 針對 FTP 安裝))<br />
#Prepare Hard Drive(準備硬碟)<br />
##Auto-Prepare(自動準備)<br />
##Partition Hard Drives(分割硬碟)<br />
##Set Filesystem Mountpoints(設定檔案系統的掛載點)<br />
#Select Packages(選擇套件)<br />
#Install Packages(安裝套件 )<br />
#Configure System(設定系統組態)<br />
#Install Kernel(安裝核心)<br />
#Install Bootloader(安裝啟動程式載入器)<br />
#Exit Install(退出安裝)<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32077
Official Installation Guide (正體中文)
2007-11-08T21:16:08Z
<p>Arnix: /* Pacman */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===什麼是 Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap<br />
#Running Setup<br />
#Configure Network (FTP Install only)<br />
#Prepare Hard Drive<br />
##Auto-Prepare<br />
##Partition Hard Drives<br />
##Set Filesystem Mountpoints<br />
#Select Packages<br />
#Install Packages<br />
#Configure System<br />
#Install Kernel<br />
#Install Bootloader<br />
#Exit Install<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32076
Official Installation Guide (正體中文)
2007-11-08T21:15:11Z
<p>Arnix: /* 如何製作套件包 */</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===什麼是 Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap<br />
#Running Setup<br />
#Configure Network (FTP Install only)<br />
#Prepare Hard Drive<br />
##Auto-Prepare<br />
##Partition Hard Drives<br />
##Set Filesystem Mountpoints<br />
#Select Packages<br />
#Install Packages<br />
#Configure System<br />
#Install Kernel<br />
#Install Bootloader<br />
#Exit Install<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件包<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件包清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件包<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件包是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件包的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32075
Official Installation Guide (正體中文)
2007-11-08T21:14:41Z
<p>Arnix: </p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===什麼是 Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap<br />
#Running Setup<br />
#Configure Network (FTP Install only)<br />
#Prepare Hard Drive<br />
##Auto-Prepare<br />
##Partition Hard Drives<br />
##Set Filesystem Mountpoints<br />
#Select Packages<br />
#Install Packages<br />
#Configure System<br />
#Install Kernel<br />
#Install Bootloader<br />
#Exit Install<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件包<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件包清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件包<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件包是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件包的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件包===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32074
Official Installation Guide (正體中文)
2007-11-08T21:10:45Z
<p>Arnix: </p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件包管理器及ABS)的簡短說明。<br />
<br />
==介紹==<br />
<br />
===什麼是 Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap<br />
#Running Setup<br />
#Configure Network (FTP Install only)<br />
#Prepare Hard Drive<br />
##Auto-Prepare<br />
##Partition Hard Drives<br />
##Set Filesystem Mountpoints<br />
#Select Packages<br />
#Install Packages<br />
#Configure System<br />
#Install Kernel<br />
#Install Bootloader<br />
#Exit Install<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件包<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件包清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件包<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件包是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件包的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件包===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32073
Official Installation Guide (正體中文)
2007-11-08T21:09:43Z
<p>Arnix: </p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
This is the general user documentation for the Arch Linux<br />
distribution, Codename (Don't Panic). It covers obtaining the necessary<br />
files, installing the distribution and setting up a basic, bootable<br />
system. Additionally a short reference for the system layout and<br />
Arch-specific tools is supplied, ie. the pacman package manager and<br />
ABS.<br />
<br />
這是 Arch Linux 發行版本,代號 (Don't Panic) 的一般使用者文件。它的內容涵蓋:取得必要檔案、安裝及配置基本可以開機的系統。此外,還提供系統佈局及 Arch專用工具(pacman 套件包管理器及ABS)的簡短說明。<br />
==介紹==<br />
<br />
===什麼是 Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===許可證===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===致謝與回饋===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==安裝 Arch Linux==<br />
<br />
===在安裝之前===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
您所需要的東西<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===取得 Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===準備安裝的媒體===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===使用 CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===通用安裝程序===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
安裝步驟:<br />
<br />
#Loading a non-US Keymap<br />
#Running Setup<br />
#Configure Network (FTP Install only)<br />
#Prepare Hard Drive<br />
##Auto-Prepare<br />
##Partition Hard Drives<br />
##Set Filesystem Mountpoints<br />
#Select Packages<br />
#Install Packages<br />
#Configure System<br />
#Install Kernel<br />
#Install Bootloader<br />
#Exit Install<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==套件管理==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
移除套件包<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
更新套件包清單<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
升級系統<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
列出已安裝的套件包<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
檢查某個套件包是否已經安裝<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
顯示指定套件包的相關資訊<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===如何製作套件包===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===打包準則===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
套件包命名<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==常見問題==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32072
Official Installation Guide (正體中文)
2007-11-08T20:33:41Z
<p>Arnix: New page: Category:取得並安裝 Arch (繁體中文) Category:HOWTOs (繁體中文) {{i18n_links_start}} {{i18n_entry|English|Official Arch Linux Install Guide}} {{i18n_entry|简体中文...</p>
<hr />
<div>[[Category:取得並安裝 Arch (繁體中文)]]<br />
[[Category:HOWTOs (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
This is the general user documentation for the Arch Linux<br />
distribution, Codename (Don't Panic). It covers obtaining the necessary<br />
files, installing the distribution and setting up a basic, bootable<br />
system. Additionally a short reference for the system layout and<br />
Arch-specific tools is supplied, ie. the pacman package manager and<br />
ABS.<br />
<br />
==Introduction==<br />
<br />
===What is Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===License===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===Credits and Feedback===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==Installing Arch Linux==<br />
<br />
===Pre-Installation===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
What You Will Need<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===Acquiring Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===Preparing Installation Media===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===Using the CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===Common Installation Procedure===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
Installation Steps:<br />
<br />
#Loading a non-US Keymap<br />
#Running Setup<br />
#Configure Network (FTP Install only)<br />
#Prepare Hard Drive<br />
##Auto-Prepare<br />
##Partition Hard Drives<br />
##Set Filesystem Mountpoints<br />
#Select Packages<br />
#Install Packages<br />
#Configure System<br />
#Install Kernel<br />
#Install Bootloader<br />
#Exit Install<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==Package Management==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
Removing packages<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
Refreshing the package list<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
Upgrading the system<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
List installed packages<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
Check if a specific package is installed<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
Display specific package info<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===How to Build Packages===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===Package Guidelines===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
Package Naming<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==Frequently Asked Questions==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32071
The Arch Way (正體中文)
2007-11-08T20:33:05Z
<p>Arnix: 修改分類描述</p>
<hr />
<div>[[Category:關於 Arch (繁體中文)]]<br />
[[Category:一般 (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
我 , Judd Vinet , 因為兩個理由開始了Arch 的建造:<br />
<br />
# 我找不到一個發行版本符合我的想法。某些已經很接近的,卻帶有惱人的怪辟或者不必要的複雜特性,它們提供的壞處似乎比好處還多呢;<br />
# 為了樂趣 - 為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多。<br />
<br />
<br />
從本質來說, Arch 是:<br />
<br />
* 輕巧而且簡單的。 注意,這句話並不是針對所有人說的…<br />
<br />
* 它'''不是'''設計給新手用的發行版本; 它針對較有經驗的使用者。 The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* 免費的禮物, 再一次, "…為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多"。當你自別人那兒獲得了禮物,總會想要回饋些什麼。也因為如此,我們歡迎使用者貢獻他們的點子、工具以及建議。<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* Arch Linux 核心環境的開發,在不久的將來一段時間內不會提供任所謂「友善新手」的 圖形介面 或工具程式。<br />
<br />
* 我們這些卑微的開發者們將持續地提供 Arch 成為每個人腳下穩固的基石。如果你想讓它更好, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
Arch 開發時所遵循的價值系統:<br />
<br />
* KISS (保持簡單, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* 對 Arch 來說,「簡單」並非其如他發行版本所指的那樣。在我們的哲學裡,學習比讓某些變容易要來得重要。<br />
<br />
* 依賴圖形介面來建立並使用系統,最後的結果等於是在傷害使用者。 總有一天使用者會需要知道那些在圖形介面下隱藏的所有東西。<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* 針對 i686 最佳化。<br />
* [[pacman]]: '系統升級' 本身就一道指令: "pacman -Syu"<br />
* [[pacman]]: 無需 X/GUI 就能做相依性控管。<br />
* [[ABS]]: package-building 功能只要做一次就可以了 - 要為套件製作別種的版本是極容易的。<br />
* [[ABS]]: 您只要用一道指令就能重編機器上所有的套件。<br />
* 完全照您的需要為套件更新,完全地可客製化。<br />
* the people behind the scenes are gentle, motivated and able<br />
* 不到 20 分鐘就能建好一個功能完整的系統。<br />
* 提供一個學習 Linux 的完美環境。<br />
* 由於知道的人太少,真的很不流行。 (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide&diff=32069
Official Installation Guide
2007-11-08T20:29:01Z
<p>Arnix: </p>
<hr />
<div>[[Category:Getting and installing Arch (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|简体中文|正式的安装向导}}<br />
{{i18n_entry|繁體中文| 正式 Arch Linux 安裝指南}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
This is the general user documentation for the Arch Linux<br />
distribution, Codename (Don't Panic). It covers obtaining the necessary<br />
files, installing the distribution and setting up a basic, bootable<br />
system. Additionally a short reference for the system layout and<br />
Arch-specific tools is supplied, ie. the pacman package manager and<br />
ABS.<br />
<br />
==Introduction==<br />
<br />
===What is Arch Linux?===<br />
<br />
Arch Linux is an i686-optimized linux distribution that was originally<br />
based on ideas from CRUX, a great distribution developed by Per Lidén.<br />
<br />
Arch is fast, lightweight, flexible and simple. Those aren't very<br />
fancy buzzwords but they're all true. Arch is optimized for the i686<br />
processor, so you get more for your cpu cycle. It's lightweight<br />
compared to RedHat et al., and its simple design makes it easy to<br />
extend and mold into whatever kind of system you're building.<br />
<br />
This is backed by an easy-to-use binary package system that allows you<br />
to upgrade your entire system with one command. Arch also uses a<br />
ports-like package build system (the Arch Build System - ABS) to make<br />
it easy to build packages, which can also be synchronized with one<br />
command. Oh yeah, and you can rebuild your entire system with one<br />
command, too. Everything is done quite simply and transparently.<br />
<br />
Arch Linux strives to maintain the latest stable version of its<br />
software. We currently support a fairly streamlined core package set<br />
with a growing collection of extra packages maintained by AL<br />
developers, as well as literally thousands of additional packages<br />
submitted by trusted members of the community to our AUR for everyone<br />
to use as they see fit.<br />
<br />
In it's goal to be simple and lightweight, the relatively useless<br />
portions of a linux system have been left out, things like /usr/doc<br />
and the info pages. In my own personal experience these are rarely<br />
used, and equivalent information can be obtained from the net if need<br />
be. Manpages all the way!<br />
<br />
Arch Linux also strives to use some of the newer features that are<br />
available to linux users, Arch Linux 0.8 (Voodoo) of course uses <br />
the 2.6 Linux kernel and udev by default, and has support for <br />
EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM, and encrypted filesystems.<br />
<br />
===License===<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet and are licensed under the GNU Public<br />
License.<br />
<br />
===Credits and Feedback===<br />
<br />
This document is heavily based on the works of Judd Vinet<br />
judd@archlinux.org. Minor corrections and a good bunch of<br />
modifications and additions have been made by Dennis Herbrich<br />
dennis@archlinux.org and Tobias Powalowski tpowa@archlinux.org.<br />
Corrections and feedback should be fed into the bugtracker.<br />
An uncountable lot of people have contributed and will contribute to<br />
the evolution of the official Arch Linux Documentation<br />
by submitting corrections and suggesting improvement, it's way too<br />
unpractical to list them all. However, you know who you are, and<br />
without your help this would be near impossible to maintain and<br />
improve. Thank you!<br />
<br />
==Installing Arch Linux==<br />
<br />
===Pre-Installation===<br />
<br />
Arch Linux is optimized for the i686 processor and therefore will not<br />
run on any lower or incompatible generations of x86 CPUs<br />
(i386,i486,i586). A Pentium II or AMD K6-2 processor or higher is<br />
required. x86-64 architectures are also officially supported.<br />
<br />
There is a community-driven project that provides packages for i586<br />
and ppc. See this site for more information.<br />
<br />
Before installing Arch Linux, you should decide which installation<br />
method you would like to use. Arch Linux provides two different<br />
bootable ISO images for a CD-ROM installation.<br />
<br />
As the preferred method of installation is the flexible CD-ROM based<br />
installation, we offer you two variants of the installation medium<br />
which only differ in terms of supplied packages. You can instruct the<br />
installer to obtain the packages via FTP using any of these images,<br />
and all images can also be used as a last-resort recovery cd.<br />
<br />
* The considerably smaller 2007.08 iso (~150MB) only contains the base and kernels package categories and is otherwise identical. Please note that it is no longer necessary to download the full iso image if you plan using RAID/LVM during setup, as the necessary packages have been moved to base a while ago. Installing from a medium created with this image results in a completely functional linux system, without any frills, expecting to be used from the command line. This image is ideally suited for minimalists or experts who only want a basic, working system and go from there, and have a rather slow or difficult to set up internet connection to make an FTP install unfeasible. The name of the iso could be Archlinux-i686-2007.08-2.core.iso", according to your architecture<br />
* Finally, there is a new option available to the bandwidth-conscious, the tiny 2007.08 (~25MB) containing only the bare minimum to get the installer process running. This variant contains no packages at all, and is therefore only useful for an FTP installation, if you've got a fast and easy to setup internet connection or a package repository server on a LAN. With only 22MB this is the fastest way to start installing ArchLinux, and has the additional advantage of using the newest packages available at the time of installation instead of the release snapshot package versions included in the other images. Of course all packages you choose to install have to be downloaded from somewhere, but at least you don't have to update the system directly after installation, and safe yourself some hassle. If your network connection is cheap and fast, choose this image. <br />
<br />
If you do not have a CD-ROM drive attached to your computer, you're<br />
naturally stuck.<br />
<br />
Now obtain a bootable Arch installation CD image, either by<br />
downloading and burning one of the latest ISOs from one of the mirrors<br />
listed, or by letting someone else burn a copy if your dialup<br />
connection simply doesn't cut it, or you don't own a CD-ROM writer.<br />
You can also purchase a cd online from OSDisc, shipping nearly<br />
world-wide.<br />
<br />
Furthermore you should not worry about using an old ISO for<br />
installation, as upgrading the system to the current branch is a<br />
breeze once you've got your basic system set up. At least if you've<br />
got a broadband connection!<br />
<br />
Using a dialup PPP connection to gain access to the internet during<br />
the install process is NOW supported. ppp utilities, rp-pppoe<br />
and the ISDN userspace utilities are included in the installation<br />
media.<br />
<br />
The 2007.08 Isos now run like any installed arch system, <br />
here are the highlights: <br />
* pacman is included to allow installation of any other needed package in install environment.<br />
* complete /etc/rc.d/ and /etc/rc.conf support<br />
* complete arch network support, including ssh,telnet and portmap services<br />
* custom config files support: any media with /config directory and files will be copied to /etc/ install environment<br />
* loading packages as addons during boot: any media with /packages directory including pacman packages will be installed during bootup.<br />
* links and naim included to be able to communicate over the internet.<br />
* complete kexec support<br />
<br />
The newbie-friendliest method of installing Arch Linux surely is<br />
installing the base system and all you need to get online from the CD,<br />
and then run a complete system upgrade and add any other packages you<br />
want or need once you set up your internet connection.<br />
<br />
Another thing you should know before trying to install Arch Linux is<br />
that during the install you're asked a few questions about which hard<br />
drive to prepare, what modules to load, and what changes to make to<br />
certain system-critical files like lilo.conf and rc.conf. The<br />
installer will not hold your hand here and guide you through any<br />
potential setup known and unknown to mankind, you are expected to know<br />
what to put in and leave out. This is quite a requirement for a<br />
newbie, so if this intimidates you already, make sure you read through<br />
this whole document to get at least a vague idea what is going to be<br />
asked, and check back on IRC, the forums or a linux guru in your<br />
neighborhood if anything is not clear to you before you totally mess<br />
up your system. You may of course boldly step into the fight and<br />
tinker and try around until it works, but don't tell anyone afterwards<br />
you haven't been warned. That being said, it's not that bad. ;)<br />
<br />
What You Will Need<br />
<br />
* a working knowledge of Linux and your system, especially your hardware<br />
* Arch Linux installation media (see the mirror list)<br />
* an i686-based or x86-64 computer (PPro, Pentium 2 or higher, Athlon/Duron, etc. Note that AMD K6, Transmeta Crusoe, CyrixIII, and VIA-C3 are NOT supported.)<br />
* 128 MB RAM<br />
* some time to kill<br />
<br />
===Acquiring Arch Linux===<br />
<br />
You can download Arch Linux from any of the Arch Linux [[Mirror|mirrors]]. Just follow the links into the "iso" directory and choose the version you wish to install. In general, you are best to download the latest version as this helps avoid any difficulties during your initial update.<br />
<br />
===Preparing Installation Media===<br />
<br />
*Download <mirror>/iso/<your_architecture>/Archlinux-<version>.iso (path relative to mirror root)<br />
*Download <mirror>/iso/<your_architecture>/md5sum-<version>.txt<br />
*Verify the integrity of the .iso image using md5sum:<br />
md5sum Archlinux-<version>.iso<br />
*Burn the .iso image to a blank CD-R (this step varies depending on the OS/software you're using). If you want to download the base, ftp or a beta ISO instead, use the appropriate filename, ie: arch-0.8-base.iso instead of arch-0.8.iso, likewise for the md5sum.<br />
*Write down all your network settings so you can enter them into setup later, if you want to install via FTP:<br />
**IP Address<br />
**Subnet Mask<br />
**Gateway<br />
**Ethernet Module for your network card (eg.: eepro100, 8139too, ne2k-pci, etc.)<br />
<br />
===Using the CD-ROM===<br />
If you're already familiar with the boot process, you may skip all this <br />
babble as well, and jump to the Common Install Procedure, which outlines <br />
the actual process of installing Arch Linux.<br />
<br />
Reboot your computer with the Arch Linux Installation CD in the drive.<br />
Make sure your BIOS is set in a way to allow booting from your CD-ROM.<br />
Refer to your motherboard manual or your system manufacturer for<br />
details if you have no clue how to do that. Once the CD is booted<br />
from, you will see a boot prompt waiting for you pressing a key<br />
indefinitely, explaining what your options are at this point. Most<br />
users can just hit Enter.<br />
<br />
If your CD-ROM fails to boot for no obvious reason, and you're using a<br />
rather old CD-ROM drive in conjunction with a copy burned to a CD-RW,<br />
consider using a normal CD-R instead. Some older drives [two of mine,<br />
for example - Dennis] don't manage to read CD-RWs properly.<br />
<br />
At the end of the boot procedure, you should be dropped into a root<br />
shell with a handful of instructions filling the upper half of your<br />
screen. At this point you are ready to commence the actual<br />
installation, or do any manual preparation you consider necessary.<br />
<br />
===Common Installation Procedure===<br />
<br />
At this point your system should be booted, and the hard drive to<br />
which you'd like to install, as well as your installation source, must<br />
be accessible.<br />
<br />
Installation Steps:<br />
<br />
#Loading a non-US Keymap<br />
#Running Setup<br />
#Configure Network (FTP Install only)<br />
#Prepare Hard Drive<br />
##Auto-Prepare<br />
##Partition Hard Drives<br />
##Set Filesystem Mountpoints<br />
#Select Packages<br />
#Install Packages<br />
#Configure System<br />
#Install Kernel<br />
#Install Bootloader<br />
#Exit Install<br />
<br />
Using the available shell tools, experienced users are also able to<br />
prepare the hard drive or any devices needed for the installation<br />
before starting the installer. You may simply skip this paragraph if<br />
you don't see any immediate need for further manual interaction. Note<br />
that the Arch Linux installation media also contains a /arch/quickinst<br />
script for experienced users. This script installs the "base" set of<br />
packages to a user-specified destination directory. If you are doing<br />
an exotic install with fun things like RAID and LVM, or don't want to<br />
use the installer at all, you'll probably want to use the quickinst<br />
script. All the cool kids do it.<br />
<br />
====Loading a non-US Keymap====<br />
<br />
If you require a non-US keymap, you can use the km utility to load a<br />
new keymap. Just type km at the prompt, then use the arrow keys to<br />
navigate to the correct keymap and/or console font.<br />
<br />
====Running Setup====<br />
<br />
Now you can run /arch/setup to invoke the installer program. After an<br />
informational message you will be prompted for the installation method<br />
of your choice. If you have a fast internet connection, you might<br />
prefer the FTP installation to ensure you get the latest packages<br />
instead of using the potentially outdated CD contents. Please note<br />
that you will probably run into trouble if you have a complex proxy<br />
setup with authentication when using the FTP installation. If you<br />
can't use a CD-ROM, or any other medium you could mount at this stage,<br />
this is the only viable method of installing Arch Linux.<br />
<br />
When navigating the setup script, make sure that you select DONE from<br />
the submenus after performing each step. This saves any settings you<br />
make in preparation for the next step. Further, avoid arbitrary steps<br />
through the installation process as this can also confuse the<br />
installer.<br />
<br />
It's actually rather easy to set up your own FTP package mirror or<br />
create your own bootable installation CD with the packages you need,<br />
making the task of installing several instances of Arch Linux across<br />
multiple machines rather simple, while at the same time saving a lot<br />
of mirror bandwidth. Make your life and ours easier, and look into<br />
these alternatives!<br />
<br />
When choosing a CD-ROM or OTHER SOURCE install you will only be able<br />
to install packages contained on the CD, which may be quite old, or<br />
packages stored on a medium you were able to mount (DVD, USB stick or<br />
similar) somewhere in the filesystem tree manually. Of course it has<br />
the merit that you won't need an internet connection, and is therefore<br />
the recommended choice for dialup users or anyone else who does not<br />
feel like downloading about at least 100 MB of packages.<br />
<br />
After choosing one of the two alternatives, you will be presented with<br />
the installer menu, listing the necessary steps in the order in which<br />
they should be completed.<br />
<br />
At any point in the install process, you can switch to your 5th<br />
virtual console (ALT-F5) to view the output from the commands the<br />
setup is running. Use (ALT-F1) to get back to your first console where<br />
the installer is running, and any F-key in between if you need to open<br />
another console to intervene manually for any reason.<br />
<br />
====Configure Network (FTP Install only)====<br />
<br />
Configure Network will allow you to install and configure your network<br />
device.<br />
<br />
A list of all currently available network devices is presented to you.<br />
If no ethernet device is available yet, or not the one you want to<br />
use, you may choose to switch to another terminal first using ALT-F2<br />
for example, and load the necessary modules manually. Alternatively,<br />
you may just do as instructed, hit OK, and probe for a network module<br />
in the following screen by selecting the Probe command. If the<br />
installer fails to find a matching network module, make sure you ran<br />
the loaddisk command correctly earlier to make the ethernet modules<br />
available, if you are using floppies. When booting from CD-ROM, this<br />
is not necessary. If your network card is still not found, make sure<br />
your card is properly physically installed and supported by the linux<br />
kernel at all. Sometimes it's necessary to obtain a binary,<br />
proprietary driver from the manufacturer of your network card, and<br />
somehow manage to copy it to the installation system and load it<br />
manually. This is usually nothing for the faint of heart, and using a<br />
different model of network card is advised.<br />
<br />
When the correct module is loaded, and your desired network card is<br />
listed, you should Select the ethernet device you want to configure<br />
and you will be given the option to configure your network with DHCP.<br />
If you're connected to a DHCP server, hit YES and let the installer do<br />
the rest. If you select NO, you will be asked to enter the networking<br />
information manually, which you hopefully wrote down as you were told.<br />
Either way, your network should be successfully configured, and if<br />
you're of the skeptical kind, you may check connectivity using<br />
standard tools like ping on another console.<br />
<br />
As automatisms are not perfect, you may not be able to successfully<br />
use the installer to set up your network. In these rare cases, don't<br />
bother, and set up you network device manually in one of the consoles.<br />
All the installer needs is a transparent connection to the ftp server<br />
you are going to select later during the installation.<br />
<br />
This menu entry is only available when choosing FTP Installation, for<br />
rather obvious reasons.<br />
<br />
====Prepare Hard Drive====<br />
<br />
Prepare Hard Drive will lead you into a submenu offering two<br />
alternatives of preparing your target drive for installation.<br />
<br />
The first choice is Auto-Prepare, which will automatically partition<br />
your hard drive into a /boot, swap, and root partition, and then<br />
create filesystems on all three. These partitions will also be<br />
automatically mounted in the proper place. To be exact, this option<br />
will create a<br />
* 32 MB ext2 /boot partition<br />
* 256 MB swap partition<br />
* root and /home partition with the remaining space<br />
<br />
Actual sizes may vary slightly due to different hard disk geometries.<br />
You can choose this option if you don't know much about hard drive<br />
partitions, but be warned:<br />
<br />
AUTO-PREPARE WILL ERASE ALL DATA ON THE CHOSEN HARD DRIVE!<br />
Read the warning presented by the installer very carefully, and make<br />
sure the correct device is about to be partitioned!<br />
<br />
A way to verify your choice for a device to partition would be to open<br />
another terminal (ALT-F2, Enter) and enter<br />
cfdisk -P s <name of device><br />
<br />
there to display the current partition table of the selected device,<br />
which should suffice to identify the hard disk.<br />
<br />
If no device name is shown ("[nothing] will be COMPLETELY ERASED!<br />
..."), and the installer produces an "Device not valid" error after<br />
hitting YES, make sure you loaded all needed modules if it's a SCSI,<br />
RAID, etc. device. You can still load any modules now by changing to<br />
another terminal and issuing the commands there, then return to the<br />
installer process on terminal one (ALT-F1).<br />
<br />
If you prefer to do the partitioning manually, use the other two<br />
options, Partition Hard Drives and Set Filesystem Mountpoints to<br />
prepare the target media according to your specifications as outlined<br />
below. Then Return to Main Menu after a successful preparation.<br />
<br />
====Partition Hard Drives====<br />
<br />
Partition Hard Drives should be skipped if you chose Auto-Prepare<br />
already!<br />
<br />
Otherwise you should select the disk(s) you want to partition, and<br />
you'll be dropped into the cfdisk program where you can freely modify<br />
the partitioning information until you [Write] and [Quit].<br />
<br />
You will need at least a root partition to continue the installation,<br />
and it's helpful to note somewhere which partition you're going to<br />
mount where, as you'll be asked exactly that in the next step.<br />
<br />
====Set Filesystem Mountpoints====<br />
<br />
Set Filesystem Mountpoints should also be skipped if you chose to<br />
Auto-Prepare your hard drive. You should select this choice once the<br />
partition information is edited to your liking with the previous menu<br />
selection, or already existent through whatever other means.<br />
<br />
The first question to answer is what partition to use as swap. Select<br />
the previously created swap partition from the list, or NONE, if you<br />
don't want to use a swap partition. Using a swap file is not directly<br />
supported by the installer; Instead choose NONE here, finish the<br />
mountpoint associations, and activate a swap file on your desired,<br />
formatted partition with the swapon command.<br />
<br />
After setting up the swap partition, you'll be asked to specify the<br />
partition to be used as the root partition. This is mandatory.<br />
<br />
The association process is then repeated until you choose DONE from<br />
the list, ideally after all listed partitions have been associated<br />
with their intended mountpoints. The installer will suggest /boot for<br />
all following mountpoints after choosing swap and root.<br />
<br />
Every time you specify a partition to mount, you will be asked if you<br />
want to create a filesystem on the respective partition. If you select<br />
YES, you will be asked what filesystem to create (a matter of taste,<br />
really. Choose ext3 if you have no clue), and the partition will be<br />
formatted with the chosen filesystem, destroying all data in the<br />
process. It should be no problem, however, to say NO at this point to<br />
preserve any existing files on the partition.<br />
<br />
If you want to preserve existing data on a partition, you are strongly<br />
advised to create backups instead of hoping that nothing will go wrong<br />
during the install. Don't say I didn't warn you!<br />
<br />
You will be asked whether to create a filesystem on your swap<br />
partition, and since this partition uses a specific filesystem of it's<br />
own, you should always answer YES here.<br />
<br />
If you want to mount any other partitions, for example a separate<br />
/boot or /home partition, you will be able to do so. Simply<br />
* select a partition to mount<br />
* choose a filesystem (if you want to create one instead of keeping the data)<br />
* enter a unique mountpoint for the partition<br />
<br />
Repeat these steps until you're satisfied, then select DONE to create<br />
any filesystems and mount the partitions in their respective places.<br />
Before the actual formatting is done, the installer will present to<br />
you a list of all of your choices for review. After formatting and<br />
mounting all partitions, you may return to the Main Menu and proceed<br />
with the next step.<br />
<br />
====Select Packages====<br />
<br />
Select Packages will let you select the packages you wish to install<br />
from the CD or your FTP mirror.<br />
<br />
If you chose CD-ROM installation, you have to tell the installer<br />
whether it should try to mount the CD itself, or whether you already<br />
mounted the source media on the /src directory. Select the option<br />
according to what you need; Normally you will want to choose CD, after<br />
which you will be given the possibility to choose a CD-ROM drive from<br />
the list of all detected devices.<br />
<br />
If your CD-ROM drive is not displayed in the list, make sure you<br />
loaded any modules that may be needed, like SCSI or USB storage<br />
support, and load them in another terminal if necessary.<br />
<br />
If you chose FTP Installation, you will be asked to choose a mirror<br />
close to you from a list, or select Custom to enter your own fully<br />
qualified domain name (or IP address) to an FTP server containing the<br />
installation source packages, ie. a prepared server in your LAN, or a<br />
mirror that's not listed for whatever reason, and afterwards the full<br />
path to the directory on the server that contains the packages and<br />
specifically the file core.db.tar.gz. The installer will check your<br />
input for validity, and allow you to make corrections until you enter<br />
an address and path that are reachable and allow downloading of the<br />
package list.<br />
<br />
Whatever source you chose, after fetching the package list you'll be<br />
dropped into the package category selection screen.<br />
<br />
If you are presented an error while fetching the package database, you<br />
should either choose another FTP mirror, make sure your network is<br />
working at all, and you didn't slip any typos into your custom server<br />
address. You might also have goofed mounting of your source media in<br />
the /src directory, if you chose that option. Read the messages<br />
presented to you carefully, in most cases all you need is a little<br />
tweaking of the directory layout on your source media or server,<br />
respectively.<br />
<br />
Now, once that is tackled, you have the opportunity to specify whole<br />
package groups from which you'd generally like to install packages,<br />
then fine-tune your coarse selection by (de)selecting individual<br />
packages from the groups you have chosen.<br />
<br />
Any packages in the BASE category should stay selected under all<br />
circumstances, and you should select any other group which contains a<br />
package you might need. Please note that the upcoming individual<br />
package selection screen will only offer packages which are in the<br />
categories you select here, so if you only select BASE, you won't be<br />
able to add any other packages than those in the BASE category.<br />
<br />
If you want to only select the bare minimum for installation, but be<br />
able to browse through all available packages nevertheless to see if<br />
anything interesting is there to add, you should select all package<br />
categories, but choose to NOT select all packages by default.<br />
<br />
The "Select all packages by default?" question can be easily<br />
misunderstood; Basically you are asked whether you want all the<br />
packages in the categories you just chose to be selected or not.<br />
If you select YES, the whole list of packages contained in the chosen<br />
categories will be displayed and selected, and your job will be to<br />
deselect what you do not want.<br />
If you select NO, the same list of packages will displayed, but only<br />
packages of the BASE category will be selected, and you'll have to<br />
explicitly select any other packages you want to install.<br />
<br />
Choosing NO helps to install a lean system!<br />
<br />
It is recommended that you install all the BASE packages, but not<br />
anything else at this point. Don't worry about getting all the<br />
packages you want - you can easily install more of them once the basic<br />
system boots by itself. The only exception to this rule is installing<br />
any packages you need for setting up internet connectivity. These<br />
packages usually are:<br />
<br />
dhcpcd (base)<br />
Add if your machine is a DHCP client.<br />
<br />
isdn4k-utils (network)<br />
Add if you use ISDN for dialup.<br />
<br />
ppp (base)<br />
Add if you use an analog modem for dialup.<br />
<br />
wvdial (network)<br />
Add if you'd like to have an easy frontend to analog modem<br />
dialup setup.<br />
<br />
rp-pppoe (base)<br />
Add if you use DSL for pseudo-dialup.<br />
<br />
The downloadable base ISO does not contain any packages but those in<br />
the BASE category, so be advised to get the full ISO if you need the<br />
ISDN packages or certain helper applications!<br />
<br />
Once you're done selecting the packages you need, leave the selection<br />
screen and continue to the next step, Install Packages.<br />
<br />
====Install Packages====<br />
<br />
Install Packages will now install pacman and any other packages you<br />
selected with resolved dependencies onto your harddisk. Don't be<br />
surprised if more packages are installed than you selected! Those<br />
packages are dependencies for your selection, and the installer will<br />
not explicitly ask for permission to install these extra packages, as<br />
it assumes you know what you're doing.<br />
<br />
After the package selection, the installer will not check for free<br />
space on the target! This seemingly trivial task would eat up<br />
considerable time, and therefore the installer simply assumes to have<br />
enough free space on the target partition(s). In case it doesn't, the<br />
installation will fail in various funny ways. A df -h in another<br />
terminal might show that one or more of the targets mounted below /mnt<br />
have been filled up, causing mischief. Consider repartitioning or<br />
selecting a smaller set of packages.<br />
<br />
Error messages and debugging output is echoed as usual to terminal<br />
five (ALT-F5). During normal, successful operation, you shouldn't find<br />
much to read there, though. After the packages have been installed,<br />
proceed to the next step, Configure System.<br />
<br />
====Configure System====<br />
<br />
Configure System allows you to edit the configuration files crucial<br />
for your newly installed system. Initially you will be asked whether<br />
to allow the hwdetect script to try and detect your hardware, and<br />
produce some (even more) sensible defaults for your configuration<br />
files. Unless you're having problems/crashes, you should let it have<br />
it's way, and work from what it generates.<br />
<br />
Answer the following questions about RAID, LVM and encrypted volumes<br />
with Yes, if your root partition resides on a RAID, LVM or encrypted<br />
volume, respectively, to automatically add the necessary HOOKS to the<br />
mkinitcpio.conf. Otherwise you will get a kernel panic during boot, as<br />
your root partition will not be accessible at the time of boot. Most<br />
people will answer these questions with No, though, and not waste a<br />
second thought about it.<br />
<br />
After this automatic preconfiguration you'll be asked for your<br />
favourite editor to use for manually fine-tuning the generated<br />
configuration files, either VIM or nano. When in doubt, choose nano.<br />
<br />
If you're in a real hurry, you may skip the following step of<br />
reviewing the configuration entirely and hope the defaults will work<br />
for you, but it's strongly recommended to iterate through the list of<br />
configuration files presented here and review the settings carefully.<br />
Please refer to the System Configuration section for detailed<br />
descriptions of the various files.<br />
<br />
====Install Kernel====<br />
<br />
Install Kernel will ask you which kernel image to install on your hard<br />
drive.<br />
<br />
2.6<br />
Install the stock 2.6 kernel with SCSI/SATA/IDE support. What<br />
exactly will be supported by the kernel during boot depends on<br />
how you configured your initial ramdisk, but the default has<br />
support for practically all SCSI, SATA, and IDE systems. See<br />
the System Configuration section for more information about the<br />
new initramfs, especially the potential pitfalls with the new<br />
PATA and ide legacy drivers.<br />
<br />
Please note that this release of Arch Linux only offers one kernel to<br />
install, as flexibility has now been put into the initramfs created by<br />
the mkinitcpio tool.<br />
<br />
The CD-ROM includes the 2.6.21.1 kernel. If you are using the FTP<br />
Installation method, the kernel about to be installed will be the<br />
current version waiting on your FTP source, and might therefore<br />
introduce changes and/or incompatibilities unknown at the present<br />
time. This is unlikely, but keep this in mind.<br />
<br />
====Install Bootloader====<br />
<br />
Install Bootloader will install a bootloader on your hard drive,<br />
either GRUB (recommended) or LILO, depending on your personal<br />
preference.<br />
<br />
Before installing the bootloader, the setup script will want you to<br />
examine the appropriate configuration file to confirm the proper<br />
settings. Make sure you know what your root (and /boot, if you have<br />
it) partitions are.<br />
<br />
If you choose to install LILO, the bootloader will be automatically<br />
installed according to your settings in the configuration file, whilst<br />
GRUB demands the selection of a partition to install the bootloader<br />
to. Here you should choose what you would enter as the boot option of<br />
LILO, which is usually the entry named /dev/hda, as it refers the<br />
master boot record of the first hard disk. Detailed error messages can<br />
be found as usual on VC5 (virtual console 5), if anything goes wrong.<br />
<br />
If you plan on setting up a multiboot system, it might be a better<br />
option to install the bootloader in your root or /boot partition, and<br />
refer to that boot sector from whatever other boot loader you want to<br />
reside in the master boot record.<br />
<br />
Installing a boot loader in the MBR will relentlessly overwrite any<br />
existing bootloader! Make sure you understand the implications of that<br />
if you're running a multiboot system, or want to preserve an installed<br />
bootloader from another OS!<br />
<br />
====Exit Install====<br />
<br />
Exit Install now, remove the CD from the drive, type reboot at the<br />
command line and cross your fingers!<br />
<br />
If your system boots up, you can log in as root without any password,<br />
so your first things to do are setting a password for root with the<br />
passwd command once you're logged in, add a user as outlined in the<br />
User Management section, and set up your Internet Connection.<br />
<br />
Congratulations! Now you can proceed getting into the nitty-gritty of<br />
configuring the interesting parts of your system, and adapt it to your<br />
needs!<br />
<br />
==System Configuration==<br />
<br />
These are the core configuration files for Arch Linux. You should be<br />
comfortable hand-editing these files with a text-editor, because there<br />
aren't any GUI apps to help you out. Only the most basic configuration<br />
files are listed here. If you need help configuring a specific<br />
service, please read the appropriate manpage or refer to any online<br />
documentation you need. In many cases, the Archlinux Wiki and forums<br />
are a rich source for help as well.<br />
<br />
Arch Linux does not use any abstraction layers to administrate your<br />
system. As a result, you can usually stick to any instructions<br />
published by the author of a software, or whatever you find in a<br />
search engine of your choice, and it'll work out without confusing<br />
your system, because your system just does not care.<br />
<br />
===Configuration Files===<br />
<br />
Before attempting to boot your newly installed system, you should at<br />
least glance over these files and make sure they are not too far off<br />
the mark.<br />
<br />
<br />
'''List of Configuration Files'''<br />
* Setup-relevant configuration files:<br />
** /etc/rc.conf<br />
** /etc/hosts<br />
** /etc/fstab<br />
** /etc/mkinitcpio.conf<br />
** /etc/modprobe.conf<br />
** /etc/resolv.conf<br />
** /etc/locale.gen<br />
** /boot/grub/menu.lst<br />
** /etc/lilo.conf<br />
* Additional configuration files:<br />
** /etc/conf.d/*<br />
** /etc/profile<br />
<br />
<br />
'''/etc/rc.conf'''<br />
<br />
This is the main configuration file for Arch Linux. It allows you to<br />
set your keyboard, timezone, hostname, network, daemons to run and<br />
modules to load at bootup, profiles, and more. You should read through<br />
all the settings in this file and make sure you understand them, and<br />
change them where appropriate:<br />
<br />
LOCALE<br />
This sets your system language, which will be used by all<br />
i18n-friendly applications and utilities. See locale.gen below<br />
for available options. This setting's default is fine for US <br />
English users.<br />
<br />
HARDWARECLOCK<br />
Either UTC if your BIOS clock is set to UTC, or localtime if<br />
your BIOS clock is set to your local time. If you have an OS<br />
installed which cannot handle UTC BIOS times correctly, like<br />
Windows, choose localtime here, otherwise you should prefer<br />
UTC, which makes daylight savings time a non-issue and has a<br />
few other positive aspects.<br />
<br />
TIMEZONE<br />
Specifies your time zone. Possible time zones are the relative<br />
path to a zoneinfo file starting from the directory<br />
/usr/share/zoneinfo. For example, a german timezone would be<br />
Europe/Berlin, which refers to the file<br />
/usr/share/zoneinfo/Europe/Berlin. If you don't know the exact<br />
name of your timezone file, worry about it later.<br />
<br />
KEYMAP<br />
Defines the keymap to load with the loadkeys program on bootup.<br />
Possible keymaps are found in /usr/share/kbd/keymaps. Please<br />
note that this setting is only valid for your TTYs, not any<br />
graphical window managers or X! Again, the default is fine for<br />
US users.<br />
<br />
CONSOLEFONT<br />
Defines the console font to load with the setfont program on<br />
bootup. Possible fonts are found in<br />
/usr/share/kbd/consolefonts.<br />
<br />
CONSOLEMAP<br />
Defines the console map to load with the setfont program on<br />
bootup. Possible maps are found in /usr/share/kbd/consoletrans.<br />
You will want to set this to a map suitable for your locale<br />
(8859-1 for Latin1, for example) if you're using an utf8 locale<br />
above, and use programs that generate 8-bit output. If you're<br />
using X11 for everyday work, don't bother, as it only affects<br />
the output of linux console applications.<br />
<br />
USECOLOR<br />
Enable (or disable) colorized status messages during boot-up.<br />
<br />
MOD_AUTOLOAD<br />
If set to "yes", Arch will scan your hardware at bootup and<br />
attempt to automatically load the proper modules for your<br />
system. This is done with the hwdetect utility.<br />
<br />
MOD_BLACKLIST<br />
This is an array of modules that you do not want to be loaded<br />
at bootup. For example, if you don't want that annoying PC<br />
speaker, you could blacklist the pcspkr module.<br />
<br />
MODULES<br />
In this array you can list the names of modules you want to<br />
load during bootup without the need to bind them to a hardware<br />
device as in the modprobe.conf. Simply add the name of the<br />
module here, and put any options into the modprobe.conf if need<br />
be. Prepending a module with a bang ('!') will not load the<br />
module during bootup (this is not the same as MOD_BLACKLIST!),<br />
thus allowing to "comment out" certain modules if necessary. A<br />
benefit of specifying networking modules here is that ethernet<br />
cards covered by the listed modules will always be detected in<br />
the order the modules are listed. This prevents the dreaded<br />
interface confusion where your ethernet hardware is assigned to<br />
seemingly random interfaces after each boot. An even better way<br />
to handle this is using static interface labels by configuring<br />
udev appropriately, though.<br />
<br />
USELVM<br />
Set to "YES" to run a vgchange during sysinit, thus activating<br />
any LVM groups. If you have no idea what this means, don't<br />
bother.<br />
<br />
HOSTNAME<br />
Set this to the hostname of the machine, without the domain<br />
part. This is totally your choice, as long as you stick to<br />
letters, digits and a few common special characters like the<br />
dash. Don't be too creative here, though, and when in doubt,<br />
use the default.<br />
<br />
INTERFACES<br />
Here you define the settings for your networking interfaces.<br />
The default lines and the included comments explain the setup<br />
well enough. If you do not use DHCP to configure a device, just<br />
keep in mind that the value of the variable (whose name must be<br />
equal to the name of the device which is supposed to be<br />
configured) equals the line which would be appended to the<br />
ifconfig command if you were to configure the device manually<br />
in the shell.<br />
<br />
ROUTES<br />
You can define your own static network routes with arbitrary<br />
names here. Look at the example for a default gateway to get<br />
the idea. Basically the quoted part is identical to what you'd<br />
pass to a manual route add command, therefore reading man route<br />
is recommended if you don't know what to write here, or simply<br />
leave this alone.<br />
<br />
NET_PROFILES<br />
Enables certain network profiles at bootup. Network profiles<br />
provide a convenient way of managing multiple network<br />
configurations, and are intended to replace the standard<br />
INTERFACES/ROUTES setup that is still recommended for systems<br />
with only one network configuration. If your computer will be<br />
participating in various networks at various times (eg, a<br />
laptop) then you should take a look at the<br />
/etc/network-profiles/ directory to set up some profiles. There<br />
is a template file included there that can be used to create<br />
new profiles.<br />
<br />
DAEMONS<br />
This array simply lists the names of those scripts contained in<br />
/etc/rc.d/ which are supposed to be started during the boot<br />
process. If a script name is prefixed with a bang (!), it is<br />
not executed. If a script is prefixed with an "at" symbol (@),<br />
then it will be executed in the background, ie. the startup<br />
sequence will not wait for successful completion before<br />
continuing. Usually you do not need to change the defaults to<br />
get a running system, but you are going to edit this array<br />
whenever you install system services like sshd, and want to<br />
start these automatically during bootup. This is basically<br />
Arch's way of handling what others handle with various symlinks<br />
to an init.d directory.<br />
<br />
<br />
'''/etc/hosts'''<br />
<br />
This is where you stick hostname/ip associations of computers on your<br />
network. If a hostname isn't known to your DNS, you can add it here to<br />
allow proper resolving, or override DNS replies. You usually don't<br />
need to change anything here, but you might want to add the hostname<br />
and hostname + domain of the local machine to this file, resolving to<br />
the IP of your network interface. Some services, postfix for example,<br />
will bomb otherwise. If you don't know what you're doing, leave this<br />
file alone until you read man hosts.<br />
<br />
<br />
'''/etc/fstab'''<br />
<br />
Your filesystem settings and mountpoints are configured here. The<br />
installer should have created the necessary entries for you, but you<br />
should look over it and make sure it's right, especially when using an<br />
encrypted root device, LVM or RAID.<br />
<br />
With the current kernel, an important change has been introduced<br />
pertaining to the ATA/IDE subsystem. The new pata (Parallel ATA)<br />
drivers replace the legacy IDE subsystem, and one important change is<br />
that the naming scheme for IDE disks has changed from the old hda,<br />
hdb, etc. to also use device names of the type sda, sdb, etc, just<br />
like SCSI and SATA devices do. Because of this, when using the new<br />
pata driver in the HOOKS of the /etc/mkinitcpio.conf, remember to use<br />
the appropriate device names in your /etc/fstab and bootloader<br />
configuration! Alternatively, you could use the /dev/disk/by-uuid/...<br />
or /dev/disk/by-label/... representations of your disk drives where<br />
available to make absolutely sure you're referring to the right<br />
partitions, and save yourself the trouble of sorting out whether<br />
you're supposed to use sda or hda. If that's not an option, here's the<br />
rundown; If you're using pata instead of ide in the HOOKS array of the<br />
/etc/mkinitcpio.conf, you'll be using the sd? names. If not, use the<br />
old style hd? names. It is therefore crucial to check the HOOKS array<br />
in the /etc/mkinitcpio.conf, to be able to adapt the other files<br />
accordingly.<br />
<br />
<br />
'''/etc/mkinitcpio.conf'''<br />
<br />
This file allows you to fine-tune the initial ramdisk (also commonly<br />
referred to as the "initrd") for your system. The initrd is a gzipped<br />
image that is read by the kernel during bootup. The purpose of the<br />
initrd is to bootstrap the system to the point where it can access the<br />
root filesystem. This means it has to load any modules that are<br />
required to "see" things like IDE, SCSI, or SATA drives (or USB/FW, if<br />
you are booting off a USB/FW drive). Once the initrd loads the proper<br />
modules, either manually or through udev, it passes control to the<br />
Arch system and your bootup continues. For this reason, the initrd<br />
only needs to contain the modules necessary to access the root<br />
filesystem. It does not need to contain every module you would ever<br />
want to use. The majority of your everyday modules will be loaded<br />
later on by udev, during the init process.<br />
<br />
By default, mkinitcpio.conf is configured to provide all known modules<br />
for IDE, SCSI, or SATA systems through so-called HOOKS. This means the<br />
default initrd should work for almost everybody. The downside to this<br />
is that there are many modules loaded that you will not need. This is<br />
easily visible by examining your module table after booting up (with<br />
the lsmod command). While this doesn't actually hurt anything, some<br />
people find it annoying. To cull this list down to only what you<br />
actually need, you can edit mkinitcpio.conf and remove the subsystem<br />
HOOKS (ie, IDE, SCSI, RAID, USB, etc) that you don't need.<br />
<br />
You can customize even further by specifying the exact modules you<br />
need in the MODULES array and remove even more of the hooks, but take<br />
heed to the comments in the file, as this is a touchy place to go<br />
crazy with removing entries!<br />
<br />
If you're using RAID or encryption on your root filesystem, then<br />
you'll have to tweak the RAID/CRYPT settings near the bottom. See the<br />
wiki pages for RAID/LVM, filesystem encryption, and mkinitcpio for<br />
more info.<br />
<br />
When you're finished tweaking mkinitcpio.conf, you must run mkinitcpio<br />
-p kernel26 as root to regenerate the images, unless you're still<br />
installing the system; In that case this step will be done<br />
automatically after choosing Install Kernel later in the process.<br />
<br />
WARNING: If you fail to set up your mkinitcpio.conf correctly, your<br />
system will not boot! For this reason, you should be especially<br />
careful when tweaking this file.<br />
<br />
If you do manage to render your system unbootable, you can try using<br />
the fallback image that is installed alongside the stock kernel. A<br />
boot option for this is included in the default GRUB and LILO <br />
configuration.<br />
<br />
Read the warning about the pata transition problems elaborated in the<br />
fstab section carefully!<br />
<br />
<br />
'''/etc/modprobe.conf'''<br />
<br />
This tells the kernel which modules it needs to load for system<br />
devices, and what options to set. For example, to have the kernel load<br />
your Realtek 8139 ethernet module when it starts the network (ie.<br />
tries to setup eth0), use this line:<br />
alias eth0 8139too<br />
<br />
The syntax of this file is nearly identical to the old modules.conf<br />
scheme, unless you use some of the more exotic options like<br />
post-install. Then you should invest a little time into reading man<br />
modprobe.conf.<br />
<br />
Most people will not need to edit this file.<br />
<br />
<br />
'''/etc/resolv.conf'''<br />
<br />
Use this file to manually setup your nameserver(s) that you want to<br />
use. It should basically look like this:<br />
search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2<br />
<br />
Replace domain.tld and the ip addresses with your settings. The<br />
so-called search domain specifies the default domain that is appended<br />
to unqualified hostnames automatically. By setting this, a ping myhost<br />
will effectively become a ping myhost.domain.tld with the above<br />
values. These settings usually aren't mighty important, though, and<br />
most people should leave them alone for now. If you use DHCP, this<br />
file will be replaced with the correct values automatically when<br />
networking is started, meaning you can and should happily ignore this<br />
file.<br />
<br />
<br />
'''/etc/locale.gen'''<br />
<br />
This file contains a list of all supported locales and charsets<br />
available to you. When choosing a LOCALE in your /etc/rc.conf or when<br />
starting a program, it is required to uncomment the respective locale<br />
in this file, to make a "compiled" version available to the system,<br />
and run the locale-gen command as root to generate all uncommented<br />
locales and put them in their place afterwards. You should uncomment<br />
all locales you intend to use.<br />
<br />
During the installation process, you do not need to run locale-gen<br />
manually, this will be taken care of automatically after saving your<br />
changes to this file.<br />
<br />
By default, all locales are commented out, including the default<br />
en_US.utf8 locale referred to in the /etc/rc.conf file. To make your<br />
system work smoothly, you must edit this file and uncomment at least<br />
the one locale you're using in your rc.conf.<br />
<br />
<br />
'''/boot/grub/menu.lst'''<br />
<br />
GRUB is the default bootloader for Arch Linux. You should check and<br />
modify this file to accommodate your boot setup if you want to use<br />
GRUB, otherwise read on about the LILO configuration.<br />
<br />
Make sure you read the warning regarding the pata transition<br />
elaborated on in the fstab section!<br />
<br />
Configuring GRUB is quite easy, the biggest hurdle is that it uses yet<br />
another device naming scheme different from /dev; Your hard disks as a<br />
whole are referred to as (hd0), (hd1), etc., sequentially numbered in<br />
order of appearance on the IDE/SCSI bus, just like the hda, hdb, etc.<br />
names in Linux. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 meaning the first partition. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding.<br />
<br />
Once you grasped the concept of device naming, all you need to do is<br />
to choose a nice title for your boot section(s), supply the correct<br />
root partition device as a parameter to the root option to have it<br />
mounted as / on bootup, and create a kernel line that includes the<br />
partition and path where the kernel is located as well as any boot<br />
parameters. If using the stock Arch 2.6.x kernel, you'll also need an<br />
initrd line that points to the kernel26.img file in your /boot<br />
directory. The path you put on your initrd line should be the same as<br />
the path to vmlinuz26 that you provide on the kernel line. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines, especially in<br />
regard to the pata issue!<br />
<br />
To create a boot option that loads the bootsector of a different OS,<br />
the following example might be helpful. You will probably succeed in<br />
starting any Microsoft-based operating system with it, just add this<br />
block to the file after any other sections, and modify the partition<br />
device accordingly to refer to the partition containing the bootsector<br />
of the OS you are intending to boot.<br />
(1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1<br />
<br />
For advanced configuration of other OSes, please refer to the online<br />
GRUB manual.<br />
<br />
After checking your bootloader configuration for correctness, you'll<br />
be prompted for a partition to install the loader to. Unless you're<br />
using yet another boot loader, you should install GRUB to the MBR of<br />
the installation disk, which is usually represented by the appropriate<br />
device name without a number suffix.<br />
<br />
<br />
'''/etc/lilo.conf'''<br />
<br />
This is the configuration file for the LILO bootloader. Make sure you<br />
check this one and get it right if you want to use LILO to boot your<br />
system. See LILO documentation for help on this.<br />
<br />
Things you should check are the root= lines in the image sections and<br />
the boot= line right at the beginning of the file. The root lines<br />
specify the device which shall be mounted as the root filesystem on<br />
bootup. If you don't know what is supposed to be entered here, change<br />
to another terminal and type mount to see a list of all currently<br />
mounted drives, and look for the line which displays a device name<br />
mounted on /mnt type [...]. The device path at the beginning of this<br />
very line should be entered in the root lines of your lilo.conf.<br />
Change if necessary, and keep the pata issue in mind!<br />
<br />
The boot line should be okay by default in most cases. Unless you have<br />
a weird boot manager setup in mind with multiple OSes, the device<br />
referenced here should be having the same prefix your root lines have,<br />
but not end with a number. For example, a root of /dev/hda3 means you<br />
probably want to install LILO into the Master Boot Record of the hard<br />
disk, so you would set boot to /dev/hda, which references the disk as<br />
a whole. During installation, the boot device must be the current name<br />
of the device where you want to write the boot sector to; This may<br />
differ from the name of the device after the first boot, thanks to the<br />
pata transition! Check carefully what device to write to during the<br />
installation stage, for example with the mount command.<br />
<br />
To prevent some serious grief, you should make sure you know how to<br />
restore the bootsector of your other OSes, for example with Windows's<br />
FIXBOOT/FIXMBR tools.<br />
<br />
To be on the safe side, you should keep the option lba32 listed. This<br />
will prevent some geometry issues from happening.<br />
<br />
In some cases, depending on your BIOS, LILO will not run on bootup and<br />
spill out an error code infinitely. In most cases you either removed<br />
the lba32 option, or your hardware setup is a little special, meaning<br />
that maybe your CD-ROM drive is primary master and the hard disk you<br />
installed secondary slave. This can very well confuse your BIOS, and<br />
thus stop the boot process. To prevent that you can try and make the<br />
install drive the primary master on your IDE bus. If you've got a<br />
mixed IDE and SCSI system and the problem persists, you'll probably<br />
need some experimentation with the disk and bios options of LILO to<br />
provide a working mapping; The disk drives in your system are numbered<br />
sequentially by your BIOS, starting with 0x80. If you're lucky your<br />
SCSI controller tells you which drive has which BIOS ID, but usually<br />
you're not. How the drives are effectively numbered is depending on<br />
your BIOS, so in the worst case you can only guess until it works. A<br />
typical disk line would look like this:<br />
boot=/dev/hda<br />
disk=/dev/hda bios=0x80<br />
<br />
The disk option maps a BIOS ID to the disk device known to linux. Note<br />
that there is still no guarantee that things will work as other things<br />
can be wrong, so do not despair if all your tries fail, but rather try<br />
rearranging your hardware in a way that's not totally odd. In this<br />
area too much can go wrong and needs special handling to be explained<br />
here. In most cases the lba32 option will suffice anyway. Old hard<br />
drives will usually need a little more special care until they do as<br />
told.<br />
<br />
Don't become fidgety when reading this section, I (Dennis) just<br />
happened to stumble over this problem when experimenting with a rather<br />
odd system, and figured it'd be a good idea to mention this show<br />
stopper and workarounds here. You probably won't ever experience this,<br />
as you should be using GRUB anyway.<br />
<br />
How to recreate a LILO boot sector with only a rescue disk is<br />
explained later in this document.<br />
<br />
<br />
'''/etc/conf.d/*'''<br />
<br />
During setup, this is totally unimportant. Consider this as reference<br />
for the interested.<br />
<br />
Some daemon scripts will have a matching configuration file in this<br />
directory that contains some more-or-less useful default values. When<br />
a daemon is started, it will first source the settings from it's<br />
config file within this directory, and then source the /etc/rc.conf.<br />
This means you can easily centralize all your daemon configuration<br />
options in your /etc/rc.conf simply by setting an appropriate variable<br />
value, or split up your configuration over multiple files if you<br />
prefer a decentralized approach to this issue. Isn't life great if<br />
it's all just simple scripting?<br />
<br />
<br />
'''/etc/profile'''<br />
<br />
This script is run on each user login to initialize the system. It is<br />
kept quite simple under Arch Linux, as most things are. You may wish<br />
to edit or customize it to suit your needs.<br />
<br />
===Boot Scripts===<br />
<br />
Arch Linux uses a fairly simple bootup sequence quite similar to *BSDs. The first boot script to run is /etc/rc.sysinit. When it's done, /etc/rc.multi will be called (in a normal bootup). The last script to run will be /etc/rc.local. When started in runlevel 1, the single user mode, the script /etc/rc.single is run instead of /etc/rc.multi. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the bootup sequence for all possible runleves. In fact, due to this approach Arch only really has three runlevels, if you take starting up X in runlevel 5 into account. The boot scripts are using the variables and definitions found in the /etc/rc.conf file and also a set of general functions defined in the<br />
/etc/rc.d/functions script. If you plan to write your own daemon<br />
files, you should consider having a look at this file and existing<br />
daemon scripts.<br />
<br />
Boot Script Overview<br />
<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/rc.shutdown<br />
#/etc/rc.local.shutdown<br />
#/etc/rc.d/*<br />
<br />
<br />
'''/etc/rc.sysinit'''<br />
<br />
The main system boot script. It does boot-critical things like<br />
mounting filesystems, running udev, activating swap, loading modules,<br />
setting localization parameters, etc. You will most likely never need<br />
to edit this file!<br />
<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is<br />
started in single-user mode, for example with the kernel parameter 1<br />
before booting or during normal multi-user operation with the command<br />
init 1, this script makes sure no daemons are running except for the<br />
bare minimum; syslog-ng and udev. The single-user mode is useful if<br />
you need to make any changes to the system while making sure that no<br />
remote user can do anything that might cause data loss or damage.<br />
<br />
For desktop users, this mode usually is useless as crud. You should<br />
have no need to edit this script, either.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the<br />
DAEMONS array (set in /etc/rc.conf) after which it calls<br />
/etc/rc.local. You shouldn't feel a pressing need to edit this file.<br />
<br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any<br />
last-minute commands you want the system to run at the very end of the<br />
bootup process. This is finally the one and only script you should<br />
modify if needed, and you have total freedom on what to add to this<br />
script.<br />
<br />
Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place<br />
where they belong. To avoid confusion, you should make sure that<br />
whatever you intend to add to your rc.local isn't feeling just as home<br />
in /etc/profile.d/ or any other already existant config location<br />
instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems,<br />
deactivates the swap, etc. Just don't touch.<br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any<br />
commands you want to run right before the common rc.shutdown is<br />
executed. Please note that this file does not exist by default, and<br />
for it to work properly, it must be set as executable.<br />
<br />
<br />
'''/etc/rc.d/*'''<br />
<br />
This directory contains the daemon scripts referred to from the<br />
rc.conf's DAEMONS array. In addition to being called on bootup, you<br />
can use these scripts when the system is running to manage the<br />
services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. Of course a script only exists when the<br />
appropriate package has been installed (in this case postfix). With a<br />
basic system install, you don't have many scripts in here, but rest<br />
assured that all relevant daemon scripts end up here. This directory<br />
is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/<br />
directories of other distributions, without all the symlink hassle.<br />
<br />
===User Management===<br />
<br />
Users and groups can be added and deleted with the standard commands<br />
provided in the util-linux package: useradd, userdel, groupadd,<br />
groupdel, passwd, and gpasswd. The typical way of adding a user is<br />
similar to this procedure:<br />
useradd -m -s /bin/bash johndoe<br />
passwd johndoe<br />
<br />
The first command will add the user named johndoe to the system,<br />
create a home directory for him at /home/johndoe, and place some<br />
default login files in his home directory. It will also set his login<br />
shell to be /bin/bash. The second command will ask you for a password<br />
for the johndoe user. A password is required to activate the account.<br />
<br />
As an alternative to the useradd command, the adduser script is also<br />
available to interactively create new users on your system simply by<br />
answering questions.<br />
<br />
See the manpages for more information on the remaining commands. It is<br />
a good idea to create one or multiple normal users for your day-to-day<br />
work to fully use the available security features and minimize<br />
potential damage that may be the result of using the root user for<br />
anything but system administration tasks.<br />
<br />
===Internet Access===<br />
<br />
Due to a lack of developers for dialup issues, connecting Arch to the<br />
Internet with a dialup line is requiring a lot of manual setup. If at<br />
all possible, set up a dedicated router which you can then use as a<br />
default gateway on the Arch box.<br />
<br />
There are quite a few dialup related documents in the Arch Linux Wiki<br />
<br />
<br />
'''Analog Modem'''<br />
<br />
To be able to use a Hayes-compatible, external, analog modem, you need<br />
to at least have the ppp package installed. Modify the file<br />
/etc/ppp/options to suit your needs and according to man pppd. You<br />
will need to define a chat script to supply your username and passwort<br />
to the ISP after the initial connection has been established. The<br />
manpages for pppd and chat have examples in them that should suffice<br />
to get a connection up and running if you're either experienced or<br />
stubborn enough. With udev, your serial ports usually are /dev/tts/0<br />
and /dev/tts/1.<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt<br />
to install wvdial or a similar tool to ease the setup process<br />
considerably.<br />
<br />
In case you're using a so called WinModem, which is basically a PCI<br />
plugin card working as an internal analog modem, you should indulge in<br />
the vast information found on the LinModem homepage.<br />
<br />
<br />
'''ISDN'''<br />
<br />
Setting up ISDN is done in three steps:<br />
#Install and configure hardware<br />
#Install and configure the ISDN utilities<br />
#Add settings for your ISP<br />
<br />
The current Arch stock kernels include the necessary ISDN modules,<br />
meaning that you won't need to recompile your kernel unless you're<br />
about to use rather odd or old ISDN hardware. After physically<br />
installing your ISDN card in your machine or plugging in your USB<br />
ISDN-Box, you can try loading the modules with modprobe. Nearly all<br />
passive ISDN PCI cards are handled by the hisax module which needs two<br />
parameters; type and protocol. You must set protocol to '1' if your<br />
country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3'<br />
if you're hooked to a so called leased-line without D-channel, and '4'<br />
for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the<br />
kernel documentation, more specifically in the isdn subdirectory,<br />
available online. The type parameter depends on your card; A list of<br />
all possible types is to be found in the README.HiSax kernel<br />
documentation. Choose your card and load the module with the<br />
appropriate options like this:<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my (Dennis) ELSA Quickstep<br />
1000PCI, being used in Germany with the EDSS1 protocol. You should<br />
find helpful debugging output in your /var/log/everything.log file in<br />
which you should see your card being prepared for action. Please note<br />
that you will probably need to load some usb modules before you can<br />
work with an external USB ISDN Adapter.<br />
<br />
Once you confirmed that your card works with certain settings, you can<br />
add the module options to your /etc/modprobe.conf:<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively you can only add the options line here, and add hisax to<br />
your MODULES array in the rc.conf. Your choice, really, but this<br />
example has the advantage that the module will not be loaded until<br />
it's really needed.<br />
<br />
That being done you should have working, supported hardware. Now you<br />
need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl,<br />
it'll get you started. Further down in the manpage you will find<br />
explanations on how to create a configuration file that can be parsed<br />
by isdnctrl, as well as some helpful setup examples.<br />
<br />
Please note that you have to add your SPID to your MSN setting<br />
separated by a colon if you use US NI1.<br />
<br />
After you configured your ISDN card with the isdnctrl utility, you<br />
should be able to dial into the machine you specified with the<br />
PHONE_OUT parameter, but fail the username and password<br />
authentication. To make this work add your username and password to<br />
/etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were<br />
configuring a normal analogous PPP link, depending on which protocol<br />
your ISP uses for authentication. If in doubt, put your data into both<br />
files.<br />
<br />
If you set up everything correctly, you should now be able to<br />
establish a dialup connection with isdnctrl dial ippp0 as root. If you<br />
have any problems, remember to check the logfiles!<br />
<br />
<br />
'''DSL (PPPoE)'''<br />
<br />
These instructions are only relevant to you if your PC itself is<br />
supposed to manage the connection to your ISP. You do not need to do<br />
anything but define a correct default gateway if you are using a<br />
separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to<br />
physically install the network card that is supposed to be connected<br />
to the DSL-Modem into your computer. After adding your newly installed<br />
network card to the modprobe.conf or the MODULES array, you should<br />
install the rp-pppoe package and run the pppoe-setup script to<br />
configure your connection. After you have entered all required data,<br />
you can connect and disconnect your line with<br />
/etc/rc.d/adsl start<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward,<br />
but feel free to read the manpages for hints. If you want to<br />
automatically dial in on bootup, add adsl to your DAEMONS array.<br />
<br />
==Package Management==<br />
<br />
===Pacman===<br />
<br />
pacman is the package manager which tracks all the software installed<br />
on your system. It has simple dependency support and uses the standard<br />
gzipped tar archive format for all packages. Some common tasks are<br />
explained below with the respective commands in long and short option<br />
form. For an up to date explanation of pacman's options, read man<br />
pacman. This overview is merely scratching the surface of pacman's<br />
current capabilities.<br />
<br />
Typical tasks:<br />
<br />
1. Adding a new package with a package file<br />
2. Upgrading a package with a package file<br />
3. Removing packages<br />
4. Refreshing the package list<br />
5. Upgrading the system<br />
6. Adding/Upgrading a package from the repositories<br />
7. List installed packages<br />
8. Check if a specific package is installed<br />
9. Display specific package info<br />
10. Display list of files contained in package<br />
11. Find out which package a specific file belongs to<br />
<br />
Adding a new package with a package file<br />
<br />
pacman --add foo.pkg.tar.gz<br />
pacman -A foo.pkg.tar.gz<br />
<br />
This will install the foo.pkg.tar.gz package on the system. If<br />
dependencies are missing, pacman will exit with an error and report<br />
the missing deps, but not attempt to resolve the dependencies<br />
automatically. Look at the --sync option if you expect this<br />
functionality. Adding multiple package files is possible, and if the<br />
listed files depend on each other, the packages will be automatically<br />
installed in the correct order.<br />
<br />
Upgrading a package with a package file<br />
<br />
pacman --upgrade foo.pkg.tar.gz<br />
pacman -U foo.pkg.tar.gz<br />
<br />
This does essentially the same as the --add operation, but will<br />
additionally upgrade an already-installed package at no extra cost. I<br />
can personally not imagine a case where you'd prefer --add over this<br />
--upgrade function, unless you want pacman to exit if a package is<br />
already installed.<br />
<br />
Removing packages<br />
<br />
pacman --remove foo<br />
pacman -R foo<br />
<br />
This will remove all files belonging to the package named foo, except<br />
for configuration files that have been edited. Only supply the name of<br />
the package to this command, without the pkg.tar.gz suffix.<br />
<br />
To remove any and all trace of a package, add the --nosave option to<br />
the above command.<br />
<br />
Refreshing the package list<br />
<br />
pacman --sync --refresh<br />
pacman -Sy<br />
<br />
This will retrieve a fresh master package list from the repositories<br />
defined in the /etc/pacman.conf file and uncompress it into the<br />
database area. You should use this before using --sysupgrade to make<br />
sure you get the newest packages. Depending on your pacman.conf<br />
settings, this command may require a working internet connection to<br />
access FTP/HTTP-based repositories. This option is quite similar to<br />
Debian's apt-get update command.<br />
<br />
Upgrading the system<br />
<br />
pacman --sync --sysupgrade<br />
pacman -Su<br />
<br />
This command will upgrade all packages that are out-of-date on your<br />
system by comparing the local package version to the versions in the<br />
master package list that get downloaded with the --refresh command.<br />
It's a good idea to run this regularly to keep your system up to date.<br />
Note that this command does NOT implicitly refresh the master package<br />
list, so it's usually wiser to combine both commands into one like<br />
this:<br />
pacman --sync --refresh --sysupgrade<br />
pacman -Syu<br />
<br />
With these options pacman will automatically retrieve the current<br />
master package list and do a full system upgrade to the latest<br />
packages with all dependencies being automagically resolved. You will<br />
want to run this quite often.<br />
<br />
Adding/Upgrading a package from the repositories<br />
<br />
pacman --sync foo<br />
pacman -S foo<br />
<br />
Retrieve and install package foo, complete with all dependencies it<br />
requires. Before using any sync option, make sure you refreshed the<br />
package list, or add --refresh or -y to the options to do it before<br />
the installation attempt. Unlike --add, the --sync option does not<br />
differ between installing and upgrading packages. Depending on your<br />
pacman.conf settings this function requires working internet access.<br />
<br />
Receiving strange errors when downloading packages from the server,<br />
ie. broken downloads or files that aren't found, usually are either<br />
caused by not refreshing the package list with --sync, or if you're<br />
unlucky enough to try downloading from a mirror while it's syncing<br />
its contents, and is thus in an inconsistent state.<br />
<br />
List installed packages<br />
<br />
pacman --query<br />
pacman -Q<br />
<br />
Displays a list of all installed packages in the system.<br />
<br />
Check if a specific package is installed<br />
<br />
pacman --query foo<br />
pacman -Q foo<br />
<br />
Instead of grepping the full list for a name, you can append the name<br />
of the package you are looking for to the query command. This command<br />
will display the name and version of the foo package if it is<br />
installed, nothing otherwise.<br />
<br />
Display specific package info<br />
<br />
pacman --query --info foo<br />
pacman -Qi foo<br />
<br />
Displays information on the installed package foo (size, install date,<br />
build date, dependencies, conflicts, etc.). To display this<br />
information for a package file that is not yet installed, add the<br />
--file or -p option, respectively:<br />
pacman --query --info --file foo.pkg.tar.gz<br />
pacman -Qip foo.pkg.tar.gz<br />
<br />
Display list of files contained in a package<br />
<br />
pacman --query --list foo<br />
pacman -Ql foo<br />
<br />
Lists all files belonging to package foo.<br />
<br />
Find out which package a specific file belongs to<br />
<br />
pacman --query --owns /path/to/file<br />
pacman -Qo /path/to/file<br />
<br />
This query displays the name and version of the package which contains<br />
the file referenced by it's full path as a parameter. Just using the<br />
file name without the path will not yield results.<br />
<br />
===Accessing Repositories===<br />
<br />
A package repository is a collection of packages and a package<br />
meta-info file that can reside in a local directory or on a remote<br />
FTP/HTTP server. The default repository for an Arch system is the<br />
core repository. This is kept up to date by developers with the<br />
latest version of most software and stays fairly bleeding-edge.<br />
<br />
Many users also choose to activate the extra package repository which<br />
contains more packages that are not part of Arch's core package set.<br />
You can activate this repo by uncommenting the appropriate lines in<br />
your /etc/pacman.conf. This repository is activated by default.<br />
<br />
You can also build, maintain and use your own package repositories.<br />
See the pacman manpage for instructions.<br />
<br />
If you install from CD-ROM and end up having problems accessing the<br />
Internet, you may need to install additional packages from the CD.<br />
Refer to the FAQs, specifically FAQ #3 later in this document, to find<br />
out how to define a repository that uses the installation CD-ROM as a<br />
package source.<br />
<br />
==Arch Build System (ABS)==<br />
<br />
===Binary vs. Source===<br />
<br />
Where pacman is responsible for the binary side of the package world,<br />
ABS is responsible for the source side: It helps you to build your own<br />
custom packages from source code, also letting you rebuild Arch Linux<br />
packages with your own customizations. The procedure usually goes as<br />
follows:<br />
1. Synchronize your ABS tree with the server.<br />
2. Create a new directory in /var/abs/local/ named after the package<br />
you are going to create.<br />
3. Copy the PKGBUILD.proto prototype from /var/abs/ into your newly<br />
created directory, remove the .proto suffix, and edit it to fit<br />
the new package.<br />
4. Run makepkg in the working directory with the PKGBUILD file.<br />
5. Install the newly built package with pacman.<br />
6. Send the package to your friends for bragging rights (or give it<br />
to an Archer so s/he can stick it in the master ABS tree).<br />
<br />
===Synchronizing Your ABS Tree===<br />
<br />
You can synchronize all the required package building files in<br />
/var/abs by running the abs script as root. It requires the cvsup<br />
package to operate and will complain if you don't have it installed. A<br />
working internet connection is also required, of course. Using CVS as<br />
the transfer medium allows you to follow different version trees<br />
within ABS - this can be configured in /etc/abs/supfile.arch. For<br />
example, the default supfile is set to track the core package tree,<br />
which is bleeding-edge and the recommended source to follow. You can<br />
also follow specific versions. See the comments in the supfiles for<br />
more info.<br />
<br />
ABS supports multiple repositories, which can be enabled or disabled<br />
in /etc/abs/abs.conf. By default, abs will follow the core and<br />
extra repositories, but not anything else.<br />
<br />
You will also see an /etc/abs/supfile.extra file. This will give you<br />
access to all the unofficial build scripts that were not included in<br />
the main ABS repository. If you do not want to use this repository,<br />
you can delete the file, but usually it makes more sense to edit<br />
abs.conf accordingly instead, and disable the repositories you don't<br />
need.<br />
<br />
===How to Build Packages===<br />
<br />
The build process is thoroughly explained in the makepkg manpage. Read<br />
it for instructions on building your own packages. If that's not<br />
helping you, keep your eyes peeled for tutorials in the Wiki, or ask<br />
for help in the forums or IRC.<br />
<br />
===Package Guidelines===<br />
<br />
When building package for Arch Linux, you should adhere to the package<br />
guidelines below, especially if you would like to contribute your new<br />
package to Arch Linux.<br />
<br />
Package Naming<br />
<br />
* Package names should consist of alphanumeric characters only; allletters should be lowercase.<br />
* Package versions should be the same as the version released by the author. Versions can include letters if need be (eg, nmap'sversion was 2.54beta32 a good while ago). Version tags may not include hyphens! Letters, numbers, and periods only.<br />
* Package releases are specific to Arch Linux packages. These allow users to differentiate between newer and older package builds. When a new package version is first released, the release countstarts at 1. Then as fixes and optimizations are made, the package will be re-released to the AL public and the release number will increment. When a new version comes out, the release count resets to 1. Package release tags follow the same naming restrictions as version tags.<br />
<br />
<br />
'''Directories'''<br />
<br />
Configuration files should be placed in the /etc directory. If there's<br />
more than one configuration file, it's customary to use a subdirectory<br />
in order to keep the /etc area as clean as possible. Use<br />
/etc/{pkgname}/ where {pkgname} is the name of your package (or a<br />
suitable alternative, eg, apache uses /etc/httpd/).<br />
<br />
Package files should follow these general directory guidelines:<br />
<br />
/etc System-essential configuration files<br />
/usr/bin Application binaries<br />
/usr/sbin System binaries<br />
/usr/lib Libraries<br />
/usr/include Header files<br />
/usr/lib/{pkg} Modules, plugins, etc.<br />
/usr/man Manpages<br />
/usr/share/{pkg} Application data<br />
/etc/{pkg} Configuration files for {pkg}<br />
/opt<br />
<br />
Packages that do not fit cleanly into Linux filesystem layout can be<br />
placed here. If a package's files can be cleanly placed into the above<br />
directories, then do so. If there are other high-level directories<br />
that do not fit, then you should use /opt.<br />
<br />
For example, the acrobat package has Browser, Reader, and Resource<br />
directories sitting at the same level as the bin directory. This<br />
doesn't fit into a normal Linux filesystem layout, so we place all the<br />
files in a subdirectory of /opt.<br />
<br />
Clear as mud? Good.<br />
<br />
<br />
'''makepkg Duties'''<br />
<br />
When you use makepkg to build a package for you, it does the following<br />
automatically:<br />
# Checks if package dependencies are installed<br />
# Downloads source files from servers<br />
# Unpacks source files<br />
# Does any necessary patching<br />
# Builds the software and installs it in a fake root<br />
# Removes /usr/doc, /usr/info, /usr/share/doc, and /usr/share/info from the package<br />
# Strips symbols from binaries<br />
# Strips debugging symbols from libraries<br />
# Generates the package meta file which is included with each package<br />
# Compresses the fake root into the package file<br />
# Stores the package file in the configured destination directory (cwd by default)<br />
<br />
<br />
'''Other'''<br />
<br />
Do not introduce new variables into your PKGBUILD build scripts,<br />
unless the package cannot be built without doing so, as these could<br />
possibly conflict with variables used in makepkg itself. If a new<br />
variable is absolutely required, prefix the variable name with an<br />
underscore.<br />
<br />
Avoid using /usr/libexec/ for anything. Use /usr/lib/{pkgname}<br />
instead.<br />
<br />
The "Packager" field from the package meta file can be customized by<br />
the package builder by modifying the appropriate option in the<br />
/etc/makepkg.conf file, or alternatively by exporting the PACKAGER<br />
environment variable before building packages with makepkg:<br />
export PACKAGER="John Doe <your.email>"<br />
<br />
<br />
'''Submitting Packages'''<br />
<br />
If you'd like to submit packages, please take a look at the Arch User<br />
Repository and their guidelines. New packages should be submitted to<br />
the AUR.<br />
<br />
If you're submitting a package, please do the following:<br />
*Please add a comment line to the top of your PKGBUILD file that follows this format:<br />
Contributor: Your Name <your.email><br />
*Verify the package dependencies (eg, run ldd on dynamic executables, check tools required by scripts, etc.). It's also a good idea to use the namcap utility, written by Jason Chu jason@archlinux.org, to analyze the sanity if your package. namcap will tell you about bad permissions, missing dependencies, un-needed dependencies, and other common mistakes. You can install the namcap package with pacman as usual.<br />
* All packages should come as a compressed tar file containing a directory with the newly built package, the PKGBUILD, filelist, and additional files (patches, install, ...) in it. The archive name should at least contain the name of the package. <br />
* Read the appropriate documents regarding the AUR, and the newest version of the packaging guildelines on the AUR Homepage.<br />
<br />
==Frequently Asked Questions==<br />
<br />
The FAQs listed here are only covering any problems that may keep you<br />
from booting or installing an initial Arch Linux system. If you have<br />
questions regarding further usage of the system utilities, X11 setup,<br />
etc. or how to configure your hardware, please head over to the Wiki.<br />
If you think an issue is not covered here that should be, please<br />
notify the author of this document, whose address is to be found at<br />
the very top of this file.<br />
<br />
===During package installation, pacman fails to resolve dependencies for package A because package B is not in the package set===<br />
<br />
Unless something is very broken and thus very likely to be reported by<br />
multiple people soon, you probably just forgot to mount your target<br />
partitions properly. This causes pacman to decompress the package<br />
database into the initial ramdisk, which fills up quite nicely and<br />
ultimatively leads to this error.<br />
<br />
Make sure that you use the DONE and not the CANCEL option offered by<br />
the Filesystem Mountpoints menu to apply your choices. This error<br />
should not happen if you use the Auto-Prepare feature; If it does<br />
nevertheless, please report this as a bug.<br />
<br />
===How can I install packages from the install CD with pacman --sync (so it resolves dependencies for me)?===<br />
<br />
If you would rather have packages install from the CD instead of<br />
downloading them, then mount the install CD somewhere (eg. /mnt/cd)<br />
and add this line right below the [core] line in /etc/pacman.conf:<br />
Server = file:///mnt/cd<br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync<br />
as you normally would - It will now check the /mnt/cd directory first<br />
for packages.<br />
<br />
===How can I create multiple swap partitions during the install?===<br />
<br />
Naturally you won't be able to use the Auto-Prepare feature if you<br />
want to create and use multiple swap partitions. Create the partitions<br />
manually instead, and create as many swap partitions as your little<br />
heart desires. Go through the rest of the disk preparation steps,<br />
don't mind that you're only asked for one swap partition during the<br />
mount-point setting. Once you're through with the install and are<br />
about to edit your system configuration files, you can edit the fstab<br />
file and include a line for every swap device you created earlier.<br />
Simply copy the automatically generated swap line, and modify the<br />
referenced device according to your setup. The additional swaps will<br />
be activated after the bootup when swapon -a is being run by the<br />
initscripts. Make sure you ran mkswap on all of your swap partitions<br />
manually, or else your system will complain on bootup!<br />
<br />
If, for any odd reason, you can not wait until after the installation<br />
with activating multiple swap partitions or files, you will have to<br />
open a shell on one of the virtual terminals and issue the swapon<br />
<device> for every swap drive or file you partitioned/readied before<br />
with mkswap. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files<br />
or drives, you should keep in mind that a kernel that needs to swap is<br />
actually crying bitterly for more RAM, not more swap space. Please<br />
keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
<br />
As a first step you simply boot from the Arch Install CD or disks. If<br />
your partitions are intact and don't need checking, you can try<br />
choosing one of the recovery boot options according to your partition<br />
layout, or fiddle with the GRUB boot manager settings on your own to<br />
get your existing system to boot properly. That will boot directly<br />
into your system, and you can skip all but the last step of actually<br />
reconfiguring and running LILO.<br />
<br />
If you cannot boot your old root directly, boot from the CD as if you<br />
were going to start an installation. Once you're in a shell, you mount<br />
the root partition of your harddisk into the /mnt directory, for<br />
example like this:<br />
mount /dev/hda3 /mnt<br />
<br />
Then you mount any other partitions to their respective mount points<br />
within that root of yours, for example a /boot partition:<br />
mount /dev/hda1 /mnt/boot<br />
<br />
Now you need to mount a /dev tree in the /mnt area, where LILO will be<br />
able to find it:<br />
/mnt/bin/mount --bind /dev /mnt/dev<br />
<br />
Once everything is mounted, make this /mnt directory your new root<br />
with the chroot /mnt command. This will start a new shell and drop you<br />
into the /mnt directory, which will be considered your / from then on.<br />
<br />
Now you can edit /etc/lilo.conf to your liking and run lilo to fix<br />
anything that needs fixing. Simply type exit when you want to break<br />
out of this root again, back into the original file tree. You can now<br />
reboot and test your changes.<br />
<br />
===I can't ssh into my machine!===<br />
<br />
Edit your /etc/hosts.allow file. The default configuration will reject<br />
all incoming connections, not only ssh connections.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device<br />
binding, add the name of the module to the MODULES array of your<br />
/etc/rc.conf. For on demand loading on device access, add it as usual<br />
with the alias and optioncommands to your /etc/modprobe.conf, in the<br />
rare cases that the automatisms employed by udev don't cut<br />
it. To pass any options to a module you want to load through the<br />
MODULES array, only add the appropriate options line to your<br />
/etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of "lost interrupt"===<br />
<br />
Kernel refuses to boot. It locks at:<br />
IRQ probe failed for hda<br />
hda lost interrupt<br />
<br />
This or a similar error occurs for some HD controllers on kernel<br />
2.6.x. A workaround is to pass the acpi=off option to the kernel at<br />
boot time.<br />
<br />
===I get "access denied" errors trying to play music or read DVDs===<br />
<br />
Add your user to the optical and audio groups.<br />
gpasswd -a johndoe optical<br />
gpasswd -a johndoe audio<br />
<br />
Logout, then login again as that user (eg. johndoe) so the group<br />
changes can take effect, and the device permissions shouldn't be a<br />
problem anymore.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to<br />
your real DVD device. Usually udev does this for you already, but this<br />
will serve well as an example for setting up similar symlinks.<br />
<br />
For example, if your DVD drive is accessible through /dev/sdc, you can<br />
do the following as root:<br />
cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="sdc", NAME="sdc", SYMLINK="dvd"<br />
> EOF<br />
/etc/start_udev<br />
mount /dev/pts<br />
mount /dev/shm</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32068
The Arch Way (正體中文)
2007-11-08T20:17:11Z
<p>Arnix: /* Arch 的原則與哲學 */</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
我 , Judd Vinet , 因為兩個理由開始了Arch 的建造:<br />
<br />
# 我找不到一個發行版本符合我的想法。某些已經很接近的,卻帶有惱人的怪辟或者不必要的複雜特性,它們提供的壞處似乎比好處還多呢;<br />
# 為了樂趣 - 為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多。<br />
<br />
<br />
從本質來說, Arch 是:<br />
<br />
* 輕巧而且簡單的。 注意,這句話並不是針對所有人說的…<br />
<br />
* 它'''不是'''設計給新手用的發行版本; 它針對較有經驗的使用者。 The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* 免費的禮物, 再一次, "…為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多"。當你自別人那兒獲得了禮物,總會想要回饋些什麼。也因為如此,我們歡迎使用者貢獻他們的點子、工具以及建議。<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* Arch Linux 核心環境的開發,在不久的將來一段時間內不會提供任所謂「友善新手」的 圖形介面 或工具程式。<br />
<br />
* 我們這些卑微的開發者們將持續地提供 Arch 成為每個人腳下穩固的基石。如果你想讓它更好, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
Arch 開發時所遵循的價值系統:<br />
<br />
* KISS (保持簡單, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* 對 Arch 來說,「簡單」並非其如他發行版本所指的那樣。在我們的哲學裡,學習比讓某些變容易要來得重要。<br />
<br />
* 依賴圖形介面來建立並使用系統,最後的結果等於是在傷害使用者。 總有一天使用者會需要知道那些在圖形介面下隱藏的所有東西。<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* 針對 i686 最佳化。<br />
* [[pacman]]: '系統升級' 本身就一道指令: "pacman -Syu"<br />
* [[pacman]]: 無需 X/GUI 就能做相依性控管。<br />
* [[ABS]]: package-building 功能只要做一次就可以了 - 要為套件製作別種的版本是極容易的。<br />
* [[ABS]]: 您只要用一道指令就能重編機器上所有的套件。<br />
* 完全照您的需要為套件更新,完全地可客製化。<br />
* the people behind the scenes are gentle, motivated and able<br />
* 不到 20 分鐘就能建好一個功能完整的系統。<br />
* 提供一個學習 Linux 的完美環境。<br />
* 由於知道的人太少,真的很不流行。 (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32067
The Arch Way (正體中文)
2007-11-08T20:16:16Z
<p>Arnix: /* Arch 的原則與哲學 */</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
我 , Judd Vinet , 因為兩個理由開始了Arch 的建造:<br />
<br />
# 我找不到一個發行版本符合我的想法。某些已經很接近的,卻帶有惱人的怪辟或者不必要的複雜特性,它們提供的壞處似乎比好處還多呢;<br />
# 為了樂趣 - 為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多。<br />
<br />
<br />
從本質來說, Arch 是:<br />
<br />
* 輕巧而且簡單的。 注意,這句話並不是針對所有人說的…<br />
<br />
* 它'''不是'''設計給新手用的發行版本; 它針對較有經驗的使用者。 The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* 免費的禮物, 再一次, "…為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多"。當你自別人那兒獲得了禮物,總會想要回饋些什麼。也因為如此,我們歡迎使用者貢獻他們的點子、工具以及建議。<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* Arch Linux 核心環境的開發,在不久的將來一段時間內不會提供任所謂「友善新手」的 圖形介面 或工具程式。<br />
<br />
* 我們這些卑微的開發者們將持續地提供 Arch 成為每個人腳下穩固的基石。如果你想讓它更好, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
Arch 開發時所遵循的價值系統:<br />
<br />
* KISS (保持簡單, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* 對 Arch 來說,「簡單」並非其如他發行版本所指的那樣。在我們的哲學裡,學習比讓某些變容易要來得重要。<br />
<br />
* 依賴圖形介面來建立並使用系統,最後的結果等於是在傷害使用者。 總有一天使用者會需要知道那些在圖形介面下隱藏的所有東西。<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* 針對 i686 最佳化。<br />
* [[pacman]]: '系統升級' 本身就一道指令: "pacman -Syu"<br />
* [[pacman]]: 無需 X/GUI 就能做相依性控管。<br />
* [[ABS]]: package-building 功能只要做一次就可以了 - 要為套件製作別種的版本是極容易的。<br />
* [[ABS]]: 您只要用一道指令就能重編機器上所有的套件。<br />
* 完全照您的需要為套件更新,完全地可客製化。<br />
* the people behind the scenes are gentle, motivated and able<br />
* 不到 20 分鐘就能建好一個功能完整的系統。<br />
* 提供一個學習 Linux 的完美環境。<br />
* 由於知道的人太少,真的很不流行。 (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32066
The Arch Way (正體中文)
2007-11-08T20:15:06Z
<p>Arnix: /* 原則 */</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
我 , Judd Vinet , 因為兩個理由開始了Arch 的建造:<br />
<br />
# 我找不到一個發行版本符合我的想法。某些已經很接近的,卻帶有惱人的怪辟或者不必要的複雜特性,它們提供的壞處似乎比好處還多呢;<br />
# 為了樂趣 - 為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多。<br />
<br />
<br />
從本質來說, Arch 是:<br />
<br />
* 輕巧而且簡單的。 注意,這句話並不是針對所有人說的…<br />
<br />
* 它'''不是'''設計給新手用的發行版本; 它針對較有經驗的使用者。 The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* 免費的禮物, 再一次, "…為了給自由軟體社群回饋 -- 我從他們那兒得到的是這麼的多"。當你自別人那兒獲得了禮物,總會想要回饋些什麼。也因為如此,我們歡迎使用者貢獻他們的點子、工具以及建議。<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* Arch Linux 核心環境的開發,在不久的將來一段時間內不會提供任所謂「友善新手」的 圖形介面 或工具程式。<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
* 我們這些卑微的開發者們將持續地提供 Arch 成為每個人腳下穩固的基石。如果你想讓它更好, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
Arch 開發時所遵循的價值系統:<br />
<br />
* KISS (保持簡單, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* 對 Arch 來說,「簡單」並非其如他發行版本所指的那樣。在我們的哲學裡,學習比讓某些變容易要來得重要。<br />
<br />
* 依賴圖形介面來建立並使用系統,最後的結果等於是在傷害使用者。 總有一天使用者會需要知道那些在圖形介面下隱藏的所有東西。<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* 針對 i686 最佳化。<br />
* [[pacman]]: '系統升級' 本身就一道指令: "pacman -Syu"<br />
* [[pacman]]: 無需 X/GUI 就能做相依性控管。<br />
* [[ABS]]: package-building 功能只要做一次就可以了 - 要為套件製作別種的版本是極容易的。<br />
* [[ABS]]: 您只要用一道指令就能重編機器上所有的套件。<br />
* 完全照您的需要為套件更新,完全地可客製化。<br />
* the people behind the scenes are gentle, motivated and able<br />
* 不到 20 分鐘就能建好一個功能完整的系統。<br />
* 提供一個學習 Linux 的完美環境。<br />
* 由於知道的人太少,真的很不流行。 (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32065
The Arch Way (正體中文)
2007-11-08T20:09:44Z
<p>Arnix: /* 哲學 */</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
Arch 開發時所遵循的價值系統:<br />
<br />
* KISS (保持簡單, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* 對 Arch 來說,「簡單」並非其如他發行版本所指的那樣。在我們的哲學裡,學習比讓某些變容易要來得重要。<br />
<br />
* 依賴圖形介面來建立並使用系統,最後的結果等於是在傷害使用者。 總有一天使用者會需要知道那些在圖形介面下隱藏的所有東西。<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* 針對 i686 最佳化。<br />
* [[pacman]]: '系統升級' 本身就一道指令: "pacman -Syu"<br />
* [[pacman]]: 無需 X/GUI 就能做相依性控管。<br />
* [[ABS]]: package-building 功能只要做一次就可以了 - 要為套件製作別種的版本是極容易的。<br />
* [[ABS]]: 您只要用一道指令就能重編機器上所有的套件。<br />
* 完全照您的需要為套件更新,完全地可客製化。<br />
* the people behind the scenes are gentle, motivated and able<br />
* 不到 20 分鐘就能建好一個功能完整的系統。<br />
* 提供一個學習 Linux 的完美環境。<br />
* 由於知道的人太少,真的很不流行。 (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32064
The Arch Way (正體中文)
2007-11-08T20:08:58Z
<p>Arnix: /* 哲學 */</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
Arch 開發時所遵循的價值系統:<br />
<br />
* KISS (保持簡單, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* 對 Arch 來說,「簡單」並非其如他發行版本所指的那樣。在我們的哲學裡,學習比讓某些變得容易要來得重要。<br />
<br />
* 依賴圖形介面來建立並使用系統,最後的結果等於是在傷害使用者。 總有一天使用者會需要知道那些在圖形介面下隱藏的所有東西。<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* 針對 i686 最佳化。<br />
* [[pacman]]: '系統升級' 本身就一道指令: "pacman -Syu"<br />
* [[pacman]]: 無需 X/GUI 就能做相依性控管。<br />
* [[ABS]]: package-building 功能只要做一次就可以了 - 要為套件製作別種的版本是極容易的。<br />
* [[ABS]]: 您只要用一道指令就能重編機器上所有的套件。<br />
* 完全照您的需要為套件更新,完全地可客製化。<br />
* the people behind the scenes are gentle, motivated and able<br />
* 不到 20 分鐘就能建好一個功能完整的系統。<br />
* 提供一個學習 Linux 的完美環境。<br />
* 由於知道的人太少,真的很不流行。 (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Main_page_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32062
Main page (正體中文)
2007-11-08T18:54:51Z
<p>Arnix: 修改 The Arch Way 繁體中文 連結</p>
<hr />
<div>[[Category: 繁體中文]]<br />
<br />
__NOTOC__ __NOEDITSECTION__<br />
{{Navigate_i18n_mainpages}}{{newpagelinksmain}}<br />
=== ArchLinux Wiki ===<br />
歡迎使用 [[ArchLinux]] 共筆系統 (Wiki). <br />
<br />
{{sn|新手上路 :<br />
* [[ArchLinux (繁體中文)]]<br />
* [[FAQ 常見問答集]]<br />
* [[The Arch Way (繁體中文)]]<br />
* [[ArchWiki 使用教學]]<br />
}}<br />
<br />
==== 中文環境常用套件 ====<br />
* gcin 中文輸入法(若使用(colinux/vmware)+(xming/vnc)環境,可用gcin-setup 設定為 alt+space 啟動輸入法)<br />
* ttf-fireflysung 中文字型<br />
* leafpad 支援中文的編輯器<br />
* unicode-rxvt 支援中文的 xterm<br />
<br />
==== 台灣社群 ====<br />
<br />
* [http://cle.linux.org.tw/forum/viewforum.php?f=12 CLE 論壇 :: 檢視版面 - ArchLinux]<br />
* IRC channel:<br />
** #archlinux.tw on freenode. (Not yet officially registered)<br />
<br />
==== Wiki 最新消息 ====<br />
有時候,有些最新消息值得我們發佈一則新聞稿, 但是可能只和 wiki 有關. 關於這些只和 wiki 有關係的消息, 請參閱 [[Wiki News]] 這一頁.<br />
<br />
==== 自己動手試看看 ====<br />
這是一份關於 wiki 內幾篇主要文章的名單. 大部分的時候,你都可以直接使用在頁面左方(或是右方)的 <b>瀏覽主題列 (navigation bar)</b> 來開始瀏覽 wiki 頁面的內容, 然後使用頁面上方的 <b>分頁選項 (panels)</b> 來開始編輯某個頁面的內容. 在每個頁面的最下方,你則可以找到連接到其他 Arch Linux 網站的連接. <br />
<br />
==== How Tos 教學篇 ====<br />
在設定某個軟體(硬體)時遇到困難?不知道該去哪裡找解答和資料?<br><br />
我們建議你先從 [[:Category:HowTos (繁體中文)|HowTos category]] 開始搜尋起,一般而言,你應該可以在這找到你需要的資訊。 先找出你的問題可能屬於的類別 (categories), 然後是著搜尋一下相關的主題。如果你還是無法找到需要的資訊,你可以試看看頁面左方,就在瀏覽主題列 (Navigation bar) 下方的的搜尋功能 (search box).<br />
<br />
==== 建立你自己的頁面 ====<br />
在建立/編輯一個頁面的內容前,你必須先建立你的帳號. 當你建立好自己的帳號後,請先試著在 [[Sandbox]] (沙盒)裡面測試並熟悉一下 ArchWiki 所使用的排版語法 (markups). 你自己的 user page 也是個你可以用來測試和練習的好地方. 在 [[:Category:Help|Wiki Help Category]] 這一個頁面,你可以找到關於如何使用這些語法的簡介和範例. 你隨時都可以在頁面左方的瀏覽主題列上找到這個頁面的連接.<br />
<br />
==== 負責人 ====<br />
任何問題或是建議請參閱 [[ContactList]] 的負責人聯絡名單<br />
<br />
{{navigatearchlinux}}</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32061
The Arch Way (正體中文)
2007-11-08T18:50:07Z
<p>Arnix: /* PROS */</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
The System of values by which Arch develops:<br />
<br />
* KISS (Keep It Simple, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* In Arch, 'simple' doesn't always mean what it does in other distros. It's our philosophy that the learning is more important than getting something easily done.<br />
<br />
* Relying on GUIs to build and use your system is just going to hurt a user in the end. At some point in time a user will need to know all that some GUIs hide.<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* 針對 i686 最佳化。<br />
* [[pacman]]: '系統升級' 本身就一道指令: "pacman -Syu"<br />
* [[pacman]]: 無需 X/GUI 就能做相依性控管。<br />
* [[ABS]]: package-building 功能只要做一次就可以了 - 要為套件製作別種的版本是極容易的。<br />
* [[ABS]]: 您只要用一道指令就能重編機器上所有的套件。<br />
* 完全照您的需要為套件更新,完全地可客製化。<br />
* the people behind the scenes are gentle, motivated and able<br />
* 不到 20 分鐘就能建好一個功能完整的系統。<br />
* 提供一個學習 Linux 的完美環境。<br />
* 由於知道的人太少,真的很不流行。 (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32060
The Arch Way (正體中文)
2007-11-08T18:34:21Z
<p>Arnix: /* CONS */</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
The System of values by which Arch develops:<br />
<br />
* KISS (Keep It Simple, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* In Arch, 'simple' doesn't always mean what it does in other distros. It's our philosophy that the learning is more important than getting something easily done.<br />
<br />
* Relying on GUIs to build and use your system is just going to hurt a user in the end. At some point in time a user will need to know all that some GUIs hide.<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* i686-optimized<br />
* [[pacman]]: 'System Upgrade' is ONE command: "pacman -Syu"<br />
* [[pacman]]: Dependency-control, no X/GUI needed<br />
* [[ABS]]: the package-building function need only be done once - building another version of a package is extremely easy<br />
* [[ABS]]: you can build all the packages on your machine with one command<br />
* fully up-to-date packages at your request, and fully customizable<br />
* the people behind the scenes are gentle, motivated and able<br />
* less than 20 minutes to create a fully functional system<br />
* the perfect environment to learn Linux in<br />
* not really popular, because not known (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* 在使用最新函式庫時存在某些衝突現象 ("bleeding edge")<br />
* 缺乏對新手友善的特性。<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* 由於知道的人太少,真的很不流行 。</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32059
The Arch Way (正體中文)
2007-11-08T18:24:46Z
<p>Arnix: 不確定的翻譯</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
The System of values by which Arch develops:<br />
<br />
* KISS (Keep It Simple, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* In Arch, 'simple' doesn't always mean what it does in other distros. It's our philosophy that the learning is more important than getting something easily done.<br />
<br />
* Relying on GUIs to build and use your system is just going to hurt a user in the end. At some point in time a user will need to know all that some GUIs hide.<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* i686-optimized<br />
* [[pacman]]: 'System Upgrade' is ONE command: "pacman -Syu"<br />
* [[pacman]]: Dependency-control, no X/GUI needed<br />
* [[ABS]]: the package-building function need only be done once - building another version of a package is extremely easy<br />
* [[ABS]]: you can build all the packages on your machine with one command<br />
* fully up-to-date packages at your request, and fully customizable<br />
* the people behind the scenes are gentle, motivated and able<br />
* less than 20 minutes to create a fully functional system<br />
* the perfect environment to learn Linux in<br />
* not really popular, because not known (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* some conflicts from using the newest libs ("bleeding edge")<br />
* lack of newbie-friendly features<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* not really popular, because not known</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32058
The Arch Way (正體中文)
2007-11-08T18:22:17Z
<p>Arnix: New page: Category:About Arch (繁體中文) Category:General (繁體中文) {{i18n_links_start}} {{i18n_entry|Dansk|The Arch Way (Dansk)}} {{i18n_entry|English|The Arch Way}} {{i18n_entry|...</p>
<hr />
<div>[[Category:About Arch (繁體中文)]]<br />
[[Category:General (繁體中文)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= Arch 的原則與哲學 =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
簡單地說, the Arch Way stands for: <br />
* freedom of choice <br />
* 保持簡單 <br />
* emphasis on learning rather than automation<br />
* 優雅<br />
and <br />
* user-control<br />
<br />
== 原則 ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== 哲學 ==<br />
<br />
The System of values by which Arch develops:<br />
<br />
* KISS (Keep It Simple, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* In Arch, 'simple' doesn't always mean what it does in other distros. It's our philosophy that the learning is more important than getting something easily done.<br />
<br />
* Relying on GUIs to build and use your system is just going to hurt a user in the end. At some point in time a user will need to know all that some GUIs hide.<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== 評語 ==<br />
<br />
看看使用者們對 Arch 怎麼說:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= 正反雙方的說法 =<br />
<br />
== PROS ==<br />
<br />
* i686-optimized<br />
* [[pacman]]: 'System Upgrade' is ONE command: "pacman -Syu"<br />
* [[pacman]]: Dependency-control, no X/GUI needed<br />
* [[ABS]]: the package-building function need only be done once - building another version of a package is extremely easy<br />
* [[ABS]]: you can build all the packages on your machine with one command<br />
* fully up-to-date packages at your request, and fully customizable<br />
* the people behind the scenes are gentle, motivated and able<br />
* less than 20 minutes to create a fully functional system<br />
* the perfect environment to learn Linux in<br />
* not really popular, because not known (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* some conflicts from using the newest libs ("bleeding edge")<br />
* lack of newbie-friendly features<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* not really popular, because not known</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way&diff=32057
The Arch Way
2007-11-08T18:12:21Z
<p>Arnix: fix chinese i18n tag</p>
<hr />
<div>[[Category:About Arch (English)]]<br />
[[Category:General (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|The Arch Way (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
<br />
= Arch Principles & Philosophy =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
In short, the Arch Way stands for: <br />
* freedom of choice <br />
* keep it simple <br />
* emphasis on learning rather than automation<br />
* elegance<br />
and <br />
* user-control<br />
<br />
== Principles ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== Philosophy ==<br />
<br />
The System of values by which Arch develops:<br />
<br />
* KISS (Keep It Simple, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* In Arch, 'simple' doesn't always mean what it does in other distros. It's our philosophy that the learning is more important than getting something easily done.<br />
<br />
* Relying on GUIs to build and use your system is just going to hurt a user in the end. At some point in time a user will need to know all that some GUIs hide.<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== Comments ==<br />
<br />
What users have said about Arch:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* i686-optimized<br />
* [[pacman]]: 'System Upgrade' is ONE command: "pacman -Syu"<br />
* [[pacman]]: Dependency-control, no X/GUI needed<br />
* [[ABS]]: the package-building function need only be done once - building another version of a package is extremely easy<br />
* [[ABS]]: you can build all the packages on your machine with one command<br />
* fully up-to-date packages at your request, and fully customizable<br />
* the people behind the scenes are gentle, motivated and able<br />
* less than 20 minutes to create a fully functional system<br />
* the perfect environment to learn Linux in<br />
* not really popular, because not known (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* some conflicts from using the newest libs ("bleeding edge")<br />
* lack of newbie-friendly features<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* not really popular, because not known</div>
Arnix
https://wiki.archlinux.org/index.php?title=The_Arch_Way&diff=32056
The Arch Way
2007-11-08T18:10:16Z
<p>Arnix: </p>
<hr />
<div>[[Category:About Arch (English)]]<br />
[[Category:General (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|The Arch Way (Dansk)}}<br />
{{i18n_entry|English|The Arch Way}}<br />
{{i18n_entry|Español|The Arch Way (Español)}}<br />
{{i18n_entry|Lietuviškai|Arch filosofija (Lietuviškai)}}<br />
{{i18n_entry|Polski|The Arch Way (Polski)}}<br />
{{i18n_entry|Português de Portugal|À Maneira do Arch}}<br />
{{i18n_entry|Русский|Путь_Arch}}<br />
{{i18n_entry|Česky|Principy a filozofie Arch Linuxu (Česky)}}<br />
{{i18n_entry|Italiano|The Arch Way (Italiano)}}<br />
{{i18n_entry|Français|The Arch Way (Français)}}<br />
{{i18n_entry|Deutsch|The Arch Way (Deutsch)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_links_end}}<br />
<br />
<br />
= Arch Principles & Philosophy =<br />
This page attempts to describe the principles and philosophy of [[ArchLinux|Arch Linux]]. There once was no written document about the Arch Way; most likely that will never happen again. <br />
<br />
In short, the Arch Way stands for: <br />
* freedom of choice <br />
* keep it simple <br />
* emphasis on learning rather than automation<br />
* elegance<br />
and <br />
* user-control<br />
<br />
== Principles ==<br />
I, Judd Vinet, started building Arch for two reasons:<br />
<br />
# I didn't find any other distributions that met my ideals. Some came very close to what I wanted but there were annoying quirks or needless complexity that seemed to hurt more than help;<br />
# For fun - to give a little something back to the free software community, from which I've taken so much.<br />
<br />
<br />
By its basic nature, Arch is:<br />
<br />
* Lightweight and simple. Note that doesn't mean it's for everyone....<br />
<br />
* NOT designed as a newbie distro; it's intended for more experienced users. The aim is to develop Arch into as nearly a perfect base as is humanly possible. A base doesn't include fancy tools and auto configuration mechanisms, but rather contains manual configuration tools and few functions, for the users to further develop and/or learn on their own.<br />
<br />
* A free gift, again, "...to give a little something back to the free software community, from which I've taken so much." When you receive a gift from someone, it's usually expected to give something in return. As such, users are welcome to contribute their ideas, tools and suggestions.<br />
<br />
* Aware there are two sides which contribute to Arch Linux: Developers and Users. Don't expect the two sides to merge, but to have a mutual relationship whereby anyone can pick up what they want to add to their machine; our GOALs are to:<br />
<br />
* NOT let configure tools / GUIs control the system, but that they be controlled by the user. There is nothing wrong with GUIs as long as they follow this principle.<br />
<br />
* NOT be controlled by or dependent on what tools offer. When developing or selecting a utility tool, it should be written in a hackable/readable programming language (KISS) to enable users to modify it if they so choose.<br />
<br />
* The core development of Arch Linux will NOT be providing any "newbie-friendly" GUIs/utilities at any time in the near future.<br />
<br />
* We humble developers will continue to provide Arch as a solid base for everyone and anyone. If you guys want to make it pretty, give 'er a rip. Free speech, free beer, and all that.<br />
<br />
== Philosophy ==<br />
<br />
The System of values by which Arch develops:<br />
<br />
* KISS (Keep It Simple, ...) is the basis of Arch development. A fundamentally elegant design yields the most effective, configurable and efficient system. <br />
<br />
* In Arch, 'simple' doesn't always mean what it does in other distros. It's our philosophy that the learning is more important than getting something easily done.<br />
<br />
* Relying on GUIs to build and use your system is just going to hurt a user in the end. At some point in time a user will need to know all that some GUIs hide.<br />
<br />
* ''If you try to hide the complexity of the system, you'll end up with a more complex system.'' Instead, try to make the system simpler and more logical from the inside.<br />
<br />
* Sooner or later, you'll have to find the information on the web and usenet (if man is not enough). Learning how and where to find it on the net should be the first thing a newbie has to learn.<br />
<br />
* Where some users say "...such and such distro isn't like so and so distro," Arch allows the user to make all the contributions they want as long as it doesn't go against the ideals of the design or philosophy.<br />
<br />
* Arch Linux is different from the others: at Arch, the user isn't the only concern. Minimizing development of new tools and docs while maximizing understanding of Linux' inner workings, while keeping a watchful eye always on the "KISS" aim and philosophy of Arch Linux in general...is what makes the "Arch Way" truly different.<br />
<br />
* The great thing about contributions is that you don't need anyone's permission to make them. (See?) No one can physically stop you from writing something that you (personally) find useful, even if the "powers that be" don't see it as a blessing. Write it and put it up in the User Contributions forum. If other people like it, you'll receive feedback. If virtually everyone out there hates it but you, you'll receive feedback, for sure - but who cares? It took you 20 minutes to write, and you learned something along the way. It's a winning situation no matter what.<br />
<br />
* It is what you make it.<br />
<br />
== Comments ==<br />
<br />
What users have said about Arch:<br />
<br />
* "I did a distro taste test with zenwalk(slack based), debian, Redhat fedora, redhat Enterprise, T2, freebsd, netbsd, gobolinux, and SUSE. Arch won in a close one over FreeBSD. Why? It was simple to get up n running with X, packages were VERY current and simple to install, and I didn't have to wait all day for something to compile, but my apps are compiled i686 so they are fast. Updates of whole box did not squash apps as Redhat seemed to. To me as a linux admin I am looking to bring up box, and for home use X, and then be able to add apps and libraries as I see fit. Once the box is up, hand it off to developers, or develop on it myself. Other distros had a lame package system, out of date packages, and simply had no docs to config their systems without a GUI. Arch provides the shortest step from A to B. To read more of why I stick with Arch read the section: Arch v other distros."<br />
<br />
<br />
* "After spending a lot of time with other distributions (debian, gentoo, mandrake, redhat, fedora, slackware) and even FreeBSD. I think that I finally found the distribution I was looking for."<br />
<br />
* Same thing with (k)ubuntu, Mandriva, and several others. Well, openSUSE is nice and easy (that's the one I would advice for my sister); but Arch is the One which really *rocks*.<br />
<br />
* "I have tried several distros and even took (tired?) RHCE (took it BACK?), but there was always something I disliked about each."<br />
<br />
* "My dream distro was always the simplicity of Slackware with real dependency support like Debian's, and guess what - that's Arch."<br />
<br />
* "I also found Arch my final distro."<br />
<br />
* "After trying out almost all the available distributions, I have to agree that Arch is the best."<br />
<br />
* "Hi all. I just registered here so I could report all the problems I'm having, and ask for help. Funny thing is, I HAVE NO PROBLEMS!!! I really can't believe this, but everything is just working! I installed Arch today, had a little trouble with xorg and sound setup, but found all the answers I needed in the documentation and the forums!"<br />
<br />
* "I tried Mandrake, Yoper, FC3/4, Mepis and Ubuntu. I was looking for the perfect distro. I am glad that I found Arch."<br />
<br />
* "I've always been looking for an easy-to-use distribution that didn't bloat the system and was customizable without breaking the system. After trying so many distributions, I found Arch Linux the way to go. And best of all, it's like using my very first distro (Slackware), but with benefits like Pacman and KDEmod."<br />
<br />
* "I've been playing around with Archlinux, and I've fallen in love with it, simply because it offers the same customization options without the micromanaging required by [my last distro]. Props to the Arch team!"<br />
<br />
* "For years I'd been playing around with every distro I could get my hands on--Gentoo, SuSE, OpenSuSE, RH, Fedora, Debian, U/Ku/Xubuntu, Slackware, Knoppix, DSL, and Sabayon. I've probably reformatted my harddrive a dozen dozen times. A month ago I found Arch. Sure, I'd heard about it. Sure, everyone who'd used it loved it. I figured it was time to give it a go. At first, truthfully, I was put off by, upon booting up from install, being left to fend for myself at the command line. It was scary. I realized that the truth is, for a debidiot like myself, Arch is linux nirvana. I've been using it for a week and I've learned more than I have in years with every other distro. I think I've found my home."<br />
<br />
* "After muddling around with Knoppix, Ubuntu, Debian, Fedora Core, and Damn Small, I found the distro that finally gave me the power of customization that I wanted without leaving me in the dark with hundreds of config values or wasted hours that I would run into with Gentoo. Arch Linux blends simplicity with power without limiting the user, and that's a combination to watch out for. It's become my favorite distro, and I practically swear by it."<br />
----<br />
<br />
= PROS and CONS =<br />
<br />
== PROS ==<br />
<br />
* i686-optimized<br />
* [[pacman]]: 'System Upgrade' is ONE command: "pacman -Syu"<br />
* [[pacman]]: Dependency-control, no X/GUI needed<br />
* [[ABS]]: the package-building function need only be done once - building another version of a package is extremely easy<br />
* [[ABS]]: you can build all the packages on your machine with one command<br />
* fully up-to-date packages at your request, and fully customizable<br />
* the people behind the scenes are gentle, motivated and able<br />
* less than 20 minutes to create a fully functional system<br />
* the perfect environment to learn Linux in<br />
* not really popular, because not known (still relevant?)<br />
* rolling release cycle - no large boring distribution upgrades<br />
<br />
== CONS ==<br />
<br />
* [[pacman]]: needs a fast internet connection to stay always up-to-date easily (less of a problem as time marches forward)<br />
* some conflicts from using the newest libs ("bleeding edge")<br />
* lack of newbie-friendly features<br />
* very little hardware detection (relevant?)<br />
* info files are almost always way more detailed than man-pages (gcc.info e.g.)<br />
* not really popular, because not known</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32055
Arch Linux (正體中文)
2007-11-08T18:09:27Z
<p>Arnix: remove translateme</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。藉由使用者與 Arch Linux 開發者們的貢獻,我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集。<br />
<br />
== 簡單就是美 ==<br />
<br />
為了達到簡單與輕巧的目的,我省去了相對上在一般 linux 系統沒有用的部份,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。<br />
有 Man pages 就夠了…<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,包括新式的檔案系統 (Ext2/3、ReiserFS、XFS、JFS 還有其他等等)、LVM2/EVMS、軟體 RAID、udev 支援等等。 Arch Linux 0.7 (Wombat 毛鼻袋熊) 及後續版本預設使用 2.6 版的 linux 核心。<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32054
Arch Linux (正體中文)
2007-11-08T18:05:38Z
<p>Arnix: /* 最新的工具與技術 */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。藉由使用者與 Arch Linux 開發者們的貢獻,我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集。<br />
<br />
== 簡單就是美 ==<br />
<br />
為了達到簡單與輕巧的目的,我省去了相對上在一般 linux 系統沒有用的部份,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。<br />
有 Man pages 就夠了…<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,包括新式的檔案系統 (Ext2/3、ReiserFS、XFS、JFS 還有其他等等)、LVM2/EVMS、軟體 RAID、udev 支援等等。 Arch Linux 0.7 (Wombat 毛鼻袋熊) 及後續版本預設使用 2.6 版的 linux 核心。<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32053
Arch Linux (正體中文)
2007-11-08T18:05:02Z
<p>Arnix: /* 最新的工具與技術 */ 配合英文頁面的描述修改</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。藉由使用者與 Arch Linux 開發者們的貢獻,我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集。<br />
<br />
== 簡單就是美 ==<br />
<br />
為了達到簡單與輕巧的目的,我省去了相對上在一般 linux 系統沒有用的部份,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。<br />
有 Man pages 就夠了…<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux 也致力於運用許多 Linux 上已經可以用的新功能,包括新式的檔案系統 (Ext2/3、ReiserFS、XFS、JFS 還有其他等等)、LVM2/EVMS、軟體 RAID、udev 支援等等。 Arch Linux 0.7 (Wombat 毛鼻袋熊) 及後續版本預設使用 2.6 版的 linux 核心。<br />
<br />
Arch Linux also strives to use many of the newer features that are available to Linux users, including modern filesystems (Ext2/3, Reiser, XFS, JFS and many more), LVM2/EVMS, software RAID, udev support, etc. Arch Linux 0.7 (Wombat) and above use the 2.6 Linux kernel by default.<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32052
Arch Linux (正體中文)
2007-11-08T17:51:07Z
<p>Arnix: /* 最新的工具與技術 */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。藉由使用者與 Arch Linux 開發者們的貢獻,我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集。<br />
<br />
== 簡單就是美 ==<br />
<br />
為了達到簡單與輕巧的目的,我省去了相對上在一般 linux 系統沒有用的部份,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。<br />
有 Man pages 就夠了…<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux 也致力於讓使用者能用某些較新功能,像是 Ext3、ReiserFS以及 udev 等。 Arch Linux 0.7 (Wombat 毛鼻袋熊) 預設使用 2.6 版的 linux 核心,並且能支援 XFS、JFS 的使用。<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32050
Arch Linux (正體中文)
2007-11-08T17:40:48Z
<p>Arnix: /* 簡單就是美 */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。藉由使用者與 Arch Linux 開發者們的貢獻,我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集。<br />
<br />
== 簡單就是美 ==<br />
<br />
為了達到簡單與輕巧的目的,我省去了相對上在一般 linux 系統沒有用的部份,例如 /usr/doc 目錄 及 info 說明頁等。從個人經驗來看這些真的很少用,而且一旦需要它們時,同樣的內容都能在網路上取得。<br />
有 Man pages 就夠了…<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux also strives to use some of the newer features that are available to Linux users, such as Ext3/ReiserFS and udev support. Arch Linux 0.7 (Wombat) uses the 2.6 linux kernel by default, and has support for XFS/JFS.<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32048
Arch Linux (正體中文)
2007-11-08T17:26:40Z
<p>Arnix: /* 只取最好的 */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。藉由使用者與 Arch Linux 開發者們的貢獻,我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集的 extra 套件集。<br />
<br />
== 簡單就是美 ==<br />
<br />
In its goal to be simple and lightweight, I've left out the relatively useless portions of a linux system, things like /usr/doc and the info pages. In my own personal experience these are rarely used, and the equivalent information can be obtained from the net if need be. Man pages all the way...<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux also strives to use some of the newer features that are available to Linux users, such as Ext3/ReiserFS and udev support. Arch Linux 0.7 (Wombat) uses the 2.6 linux kernel by default, and has support for XFS/JFS.<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32047
Arch Linux (正體中文)
2007-11-08T17:25:04Z
<p>Arnix: /* 只取最好的 */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux strives to maintain the latest stable version of its software. We currently support a fairly streamlined core package set with a growing collection of extra packages made by users and AL developers.<br />
<br />
Arch Linux 努力地維護它的最新穩定版本。藉由使用者與 Arch Linux 開發者們的貢獻,我們目前提供了相當精簡的 core 套件集,並搭配逐漸擴大蒐集中的 extra 套件。<br />
<br />
== 簡單就是美 ==<br />
<br />
In its goal to be simple and lightweight, I've left out the relatively useless portions of a linux system, things like /usr/doc and the info pages. In my own personal experience these are rarely used, and the equivalent information can be obtained from the net if need be. Man pages all the way...<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux also strives to use some of the newer features that are available to Linux users, such as Ext3/ReiserFS and udev support. Arch Linux 0.7 (Wombat) uses the 2.6 linux kernel by default, and has support for XFS/JFS.<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32046
Arch Linux (正體中文)
2007-11-08T17:09:06Z
<p>Arnix: /* 獨一無二的套件管理模式 */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與清楚中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux strives to maintain the latest stable version of its software. We currently support a fairly streamlined core package set with a growing collection of extra packages made by users and AL developers.<br />
<br />
== 簡單就是美 ==<br />
<br />
In its goal to be simple and lightweight, I've left out the relatively useless portions of a linux system, things like /usr/doc and the info pages. In my own personal experience these are rarely used, and the equivalent information can be obtained from the net if need be. Man pages all the way...<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux also strives to use some of the newer features that are available to Linux users, such as Ext3/ReiserFS and udev support. Arch Linux 0.7 (Wombat) uses the 2.6 linux kernel by default, and has support for XFS/JFS.<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix
https://wiki.archlinux.org/index.php?title=Arch_Linux_(%E6%AD%A3%E9%AB%94%E4%B8%AD%E6%96%87)&diff=32045
Arch Linux (正體中文)
2007-11-08T17:05:17Z
<p>Arnix: /* 獨一無二的套件管理模式 */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|Deutsch|ArchLinux (Deutsch)}}<br />
{{i18n_entry|English|ArchLinux}}<br />
{{i18n_entry|Finnish|ArchLinux (Suomi)}}<br />
{{i18n_entry|Français|ArchLinux (Français)}}<br />
{{i18n_entry|Polski|ArchLinux (Polski)}}<br />
{{i18n_entry|Português do Brasil|ArchLinux_(Portugues_do_Brasil)}}<br />
{{i18n_entry|繁體中文|ArchLinux (繁體中文)}}<br />
{{i18n_entry|简体中文|ArchLinux (简体中文)}}<br />
{{i18n_entry|Русский|ArchLinux (Русский)}}<br />
{{i18n_entry|Slovensky|ArchLinux_(Slovensky)}}<br />
{{i18n_entry|עברית|ArchLinux (עברית)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}}<br />
<br />
= 什麼是 Arch Linux? =<br />
<br />
Arch Linux 是個專為 '''i686 微處理器最佳化過的 linux distribution (套件發行版)'''。Arch Linux 一開始是取用 CRUX 的核心思想,CRUX 是一套由 Per Lidén 開發,很棒的 Linux distribution。<br />
<br />
== Arch Linux 的優勢 ==<br />
<br />
Arch 的特點是fast, lightweight, flexible 和 simple (快速,輕巧,可塑性高和簡易)。這幾個形容詞看起來可能一點也不吸引人,但是至少他們都很正確的描寫出 Arch Linux 的特點。因為 Arch 特別針對 i686 微處理器做過最佳化,所以你可得到 CPU 在每個 cycle 內所能提供的最大的效用。與 RedHat 等其他的 Linux 套件發行版相比,Arch 顯得輕巧多了,同時 Arch 的簡單設計 (simple design) 也讓使用者可以輕易的幫他擴展功能並把他塑造為符合您的需求的系統。<br />
<br />
== 獨一無二的套件管理模式 ==<br />
<br />
Arch 使用了一種易用的 binary package 管理系統 - [[pacman]] - 它讓你可以只用一個指令就能升級整個系統。 Arch 也使用類似 ports 的 套件包建立系統 (Arch Build System) 來簡化套件包的製作,它可以只用一個指令讓系統同步到最新的狀態。沒錯! 您也可以只用一個指令達到重新編譯整個系統的目的。 所有的動作都在相當簡單與直觀中完成。<br />
<br />
== 只取最好的 ==<br />
<br />
Arch Linux strives to maintain the latest stable version of its software. We currently support a fairly streamlined core package set with a growing collection of extra packages made by users and AL developers.<br />
<br />
== 簡單就是美 ==<br />
<br />
In its goal to be simple and lightweight, I've left out the relatively useless portions of a linux system, things like /usr/doc and the info pages. In my own personal experience these are rarely used, and the equivalent information can be obtained from the net if need be. Man pages all the way...<br />
<br />
== 最新的工具與技術 ==<br />
<br />
Arch Linux also strives to use some of the newer features that are available to Linux users, such as Ext3/ReiserFS and udev support. Arch Linux 0.7 (Wombat) uses the 2.6 linux kernel by default, and has support for XFS/JFS.<br />
<br />
== 其他參考資料 ==<br />
<br />
Arch 的官方網站在 http://www.archlinux.org/ 。在官方網站上你也可以找到其他相關資源的連接,例如官方提供的使用者論壇(請注意,這是由使用者自行管理,掛在官方網站下的論壇 - 很多官方開發者並不會直接參與裡面的討論),官方的文件和其他連接。你也可以參閱 [[TheArchWay]] 這一篇文章以獲得更多關於 Arch 與 Arch 背後的哲學思想的資訊。<br />
<br />
== 中文方面的資料 ==<br />
<br />
中文方面的資料目前可分為繁體中文(台灣)和簡體(中國)兩部分。<br />
<br />
繁體中文的部分主要是由 [http://cle.linux.org.tw CLE] 來負責。目前提供的資源有官方 ftp 的 mirror,一個討論區和一個 wiki 來作中文方面得資源整合。<br />
<br />
簡體中文主要是由 [http://www.linuxsir.org Linuxsir] 來負責。目前提供了一個入口網頁作中文資源整合,和一個討論區。</div>
Arnix