https://wiki.archlinux.org/api.php?action=feedcontributions&user=Cucullus&feedformat=atom
ArchWiki - User contributions [en]
2024-03-19T13:50:48Z
User contributions
MediaWiki 1.41.0
https://wiki.archlinux.org/index.php?title=Network_configuration_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=84575
Network configuration (Русский)
2009-11-20T20:39:17Z
<p>Cucullus: /* Для статического IP */</p>
<hr />
<div>[[Category:Сеть]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Česky|Konfigurace_sítě_(Česky)}}<br />
{{i18n_entry|English|Configuring_network}}<br />
{{i18n_entry|Español|Configurando la Red (Español)}}<br />
{{i18n_entry|Italiano|Configuring_network_(Italiano)}}<br />
{{i18n_entry|Русский|Настройка_сети_(Русский)}}<br />
{{i18n_entry|Slovensky|Statická IP a DHCP}}<br />
{{i18n_entry|Türkçe|Ağ Ayarları}}<br />
{{i18n_entry|简体中文|网络配置_(简体中文)}}<br />
{{i18n_links_end}}<br />
<br />
<br />
== Обзор ==<br />
Это простое руководство по настройке сети.<br />
<br />
== Загрузка модуля устройства ==<br />
Если вы используете [[hwdetect]] или [[Replacing Hotplug with LSHWD|lshwd]], они должны обнаружить модуль для вашей сетевой карты (NIC) и загрузить его автоматически при старте системы. В другом случае вы должны знать, какой модуль требуется для вашей сетевой карты.<br />
<br />
Поищите эту информацию в сети или попробуйте LiveCD, чтобы найти имя требуемого модуля запустите [[Linux And Hardware|lsmod]], выведет все загруженные модули.<br />
<br />
Теперь когда вы знаете, какой модуль использовать, можно его загрузить:<br />
<br />
# modprobe <имя_модуля><br />
<br />
Если вы не хотите использовать какой-либо автозагрузчик (например, [[hwdetect]]) , вы можете добавить его в список MODULES в <code>/etc/rc.conf</code>, чтобы не подгружать его каждый раз. Например, если tg3 является требуемым модулем:<br />
<br />
MODULES=(!usbserial tg3 snd-cmipci)<br />
<br />
== Настройка ==<br />
=== Для DHCP ===<br />
Отредактируйте <code>/etc/rc.conf</code> следующим образом: <br />
<pre><br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
ROUTES=(!gateway)<br />
</pre><br />
<br />
=== Для статического IP ===<br />
Если вы используете интернет с windows машины без роутера, необходимо использовать статические ip адреса на обоих машинах. В противном случае возникнут проблемы в локальной сети.<br />
<br />
Вам понадобится:<br />
<br />
* Ваш статический ip адрес<br />
* Маска сети<br />
* Широковещательный адрес<br />
* Ваш шлюз<br />
* Адреса ваших DNS серверов<br />
* Доменное имя<br />
<br />
Если вы находитесь в частной сети, то можете использовать ip адреса диапазона 192.168.*.* с маской сети 255.255.0.0 и широковещательным адресом 192.168.255.255. Если в вашей сети нет роутера - адрес гейта значения не имеет. Исправьте <code>/etc/rc.conf</code>, подставляя свои значения для IP, маски сети, широковещательного адреса и гейта:<br />
<pre><br />
eth0="eth0 82.137.129.59 netmask 255.255.255.0 broadcast 82.137.129.255"<br />
INTERFACES=(eth0)<br />
gateway="default gw 82.137.129.1"<br />
ROUTES=(gateway)<br />
</pre><br />
и <code>/etc/resolv.conf</code>, заменив адреса ваших DNS серверов и доменное имя:<br />
<pre><br />
nameserver 61.23.173.5<br />
nameserver 61.95.849.8<br />
search example.com<br />
</pre><br />
<br />
Количество DNS серверов не ограничено.<br />
<br />
Если вы используете DHCP и не хотите, чтобы DNS сервера менялись каждый раз при запуске сети, добавьте параметр <code>-R</code> к <code>DHCPCD_ARGS</code> в вашем <code>/etc/conf.d/dhcpcd</code> ( используется <code>/etc/rc.d/network</code>). Это предотвратит перезапись <code>/etc/resolv.conf</code> DHCP:<br />
DHCPCD_ARGS="-R -t 30 -h $HOSTNAME"<br />
<br />
== Заключительное решение ==<br />
Возможно, вам придётся добавить параметр "-S" в аргументы dhcpcd, чтобы ваша сеть работала:<br />
<code>DHCPCD_ARGS="-S -t 30 -h $HOSTNAME"</code><br />
<br />
== Установка имени компьютера ==<br />
Отредактируйте <code>/etc/rc.conf</code> и установите HOSTNAME в соответствие с желаемым именем компьютера :<br />
HOSTNAME="banana"<br />
<br />
== Установка имени хоста/ip ==<br />
Отредактируйте <code>/etc/hosts</code> и добавьте похожую строку с тем же HOSTNAME, который вы ввели в <code>/etc/rc.conf</code> :<br />
127.0.0.1 banana.localdomain banana<br />
<br />
== Загрузка настроек ==<br />
Чтобы проверить ваши настройки, либо перезагрузите компьютер, либо запустите <code>#/etc/rc.d/network restart</code><br />
Попробйте пинговать ваш шлюз, DNS сервер, ISP провайдера и другие интернет сайт в этом порядке, чтобы установить какие-либо проблемы.<br />
<br />
== Дополнительные настройки ==<br />
<br />
=== Настройка беспроводной сети ===<br />
<br />
Настройка беспроводной сети (wlan) объяснена [[Wireless Setup|на другой странице]].<br />
<br />
=== Firewall ===<br />
<br />
Вы можете установить и настроить [[Firewalls|firewall]], чтобы быть более защищённым ;-)<br />
<br />
=== Ifplugd ===<br />
<br />
Вы можете установить демон, который будет автоматически настраивать вашу сеть, когда воткнут кабель, и возвращать её в исходное состояние, когда кабель выдернут. Это полезно для лаптопов с внутренними сетевыми адаптерами, так как демон настроит интерфейс только тогда, когда кабель действительно подключён. Также можно его использовать, когда надо перезапустить сеть, но вы не хотите перезапускать компьютер или делать это из оболочки.<br />
<br />
Установка очень проста, так как пакет находится в [extra]:<br />
<br />
# pacman -S ifplugd<br />
<br />
По умолчанию он настроен на работу с интрфейсом eth0. Эта другие настройки, например задержка, могут быть настроены в <code>/etc/ifplugd/ifplugd.conf</code>.<br />
<br />
Запустите его:<br />
<br />
# /etc/rc.d/ifplugd start<br />
<br />
или добавьте в список DAEMONS в <code>/etc/rc.conf</code><br />
<br />
== Возможные проблемы ==<br />
<br />
=== Проблема расширения TCP-окна ===<br />
TCP-пакеты содержат значение "окна" в своих заголовках, которое показывает, сколько данных другой хост может послать в ответе. Это значение представлено 16-ю битами. Следовательно, размер окна ограничен 64 килобайтами. Для более эффективного использования широкополосного соединения этого мало.<br />
<br />
В 1992 году, когда стало доступно больше памяти, был описан прием (см. [http://www.faqs.org/rfcs/rfc1323.html RFC 1323]), призванный улучшить ситуацию: расширение окна (Window Scaling). Значение "окна", предоставляемое всеми пакетами, модифицируется с помощью опредяемого в момент установки соединения коэффициента (Scale Factor).<br />
Коэффициент представлен восемью битами и позволяет увеличить значение окна в 32 раза.<br />
<br />
Но в интернете появилось множество роутеров и межсетевых экранов, которые переписывали значение окна на 0, создавая недоразумения.<br />
<br />
В ядре 2.6.17 была введена новая схема генерации коэффициента, с которой последствия прохождения пакетов через подобные роутеры стали более заметны.<br />
<br />
В результате соединение в лучшем случае очень медленно или падает.<br />
<br />
==== Как диагностировать проблему? ====<br />
<br />
Во-первых, давайте уясним: эта проблема проявляется не всегда. В некоторых случаях, вы сможете использовать TCP-соединения и соединяться с некоторыми хостами (очень немногими).<br />
<br />
'''Внимание''': вывод <code>dmesg</code> не выявит ничего необычного, логи будут чисты и <code>ifconfig</code> сообщит, что все нормально; в действительности все в норме.<br />
<br />
Если же вы не можете просмотреть любой веб-сайт, однако можете пинговать некоторые хосты, велики шансы, что вы столкнулись с этой проблемой: ping использует ICMP-протокол, которого не касаются проблемы TCP.<br />
<br />
Можете попробовать воспользоваться WireShark. Вы можете увидеть удачные UDP- и ICMP-соединения и неудачные TCP.<br />
<br />
==== Как это исправить? (Плохой способ) ====<br />
<br />
Для исправления плохим способом, вы можете изменить значение tcp_rmem, на котором базируется алгоритм вычисления коэффициента. Несмотря на то, что это может сработать с большинством хостов, нет гарантии, что это сработает с очень удаленными.<br />
<br />
echo "4096 87380 174760" > /proc/sys/net/ipv4/tcp_rmem<br />
<br />
Еще вы можете попробовать удалить один из модулей оперативной памяти (да, сэр).<br />
<br />
==== Как это исправить? (Хороший способ) ====<br />
<br />
Просто отключить злополучное расширение окна. Даже если это и хорошая функция, она может не работать, если вы не сможете разобраться с некорректной работой роутеров. Есть несколько способов отключить расширение окна, и похоже, что самым надежным будет добавить следующую строку в файл <code>/etc/rc.local</code>:<br />
<br />
echo 0 > /proc/sys/net/ipv4/tcp_window_scaling<br />
<br />
==== Как это исправить? (Действительно хороший способ) ====<br />
<br />
Если это происходит по вине роутеров и межсетевых экранов, замените их. Некоторые пользователи сообщали, что проблема была в их собственных DSL-роутерах.<br />
<br />
==== Хотите больше информации об этом? ====<br />
<br />
Эта секция основана на статьях [http://lwn.net/Articles/92727/ TCP window scaling and broken routers] и [http://kerneltrap.org/node/6723 Window Scaling on the Internet].<br />
<br />
Позднее, некоторые пользователи Arch столкнулись с этим:<br />
<br />
* [http://www.archlinux.org/pipermail/arch/2006-June/011250.html Odd network issue]<br />
* [http://www.archlinux.org/pipermail/arch/2006-September/011943.html Kernel 2.6.17 and TCP window scaling] &mdash; Тема, с которой началась эта статья<br />
<br />
Также есть несколько обсуждений в LKML.<br />
<br />
[[Category:Русский]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Network_configuration_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=84574
Network configuration (Русский)
2009-11-20T20:38:50Z
<p>Cucullus: /* Для DHCP */</p>
<hr />
<div>[[Category:Сеть]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Česky|Konfigurace_sítě_(Česky)}}<br />
{{i18n_entry|English|Configuring_network}}<br />
{{i18n_entry|Español|Configurando la Red (Español)}}<br />
{{i18n_entry|Italiano|Configuring_network_(Italiano)}}<br />
{{i18n_entry|Русский|Настройка_сети_(Русский)}}<br />
{{i18n_entry|Slovensky|Statická IP a DHCP}}<br />
{{i18n_entry|Türkçe|Ağ Ayarları}}<br />
{{i18n_entry|简体中文|网络配置_(简体中文)}}<br />
{{i18n_links_end}}<br />
<br />
<br />
== Обзор ==<br />
Это простое руководство по настройке сети.<br />
<br />
== Загрузка модуля устройства ==<br />
Если вы используете [[hwdetect]] или [[Replacing Hotplug with LSHWD|lshwd]], они должны обнаружить модуль для вашей сетевой карты (NIC) и загрузить его автоматически при старте системы. В другом случае вы должны знать, какой модуль требуется для вашей сетевой карты.<br />
<br />
Поищите эту информацию в сети или попробуйте LiveCD, чтобы найти имя требуемого модуля запустите [[Linux And Hardware|lsmod]], выведет все загруженные модули.<br />
<br />
Теперь когда вы знаете, какой модуль использовать, можно его загрузить:<br />
<br />
# modprobe <имя_модуля><br />
<br />
Если вы не хотите использовать какой-либо автозагрузчик (например, [[hwdetect]]) , вы можете добавить его в список MODULES в <code>/etc/rc.conf</code>, чтобы не подгружать его каждый раз. Например, если tg3 является требуемым модулем:<br />
<br />
MODULES=(!usbserial tg3 snd-cmipci)<br />
<br />
== Настройка ==<br />
=== Для DHCP ===<br />
Отредактируйте <code>/etc/rc.conf</code> следующим образом: <br />
<pre><br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
ROUTES=(!gateway)<br />
</pre><br />
<br />
=== Для статического IP ===<br />
Если вы используете интернет с windows машины без роутера, необходимо использовать статические ip адреса на обоих машинах. В противном случае возникнут проблемы в локальной сети.<br />
<br />
Вам понадобится:<br />
<br />
* Ваш статический ip адрес<br />
* Маска сети<br />
* Широковещательный адрес<br />
* Ваш шлюз<br />
* Адреса ваших DNS серверов<br />
* Доменное имя<br />
<br />
Если вы находитесь в частной сети, то можете использовать ip адреса диапазона 192.168.*.* с маской сети 255.255.0.0 и широковещательным адресом 192.168.255.255. Если в вашей сети нет роутера - адрес гейта значения не имеет. Исправьте <code>/etc/rc.conf</code>, подставляя свои значения для IP, маски сети, широковещательного адреса и гейта:<br />
<pre><br />
lo="lo 127.0.0.1"<br />
eth0="eth0 82.137.129.59 netmask 255.255.255.0 broadcast 82.137.129.255"<br />
INTERFACES=(lo eth0)<br />
gateway="default gw 82.137.129.1"<br />
ROUTES=(gateway)<br />
</pre><br />
и <code>/etc/resolv.conf</code>, заменив адреса ваших DNS серверов и доменное имя:<br />
<pre><br />
nameserver 61.23.173.5<br />
nameserver 61.95.849.8<br />
search example.com<br />
</pre><br />
<br />
Количество DNS серверов не ограничено.<br />
<br />
Если вы используете DHCP и не хотите, чтобы DNS сервера менялись каждый раз при запуске сети, добавьте параметр <code>-R</code> к <code>DHCPCD_ARGS</code> в вашем <code>/etc/conf.d/dhcpcd</code> ( используется <code>/etc/rc.d/network</code>). Это предотвратит перезапись <code>/etc/resolv.conf</code> DHCP:<br />
DHCPCD_ARGS="-R -t 30 -h $HOSTNAME"<br />
<br />
== Заключительное решение ==<br />
Возможно, вам придётся добавить параметр "-S" в аргументы dhcpcd, чтобы ваша сеть работала:<br />
<code>DHCPCD_ARGS="-S -t 30 -h $HOSTNAME"</code><br />
<br />
== Установка имени компьютера ==<br />
Отредактируйте <code>/etc/rc.conf</code> и установите HOSTNAME в соответствие с желаемым именем компьютера :<br />
HOSTNAME="banana"<br />
<br />
== Установка имени хоста/ip ==<br />
Отредактируйте <code>/etc/hosts</code> и добавьте похожую строку с тем же HOSTNAME, который вы ввели в <code>/etc/rc.conf</code> :<br />
127.0.0.1 banana.localdomain banana<br />
<br />
== Загрузка настроек ==<br />
Чтобы проверить ваши настройки, либо перезагрузите компьютер, либо запустите <code>#/etc/rc.d/network restart</code><br />
Попробйте пинговать ваш шлюз, DNS сервер, ISP провайдера и другие интернет сайт в этом порядке, чтобы установить какие-либо проблемы.<br />
<br />
== Дополнительные настройки ==<br />
<br />
=== Настройка беспроводной сети ===<br />
<br />
Настройка беспроводной сети (wlan) объяснена [[Wireless Setup|на другой странице]].<br />
<br />
=== Firewall ===<br />
<br />
Вы можете установить и настроить [[Firewalls|firewall]], чтобы быть более защищённым ;-)<br />
<br />
=== Ifplugd ===<br />
<br />
Вы можете установить демон, который будет автоматически настраивать вашу сеть, когда воткнут кабель, и возвращать её в исходное состояние, когда кабель выдернут. Это полезно для лаптопов с внутренними сетевыми адаптерами, так как демон настроит интерфейс только тогда, когда кабель действительно подключён. Также можно его использовать, когда надо перезапустить сеть, но вы не хотите перезапускать компьютер или делать это из оболочки.<br />
<br />
Установка очень проста, так как пакет находится в [extra]:<br />
<br />
# pacman -S ifplugd<br />
<br />
По умолчанию он настроен на работу с интрфейсом eth0. Эта другие настройки, например задержка, могут быть настроены в <code>/etc/ifplugd/ifplugd.conf</code>.<br />
<br />
Запустите его:<br />
<br />
# /etc/rc.d/ifplugd start<br />
<br />
или добавьте в список DAEMONS в <code>/etc/rc.conf</code><br />
<br />
== Возможные проблемы ==<br />
<br />
=== Проблема расширения TCP-окна ===<br />
TCP-пакеты содержат значение "окна" в своих заголовках, которое показывает, сколько данных другой хост может послать в ответе. Это значение представлено 16-ю битами. Следовательно, размер окна ограничен 64 килобайтами. Для более эффективного использования широкополосного соединения этого мало.<br />
<br />
В 1992 году, когда стало доступно больше памяти, был описан прием (см. [http://www.faqs.org/rfcs/rfc1323.html RFC 1323]), призванный улучшить ситуацию: расширение окна (Window Scaling). Значение "окна", предоставляемое всеми пакетами, модифицируется с помощью опредяемого в момент установки соединения коэффициента (Scale Factor).<br />
Коэффициент представлен восемью битами и позволяет увеличить значение окна в 32 раза.<br />
<br />
Но в интернете появилось множество роутеров и межсетевых экранов, которые переписывали значение окна на 0, создавая недоразумения.<br />
<br />
В ядре 2.6.17 была введена новая схема генерации коэффициента, с которой последствия прохождения пакетов через подобные роутеры стали более заметны.<br />
<br />
В результате соединение в лучшем случае очень медленно или падает.<br />
<br />
==== Как диагностировать проблему? ====<br />
<br />
Во-первых, давайте уясним: эта проблема проявляется не всегда. В некоторых случаях, вы сможете использовать TCP-соединения и соединяться с некоторыми хостами (очень немногими).<br />
<br />
'''Внимание''': вывод <code>dmesg</code> не выявит ничего необычного, логи будут чисты и <code>ifconfig</code> сообщит, что все нормально; в действительности все в норме.<br />
<br />
Если же вы не можете просмотреть любой веб-сайт, однако можете пинговать некоторые хосты, велики шансы, что вы столкнулись с этой проблемой: ping использует ICMP-протокол, которого не касаются проблемы TCP.<br />
<br />
Можете попробовать воспользоваться WireShark. Вы можете увидеть удачные UDP- и ICMP-соединения и неудачные TCP.<br />
<br />
==== Как это исправить? (Плохой способ) ====<br />
<br />
Для исправления плохим способом, вы можете изменить значение tcp_rmem, на котором базируется алгоритм вычисления коэффициента. Несмотря на то, что это может сработать с большинством хостов, нет гарантии, что это сработает с очень удаленными.<br />
<br />
echo "4096 87380 174760" > /proc/sys/net/ipv4/tcp_rmem<br />
<br />
Еще вы можете попробовать удалить один из модулей оперативной памяти (да, сэр).<br />
<br />
==== Как это исправить? (Хороший способ) ====<br />
<br />
Просто отключить злополучное расширение окна. Даже если это и хорошая функция, она может не работать, если вы не сможете разобраться с некорректной работой роутеров. Есть несколько способов отключить расширение окна, и похоже, что самым надежным будет добавить следующую строку в файл <code>/etc/rc.local</code>:<br />
<br />
echo 0 > /proc/sys/net/ipv4/tcp_window_scaling<br />
<br />
==== Как это исправить? (Действительно хороший способ) ====<br />
<br />
Если это происходит по вине роутеров и межсетевых экранов, замените их. Некоторые пользователи сообщали, что проблема была в их собственных DSL-роутерах.<br />
<br />
==== Хотите больше информации об этом? ====<br />
<br />
Эта секция основана на статьях [http://lwn.net/Articles/92727/ TCP window scaling and broken routers] и [http://kerneltrap.org/node/6723 Window Scaling on the Internet].<br />
<br />
Позднее, некоторые пользователи Arch столкнулись с этим:<br />
<br />
* [http://www.archlinux.org/pipermail/arch/2006-June/011250.html Odd network issue]<br />
* [http://www.archlinux.org/pipermail/arch/2006-September/011943.html Kernel 2.6.17 and TCP window scaling] &mdash; Тема, с которой началась эта статья<br />
<br />
Также есть несколько обсуждений в LKML.<br />
<br />
[[Category:Русский]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=67386
Timezone (Русский)
2009-04-22T09:58:51Z
<p>Cucullus: /* UTC и localtime */</p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Русский]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_entry|Español|TIMEZONE (Español)}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное мировое) или по местному (local time) времени.<br />
Как правило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно устанавливаются по местному времени.<br />
<br />
Установить режим машинных часов можно через переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>UTC</code>, то Linux переведёт часы с зимнего на летнее время (или наоборот) вне зависимости от того работал компьютер в момент перехода на другое время или нет.<br />
<br />
'''ВАЖНО:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (или наоборот), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботятся о переводе часов. В противном случае Вам придётся перевести часы вручную.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Wpa_supplicant_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=60223
Wpa supplicant (Русский)
2009-02-05T23:32:42Z
<p>Cucullus: /* Установка */</p>
<hr />
<div>{{i18n_links_start}}<br />
{{i18n_entry|English|WPA Supplicant}}<br />
{{i18n_entry|简体中文|WPA 客户端}}<br />
{{i18n_entry|Russian|WPA Supplicant (Русский)}}<br />
{{i18n_links_end}}<br />
<br />
[[Category:Русский]]<br />
[[Category:Сеть]]<br />
==Читать в первую очередь==<br />
Эта статья предполагает, что вы общаетесь на "ты" со своим "железом" и способны не заблудиться в конфигурационных файлах и настройках вашей системы. Также очень важно, чтобы вы *прочли и поняли* статью [[Wireless Setup (Русский)]], потому что это базис для всего того, что мы попытаемся тут объяснить.<br />
<br />
Предыдущая статья была расширена с использованием [[ABS - The Arch Build System (Russian)]] и Сетевых Профилей, упомянутых в [[Wireless Setup (Русский)]]. Я считаю, что лучшее понимание системы всегда помогает, но, как правило, отвлекают целей и, в конечном итоге влияет на масштабы этого документа. <br />
<br />
Наконец, эта статья не является обязательной, если ваше "железо" работает из коробки или с использованием демона типа Network Manager или подобного. Если вы предпочитаете использовать графическую для настройки соединений, вам не следует читать это.<br />
<br />
==Что такое WPA Supplicant?==<br />
Вероятно вы слышали о присущей WEP уязвимости. Сеть, защищенная статическим ключом WEP легко может быть подвержена риску со стороны заинтересованного взломщика. WPA решает проблему статического ключа, изменяя его в пакете отданных\полученных частот, или каждый раз по прошествию какого-то времени. Этот процесс предоставляется демоном, который тесно связан с беспроводным оборудованием. <br />
<br />
Плохие драйверы (в частности те, которые используют ndispluginwrapper) могут привести к бесплодным попыткам настройки сети, когда они используются вместе с wpa_supplicant, итак, если возможно, то используйте "железо" с соответствующей поддержкой и высоким качеством драйверов.<br />
<br />
Для подробной информации можно использоваться домашнюю страницу проекта WPA Supplicant: http://hostap.epitest.fi/wpa_supplicant/<br />
<br />
==Установка==<br />
wpa_supplicant установлен по умолчанию, когда вытягивается группа 'base' из репозиториев. Используя pacman, пакет может быть установлен явно:<br />
pacman -S wpa_supplicant<br />
<br />
Пакет был собран для поддержки очень большого диапозона беспроводного оборудования. Для вашего сведения, вот список, который можно получить, выполнив 'wpa_supplicant ", без кавычек в вашей строке запроса Bash.<br />
<br />
# wpa_supplicant<br />
...<br />
<br />
Driver list: # список драйверов<br />
<br />
*HostAP<br />
*Prism54<br />
*Madwifi<br />
*NDISWrapper<br />
*AMTEL<br />
*IPW (both 2100 and 2200 drivers)<br />
*WEXT (Generic Linux wireless extensions)<br />
*Wired ethernet<br />
<br />
Большая часть беспроводного оборудования поддерживается по умолчанию в wpa_supplicant. Даже если производитель вашего чипсета не перечислен (что проиходит в большинстве возможных случаев), вы по прежнему можете вынудить использовать Generic Wireless Extensions для соединения с защищенной WPA сетью. Основываясь на своем богатом опыте, 75% "железа" поддерживается WEXT, около 20% совместимо после перекомпиляции wpa_supplicant/драйверов из исходников и, к сожалению, 5% вообще несовместимо по определению. Я буду говорить о несовместимости позже, но если вы в полном отчаяние, используйте ABS как вариант. WPA Supplicant доступен в /var/abs/core/wpa_supplicant.<br />
<br />
==Процесс==<br />
/etc/wpa_supplicant.conf содержит все настройки для wpa_supplicant. Их содержание довольно простое, несмотря на то, что файл-пример ужасно запутанный. Для упрощения: под учетной записью root переименуйте стандартный файл wpa_supplicant.conf. Он не нужен в данный момент.<br />
# mv /etc/wpa_supplicant.conf /etc/wpa_supplicant.conf.original<br />
<br />
SSID и пароль для вашей зашифрованной сети должен быть кодирован в шестнадцатиричную строку. Это легко выполняется при использовании утилиты wpa_passphrase, которая является частью пакета wpa_supplicant. Используйте синтаксис <code>wpa_passphrase [ssid] [passphrase]</code><br />
<br />
*Пример:<br />
<br />
# wpa_passphrase mywireless secretpassphrase<br />
<br />
должно сгенерироваться что-то наподобии представленного ниже:<br />
network={<br />
ssid="mywireless"<br />
#psk="secretpassphrase"<br />
psk=b90e230f1f2f5361a9b2d3acf276745ee3c751c0724a3b0052d6df15ec420e69<br />
}<br />
<br />
Это базовые настройки для того, чтобы зашифрованная сеть заработала. Первая строка "заявляет" об открытии сети, вторая содержит SSID для базовой станции с которой вы хотите соединиться, третья - пароль, и четвертная содержит hex-код, который требуется для связи с сетью.<br />
*Воспользуйтесь wpa_passphrase, укажите актуальный SSID и пароль, а затем передайте вывод в файл /etc/wpa_supplicant.conf:<br />
<br />
# wpa_passphrase myssid mypassphrase > /etc/wpa_supplicant.conf<br />
<br />
изменяйте информацию на применимую лично к вам. Эта команда создаст базовый файл /etc/wpa_supplicant.conf из вывода команды wpa_passphrase. <br />
{{Box Note | Ваша информация о сети будет сохранена в обычном текстовом формате, так что вы можете изменить права доступа для только что созданного файла /etc/wpa_supplicant.conf (например <tt>chmod 0600 /etc/wpa_supplicant.conf</tt> сделает файл читаемым только для root), в зависимости от вашего осознания вопросов безопасности. }}<br />
<br />
Внесение дополнительной WPA-защищенной сети может быть сделано так:<br />
# wpa_passphrase additional_ssid additional_passphrase >> /etc/wpa_supplicant.conf<br />
Знаки '>>' добавят вывод команды в конец файла /etc/wpa_supplicant.conf без перезаписи.<br />
<br />
Существует большое количество настроек, которые можно применить для вашей сети, их вы можете изучить просмотрев оригинальный конфигурационный файл. В большинстве случаев вы можете пользоваться настройками по умолчанию, и не выполнять из последующего ничего.<br />
<br />
Последнее, впишите эти дополнительные строки в самый верх файла /etc/wpa_supplicant.conf, используя ваш любимый редактор:<br />
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=wheel<br />
<br />
Если вам необходимо соединяться с несколькими сетями, просто укажите блоки для другой сети в этом же файле. Изменяйте приоритеты по желанию, приоритет с большим числом обрабатывается в первую очередь.<br />
<br />
Теперь можно попробовать соединиться вручную.<br />
<br />
Сначала поднимите сетевой wifi интерфейс. Для этого, в последующем примере используется интерфейс <code>wlan0.</code><br />
<br />
# ifconfig wlan0 up<br />
<br />
Далее, укажите интерфейсу SSID точки доступа:<br />
# iwconfig wlan0 essid [ssid]<br />
После того как SSID будет принят (около 10 секунд в среднем), вам необходимо будет запустить wpa_supplicant для завершения ассоции шифрования. Как правило, у вас будет возможность использовать драйвер ''W'''ireless '''EXT'''ensions, если нет, то вы можете узнать в интернете как это сделать для вашего беспроводного оборудования.<br />
<br />
Выполните следующее с правами root:<br />
<br />
# wpa_supplicant -B -Dwext -i wlan0 -c /etc/wpa_supplicant.conf <br />
Что сообщит wpa_supplicant об использовании стандартной конфигурации "железа" (WEXT - Linux '''W'''ireless '''EXT'''ensions) и привяжет к SSID, указанному в /etc/wpa_supplicant.conf. Кроме того, это объединение должно осуществляться посредством беспроводного интерфейса wlan0 и этот процесс должен перейти на задний план (-B). Для подробного вывода добавьте '''-d''' или '''-dd''' (для отладки), чтобы в консоль получить больше информации.<br />
<br />
В выводе консоли должна быть строка ''''Associated:'''' и последующий за ней MAC-адрес. Все что теперь необходимо - получить IP-адрес.<br />
<br />
С правами root выполните:<br />
# dhcpcd wlan0<br />
<br />
*Заметка: *Не* запрашивайте IP сразу! Вы должны подождать, чтобы быть уверенным, что привязка прошла. Если вы используете скрипт, то можно добавить "sleep 10s", чтобы подождать 10 секунд.<br />
<br />
Проверьте, получил ли интерфейс IP-адрес, воспользуйтесь ifconfig:<br />
# ifconfig wlan0<br />
<br />
wlan0 Link encap:Ethernet HWaddr 00:1C:BF:66:4E:E0 <br />
inet addr:192.168.0.62 Bcast:192.168.0.255 Mask:255.255.255.0<br />
inet6 addr: fe80::21c:bfff:fe66:4ee0/64 Scope:Link<br />
UP BROADCAST MULTICAST MTU:1500 Metric:1<br />
RX packets:140387 errors:0 dropped:0 overruns:0 frame:0<br />
TX packets:96902 errors:0 dropped:0 overruns:0 carrier:0<br />
collisions:0 txqueuelen:1000<br />
RX bytes:125513183 (119.6 Mb) TX bytes:12299192 (11.7 Mb)<br />
<br />
Если вывод похож на представленный выше, значит вы соединены. Если это так, то вы можете заняться изучением скриптов netcfg2 для настройки на более постоянных условиях и получить работающую сеть при запуске компьютера.<br />
В зависимости от того, какой подход к настройке беспроводной сети вы избрали, вы можете решить использовать графическую, но не такую "захватывающую" утилиту, например [[Wicd]] или выбрать использование сетевых профилей, поддерживаемых netcfg.<br />
<br />
Более продвинутые настройки, такие как EAPOL и RADIUS аутентификации очень хорошо описаны в man-странице wpa_supplicant.conf. Эти настройки выходят за пределы этой статьи.<br />
<br />
==Но блин, у меня оно не работает - (Перекомпиляция wpa_supplicant из исходников)==<br />
Возьмите копию исходных текстов wpa_supplicant на домашней странице проекта или из ABS. После того как скачаете и распакуете, взгляните на файл '.config' (да, он скрыт). Файл выглядит как файл конфигурации ядра, но намного меньше. Обратите внимание на секцию с заголовком CONFIG_DRIVER_''DRIVERNAME'' и выберите "да" или "нет", в зависимости от вашего драйвера. Будьте осторожны с выбором, потому что вам понадобится указать дополнительный путь к исходным текстам драйвера беспроводных устройств, чтобы правильно скомпилировать компоненты ассоциирующиеся на низком уровне. Некоторые странные карты Atheros могут потребовать новой компиляции wpa_supplicant со сборкой последней доступной версией madwifi из SVN. Если это тот случай, вот пример для демонстрации процесса компиляции:<br />
<br />
'''пример с madwifi''': отредактируйте следующие строки в файле конфигурации, чтобы они выглядели как те, что ниже. Это предполагает, что вы собрали madwifi из ABS и исходники сохранены в /var/abs/local/madwifi/src/.<br />
<br />
#Интерфейс драйвера для madwifi<br />
CONFIG_DRIVER_MADWIFI=y<br />
#Измените приведенные директории, чтобы они совпадали с локальными<br />
CFLAGS += -I/var/abs/local/madwifi/src/madwifi<br />
<br />
Достаточно настроить один раз, далее можно будет использоваться makepkg.<br />
<br />
==Управление==<br />
===[[Wicd]]===<br />
<br />
Установка:<br />
# pacman -S [[wicd]] <br />
<br />
Очень просто. Ищите сети, вводите требуемые данныи и соединяетесь. Возможно понадобится добавить<br />
/usr/lib/wicd/autoconnect.py<br />
<br />
в ваши init-скрипты и скрипты управления питанием для соединения с вашими сетями, если необходимо автосоединение.<br />
<br />
===netcfg===<br />
<br />
Это очень минималистичный вариант, который работает в большинстве случаев. Я говорю "в большинстве случаев", потому что я видел некоторые проблемы соединения с некоторыми настройками, которые я не смог отладить. Большинство этих проблем возникают около DHCP (таймауты), их можно исправить перезапустив dhcpcd.<br />
<br />
Конфигурация профиля предельно проста. Отредактируйте профиль согласно вашим нуждам, уделяя особое внимание на:<br />
SECURITY="wpa"<br />
KEY="вашпароль"<br />
<br />
Эта конфигурация должна работать в большинстве систем. Если ваше "железо" показывает любой признак отказа работы, вы можете изменить значение связанные с драйвером wpa_supplicant. <br />
<br />
'''Пример профиля, использующего для соединения с сетью wekonet карту ralink на channel 11'''<br />
#<br />
# Network Profile<br />
#<br />
<br />
DESCRIPTION="Example WPA Network Profile"<br />
<br />
# Network Settings<br />
INTERFACE=ra0<br />
HOSTNAME=wekonet<br />
<br />
# Interface Settings (use IFOPTS="dhcp" for DHCP)<br />
IFOPTS="dhcp"<br />
#GATEWAY=192.168.0.1<br />
<br />
# DNS Settings (optional)<br />
#DOMAIN=localdomain<br />
#DNS1=192.168.0.1<br />
#DNS2=<br />
<br />
# Wireless Settings (optional)<br />
ESSID=wekonet<br />
#KEY=<br />
IWOPTS="mode managed essid $ESSID channel 11"<br />
<br />
#WIFI_INTERFACE=wlan0 # используйте эту строку, если вы хотите указать специальный беспроводной интерфейс,<br />
# который обращается к реальному $INTERFACE<br />
<br />
#WIFI_WAIT=5 # количество секунд для ожидания ассоциации сетевой карты<br />
# прежде чем интерфейс поднимется<br />
<br />
USEWPA="yes" # запуск wpa_supplicant из профиля<br />
WPAOPTS="-D ralink" # используйте "" для обычной работы или укажите особые дополнительные<br />
# опции (например, "-D ipw")<br />
# смотите /etc/wpa_supplicant.conf для настройки<br />
<br />
==Общие проблемы==<br />
99.9% проблем связаны с ассоциацией карты. Итак, внимательно посмотрите на вывод wpa_supplicant, когда обнаружено отклонение. Добавьте "-d" (для отладки), чтобы повысить подробности вывода. Обычно "-dd" бывает достаточно, в то время как "-dddd" может убить все.<br />
<br />
Когда будете просматривать запись (лог), обратите внимание на строки типа:<br />
<br />
ioctl['''ЧТО УГОДНО''']: Operation not supported<br />
<br />
В этом случае вы сталкиваетесь с проблемой драйвера. Обновите драйвер или измените параметр -D.<br />
<br />
Другая распространенная проблема - это сообщение ''No suitable AP found''. Wpa_supplicant, очевидно, испытывает трудности в обнаружении скрытых ESSID. Обычно установка "scan_ssid=1" в блоке "сеть" исправляет эту проблему.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=VMware_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=55424
VMware (Русский)
2008-12-14T12:57:02Z
<p>Cucullus: /* Установка VMware Server */</p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
{{translateme}}<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Installing_VMware}}<br />
{{i18n_entry|简体中文|安装VMWare}}<br />
{{i18n_entry|Italiano|Installing_VMware (Italiano)}}<br />
{{i18n_entry|Русский|Установка_VMware (Русский)}}<br />
{{i18n_links_end}}<br />
[http://www.vmware.com/ VMware] устанавливается на [[Arch Linux]] довольно легко, однако установка не всегда предельно ясна.<br />
<br />
==Установка VMware Workstation==<br />
Следующая информация взята из пользовательких комментариев в AUR по VMWare Workstation пользователем whompus. Она описывает как установить VMWare Workstation 6.5.x на одну из архитектур.<br />
<br />
В качестве временной меры можно воспользоваться представленным способом установки 6.5. Заметьте, что pacman '''не''' будет использован в данном случае, так что установку '''нельзя''' будет отследить\удалить, используя pacman.<br />
<br />
Для установки Workstation на Linux действуйте следующим образом:<br />
<br />
1. Скачайте VMware-Workstation-6.5.xxxxxx.bundle. Где xxxxx минорная (с незначительными изменениями) версия программы и архитектура.<br />
<br />
2. В терминале смените текущую дерикторию на ту, в которую загрузили файл.<br />
<br />
3. С правами root выполните начальные шаги установки:<br />
# mkdir -p /etc/rc.d/vmware.d/rc{0,1,2,3,4,5,6}.d<br />
# sh VMware-Workstation-6.5.xxxxxx.bundle --console --custom<br />
<br />
4. Прочитайте и примите EULA для продолжения.<br />
<br />
5. Принимайте стандартные настройки до тех пор, пока не появится запрос "System service runlevels", установите тогда следующее:<br />
/etc/rc.d/vmware.d/<br />
<br />
6. Для System service scripts выставьте:<br />
/etc/rc.d<br />
<br />
7. (Опционально) Введите путь к директории с Integrated Virtual Debugger для Eclipse, если Eclipse установлен.<br />
<br />
8. Жмите "ввод" для установки. Заметка: если ничего не произошло и заново открылось приглашение в консоли, попробуйте запустить установку снова без параметра '--console'.<br />
<br />
9. Откройте Workstation (наберите <code>vmware</code> в консоли) для настройки и использования!<br />
<br />
==Установка VMware Server==<br />
{{Box Note |''' Настоятельно рекомендуется использовать VMWare Server 2 на ядре 2.6.27, так как это актуальные сборки. Также они не требуют наложения патча.'''}}<br />
<br />
Вы можете использовать [http://aur.archlinux.org/packages.php?do_Details=1&ID=6182&O=0&L=0&C=0&K=vmware&SB=n&SO=a&PP=25&do_MyPackages=0&do_Orphans=0&SeB=nd AUR] или ручную установку [http://www.vmware.com/download/server/ VMware Server] скачанного с [http://www.vmware.com/ VMware.com]. Это руководство покажет как в ручную установить скачанный тарбол с VMware server, предполагается, что вы используете Voodoo или более свежий Arch Linux с версией ядра 2.6.20+ '''32-bit'''.<br />
<br />
===Требования:===<br />
* Root доступ. Одно из двух, 'sudo' или 'su'. В этом руководстве я буду использовать 'sudo'.<br />
* [http://archlinux.org/packages/search/?repo=all&category=all&q=xinetd&lastupdate=&limit=50 Xinetd] установлен и запущен.<br />
* Библиотеки X - libxtst, libxt и libxrender установлены.<br />
* [http://www.vmware.com/download/server/ VMware server tarball]; последний 1.0.4 build 56528 во время написания этих строк.<br />
* <strike>VMware server [http://www.vmware.com/community/thread.jspa?messageID=76957&tstart=0 any-to-any]" patch: [http://platan.vc.cvut.cz/ftp/pub/vmware mirror 1] and [ftp://ftp.cvut.cz/vmware mirror 2]. Note: For server 1.0.4 build 56528 you need patch vmware-any-any-update113.tar.bz2, which is on mirror 1 only.</strike><br />
* UPDATE: Для ядра 2.6.24 вам понадобится этот [http://rtr.ca/vmware-2.6.24/ patch] (vmware-any-any-update115a.tgz)<br />
* UPDATE: Для ядра 2.6.25 вам также понадобится также этот [http://blog.creonfx.com/temp/vmware-any-any-update-117-very-ALPHA.tgz patch] (vmware-any-any-update-117-very-ALPHA)<br />
* Совместимость с VMware Workstation >= 6.0.2 Build 59824 on Linux 2.6.25<br />
* UPDATE: Для ядра 2.6.26 вам понадобится этот [http://vmkernelnewbies.googlegroups.com/web/vmware-any-any-update117d.tar.gz patch] (vmware-any-any-update117d.tar.gz), VMware версии 6.0.5 этот патч не нуже, версия vmmon нужна не младше 169.<br />
* UPDATE: Для ядра 2.6.26 и VMWare 6.5 патчи больше _не_ нужны (6.5.0 build-118166). Графический инсталлятор работает хорошо, а все модули работают "из коробки". Следуйте дальнейшим инструкциям до определения директории, содержащей init-скрипты.<br />
<br />
===Инструкция:===<br />
* Выполните '''''sudo mkdir -p /etc/rc.d/vmware.d/rc{0,1,2,3,4,5,6}.d''''' для создания runlevel-директорий для VMware.<br />
* Выполните '''''sudo ln -s /bin/lsmod /sbin/''''' для создания символической ссылки на lsmod.<br />
* Извлеките тарбол с VMware Server куда угодно, например в /tmp/.<br />
* Выполните '''''cd /tmp/vmware-server-distrib;sudo ./vmware-install.pl'''''. Я использовал для установки '''''/home/vmware/bin'''''.<br />
* При запросе расположения директорий от ''rc0.d'' до ''rc6.d'', используйте '''''/etc/rc.d/vmware.d'''''.<br />
* При запросе директории с init скриптами укажите '''''/etc/rc.d'''''.<br />
* '''*Выйдите*''', когда появится запрос о запуске первоначальной конфигурации VMware.<br />
* Извлеките куда-нибудь VMware Server any-to-any patch... например /tmp/.<br />
* Выполните '''''cd /tmp/vmware-any-any-update*REV*;sudo ./runme.pl'''''. Это наложит заплатку на модули VMware Server, чтобы позволить ядру Linux 2.6.20 скомпилироваться.<br />
* Для ядра 2.6.25 дополнительно к предыдущей заплатке patch115a или 116 вам понадобится вручную установить 117_Alpha.<br />
* Для 2.6.25 Извлеките 117 в каталог '''''tar xzf vmware-any-any-update-117-very-ALPHA.tgz -C /usr/lib/vmware/modules/source/<br />
* Для наложения заплатки на 2.6.25 '''''cd /usr/lib/vmware/modules/source/''''' и запустите '''''./vmware-2.6.25.sh''''' и продолжите выполнять следующие шаги.<br />
* Выполните '''''cd /home/vmware/bin;sudo ./vmware-config.pl''''' для компиляции модулей VMware.<br />
<br />
== Запуск ==<br />
<br />
Возможно, что при первом запуске VMware Server вы получите ошибку, которая начинается примерно так "Unable to power virtual machine". Остановите VMware Server и перезапустите xinetd '''''/etc/rc.d/vmware stop;wait;/etc/rc.d/xinetd restart'''''.<br />
<br />
Выполните '''''sudo /home/vmware/bin/vmware-config.pl''''' снова. Если ошибка не исчезла, перезапустите свой компьютер и повторите последнее действие снова. Все должно исправиться.<br />
<br />
Теперь <code>vmware</code> init-скрипт в <code>/etc/rc.d</code>. Вы можете добавить его в лист демонов, если захотите. Лично я так не сделал, но если вы намереваетесь использовать сеть vmware, не используя сам vmware, вам это понадобится. Вам нужно запустить этот init-скрипт перед запуском VMware.<br />
<br />
Есть проблема, когда vmware не может корректно запуститься после перезагрузки. Для того, чтобы исправить это, отредактируйте <code>/etc/rc.d/vmware</code>, найдите следующий текст<br />
case "$1" in<br />
start)<br />
и вставьте<br />
rm /etc/vmware/not_configured<br />
сразу же после последней строки.<br />
<br />
Чтобы запустить vmware, просто выполните <code>vmware</code> в терминале, или создайте ярлык или строку меню, как пожелаете.<br />
<br />
'''Некоторые замечания:'''<br />
<br />
Оставьте директорию <code>/etc/rc.d/vmware.d</code> там где она есть, потому что она необходима, когда вы выполните <code>vmware-config.pl</code>.<br />
<br />
Помните, если ваше ядро изменилось или обновилось, вам нужно запустить <code>vmware-config.pl</code> снова.<br />
<br />
== Ядро 2.6 и udev ==<br />
<br />
Follow the steps above and then:<br />
<br />
'''1. Modify udev config'''<br />
<br />
Edit <code>/etc/udev/rules.d/00-myrules.rules</code> and add 2 lines:<br />
# tty devices<br />
KERNEL="tty<nowiki>[[0-9]]</nowiki>*", NAME="vc/%n", SYMLINK="%k"<br />
<br />
# floppy devices<br />
KERNEL="fd<nowiki>[[0-9]]</nowiki>*", NAME="floppy/%n" , SYMLINK="fd%n"<br />
<br />
'''2. Start/stop script'''<br />
<br />
It takes care of devices and starts vmware, also stops vmware and removes dev entries. Call it, for example, <code>mkvmdev</code>, chmod it <code>755</code> and put in <code>/etc/rc.d</code>:<br />
<br />
<pre><br />
#!/bin/sh<br />
<br />
. /etc/rc.conf<br />
. /etc/rc.d/functions<br />
<br />
case "$1" in<br />
start)<br />
stat_busy "Creating /dev entries and starting VMware"<br />
for i in `seq 0 9`; do<br />
mknod /dev/vmnet$i c 119 $i<br />
chmod 0600 /dev/vmnet$i<br />
done<br />
for i in `seq 0 3`; do<br />
mknod /dev/parport$i c 99 $i<br />
chmod 0600 /dev/parport$i<br />
done<br />
mknod /dev/vmmon c 10 165<br />
chmod 0660 /dev/vmmon<br />
/etc/rc.d/vmware start<br />
;;<br />
<br />
stop)<br />
stat_busy "Stopping VMware and removing /dev entries"<br />
/etc/rc.d/vmware stop<br />
rm /dev/vmmon<br />
for i in `seq 0 3`; do<br />
rm /dev/parport$i<br />
done<br />
for i in `seq 0 9`; do<br />
rm /dev/vmnet$i<br />
done<br />
;;<br />
<br />
restart)<br />
$0 stop<br />
$0 start<br />
;;<br />
<br />
*)<br />
echo "usage: $0 {start|stop|restart}"<br />
esac<br />
exit 0<br />
</pre><br />
<br />
'''3. Modify <code>/etc/rc.conf</code>.''' (*Note - this step is optional! See also the notes under the "Running" section above)<br />
<br />
Add <code>mkvmdev</code> to daemons in your <code>rc.conf</code>, and remember to remove <code>vmware</code> from <code>rc.conf</code>. Or if you prefer, you can delete the lines that launch vmware from <code>mkvmdev</code> and leave your original <code>vmware</code> in <code>rc.conf</code> - your choice.<br />
<br />
-----<br />
<br />
'''Comments:'''<br />
<br />
hi guys, a couple of quick questions:<br><br />
- why is /dev/vmmon chmod 0660, as opposed to the rest (0600)?<br><br />
- i suppose /dev/vmmon should be "rm"-ed as well in the "stop" section for the script above? (that line is missing) - FIXED<br />
<br />
== VMware and kernel 2.6.16 compile modules problem ==<br />
'''PROBLEM''': kernel 2.6.16-x - vmware or vmwareplayer complains that headers are incorect.<br><br />
'''FIX''': You need [http://knihovny.cvut.cz/ftp/pub/vmware/vmware-any-any-update101.tar.gz vmware-any-any-update] patch [ftp://ftp.cvut.cz/vmware/vmware-any-any-update101.tar.gz mirror here] [http://www.inarad.ro/soft/vmware/vmware-any-any-update101.tar.gz or here].<br> Just untar the archive and run ./runme.pl as root - and you-re happy again!<br />
<br />
== VMware and kernel 2.6.20 compile modules problem ==<br />
<br />
Below is a solution for compiling the vmware modules on kernel 2.6.20.<br />
<br />
<pre><br />
cd /usr/lib/vmware/modules/source/<br />
sudo tar -xvf vmmon.tar<br />
cd vmmon-only<br />
sudo vi include/compat_kernel.h<br />
<br />
Find this:<br />
<br />
#define __NR_compat_exit __NR_exit<br />
static inline _syscall1(int, compat_exit, int, exit_code);<br />
<br />
and change the static inline ..... line to:<br />
<br />
int compat_exit(int exit_code);<br />
<br />
Then tar up the vmmon-only directory again.<br />
<br />
cd .. #go back to the source directory<br />
tar -cf vmmon.tar vmmon-only<br />
<br />
Finally, run vmware-config.pl<br />
</pre><br />
<br />
== VMware and kernel 2.6.22 compile modules problem ==<br />
May not work properly yet. Apply the patch from http://knihovny.cvut.cz/ftp/pub/vmware/vmware-any-any-update112.tar.gz , replace vmnet.tar with http://npw.net/~phbaer/vmnet.tar and reinstall. Note: this is an '''ugly hack''', please dont put it into production systems. Some guest OS'es may have crashes and networking problems with this. '''Dont tell us that you havent been warned'''<br />
<br />
== VMware and kernel 2.6.24 compile modules problem ==<br />
May not work properly yet. Apply the patch from http://bio.artcradle.com/temp/vault/vmware-any-any-update-116.tgz (untar, run runme.pl script) Note: this is an '''ugly hack''', please don't put it into production systems. Some guest OS'es may have crashes and networking problems with this. '''Don't tell us that you haven't been warned'''<br />
<br />
== VMware and kernel 2.6.25 compile modules problem ==<br />
There are extra steps required for Vmware WKS 6.0.3 build 80004, should be the same for VMware Server<br />
# Install and patch as described (use vmware-any-any-update-116.tgz)<br />
# Download the [http://blog.creonfx.com/temp/vmware-any-any-update-117-very-ALPHA.tgz patch117]vmware-any-any-update-117-very-ALPHA.tgz <br />
# Extract the archive in /usr/lib/vmware/modules/source <br />
# Run vmware-2.6.25.sh and then vmware-config.pl<br />
<br />
== VMware and kernel 2.6.26 compile modules problem ==<br />
If after compiling the modules following the method for 2.6.25 you receive the "Version mismatch with vmmon module:" error when powering on a virtual machine you will need to take one additional step.<br />
<br />
<pre><br />
<br />
cd /usr/lib/vmware/moduels/source/;<br />
sudo tar -xvf vmmon.tar;<br />
sudo vi vmmon-only/include/iocontrols.h;<br />
<br />
<br />
Find the line 48:<br />
<br />
#define VMMON_VERSION (161 << 16 | 0)<br />
<br />
and change to <br />
<br />
#define VMMON_VERSION (167 << 16 | 0)<br />
<br />
Save and exit.<br />
<br />
<br />
sudo tar -cf vmmon.tar vmmon-only;<br />
<br />
Finally, run vmware-config.pl.<br />
<br />
</pre><br />
<br />
== slow networking between host and guest ==<br />
"Those oversized improperly checksummed packets are TCP Segmentation Offload packets. Use ''''ethtool -k eth0 tso off'''' to disable TSO on eth0 (or any other interface which you want to get bridged). At this moment vmnet does not understand TSO, and in addition to that it is silly to use TSO together with bridged networking as vmnet will have to split such packet anyway to pass it to the guest, so splitting will be done anyway, and in addition to it kernel will have to prepare metadata about TCP stream for hardware, so you'll probably get worse performance with TSO enabled than with disabled when you'll have some guest running."<br />
<br />
'''NOTE:''' ''ethtool is on extra packages''<br />
<br />
== Samba issues ==<br />
The guest os under vmware cannot see a samba share running on the linux host. To fix this problem, edit /etc/samba/smb.conf and make some changes under [global]. The following are suggested:<br><br />
workgroup = YOUR_WORKGROUP<br><br />
netbios name = YOUR_SERVER_NAME<br><br />
encrypt passwords = yes<br><br />
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE SO_RCVBUF=8192 SO_SNDBUF=8192<br><br />
interfaces = eth0 vmnet1 vmnet8<br><br />
sysv shm key=/dev/vmnet1<br><br />
bind interfaces only = true<br><br />
<br />
== Connecting Remotely ==<br />
If you setup a server that you would like to connect to remotely, please add the following to <b>/etc/hosts.allow</b>:<br />
<pre>vmware-authd: ALL</pre><br />
This will enable <b>xinetd</b> to allow connections from a remote vmware client.<br><br />
<br><br />
If this condition is not met, you may see in your <b>/var/log/everything.log</b>:<br />
<pre>Feb 4 03:34:12 jeffc xinetd[7232]: libwrap refused connection to vmware-authd (libwrap=vmware-authd) from 192.168.1.1</pre></div>
Cucullus
https://wiki.archlinux.org/index.php?title=VMware_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=55423
VMware (Русский)
2008-12-14T12:54:37Z
<p>Cucullus: поправил чуток</p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
{{translateme}}<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Installing_VMware}}<br />
{{i18n_entry|简体中文|安装VMWare}}<br />
{{i18n_entry|Italiano|Installing_VMware (Italiano)}}<br />
{{i18n_entry|Русский|Установка_VMware (Русский)}}<br />
{{i18n_links_end}}<br />
[http://www.vmware.com/ VMware] устанавливается на [[Arch Linux]] довольно легко, однако установка не всегда предельно ясна.<br />
<br />
==Установка VMware Workstation==<br />
Следующая информация взята из пользовательких комментариев в AUR по VMWare Workstation пользователем whompus. Она описывает как установить VMWare Workstation 6.5.x на одну из архитектур.<br />
<br />
В качестве временной меры можно воспользоваться представленным способом установки 6.5. Заметьте, что pacman '''не''' будет использован в данном случае, так что установку '''нельзя''' будет отследить\удалить, используя pacman.<br />
<br />
Для установки Workstation на Linux действуйте следующим образом:<br />
<br />
1. Скачайте VMware-Workstation-6.5.xxxxxx.bundle. Где xxxxx минорная (с незначительными изменениями) версия программы и архитектура.<br />
<br />
2. В терминале смените текущую дерикторию на ту, в которую загрузили файл.<br />
<br />
3. С правами root выполните начальные шаги установки:<br />
# mkdir -p /etc/rc.d/vmware.d/rc{0,1,2,3,4,5,6}.d<br />
# sh VMware-Workstation-6.5.xxxxxx.bundle --console --custom<br />
<br />
4. Прочитайте и примите EULA для продолжения.<br />
<br />
5. Принимайте стандартные настройки до тех пор, пока не появится запрос "System service runlevels", установите тогда следующее:<br />
/etc/rc.d/vmware.d/<br />
<br />
6. Для System service scripts выставьте:<br />
/etc/rc.d<br />
<br />
7. (Опционально) Введите путь к директории с Integrated Virtual Debugger для Eclipse, если Eclipse установлен.<br />
<br />
8. Жмите "ввод" для установки. Заметка: если ничего не произошло и заново открылось приглашение в консоли, попробуйте запустить установку снова без параметра '--console'.<br />
<br />
9. Откройте Workstation (наберите <code>vmware</code> в консоли) для настройки и использования!<br />
<br />
==Установка VMware Server==<br />
'''Заметка''' Настоятельно рекомендуется использовать VMWare Server 2 на ядре 2.6.27, так как это актуальные сборки. Также они не требуют наложения патча.<br />
<br />
Вы можете использовать [http://aur.archlinux.org/packages.php?do_Details=1&ID=6182&O=0&L=0&C=0&K=vmware&SB=n&SO=a&PP=25&do_MyPackages=0&do_Orphans=0&SeB=nd AUR] или ручную установку [http://www.vmware.com/download/server/ VMware Server] скачанного с [http://www.vmware.com/ VMware.com]. Это руководство покажет как в ручную установить скачанный тарбол с VMware server, предполагается, что вы используете Voodoo или более свежий Arch Linux с версией ядра 2.6.20+ '''32-bit'''.<br />
<br />
===Требования:===<br />
* Root доступ. Одно из двух, 'sudo' или 'su'. В этом руководстве я буду использовать 'sudo'.<br />
* [http://archlinux.org/packages/search/?repo=all&category=all&q=xinetd&lastupdate=&limit=50 Xinetd] установлен и запущен.<br />
* Библиотеки X - libxtst, libxt и libxrender установлены.<br />
* [http://www.vmware.com/download/server/ VMware server tarball]; последний 1.0.4 build 56528 во время написания этих строк.<br />
* <strike>VMware server [http://www.vmware.com/community/thread.jspa?messageID=76957&tstart=0 any-to-any]" patch: [http://platan.vc.cvut.cz/ftp/pub/vmware mirror 1] and [ftp://ftp.cvut.cz/vmware mirror 2]. Note: For server 1.0.4 build 56528 you need patch vmware-any-any-update113.tar.bz2, which is on mirror 1 only.</strike><br />
* UPDATE: Для ядра 2.6.24 вам понадобится этот [http://rtr.ca/vmware-2.6.24/ patch] (vmware-any-any-update115a.tgz)<br />
* UPDATE: Для ядра 2.6.25 вам также понадобится также этот [http://blog.creonfx.com/temp/vmware-any-any-update-117-very-ALPHA.tgz patch] (vmware-any-any-update-117-very-ALPHA)<br />
* Совместимость с VMware Workstation >= 6.0.2 Build 59824 on Linux 2.6.25<br />
* UPDATE: Для ядра 2.6.26 вам понадобится этот [http://vmkernelnewbies.googlegroups.com/web/vmware-any-any-update117d.tar.gz patch] (vmware-any-any-update117d.tar.gz), VMware версии 6.0.5 этот патч не нуже, версия vmmon нужна не младше 169.<br />
* UPDATE: Для ядра 2.6.26 и VMWare 6.5 патчи больше _не_ нужны (6.5.0 build-118166). Графический инсталлятор работает хорошо, а все модули работают "из коробки". Следуйте дальнейшим инструкциям до определения директории, содержащей init-скрипты.<br />
<br />
===Инструкция:===<br />
* Выполните '''''sudo mkdir -p /etc/rc.d/vmware.d/rc{0,1,2,3,4,5,6}.d''''' для создания runlevel-директорий для VMware.<br />
* Выполните '''''sudo ln -s /bin/lsmod /sbin/''''' для создания символической ссылки на lsmod.<br />
* Извлеките тарбол с VMware Server куда угодно, например в /tmp/.<br />
* Выполните '''''cd /tmp/vmware-server-distrib;sudo ./vmware-install.pl'''''. Я использовал для установки '''''/home/vmware/bin'''''.<br />
* При запросе расположения директорий от ''rc0.d'' до ''rc6.d'', используйте '''''/etc/rc.d/vmware.d'''''.<br />
* При запросе директории с init скриптами укажите '''''/etc/rc.d'''''.<br />
* '''*Выйдите*''', когда появится запрос о запуске первоначальной конфигурации VMware.<br />
* Извлеките куда-нибудь VMware Server any-to-any patch... например /tmp/.<br />
* Выполните '''''cd /tmp/vmware-any-any-update*REV*;sudo ./runme.pl'''''. Это наложит заплатку на модули VMware Server, чтобы позволить ядру Linux 2.6.20 скомпилироваться.<br />
* Для ядра 2.6.25 дополнительно к предыдущей заплатке patch115a или 116 вам понадобится вручную установить 117_Alpha.<br />
* Для 2.6.25 Извлеките 117 в каталог '''''tar xzf vmware-any-any-update-117-very-ALPHA.tgz -C /usr/lib/vmware/modules/source/<br />
* Для наложения заплатки на 2.6.25 '''''cd /usr/lib/vmware/modules/source/''''' и запустите '''''./vmware-2.6.25.sh''''' и продолжите выполнять следующие шаги.<br />
* Выполните '''''cd /home/vmware/bin;sudo ./vmware-config.pl''''' для компиляции модулей VMware.<br />
<br />
== Запуск ==<br />
<br />
Возможно, что при первом запуске VMware Server вы получите ошибку, которая начинается примерно так "Unable to power virtual machine". Остановите VMware Server и перезапустите xinetd '''''/etc/rc.d/vmware stop;wait;/etc/rc.d/xinetd restart'''''.<br />
<br />
Выполните '''''sudo /home/vmware/bin/vmware-config.pl''''' снова. Если ошибка не исчезла, перезапустите свой компьютер и повторите последнее действие снова. Все должно исправиться.<br />
<br />
Теперь <code>vmware</code> init-скрипт в <code>/etc/rc.d</code>. Вы можете добавить его в лист демонов, если захотите. Лично я так не сделал, но если вы намереваетесь использовать сеть vmware, не используя сам vmware, вам это понадобится. Вам нужно запустить этот init-скрипт перед запуском VMware.<br />
<br />
Есть проблема, когда vmware не может корректно запуститься после перезагрузки. Для того, чтобы исправить это, отредактируйте <code>/etc/rc.d/vmware</code>, найдите следующий текст<br />
case "$1" in<br />
start)<br />
и вставьте<br />
rm /etc/vmware/not_configured<br />
сразу же после последней строки.<br />
<br />
Чтобы запустить vmware, просто выполните <code>vmware</code> в терминале, или создайте ярлык или строку меню, как пожелаете.<br />
<br />
'''Некоторые замечания:'''<br />
<br />
Оставьте директорию <code>/etc/rc.d/vmware.d</code> там где она есть, потому что она необходима, когда вы выполните <code>vmware-config.pl</code>.<br />
<br />
Помните, если ваше ядро изменилось или обновилось, вам нужно запустить <code>vmware-config.pl</code> снова.<br />
<br />
== Ядро 2.6 и udev ==<br />
<br />
Follow the steps above and then:<br />
<br />
'''1. Modify udev config'''<br />
<br />
Edit <code>/etc/udev/rules.d/00-myrules.rules</code> and add 2 lines:<br />
# tty devices<br />
KERNEL="tty<nowiki>[[0-9]]</nowiki>*", NAME="vc/%n", SYMLINK="%k"<br />
<br />
# floppy devices<br />
KERNEL="fd<nowiki>[[0-9]]</nowiki>*", NAME="floppy/%n" , SYMLINK="fd%n"<br />
<br />
'''2. Start/stop script'''<br />
<br />
It takes care of devices and starts vmware, also stops vmware and removes dev entries. Call it, for example, <code>mkvmdev</code>, chmod it <code>755</code> and put in <code>/etc/rc.d</code>:<br />
<br />
<pre><br />
#!/bin/sh<br />
<br />
. /etc/rc.conf<br />
. /etc/rc.d/functions<br />
<br />
case "$1" in<br />
start)<br />
stat_busy "Creating /dev entries and starting VMware"<br />
for i in `seq 0 9`; do<br />
mknod /dev/vmnet$i c 119 $i<br />
chmod 0600 /dev/vmnet$i<br />
done<br />
for i in `seq 0 3`; do<br />
mknod /dev/parport$i c 99 $i<br />
chmod 0600 /dev/parport$i<br />
done<br />
mknod /dev/vmmon c 10 165<br />
chmod 0660 /dev/vmmon<br />
/etc/rc.d/vmware start<br />
;;<br />
<br />
stop)<br />
stat_busy "Stopping VMware and removing /dev entries"<br />
/etc/rc.d/vmware stop<br />
rm /dev/vmmon<br />
for i in `seq 0 3`; do<br />
rm /dev/parport$i<br />
done<br />
for i in `seq 0 9`; do<br />
rm /dev/vmnet$i<br />
done<br />
;;<br />
<br />
restart)<br />
$0 stop<br />
$0 start<br />
;;<br />
<br />
*)<br />
echo "usage: $0 {start|stop|restart}"<br />
esac<br />
exit 0<br />
</pre><br />
<br />
'''3. Modify <code>/etc/rc.conf</code>.''' (*Note - this step is optional! See also the notes under the "Running" section above)<br />
<br />
Add <code>mkvmdev</code> to daemons in your <code>rc.conf</code>, and remember to remove <code>vmware</code> from <code>rc.conf</code>. Or if you prefer, you can delete the lines that launch vmware from <code>mkvmdev</code> and leave your original <code>vmware</code> in <code>rc.conf</code> - your choice.<br />
<br />
-----<br />
<br />
'''Comments:'''<br />
<br />
hi guys, a couple of quick questions:<br><br />
- why is /dev/vmmon chmod 0660, as opposed to the rest (0600)?<br><br />
- i suppose /dev/vmmon should be "rm"-ed as well in the "stop" section for the script above? (that line is missing) - FIXED<br />
<br />
== VMware and kernel 2.6.16 compile modules problem ==<br />
'''PROBLEM''': kernel 2.6.16-x - vmware or vmwareplayer complains that headers are incorect.<br><br />
'''FIX''': You need [http://knihovny.cvut.cz/ftp/pub/vmware/vmware-any-any-update101.tar.gz vmware-any-any-update] patch [ftp://ftp.cvut.cz/vmware/vmware-any-any-update101.tar.gz mirror here] [http://www.inarad.ro/soft/vmware/vmware-any-any-update101.tar.gz or here].<br> Just untar the archive and run ./runme.pl as root - and you-re happy again!<br />
<br />
== VMware and kernel 2.6.20 compile modules problem ==<br />
<br />
Below is a solution for compiling the vmware modules on kernel 2.6.20.<br />
<br />
<pre><br />
cd /usr/lib/vmware/modules/source/<br />
sudo tar -xvf vmmon.tar<br />
cd vmmon-only<br />
sudo vi include/compat_kernel.h<br />
<br />
Find this:<br />
<br />
#define __NR_compat_exit __NR_exit<br />
static inline _syscall1(int, compat_exit, int, exit_code);<br />
<br />
and change the static inline ..... line to:<br />
<br />
int compat_exit(int exit_code);<br />
<br />
Then tar up the vmmon-only directory again.<br />
<br />
cd .. #go back to the source directory<br />
tar -cf vmmon.tar vmmon-only<br />
<br />
Finally, run vmware-config.pl<br />
</pre><br />
<br />
== VMware and kernel 2.6.22 compile modules problem ==<br />
May not work properly yet. Apply the patch from http://knihovny.cvut.cz/ftp/pub/vmware/vmware-any-any-update112.tar.gz , replace vmnet.tar with http://npw.net/~phbaer/vmnet.tar and reinstall. Note: this is an '''ugly hack''', please dont put it into production systems. Some guest OS'es may have crashes and networking problems with this. '''Dont tell us that you havent been warned'''<br />
<br />
== VMware and kernel 2.6.24 compile modules problem ==<br />
May not work properly yet. Apply the patch from http://bio.artcradle.com/temp/vault/vmware-any-any-update-116.tgz (untar, run runme.pl script) Note: this is an '''ugly hack''', please don't put it into production systems. Some guest OS'es may have crashes and networking problems with this. '''Don't tell us that you haven't been warned'''<br />
<br />
== VMware and kernel 2.6.25 compile modules problem ==<br />
There are extra steps required for Vmware WKS 6.0.3 build 80004, should be the same for VMware Server<br />
# Install and patch as described (use vmware-any-any-update-116.tgz)<br />
# Download the [http://blog.creonfx.com/temp/vmware-any-any-update-117-very-ALPHA.tgz patch117]vmware-any-any-update-117-very-ALPHA.tgz <br />
# Extract the archive in /usr/lib/vmware/modules/source <br />
# Run vmware-2.6.25.sh and then vmware-config.pl<br />
<br />
== VMware and kernel 2.6.26 compile modules problem ==<br />
If after compiling the modules following the method for 2.6.25 you receive the "Version mismatch with vmmon module:" error when powering on a virtual machine you will need to take one additional step.<br />
<br />
<pre><br />
<br />
cd /usr/lib/vmware/moduels/source/;<br />
sudo tar -xvf vmmon.tar;<br />
sudo vi vmmon-only/include/iocontrols.h;<br />
<br />
<br />
Find the line 48:<br />
<br />
#define VMMON_VERSION (161 << 16 | 0)<br />
<br />
and change to <br />
<br />
#define VMMON_VERSION (167 << 16 | 0)<br />
<br />
Save and exit.<br />
<br />
<br />
sudo tar -cf vmmon.tar vmmon-only;<br />
<br />
Finally, run vmware-config.pl.<br />
<br />
</pre><br />
<br />
== slow networking between host and guest ==<br />
"Those oversized improperly checksummed packets are TCP Segmentation Offload packets. Use ''''ethtool -k eth0 tso off'''' to disable TSO on eth0 (or any other interface which you want to get bridged). At this moment vmnet does not understand TSO, and in addition to that it is silly to use TSO together with bridged networking as vmnet will have to split such packet anyway to pass it to the guest, so splitting will be done anyway, and in addition to it kernel will have to prepare metadata about TCP stream for hardware, so you'll probably get worse performance with TSO enabled than with disabled when you'll have some guest running."<br />
<br />
'''NOTE:''' ''ethtool is on extra packages''<br />
<br />
== Samba issues ==<br />
The guest os under vmware cannot see a samba share running on the linux host. To fix this problem, edit /etc/samba/smb.conf and make some changes under [global]. The following are suggested:<br><br />
workgroup = YOUR_WORKGROUP<br><br />
netbios name = YOUR_SERVER_NAME<br><br />
encrypt passwords = yes<br><br />
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE SO_RCVBUF=8192 SO_SNDBUF=8192<br><br />
interfaces = eth0 vmnet1 vmnet8<br><br />
sysv shm key=/dev/vmnet1<br><br />
bind interfaces only = true<br><br />
<br />
== Connecting Remotely ==<br />
If you setup a server that you would like to connect to remotely, please add the following to <b>/etc/hosts.allow</b>:<br />
<pre>vmware-authd: ALL</pre><br />
This will enable <b>xinetd</b> to allow connections from a remote vmware client.<br><br />
<br><br />
If this condition is not met, you may see in your <b>/var/log/everything.log</b>:<br />
<pre>Feb 4 03:34:12 jeffc xinetd[7232]: libwrap refused connection to vmware-authd (libwrap=vmware-authd) from 192.168.1.1</pre></div>
Cucullus
https://wiki.archlinux.org/index.php?title=Network_Time_Protocol_daemon_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=53932
Network Time Protocol daemon (Русский)
2008-11-21T17:59:58Z
<p>Cucullus: </p>
<hr />
<div>[[Category:Сеть]]<br />
[[Category:Демоны и системные службы]]<br />
[[Category:Русские HowTo]]<br />
[[Category:Русский]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|:Network Time Protocol}}<br />
{{i18n_entry|简体中文|:Network Time Protocol (简体中文)}}<br />
{{i18n_entry|Русский|:Network Time Protocol (Русский)}}<br />
{{i18n_links_end}}<br />
{{translateme}}<br />
Эта статья описывает различные возможности по поддержанию точного системного времени и даты вашего Arch Linux. В первую очередь описано лёгкое в использовании решение &mdash; OpenNTPD. Во вторую &mdash; оригинальный ntpd.<br />
<br />
== OpenNTPD ==<br />
<br />
===Использование OpenNTPD вместо ntpd===<br />
<br />
OpenNTPD &mdash; это свободная, простая в использовании реализация протокола NTP. OpenNTPD предоставляет возможность синхронизации локальных часов с удалённым сервером NTP и может сам работать в качестве NTP-сервера, передавая локальное время.<br />
<br />
OpenNTPD в основном разрабатывается Henning Brauer как часть проекта OpenBSD. Он представляет из себя написанную с нуля реализацию протокола NTP и его гораздо проще настраивать и использовать, чем ntpd.<br />
<br />
В первую очередь, необходимо установить пакет <tt>openntpd</tt>. Он доступен в репозитории <tt>community</tt>.<br />
<br />
# pacman -S openntpd<br />
<br />
После установки надо отредактировать файл <tt>/etc/ntpd.conf</tt>. Это совсем несложно.<br />
<br />
Конфигурация по умолчанию вполне пригодна, если всё, что вам нужно &mdash; это синхронизация времени на локальном компьютере.<br />
<pre><br />
# $OpenBSD: ntpd.conf,v 1.7 2004/07/20 17:38:35 henning Exp $<br />
# sample ntpd configuration file, see ntpd.conf(5)<br />
<br />
# Addresses to listen on (ntpd does not listen by default)<br />
#listen on *<br />
#listen on 127.0.0.1<br />
#listen on ::1<br />
<br />
# sync to a single server<br />
#server ntp.example.org<br />
<br />
# use a random selection of 8 public stratum 2 servers<br />
# see http://twiki.ntp.org/bin/view/Servers/NTPPoolServers<br />
servers pool.ntp.org<br />
</pre><br />
<br />
Чтобы синхронизировать время с каким-либо конкретным сервером, раскомментируйте и поправьте директиву <tt>server</tt>.<br />
<br />
server ntp.example.org<br />
<br />
Директива <tt>servers</tt> работает так же, как и <tt>server</tt>, с той разницей, что если доменному имени сервера соответствуют несколько IP-адресов, время будет синхронизировано со всеми из них. Значение по умолчанию, "pool.ntp.org", пригодно в большинстве случаев.<br />
<br />
servers pool.ntp.org<br />
<br />
Также можно воспользоваться пулом российских серверов:<br />
<br />
servers ru.pool.ntp.org<br />
<br />
Допускается использовать любое количество директив <tt>server</tt> и <tt>servers</tt>.<br />
<br />
Если вы хотите, чтобы компьютер, на котором запущен OpenNTPD, также сам являлся NTP-сервером, просто раскомментируйте и поправьте директиву <tt>listen</tt>.<br />
<br />
Например:<br />
listen on *<br />
будет слушать порт на всех сетевых интерфейсах, а<br />
listen on 127.0.0.1<br />
будет слушать только на кольцевом интерфейсе.<br />
<br />
Если вы хотите, чтобы OpenNTPD запускался при старте системы, добавьте <tt>openntpd</tt> в массив DAEMONS вашего <tt>/etc/rc.conf</tt>.<br />
<br />
Посмотреть состояние синхронизации можно в файле <tt>/var/log/daemon.log</tt>.<br />
<br />
=== Устранение неполадок ===<br />
Если вы видите, что время вашего компьютера установлено неправильно и в логе присутствует строка<br />
openntpd adjtime failed: Invalid argument<br />
тогда попробуйте набрать <tt>ntpd -s -d</tt> в консоли.<br />
<br />
== ntp ==<br />
===Installation===<br />
# pacman -S ntp<br />
<br />
===/etc/ntp.conf Configuration===<br />
The very first line of your ntp.conf file should contain a line such as the following:<br />
restrict default noquery notrust nomodify<br />
<br />
This essentially restricts everyone from modifying anything. Following this, you need to let ntpd know what you want to let through into your NTP server. Here is where you would specify any other ip addresses you would like to synchronize on your NTP server. For example:<br />
restrict 1.2.3.4<br />
restrict 192.168.0.0 mask 255.255.255.0 nomodify<br />
<br />
This tells ntpd that 1.2.3.4 and all ip addresses from the 192.168.0.0 range will be allowed to synchronize on this server, but they will not be allowed to modify anything. All other IP addresses in the world will still obey the default restrictions (the first line in the ntp.conf).<br />
<br />
Now, is where the stratum 2 servers that our server will synchronize with come into play. The lines in ntp.conf will be used to tell ntpd what servers we would like to use for synchronizing (these are just examples; use ntp servers that are closest to your location). Please see http://ntp.isc.org/bin/view/Servers/NTPPoolServers for a list a closer servers.<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
Unless you have a good reason not to, it is advisable to use the pool.ntp.org servers: http://www.pool.ntp.org/.<br />
Alternatively, a list of ntp servers is available at http://www.eecis.udel.edu/~mills/ntp/clock2a.html. Please pay attention to the Access Policies. <br />
<br />
If we left it alone right now, we would never connect to a server because the response from any of the three servers listed above would never be allowed back into our server due to the fact that our default restrict statement would be in use (since we did not add the servers to our lesser restrictions (like we did with 127.0.0.1 and the subnet of 192.168.0.0).<br />
<br />
To correct this, enter the following lines in ntp.conf:<br />
restrict ntp1.cs.wisc.edu noquery nomodify<br />
restrict ntp3.cs.wisc.edu noquery nomodify<br />
restrict ntp3.sf-bay.org noquery nomodify<br />
<br />
This will allow the response from the above servers into our system so our local clock can be synchronized. The noquery restriction will not allow any of the above three servers to query for information from our server. The nomodify restriction will not allow the three servers to modify anything (synchronization will still take place).<br />
<br />
The only thing left to do is add the drift file (which keeps track of yours clocks time deviation). and the log file location:<br />
driftfile /etc/ntp.drift<br />
logfile /var/log/ntp.log<br />
<br />
The complete file will look like this:<br />
<br />
<pre><br />
# default restrictions<br />
restrict default noquery notrust nomodify<br />
<br />
# override the default restrictions here<br />
restrict 10.1.1.0 mask 255.255.255.0 nomodify<br />
<br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
restrict ntp1.cs.wisc.edu noquery nomodify<br />
restrict ntp3.cs.wisc.edu noquery nomodify<br />
restrict ntp3.sf-bay.org noquery nomodify<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
# time deviation<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
</pre><br />
<br />
Take note that this is for a client and a server ntp.conf configuration. If you just want to synchronize with a stratum server and are not concerned with other PCs synchronizing with your ntp server, then you can do something like the following (note that only 127.0.0.1 is allowed to be synchronized):<br />
<br />
<pre><br />
# default restrictions<br />
restrict default noquery notrust nomodify<br />
<br />
# Permit all access over the loopback interface<br />
restrict 127.0.0.1<br />
<br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
restrict ntp1.cs.wisc.edu noquery nomodify<br />
restrict ntp3.cs.wisc.edu noquery nomodify<br />
restrict ntp3.sf-bay.org noquery nomodify<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
# time deviation<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
</pre><br />
<br />
... or if you don't care about restrictions at all, something like this (note there are no restrictions, thus no need to reduce restrictions for 127.0.0.1 to allow your local clock to synchronize):<br />
<br />
<pre><br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
# time deviation<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
</pre><br />
<br />
===A Note about Security===<br />
You may wonder about all of the restrict lines. The reason for them is security. If you don't want a secure NTP server, don't add any restrict lines to your ntp.conf file. If you want a secure NTP server, start out by adding a default restrict that doesn't allow anything to contact your server, then add more (less restrictive) restrict lines - allowing certain addresses various access privileges.<br />
<br />
===/etc/rc.d/network file modification===<br />
One more thing that you may want to do. In some cases, your /etc/ntp.conf file may be overwritten by dhcp. To avoid this, edit the /etc/conf.d/dhcpcd file and add <code>-N</code> to the line that starts with '<code>dhcpcd -t 10</code>'.<br />
<br />
'''Note:''' This was my experience/solution with setting the time:<br />
<br />
On my system my /etc/conf.d/dhcpcd contains a single line:<br />
DHCPCD_ARGS="-t 30 -h $HOSTNAME"<br />
<br />
I assume it needs to be changed to:<br />
DHCPCD_ARGS="-N -t 30 -h $HOSTNAME"<br />
<br />
Some have suggested adding <code>-R</code> to preserve /etc/resolv.conf as well.<br />
<br />
===To fix Time use /etc/rc.local===<br />
To set the correct time; Set time and start ntpd at boot via /etc/rc.local<br />
<br />
Relevant sections of /etc/rc.conf<br />
HARDWARECLOCK="UTC"<br />
TIMEZONE="US/Mountain"<br />
<br />
''Network/DHCP section:''<br />
lo="lo 127.0.0.1"<br />
eth0="dhcp"<br />
INTERFACES=(lo eth0)<br />
''Daemons subsection:''<br />
DAEMONS=(syslog-ng hotplug !pcmcia network netfs !ntpd crond dbus hal alsa gdm)<br />
<br />
This is my /etc/rc.local<br />
#!/bin/bash<br />
#<br />
# /etc/rc.local: Local multi-user startup script.<br />
#<br />
<br />
# Re-copy ntp.conf (was over written by dhcp)<br />
cp /root/CONFIG.BAK/ntp.conf.bac /etc/ntp.conf<br />
# I advise you keep your desired /etc/ntp.conf<br />
# OUTSIDE of /etc<br />
<br />
# Set time<br />
/usr/bin/ntpdate ntp.nasa.gov #Use any time server you like here<br />
<br />
# Start ntpd<br />
/etc/rc.d/ntpd start<br />
<br />
And here is my /root/CONFIG.BAK/ntp.conf.bac (this is just a copy of the desired /etc/ntp.conf)<br />
# default restrictions<br />
restrict default noquery notrust nomodify<br />
<br />
# override the default restrictions here<br />
restrict 127.0.0.1 nomodify<br />
restrict 192.168.2.0 mask 255.255.255.0 nomodify<br />
<br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp.nasa.gov #Use any time server you like here<br />
<br />
restrict ntp.nasa.gov noquery nomodify<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
<br />
Leave /etc/conf.d/dhcpcd at default. Mine is a single line and reads<br />
DHCPCD_ARGS="-t 30 -h $HOSTNAME"<br />
<br />
With this configuration I get the correct time and ntpd running at boot.<br />
There may be a better way, but this worked for me.<br />
I hope it helps.<br />
<br />
===Updating your system immediately using ntpdate===<br />
It is recommended to add a line like the following to your /etc/rc.local file so when you boot your system, your time will be correct (use an NTP server close to your location).<br />
/usr/bin/ntpdate ntp1.cs.wisc.edu<br />
<br />
Running ''ntpdate'' when you boot up is a good idea because ntpd may take a long time to synchronize your local clock depending on how far off the time is. If your clock is synchronized when ntpd starts, then it's sole purpose is to keep it synchronized. To run ntpd at startup, add ''ntpd'' to the daemons section of the /etc/rc.conf file.<br />
<br />
ntpd will work well if you have a connection to the internet all the time. If you are using dialup, you may just want to stick with using ntpdate via the command line.<br />
<br />
===Querying your NTP server using ntpq===<br />
There is a default restrict statement for the localhost that includes an ignore flag. Without overriding it (adding the line ''restrict'' ''127.0.0.1'') you will not be able to query your NTP server. If that's not a concern to you, then leave out the restrict line for your localhost. You will still be able to synchronize with your stratum 2 servers.<br />
<br />
== External Resources ==<br />
* http://www.ntp.org/<br />
* http://twiki.ntp.org/bin/view/Main/WebHome<br />
* http://www.eecis.udel.edu/~mills/ntp/html/index.html<br />
* http://www.openntpd.org</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Network_Time_Protocol_daemon_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=53931
Network Time Protocol daemon (Русский)
2008-11-21T17:58:35Z
<p>Cucullus: </p>
<hr />
<div>[[Category:Networking (English)]]<br />
[[Category:Демоны и системные службы]]<br />
[[Category:Русские HowTo]]<br />
[[Category:Русский]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|:Network Time Protocol}}<br />
{{i18n_entry|简体中文|:Network Time Protocol (简体中文)}}<br />
{{i18n_entry|Русский|:Network Time Protocol (Русский)}}<br />
{{i18n_links_end}}<br />
{{translateme}}<br />
Эта статья описывает различные возможности по поддержанию точного системного времени и даты вашего Arch Linux. В первую очередь описано лёгкое в использовании решение &mdash; OpenNTPD. Во вторую &mdash; оригинальный ntpd.<br />
<br />
== OpenNTPD ==<br />
<br />
===Использование OpenNTPD вместо ntpd===<br />
<br />
OpenNTPD &mdash; это свободная, простая в использовании реализация протокола NTP. OpenNTPD предоставляет возможность синхронизации локальных часов с удалённым сервером NTP и может сам работать в качестве NTP-сервера, передавая локальное время.<br />
<br />
OpenNTPD в основном разрабатывается Henning Brauer как часть проекта OpenBSD. Он представляет из себя написанную с нуля реализацию протокола NTP и его гораздо проще настраивать и использовать, чем ntpd.<br />
<br />
В первую очередь, необходимо установить пакет <tt>openntpd</tt>. Он доступен в репозитории <tt>community</tt>.<br />
<br />
# pacman -S openntpd<br />
<br />
После установки надо отредактировать файл <tt>/etc/ntpd.conf</tt>. Это совсем несложно.<br />
<br />
Конфигурация по умолчанию вполне пригодна, если всё, что вам нужно &mdash; это синхронизация времени на локальном компьютере.<br />
<pre><br />
# $OpenBSD: ntpd.conf,v 1.7 2004/07/20 17:38:35 henning Exp $<br />
# sample ntpd configuration file, see ntpd.conf(5)<br />
<br />
# Addresses to listen on (ntpd does not listen by default)<br />
#listen on *<br />
#listen on 127.0.0.1<br />
#listen on ::1<br />
<br />
# sync to a single server<br />
#server ntp.example.org<br />
<br />
# use a random selection of 8 public stratum 2 servers<br />
# see http://twiki.ntp.org/bin/view/Servers/NTPPoolServers<br />
servers pool.ntp.org<br />
</pre><br />
<br />
Чтобы синхронизировать время с каким-либо конкретным сервером, раскомментируйте и поправьте директиву <tt>server</tt>.<br />
<br />
server ntp.example.org<br />
<br />
Директива <tt>servers</tt> работает так же, как и <tt>server</tt>, с той разницей, что если доменному имени сервера соответствуют несколько IP-адресов, время будет синхронизировано со всеми из них. Значение по умолчанию, "pool.ntp.org", пригодно в большинстве случаев.<br />
<br />
servers pool.ntp.org<br />
<br />
Также можно воспользоваться пулом российских серверов:<br />
<br />
servers ru.pool.ntp.org<br />
<br />
Допускается использовать любое количество директив <tt>server</tt> и <tt>servers</tt>.<br />
<br />
Если вы хотите, чтобы компьютер, на котором запущен OpenNTPD, также сам являлся NTP-сервером, просто раскомментируйте и поправьте директиву <tt>listen</tt>.<br />
<br />
Например:<br />
listen on *<br />
будет слушать порт на всех сетевых интерфейсах, а<br />
listen on 127.0.0.1<br />
будет слушать только на кольцевом интерфейсе.<br />
<br />
Если вы хотите, чтобы OpenNTPD запускался при старте системы, добавьте <tt>openntpd</tt> в массив DAEMONS вашего <tt>/etc/rc.conf</tt>.<br />
<br />
Посмотреть состояние синхронизации можно в файле <tt>/var/log/daemon.log</tt>.<br />
<br />
=== Устранение неполадок ===<br />
Если вы видите, что время вашего компьютера установлено неправильно и в логе присутствует строка<br />
openntpd adjtime failed: Invalid argument<br />
тогда попробуйте набрать <tt>ntpd -s -d</tt> в консоли.<br />
<br />
== ntp ==<br />
===Installation===<br />
# pacman -S ntp<br />
<br />
===/etc/ntp.conf Configuration===<br />
The very first line of your ntp.conf file should contain a line such as the following:<br />
restrict default noquery notrust nomodify<br />
<br />
This essentially restricts everyone from modifying anything. Following this, you need to let ntpd know what you want to let through into your NTP server. Here is where you would specify any other ip addresses you would like to synchronize on your NTP server. For example:<br />
restrict 1.2.3.4<br />
restrict 192.168.0.0 mask 255.255.255.0 nomodify<br />
<br />
This tells ntpd that 1.2.3.4 and all ip addresses from the 192.168.0.0 range will be allowed to synchronize on this server, but they will not be allowed to modify anything. All other IP addresses in the world will still obey the default restrictions (the first line in the ntp.conf).<br />
<br />
Now, is where the stratum 2 servers that our server will synchronize with come into play. The lines in ntp.conf will be used to tell ntpd what servers we would like to use for synchronizing (these are just examples; use ntp servers that are closest to your location). Please see http://ntp.isc.org/bin/view/Servers/NTPPoolServers for a list a closer servers.<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
Unless you have a good reason not to, it is advisable to use the pool.ntp.org servers: http://www.pool.ntp.org/.<br />
Alternatively, a list of ntp servers is available at http://www.eecis.udel.edu/~mills/ntp/clock2a.html. Please pay attention to the Access Policies. <br />
<br />
If we left it alone right now, we would never connect to a server because the response from any of the three servers listed above would never be allowed back into our server due to the fact that our default restrict statement would be in use (since we did not add the servers to our lesser restrictions (like we did with 127.0.0.1 and the subnet of 192.168.0.0).<br />
<br />
To correct this, enter the following lines in ntp.conf:<br />
restrict ntp1.cs.wisc.edu noquery nomodify<br />
restrict ntp3.cs.wisc.edu noquery nomodify<br />
restrict ntp3.sf-bay.org noquery nomodify<br />
<br />
This will allow the response from the above servers into our system so our local clock can be synchronized. The noquery restriction will not allow any of the above three servers to query for information from our server. The nomodify restriction will not allow the three servers to modify anything (synchronization will still take place).<br />
<br />
The only thing left to do is add the drift file (which keeps track of yours clocks time deviation). and the log file location:<br />
driftfile /etc/ntp.drift<br />
logfile /var/log/ntp.log<br />
<br />
The complete file will look like this:<br />
<br />
<pre><br />
# default restrictions<br />
restrict default noquery notrust nomodify<br />
<br />
# override the default restrictions here<br />
restrict 10.1.1.0 mask 255.255.255.0 nomodify<br />
<br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
restrict ntp1.cs.wisc.edu noquery nomodify<br />
restrict ntp3.cs.wisc.edu noquery nomodify<br />
restrict ntp3.sf-bay.org noquery nomodify<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
# time deviation<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
</pre><br />
<br />
Take note that this is for a client and a server ntp.conf configuration. If you just want to synchronize with a stratum server and are not concerned with other PCs synchronizing with your ntp server, then you can do something like the following (note that only 127.0.0.1 is allowed to be synchronized):<br />
<br />
<pre><br />
# default restrictions<br />
restrict default noquery notrust nomodify<br />
<br />
# Permit all access over the loopback interface<br />
restrict 127.0.0.1<br />
<br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
restrict ntp1.cs.wisc.edu noquery nomodify<br />
restrict ntp3.cs.wisc.edu noquery nomodify<br />
restrict ntp3.sf-bay.org noquery nomodify<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
# time deviation<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
</pre><br />
<br />
... or if you don't care about restrictions at all, something like this (note there are no restrictions, thus no need to reduce restrictions for 127.0.0.1 to allow your local clock to synchronize):<br />
<br />
<pre><br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp1.cs.wisc.edu<br />
server ntp3.cs.wisc.edu<br />
server ntp3.sf-bay.org<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
# time deviation<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
</pre><br />
<br />
===A Note about Security===<br />
You may wonder about all of the restrict lines. The reason for them is security. If you don't want a secure NTP server, don't add any restrict lines to your ntp.conf file. If you want a secure NTP server, start out by adding a default restrict that doesn't allow anything to contact your server, then add more (less restrictive) restrict lines - allowing certain addresses various access privileges.<br />
<br />
===/etc/rc.d/network file modification===<br />
One more thing that you may want to do. In some cases, your /etc/ntp.conf file may be overwritten by dhcp. To avoid this, edit the /etc/conf.d/dhcpcd file and add <code>-N</code> to the line that starts with '<code>dhcpcd -t 10</code>'.<br />
<br />
'''Note:''' This was my experience/solution with setting the time:<br />
<br />
On my system my /etc/conf.d/dhcpcd contains a single line:<br />
DHCPCD_ARGS="-t 30 -h $HOSTNAME"<br />
<br />
I assume it needs to be changed to:<br />
DHCPCD_ARGS="-N -t 30 -h $HOSTNAME"<br />
<br />
Some have suggested adding <code>-R</code> to preserve /etc/resolv.conf as well.<br />
<br />
===To fix Time use /etc/rc.local===<br />
To set the correct time; Set time and start ntpd at boot via /etc/rc.local<br />
<br />
Relevant sections of /etc/rc.conf<br />
HARDWARECLOCK="UTC"<br />
TIMEZONE="US/Mountain"<br />
<br />
''Network/DHCP section:''<br />
lo="lo 127.0.0.1"<br />
eth0="dhcp"<br />
INTERFACES=(lo eth0)<br />
''Daemons subsection:''<br />
DAEMONS=(syslog-ng hotplug !pcmcia network netfs !ntpd crond dbus hal alsa gdm)<br />
<br />
This is my /etc/rc.local<br />
#!/bin/bash<br />
#<br />
# /etc/rc.local: Local multi-user startup script.<br />
#<br />
<br />
# Re-copy ntp.conf (was over written by dhcp)<br />
cp /root/CONFIG.BAK/ntp.conf.bac /etc/ntp.conf<br />
# I advise you keep your desired /etc/ntp.conf<br />
# OUTSIDE of /etc<br />
<br />
# Set time<br />
/usr/bin/ntpdate ntp.nasa.gov #Use any time server you like here<br />
<br />
# Start ntpd<br />
/etc/rc.d/ntpd start<br />
<br />
And here is my /root/CONFIG.BAK/ntp.conf.bac (this is just a copy of the desired /etc/ntp.conf)<br />
# default restrictions<br />
restrict default noquery notrust nomodify<br />
<br />
# override the default restrictions here<br />
restrict 127.0.0.1 nomodify<br />
restrict 192.168.2.0 mask 255.255.255.0 nomodify<br />
<br />
# public NTP servers to sync with (all stratum 2)<br />
server ntp.nasa.gov #Use any time server you like here<br />
<br />
restrict ntp.nasa.gov noquery nomodify<br />
<br />
# NTP drift file - used to keep track of your system clocks<br />
driftfile /etc/ntp.drift<br />
<br />
# NTP log file<br />
logfile /var/log/ntp.log<br />
<br />
Leave /etc/conf.d/dhcpcd at default. Mine is a single line and reads<br />
DHCPCD_ARGS="-t 30 -h $HOSTNAME"<br />
<br />
With this configuration I get the correct time and ntpd running at boot.<br />
There may be a better way, but this worked for me.<br />
I hope it helps.<br />
<br />
===Updating your system immediately using ntpdate===<br />
It is recommended to add a line like the following to your /etc/rc.local file so when you boot your system, your time will be correct (use an NTP server close to your location).<br />
/usr/bin/ntpdate ntp1.cs.wisc.edu<br />
<br />
Running ''ntpdate'' when you boot up is a good idea because ntpd may take a long time to synchronize your local clock depending on how far off the time is. If your clock is synchronized when ntpd starts, then it's sole purpose is to keep it synchronized. To run ntpd at startup, add ''ntpd'' to the daemons section of the /etc/rc.conf file.<br />
<br />
ntpd will work well if you have a connection to the internet all the time. If you are using dialup, you may just want to stick with using ntpdate via the command line.<br />
<br />
===Querying your NTP server using ntpq===<br />
There is a default restrict statement for the localhost that includes an ignore flag. Without overriding it (adding the line ''restrict'' ''127.0.0.1'') you will not be able to query your NTP server. If that's not a concern to you, then leave out the restrict line for your localhost. You will still be able to synchronize with your stratum 2 servers.<br />
<br />
== External Resources ==<br />
* http://www.ntp.org/<br />
* http://twiki.ntp.org/bin/view/Main/WebHome<br />
* http://www.eecis.udel.edu/~mills/ntp/html/index.html<br />
* http://www.openntpd.org</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Beginners%27_guide_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=53746
Beginners' guide (Русский)
2008-11-17T14:01:12Z
<p>Cucullus: /* /etc/resolv.conf (для статического IP) */ алё! думаем головой, когда переводим!</p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
{{Box Note |'''По возможности, пользуйтесь английской версией этого документа, т.к. именно она обновляется в первую очередь, содержит все последние изменения и самую актуальную на данный момент информацию.'''}}<br />
{{Box Note|'''Уважаемые переводчики, прежде чем переводить какой-либо раздел, сравните его с английской версией ибо информация в нём могла устареть'''}}<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|Dansk_Begynderguide}}<br />
{{i18n_entry|简体中文|Beginners Guide 新手指南}}<br />
{{i18n_entry|Deutsch|Beginners Guide (Deutsch)}}<br />
{{i18n_entry|English|Beginners Guide}}<br />
{{i18n_entry|Español|Guía para Principiantes (Español)}}<br />
{{i18n_entry|Česky|Průvodce začátečníka (Česky)}}<br />
{{i18n_entry|Italiano|Beginners Guide (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Pradedančiųjų gidas (Lietuviškai)}}<br />
{{i18n_entry|Português Brasil|Guia do Iniciante(Português do Brasil)}}<br />
{{i18n_entry|Русский|Руководство для новичков}}<br />
{{i18n_links_end}}<br />
<br />
=====Всё, что вы хотели знать об установке Arch, но боялись спросить=====<br />
Добро пожаловать. Этот документ проведёт вас через процесс установки и настройки [[ArchLinux|Arch Linux]]; простого, быстрого и лёгкого GNU/Linux дистрибутива, <code>UNIX</code>-подобной операционной системы. Это больше, чем установочное руководство; Arch Linux требует определённого уровня глубоких знаний о его конфигурации, а так же методологии системы GNU/Linux и по этой причине, на этом пути содержится много дополнительной пояснительной информации. Он направлен на новых пользователей Arch, но стремится выступать как сильная справочная и информационная база для всех. Хоть это руководство предназначено для того, чтобы показать как получить полностью сконфигурированную систему Arch Linux (графическое окружени рабочего стола, возможность просмотра DVD, использования Интернет, работа с электронной почтой и прослушивания музыки), невозможно показать (или даже предположить) все возможности и варианты. По замыслу авторов, это руководство должно сфокусироваться на крайне полезных шагах; возможно вы захотите получить глубокие знания используя [[Main Page|Arch Linux Wiki]] или [http://bbs.archlinux.org/ Arch Linux Forums]. Вы также можете быть заинтересованы в чтении статьи [[Путь Arch]], в которой изложены основные принципы дистрибутива Arch Linux.<br />
<br />
Так как Arch Linux и все <code>UNIX</code>-подобные операционные системы являются в своей основе 'модульными', статья логически разбита на три основных части:<br />
<br />
'''[[#Часть 1: Установка базовой системы|Часть 1: Установка базовой системы]]'''<br />
<br />
'''[[#Часть 2: Установка X и установка ALSA|Часть 2: Установка X и установка ALSA]]'''<br />
<br />
'''[[#Часть 3: Установка и настройка окружения рабочего стола|Часть 3: Установка и настройка окружения рабочего стола]]'''<br />
<br />
=====DON'T PANIC!=====<br />
Имейте в виду, что процедура установки Arch Linux может сильно отличаться от установки других GNU/Linux дистрибутивов и вы можете запутаться, особенно, если вы новичок. Обычно, GNU/Linux дистрибутивы распространяются вместе с большим набором софта на CD (или даже DVD), включающим стандартное Рабочее Окружение(DE), стандартный набор программ и установок, автонастройщик оборудования и графический установщик, все что выбрано за вас. Для различия, система Arch Linux создаётся '''пользователем''', из установщика с псевдографикой и базовой системы в которой нет ничего кроме bash и простых консольных программ. Это — '''[[Путь Arch]].''' В отличие от большинства других дистрибутивов с жёсткой структурой, здесь нет ни стандартного окружения, ни конфигурации сделанной за пользователя. Попросту говоря, Arch ждет вашего вклада. Из командной строки, ''вы'' можете установить необходимые пакеты из репозитория используя [[pacman]] и ''вручную'' настроить вашу систему под ''свои'' потребности, до того как это сделает кто-то другой. Этот метод дает вам максимум гибкости, выбора и контроля за вашей системой. Потому что когда '''вы''' настраиваете систему, вы всегда знаете все "гайки и болты" вашей системы и вам знакомо то, что находится "под капотом". <br />
<br />
Arch Linux настраивается редактированием текстовых файлов. Из-за этого не требуются графические инструменты для настройки. <br />
Также запомните, что Arch Linux направлен на опытных пользователей GNU/Linux, на тех кто хочет минимального 'разделения' оборудования и софта, на тех пользователей, которые могут тратить своё время на чтение манов о своей системе.<br />
<br />
''Arch — это инструмент созданный пользователем.''<br />
<br />
=====[[Путь Arch]]=====<br />
<br />
'''''Принципы разработки Arch Linux направлены на сохранение [[Путь Arch|простоты]].'' '''<br />
<br />
Стоит учитывать, что 'простота' не означает 'легкость' или 'дружелюбие' в данном контексте. Но подразумевает 'отсутствие лишних сущностей, модификаций или надуманной сложности' и стремление к элегантному и минималистичному окружению.<br />
<br />
''"Простота подразумевается не с позиции конечного использования, а с технической точки зрения. Лучше стремиться к технической элегантности, нежели быть простым в использовании, но мусором с технической точки зрения." -Aaron Griffin''<br />
<br />
''"Значимая часть [моего метода] подразумевает простоту..Я всегда верил в то, что простой путь - правильный путь."'' - Bruce Lee<br />
<br />
Принцип "Бритвы Оккама": ''Entia non sunt multiplicanda praeter necessitatem'' или "Не следует множить сущности без необходимости." "Бритва" в данном случае означает отбрасывание, вырезание из предмета лишних усложнений и домыслов для того, чтобы добиться наиболее простого объяснения, метода или теории.<br />
<br />
{{Box Note |'''Для успешной установки и правильной настройки дистрибутива необходимо в точности выполнять приведённые инструкции. ''Пожалуйста'', читайте их внимательно.'''}}<br />
* Вы можете распечатать данную статью, она уместится примерно на 58 страницах, которые послужат полезным руководством использования Arch Linux.<br />
* ''Если вы хотите добавить что-то в данную инструкцию, пожалуйста, указывайте не только "Как" что-либо делать, но и "Зачем" именно может понадобиться это делать.''<br />
* Arch Wiki поможет вам разобраться с возникающими проблемами, ответы на которые сначала стоит поискать на [http://wiki.archlinux.org/index.php/Main_Page_(Русский) главной странице]. Также вам доступны каналы IRC и [http://bbs.archlinux.org/ форум].<br />
----<br />
Добро пожаловать в Arch Linux! Давайте приступим.<br />
<br />
==Часть 1: Установка базовой системы==<br />
===Скачайте самый последний установочный образ ===<br />
<br />
Вы можете получить самый последний образ Arch Linux'а [http://archlinux.org/download/ здесь.]<br />
<br />
*Core-iso и FTP-downloads включают в себя только самые необходимые пакеты для создания '''базовой системы Arch Linux'''. ''Нужно заметить что в Базовую Систему не включен GUI. Сюда главным образом входит GNU инструментарий, (компилятор, ассемблер, линковщик, библиотеки и немного полезных утилит) ядро Linux, и немного дополнительных библиотек и модулей.'' Остальное в Arch Linux, включая GUI, может быть установлено из консоли, ''пользователем'', используя менеджер пакетов - pacman для загрузки и установки i686/x86-64 бинарных пакетов. Процесс описывается в деталях ниже.<br />
<br />
Запишите образ системы на CD. <br />
{{Box Note| При записи не используйте скорость больше чем 8x - это рекомендованная скорость для надёжной записи, также некоторые пользователи рекомендуют устанавливать очень низкую скорость '''''4x или 2x!''''' Если вам встретились неожиданные проблемы с установкой, попытайтесь записать образ с самой низкой скоростью поддерживаемой вашей системой.}}<br />
<br />
===Загрузка с Arch Linux CD===<br />
Вы должны следовать этим инструкциям, но также вы можете найти весьма полезным [[Руководство_по_установке|Официальное руководство по установке Arch Linux]]. <br />
Вставьте CD в ваш CD-ROM и загрузитесь с CD. Если ваш компьютер по умолчанию загружается не с CD, вы можете исправить это <br />
изменив порядок загрузки в биосе (чтобы войти в биос используйте клавиши DEL, F1, F2, F11 или F12 при запуске компьютера (в зависимости от типа биоса)).<br />
<br />
Полезные опции загрузки:<br />
* '''ide-legacy''' если у вас возникают проблемы с IDE приводами<br />
* '''noapic acpi=off pci=routeirq nosmp''' если ваша система зависает при загрузке системы<br />
* '''acpi=nommconf''' если у вас возникают "задержки" после загрузки pci:mmconfig <br />
* '''memtest86+''' если вы хотите проверить вашу оперативную память на ошибки<br />
* '''lowmem''' полезно для старых компьютеров с ограниченным объёмом оперативной памяти<br />
<br />
Требования к памяти:<br />
* CORE ISO: lowmem-загрузка образа - 64 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* CORE ISO: обычная загрузка образа - 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* FTP ISO : 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
<br />
Выберите "Arch Linux Installation / Rescue System". Если вы нуждаетесь в изменениях опций загрузки, нажмите "e" для редактирования конфигурации загрузки.<br />
Система будет загружена и вам будет представлено сообщение приветствия с некоторыми пояснениями.<br />
<br />
===Вход в систему и изменение раскладки===<br />
Войдите в систему как 'root'. Если ваша клавиатура не имеет американскую раскладку, выполните в командной строке следующее:<br />
{{Box Note| Скорее всего, у вас клавиатура с "американской" раскладкой (если ваша клавиатура приобретена в России)}}<br />
loadkeys <ваша раскладка><br />
<br />
===Запуск установки===<br />
Введите<br />
/arch/setup <br />
чтобы начать установку Arch Linux. <br />
<br />
<br />
====Выбор источника установки====<br />
После экрана приветствия вам будет предложено выбрать источник установки. Выберите CD, если хотите использовать диск. Или выберите FTP, если хотите использовать образ из FTP. <br />
* В первом случае, переходите к чтению главы о [[#Подготовка жёсткого диска|Подготовке жесткого диска]].<br />
* Во втором случае, вам будет предложено загрузить драйвер для сетевой карты вручную. Но, как правило, Udev автоматически вполне успешно определяет комплектующие - вы можете проверить это выполнив "ifconfig -a" из vc2. Для продолжения установки нажмите "OK".<br />
<br />
====FTP: Настройка Сети====<br />
Вам будут показаны доступные интерфейсы. Если нужный интерфейс присутствует в списке - значит он определился правильно. В обратном случае, вы можете попробовать определить его прямо из установщика или из другой виртуальной консоли (vc).<br />
<br />
Далее выберите нужный интерфейс и продолжайте установку.<br />
<br />
Затем вам будет предложено использовать DHCP для автоматического получения сетевых настроек. В случае отказа, вам будет предложено вручную ввести ваш статический IP-адрес, маску подсети, адрес шлюза и т.д. И, наконец, вы сможете пересмотреть проделанные настройки и удостовериться в их правильности.<br />
<br />
Переходите к чтению о [[#Подготовка жёсткого диска|Подготовке жёсткого диска]].<br />
<br />
====Подготовка жёсткого диска====<br />
Выберите первый пункт меню - "Prepare Hard Drive". Вам будет предложено автоматически подготовить ваш жёсткий диск к установке Arch Linux, либо вручную переразбить и подготовить разделы.<br />
* 1. Автоматическая подготовка<br />
Установщик сам разобъёт ваш жесткий диск на следующие разделы:<br />
* Загрузочный раздел /boot c файловой системой ext2 и размером по умолчанию в 32 мегабайта. Вы сможете изменить это значение. <br />
* Раздел подкачки swap с размером по умолчанию в 256 мегабайтов. Вы также сможете изменить это значение.<br />
* Отдельные разделы для корня / и домашней директории пользователей /home. Размеры вы определяете сами. Также вам будет предоставлен выбор из файловых систем: ext2, ext3, reiserfs, xfs и jfs. Но следует учесть, что оба этих раздела должны быть отформатированы в одинаковой файловой системе.<br />
<br />
Не забывайте - автоматическая подготовка сотрёт все данные на вашем жёстком диске! Внимательно читайте предупреждение установщика.<br />
<br />
* 2. '''(Рекомендуется)''' Ручная подготовка<br />
<br />
Выберите из списка жёсткий диск, на который будет произведена установка (/dev/sd''x'').<br />
<br />
''На этом этапе более опытные пользователи могут сразу перейти к главе о '''[[#Выбор Пакетов|выборе пакетов]]'''.''<br />
<br />
=====Информация о разбивке=====<br />
Разбивка жёсткого диска заключается в создании отдельных зон (разделов) на жёстком диске. Они будут выглядеть как отдельные диски со своими файловыми системами. Разделы подразделяются на "Основные" (Primary), "Расширенные" (Extended) и "Логические" (Logical).<br />
<br />
'''Основные''' разделы могут быть загрузочными и их количество ограничено четырьмя. Больше четырёх главных разделов создать нельзя и нужно использовать '''Расширенные''' разделы, которые будут содержать '''Логические'''.<br />
<br />
Расширенные разделы не могут быть использованы сами по себе - они всего лишь "контейнеры" для логических. Жёсткий диск может содержать только один расширенный раздел, который может быть разделён на логические.<br />
<br />
Во время разбивки диска можно заметить схему нумерации разделов. Главные получают названия sda1-3, расширенный раздел - sda4, а логические, соответственно, sda5, sda6 и т.д.<br />
<br />
=====Раздел Подкачки (swap)=====<br />
Данный раздел является чем-то вроде "виртуального ОЗУ". На нем хранятся данные, которые не умещаются, либо не подходят для хранения в оперативной памяти.<br />
<br />
Исторически сложилось, что размер раздела подкачки определяется по схеме 2ХОЗУ. То есть, двойной объем оперативной памяти. Затем, с развитием компьютерной техники, данное правило не всегда стало являться необходимым. На компьютере с 512 мегабайтами памяти правило 2Х все еще действует эффективно. Однако, на машинах с 1 гигабайтом памяти обычно наиболее эффективна схема 1ХОЗУ. Если размер вашего ОЗУ больше или равен 1 гигабайту, то можно вообще обойтись без раздела подкачки, однако это не рекомендуется. Мы создадим раздел размером в 1 гигабайт в нашем примере.<br />
<br />
{{Box Note|Если вы планируете использовать технологии suspend-to-disk или hibernate, то размер раздела подкачки, по меньшей мере, должен соответствовать размеру вашей оперативной памяти. Но рекомендуется задать размер хотя бы на 15% больший, чтобы учесть появление испорченных секторов на диске (bad sectors).}}<br />
=====Схема Разбивки=====<br />
Схема разбивки разделов довольно индивидуальна и во многом зависит от предпочтений и нужд конкретного пользователя. Но, как минимум, вам нужны два раздела: один для корня ( / ), второй для раздела подкачки (swap). Однако, вы можете захотеть иметь отдельные разделы для /boot (на нем обычно находится ядро Linux), /var и /home (пользовательская директория). Обычно иметь два раздела отдельно для корня ( / ) и отдельно для /home считается хорошей практикой и более удобным и безопасным решением.<br />
В нашем примере мы создадим три отдельных раздела: для корня, для /home и один раздел подкачки swap.<br />
<br />
=====cfdisk===== <br />
Итак, начнём с создания главного раздела, содержащего корневую файловую систему.<br />
<br />
Для создания нового раздела выберите пункт '''N'''ew, затем Primary. Далее задайте желаемый размер раздела (что-то между 4 и 12 гигабайт будет хорошим выбором). Выберите только что созданный раздел и сделайте его загрузочным, выбрав пункт '''B'''ootable.<br />
<br />
Также выберите пункт '''T'''ype и задайте значение '83 Linux'. Нашему разделу должно присвоится имя sda1.<br />
<br />
Затем создадим раздел подкачки. Задайте размер между 512 мегабайт и 1 гигабайтом, выберите '''T'''ype - 82 (Linux swap / Solaris). Наш раздел должен быть теперь виден как sda2.<br />
<br />
Теперь ещё один раздел для /home. Выберите главный раздел и установите желаемый размер в зависимости от того, что пользователи вашего компьютера будут хранить в своих персональных директориях. Также, как и для корня, задайте '''T'''ype - 83 Linux. Данный раздел появится как sda3.<br />
<br />
<br />
<br />
Вот как должна выглядеть наша таблица разделов (размеры могут отличаться):<br />
<br />
Name Flags Part Type FS Type [Label] Size (MB)<br />
-------------------------------------------------------------------------<br />
sda1 Boot Primary Linux (4096 - 8192)<br />
sda2 Primary Linux swap / Solaris (512 - 1024)<br />
sda3 Primary Linux (> 100 or remaining space)<br />
<br />
Выберите '''W'''rite и нажмите ''''yes''''. Или нажмите '''Q'''uit для выхода из программы разбивки.<br />
<br />
<br />
=====Мои IDE-диски выглядят как SCSI, почему?=====<br />
В последних версиях ядра Linux все диски (IDE, SATA, SCSI) именуются как sd''x''. Пусть это вас не волнует, это нормально.<br />
<br />
====Назначение точек монтирования====<br />
Во-первых, выберите нужный раздел под раздел подкачки (в нашем примере это sda3). Во-вторых, выберите раздел для монтирования корневой ФС (sda1 в нашем примере). Вам будет предложено выбрать желаемую файловую систему.<br />
<br />
=====Файловые системы=====<br />
<br />
Выбор файловой системы достаточно субъективен. Каждая из предложенных ФС имеет свои достоинства и недостатки, всё зависит целиком от ваших предпочтений. Далее мы кратко рассмотрим поддерживаемые ФС:<br />
<br />
1. '''[http://ru.wikipedia.org/wiki/Ext2 ext2]''' - старая и надежная файловая система для ОС GNU/Linux. Очень стабильна, но без поддержки журналирования - это значит, что в случае аппаратных сбоев или перепадов напряжения ваша информация может пострадать. Не слишком хороший выбор для корневого и /home разделов. Данная ФС может быть легко преобразована в ext3.<br />
<br />
2. '''[http://ru.wikipedia.org/wiki/Ext2 ext3]''' - наследница ext2, но с поддержкой журналирования. Она полностью совместима с ext2. Однако, по некоторым тестам немного медленнее, нежели остальные ФС. Тем не менее, очень стабильна и активно используется, поддерживается и разрабатывается сообществом GNU/Linux.<br />
<br />
3. '''[http://ru.wikipedia.org/wiki/ReiserFS ReiserFS]''' - высокопроизводительная файловая система, разработанная Гансом Райзером. Считается очень быстрой, особенно при операциях с файлами маленького размера, однако сравнительно медленно монтируется. Вполне готова к использованию и стабильна. Однако, не слишком активно разрабатывается на данный момент (все силы отданы Reiser4).<br />
<br />
4. '''[http://ru.wikipedia.org/wiki/JFS JFS]''' - '''J'''ournaled '''F'''ile'''S'''ystem, файловая система от IBM. Использует наименьшее количество ресурсов центрального процессора, нежели остальные ФС. Очень быстра в монтировании и использовании. Однако, не так широко используется, как ext или ReiserFS.<br />
<br />
5. '''[http://ru.wikipedia.org/wiki/JFS XFS]''' - журналируемая ФС, которая показывает наибольшую скорость при операциях с большими файлами. Хороший выбор для разделов с большим их количеством.<br />
<br />
Наиболее значимое отличие между ними - журналирование. Все, кроме ext2, его поддерживают, однако техника журналирования не у всех одинакова. Только ext3 поддерживает хранение в журнале данных и мета-данных (информация о директориях). Это значит, что только она в случае сбоя сможет восстановить полностью в точной мере ту информационную структуру, которая была до сбоя.<br />
<br />
Выберите и создайте ФС для корня. Далее вам будет предложено создать дополнительные разделы. В нашем примере, нам понадобится создать еще sda2. Выберите файловую систему и примонтируйте ее как /home. Нажмите Done и возвращайтесь в главное меню установщика.<br />
<br />
===Выбор пакетов===<br />
На данном этапе вам предстоит выбрать пакеты, которые будут установлены на вашу систему.<br />
* Установка из Core ISO: выберите подходящее устройство CD-ROM из списка.<br />
* Установка из FTP ISO: выберите FTP/HTTP-зеркало для получения пакетов.<br />
<br />
Процесс выбора пакетов разбит на две стадии: выбор категорий пакетов, а затем - выбор отдельных пакетов в этих категориях. С помощью клавиши пробела вы можете устанавливать и снимать выделение пакетов и категорий. Ниже приведен список категорий пакетов с объяснениями:<br />
<br />
* '''BASE:''' содержит только базовые, необходимые системные пакеты. Минимальный набор для базовой системы.<br />
*'''SUPPORT:''' здесь находятся дополнительные пакеты для работы с сетью и файловыми системами. Например, такие как gpm, fuse, dnsutils, ndiswrapper, ntfs-3g, драйвера для wi-fi адаптеров и т.п.<br />
*'''DEVEL:''' пакеты для сборки программ. То есть, GCC, autoconf, automake, make и т.п.<br />
*'''LIB:''' различные системные библиотеки - gmp, libelf, libevent и т.п.<br />
<br />
Нажмите OK и далее выберите опцию 'yes', когда вам будет предложено выбрать все пакеты по умолчанию ('Select all packages by default').<br />
<br />
Далее вам будет показан список пакетов в выбранных категориях. Для новичка будет лучшим выбором оставить всё как есть. Тогда как более опытные пользователи могут убрать ненужные им пакеты из данного списка.<br />
<br />
===Установка пакетов===<br />
Теперь выберите пункт 'Install Packages', чтобы начать установку пакетов. Вам будет предложено сохранить загруженные из источника установки пакеты в системном кэше. Это хороший выбор, который может очень вам помочь, если какой-либо новый установленный пакет будет работать не так, как надо. Тогда можно просто восстановить старую версию из кэша. Помните, что вы всегда можете очистить ваш кэш вручную при необходимости.<br />
Установщик произведет установку выбранных вами пакетов и ядра Arch Linux в вашу новую систему.<br />
<br />
*FTP ISO: менеджер пакетов [[Pacman_(Русский)|Pacman]] установит пакеты с сетевого зеркала (прогресс вы можете наблюдать на vc5, а чтобы вернуться назад к установщику - перейдите на vc1).<br />
*CORE ISO: пакеты будут установлены с оптического диска.<br />
<br />
===Конфигурация системы===<br />
''Чёткое следование и понимание следующих шагов является ключем к корректной работе системы.'' <br />
<br />
Установщик спросит вас о необходимости использования [[Hwdetect|hwdetect]] для сбора информации о параметрах компьютера. Новичку следует выбрать 'yes'. <br />
<br />
Опытные пользователи, которые хорошо знают свое железо, требующиеся модули, а так же те, что могут вручную отладить /etc/rc.conf, /etc/mkinitcpio и /etc/fstab, и т.д. с нуля могут выбрать'no'. (Не требует напоминания тот факт, что сия опция крайне сложна, выходит за рамки этого руководства и поэтому не освещается им)<br />
<br />
Далее будут заданы вопросы, необходимо ли вам будет загружаться с USB-устройств, FireWire-устройств, PCMCIA-устройств, общих папок NFS, программных RAID-массивов, LVM2 разделов, шифрованных разделов и о поддержке DSDT. Выбирайте 'yes' если вам что-то из вышеописанного требуется. В рамках нашего руководства не требуется ничего из описанного. <br />
<br />
Теперь вас спросят, какой текстовый редактор вы желаете использовать; выбирайте [http://en.wikipedia.org/wiki/Nano_%28text_editor%29 nano] (проще для освоения) или [http://en.wikipedia.org/wiki/Vim_%28text_editor%29 vi/vim] (рекомендуется, сложнее для освоения). Перед вами появится меню, включающее список наиболее важных конфигурационных файлов системы. Если вы хотите просмотреть возможные настройки, указанные в /etc/rc.conf, то просто нажмите Alt+F2, чтобы попасть в консоль, просмотрите файл и вернитесь в установщик с помощью Alt+F1. <br />
<br />
=====Почему установщик не делает это всё автоматически?=====<br />
Сокрытие процесса установки является прямой противоположностью [[пути Arch|Путь Arch]]. Пока имеет место факт, что последние версии ядра и средства определения оборудования замечательным образом поддерживают различное оборудование и автоконфигурацию, Arch будет представлять пользователю все соотвествующие конфигурационные файлы в течение установки с целью ''прозрачности''. К тому времени, как вы закончите настройку этих файлов под свои нужды, вы будете знать элементарные методы ручной настройки Arch Linux'а и будете знакомы с базовой структурой, будучи хорошо подготовленны к продуктивному использованию вашей новой системы.<br />
<br />
====='''/etc/rc.conf'''=====<br />
Arch Linux следует трациям '''*BSD''' использования '''/etc/rc.conf''' в качестве принципиального расположения системной конфигурации. Этот небольшой файл содержит обширный набор различных параметров, используемых при запуске системы. Как становится ясно из его имени, этот файл так же содержит настройки /etc/rc* файлов, а так же и вызывает эти файлы. Файл /etc/rc.conf предлагает простой, элегантный метод поточной конфигурации системных ресурсов включая широкие возможности контроля, охотно представляя их пользователям Arch Linux.<br />
<br />
* Секция '''LOCALIZATION''' <br />
** '''LOCALE'''=: Устанавливает системную локаль, которая будет использоватся для всех i18n приложений и утилит. Вы можете просмотреть список доступных локалей, введя комманду 'locale -a' в коммандой строке. Начальные настройки подходят для англоязычных пользователей (процесс локализации системы описан в [http://wiki.archlinux.org/index.php/Интернационализация соотвествующем руководстве]).<br />
<br />
** '''HARDWARECLOCK'''=: Определяет, каким образом аппаратные часы вашего компьютера, которые синхронизируются при загрузке и выключении, хранят время: '''UTC''' или '''localtime'''. UTC может сильно упростить смену часовых поясов, а так же переход на летнее/зимнее время. localtime необходим, если вы используете несколько операционных систем (скажем, у вас так же установлен Windows), которые хранят в аппаратных часах лишь localtime.<br />
** '''TIMEZONE'''=: Определяет ваш часовой пояс. Для Москвы, скажем, это "Europe/Moscow". (Все возможные часовые пояса хранятся в /usr/share/zoneinfo/).<br />
** '''KEYMAP'''=: Все возможные раскладки хранятся в /usr/share/kbd/keymaps. Учтите, что эта опция определяется только для TTY (текстовой консоли), а не графического оконого менеджера и X-ов!<br />
** '''CONSOLEFONT'''=: Возможные консольные шрифты хранятся в /usr/share/kbd/consolefonts/ если вам вдруг требуется замена. Для поддержки русского языка требуется указать "/usr/share/kbd/consolefonts/cyr-sun16".<br />
** '''CONSOLEMAP'''=: Определяет, какую console map загрузить с программой установки шрифтов при загрузке системы. Возможные map'ы можно найти в /usr/share/kbd/consoletrans, если вдруг необходимо. По умолчанию поле пустое, что считается безопасным. <br />
** '''USECOLOR'''=: Установите "yes", если у вас цветной монитор и вы хотите, что бы в консоли отображались цвета.<br />
<br />
LOCALE="ru_RU.UTF-8"<br />
HARDWARECLOCK="UTC"<br />
TIMEZONE="Europe/Moscow"<br />
KEYMAP="ru" # Или ru-mab для раскладки с переключением по Ctrl-Shift<br />
CONSOLEFONT="/usr/share/kbd/consolefonts/cyr-sun16"<br />
CONSOLEMAP=""<br />
USECOLOR="yes"<br />
<br />
* Секция '''HARDWARE'''<br />
** '''MOD_AUTOLOAD'''=: Если установлена как "yes", то '''udev''' будет автоматически проверять устройства и загружать соотвествующие модули во время загрузки системы. Установка в положение "no" возложит на пользователя возможность определят эту информацию самостоятельно или скомпилировать свое собственное ядро и модули, и т.д. <br />
** '''MOD_BLACKLIST'''=: Крайне не рекомендуется добавление blacklist'овых модулей прямо в строчку '''MODULES=''' далее. <br />
** '''MODULES'''=: Определяет дополнительные модули, если известно, что важный модуль пропущен, ('''hwdetect''' должен быть заполнен в наиболее важных модулях). Так же задайте какие-либо blacklist'овые модули, ставя перед ними восклицательный знак (!). Udev НЕ будет загружать blacklist'овые модули. К примеру, IPv6-модуль, так же как и надоедливый pc-спикер, отключены. <br />
# Сканирует устройства и загружает соотвествующие модули<br />
MOD_AUTOLOAD="yes"<br />
# Blacklist-модуль - Крайне не рекомендуется<br />
MOD_BLACKLIST=()<br />
#<br />
MODULES=(e100 eepro100 mii slhc snd-ac97-codec snd-intel8x0 soundcore !net-pf-10 !pcspkr)<br />
* Секция '''NETWORKING'''<br />
** '''HOSTNAME'''=: Задайте имя хоста (HOSTNAME) на свой вкус.<br />
** '''eth0'''=: 'Ethernet, card 0'. Задайте IP адрес интерфейса, сетевую маску и широковещательный адрес ''если'' вы используете '''статический IP'''. Задайте eth0="dhcp" если вы используете '''DHCP'''<br />
** '''INTERFACES'''=: Здесь задайте какие-либо/все интерфейсы. Если вы НЕ используете DHCP для конфигурации устройства, просто запомните, что значение переменной (имя которой должно совпадать с именем устройства, которое вы настраиваете) совпадает со строкой, которая будет следовать за коммандой "ifconfig", если вы решите настраивать устройство вручную в коммандой строке. <br />
** '''gateway'''=: Если вы используете '''статический IP''', установите адрес шлюза. Не трогайте этот параметр, если вы используете'''DHCP'''<br />
** '''ROUTES'''=: Если вы используете статический '''IP''', уберите '''!''' перед 'gateway'. Оставьте'''!''', если используете '''DHCP'''<br />
<br />
К примеру, если используется '''DHCP''':<br />
HOSTNAME="arch"<br />
#eth0="eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255" <br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
gateway="default gw 192.168.0.1"<br />
ROUTES=(!gateway)<br />
* Секция '''DAEMONS'''<br />
Этот массив задает список имен скриптов в /etc/rc.d/ которые будут запускаться во время загрузки системы, а так же порядок их запуска. <br />
DAEMONS=(@network syslog-ng netfs crond)<br />
*Если перед именем скрипта стоит восклицательный знак (!), он не исполняется. <br />
*Если перед скриптом стоит символ "at" (выглядит как "@"), тогда он будет запущен в фоновом режиме; очередь загрузки не будет ожидать успешного завершения демона перед переходом к загрузке следующего. Полезно для ускорения загрузки системы.<br />
*Редактируете этот массив, когда устанавливаете новые системные сервисы, если желаете, чтобы они загружались во время запуска системы.<br />
<br />
Это загрузка в 'стиле BSD', с особым Arch-способом обращения, в то время как остальные обращаются с помощью symlinks к директории /etc/init.d<br />
<br />
=====О Демонах=====<br />
Потушите свечу, уберите распятие, унесите иконы. Да, разговор пойдет о Демонах, но вовсе не о тех, о которых вы подумали сначала. И, да, вам не обязательно изменять строчку [[daemons]] в этот раз, но будет полезно объяснить, кто такие Демоны, поскольку они пригодятся нам далее в этом руководстве. <br />
<br />
По аналогии с сервисами Windows, ''демоны'' это программы, работающие в фоновом режиме, ожидающие наступления определенного события и предоставляющие сервисы. Отличный пример - вебсервер, который ожидает запроса на получение страницы или SSH-сервер, ожидающий, пока кто-нибудь не попробует войти в систему. В отличие от этих "полноценных" программ, их работа не так заметна. К примеру демон, который записывает что-либо в log-файл (к примеру, syslog, metalog), демон, понижающий частоту вашего CPU, когда система ничем не занята (к примеру:cpufreq), и демоны, которые представляют вам графический вариант входа в систему (log on) (к примеру: gdm, kdm). Все эти программы могут быть добавлены в строку "daemons" и будут запущены во время загрузки операционной системы. Всячекие полезные демоны будут представлены далее в этом руководстве. (Призыв Азазеля, Велиара, Асмодея, Маммона, Балтазара и других высших демонов в этом руководстве не рассматривается).<br />
<br />
Обращаясь к истории, термин ''daemon'' был предложен программистами MIT's Project MAC. Они заимствовали имя из ''Maxwell's demon'', мысленный эксперимент, главным персонажем которого является гипотетическое разумное существо ростом c молекулу. Выдумано Джеймсом Максвеллом с целью проиллюстрировать Второе начало термодинамики. <code>UNIX</code> системы унаследовали терминологию и создали бэкроним '''d'''isk '''a'''nd '''e'''xecution '''mon'''itor. <br />
<br />
*'''''Подсказка: Все демоны в Arch проживают в директории /etc/rc.d/ Звоните! :)'''''<br />
<br />
=====Про /etc/fstab=====<br />
Так называемый '''fstab''' ('''f'''ile '''s'''ystems '''tab'''le) это часть конфигурации системы, отображающая все доступные диски и дисковые разделы; показывающая, как они инициализированны/интегрированны в системную файловую систему. Данный '''/etc/fstab''' обычно используется коммандой '''mount''', которая читает /etc/fstab дабы определить, какие настройки нужно использовать для монтирования определенного устройства.<br />
<br />
<br />
К примеру, '''/etc/fstab''':<br />
<br />
#<br />
# /etc/fstab: static file system information<br />
#<br />
# <file system> <dir> <type> <options> <dump> <pass><br />
none /dev/pts devpts defaults 0 0<br />
none /dev/shm tmpfs defaults 0 0<br />
#/dev/cdrom /mnt/cdrom iso9660 ro,user,noauto,unhide 0 0<br />
#/dev/dvd /mnt/dvd udf ro,user,noauto,unhide 0 0<br />
#/dev/fd0 /mnt/fd0 vfat user,noauto 0 0<br />
/dev/disk/by-uuid/0ec-9339 / jfs defaults,noatime,nodiratime 0 1<br />
/dev/disk/by-uuid/7ef-223-0 /home jfs defaults,noatime,nodiratime 0 2<br />
/dev/disk/by-uuid/530-1e-2c2 swap swap defaults 0 0<br />
<br />
Измените '''fstab''' под себя, если желаете.<br />
{{Box Note | Как было писано в 2008-04rc, Arch теперь использует UUID, или Universally Unique Identifier конвертацию имен для повышения совместимости. Крайне полезно при активной работе над ядром и udev, что может повлечь случайное изменение в порядке загрузки драйверов storage-контроллеров и невозможности загрузки системы из-за kernel-panic. Почти все материнские платы имеют несколько контроллеров (SATA, IDE), и в вышеуказанных случаях, /dev/sda мог запросто стать /dev/sdb при следующей загрузке - с тех пор была введена UUID.}}<br />
ls -lF /dev/disk/by-uuid/<br />
Отобразит разделы, отсортированные по uuid.<br />
<br />
*Если вы планируете использование '''hal''' для автоматического монтирования всякой всячины (вроде DVD дисков), вы, возможно, изволите закомментить записи, касающиеся cdrom и dvd для подготовки к установке '''hal''', который будет инсталлирован нами далее в этом руководстве.<br />
<br />
{{Box Note | '''''Опции 'noatime' и 'nodiratime' опции могут спокойно быть применены к / и /home независимо от Вашего указанного типа файловой системы для увеличенния скорости, производительности, и эффективности как для ноутбуков, так же как стационарных компьютеров.'''''}}<br />
<br />
Дополнительная информация доступна в разделе wiki: [[Fstab]].<br />
<br />
====='''/etc/mkinitcpio.conf и /etc/modprobe.conf'''=====<br />
Нам с вами не требуется настройка этих файлов на данном этапе. <br />
<br />
* '''mkinitcpio.conf''' Этот файл позволяет Вам точно настраивать начальную файловую систему (также обычно называемый начальным ram-диском или "initrd"). Файл initrd является созданным gzipp'ом образом, который был прочитан ядром во время загрузки. Цель initrd - довести систему до момента, когда она сможет обратиться к основной root'овой файловой системе. Это значит, что этот файл должен загрузить любые модули, которые потребуются для таких устройств, как IDE, SCSI или диски SATA (Или USB/FW, если вы грузитесь с USB/FW-устройства). Как только initrd загрузит соотвествующие модули, вручную или с помощью udev'а, он передает управление системе Arch'а и загрузка продолжается. По этой причине initrd должен содержать только те модули, которые необходимы для доступа к корневой файловой системе. Он не должен содержать каждый из модулей, которые вы хотели бы использовать! Большиство модулей, которые вы используете в повседневной работе, будут загружены позже через udev в течение init-процесса. <br />
<br />
* '''modprobe.conf''' используется для применения особых настроек к некоторым модулям ядра.<br />
<br />
=====/etc/resolv.conf (для статического IP)=====<br />
''Преобразователь адресов'' это набор стандартных действий в библиотеке "C" который предоставляет доступ к Internet Domain Name System (DNS). Одна из основных функций DNS - переводить текстовые URL в ip-адреса чтобы сервер понял, с какой именно машиной в Интернете/Локальной сети вы желаете установить соединение. Конфигурационный файл /etc/resolv.conf содержит информация, которая считывается преобразователем адресов во время первого вызова процессом. <br />
<br />
*''Если вы используете DHCP, вы можете спокойно игнорировать этот файл, поскольку он динамически создается и уничтожается демоном dhcpcd. Вы можете изменить этот порядок действий, установленный по умолчанию, если желаете. (Смотрите [[Network]]).''<br />
<br />
Если вы используете статический IP, задайте ваши DNS-сервера в /etc/resolv.conf (nameserver <ip-адрес>). Можете задать их сколько вам угодно, к примеру:<br />
nameserver 4.2.2.1<br />
nameserver 4.2.2.2<br />
<br />
Если вы используете роутер, вы, возможно, хотите задать ваши DNS-сервера в самом роутере , и просто указать на него в '''/etc/resolv.conf''', используя IP вашего роутера (который, кстати, также является вашим шлюзом в '''/etc/rc.conf'''), например:<br />
nameserver 192.168.1.1<br />
<br />
Если используется '''DHCP''', вы можете также задать ваши DNS сервера в роутере, или использовать автоматическую настройку вашим ISP (провайдером), если ваш провайдер это позволяет.<br />
<br />
=====/etc/hosts=====<br />
<br />
Этот файл создает соотвествия между IP адресами, сетевыми именами машин (hostnames) и их псевдонимами, по одному IP на строчку. Для каждого компьютера каждая одиночная линия должна содержать следующие данные:<br />
<IP-адрес> <сетевое имя компьютера> [псевдоним...]<br />
Добавьте ваше ''сетевое имя'', совпадающее с тем, что вы задали в /etc/rc.conf, так же как и псевдом, чтобы все выглядело примерно так:<br />
127.0.0.1 localhost.localdomain localhost '''''VasyaPupkin-Zade'''''<br />
{{Box Note |''Учтите, что все данные, что вы ввели, '''включая 'localhost'''', требуют программной совместимости! Слишком длинные имена, имена с нестандартными символами могут не поддерживаться некоторыми системами. Это может привести к падению производительности сети, замедленной работе/неработаспособности некоторых программ. Это крайне распространенная ошибка среди новичков.''}}<br />
<br />
Если вы используете статический IP, добавьте еще одну линию, используя синтаксис: <статический-IP> <hostname.domainname.org> <hostname> к примеру:<br />
192.168.1.100 '''''Сетевое имя вашего компьютера'''''.domain.org '''''Сетевое имя вашего компьютера'''''<br />
<br />
*'''Подсказка''': Для удобства вы также можете использовать псевдонимы /etc/hosts для компьютеров в вашей локальной сети и/или в Интернете, к примеру:<br />
64.233.169.103 www.google.com g<br />
192.168.1.90 mp3<br />
192.168.1.88 megaporn<br />
Эта простая махинация с применением черной магии позволит вам загружать google, просто введя 'g' в вашем браузере, а также соединятся с mp3 и порносерверами в вашей локальной сети, просто вводя их имена (вами и заданные), а не набирая каждый раз их IP-адреса (как часто бывает).<br />
<br />
=====/etc/hosts.deny и /etc/hosts.allow=====<br />
Изменяйте это конфигурационные файлы под свои нужды, если вы планируете использовать [[SSH|ssh]] демона. Стандартная конфигурация будет отвергать все входящие соединения (не только SSH-соединения). Отредактируйте файл '''/etc/hosts.allow '''и добавьте: <br />
sshd:all <br />
Это разрешит все входящие ssh соединения.<br />
<br />
Если же [[SSH|ssh]] демон вы не планируете использовать, не трогайте этот файл (он должен быть пустой) для повышения безопасности.<br />
<br />
=====/etc/locale.gen=====<br />
<br />
Команда '''locale-gen''' считывает из '''/etc/locale.gen''' данные для создания определенной локали. Далее она может быть использована '''glibc''' или любой другой программой или библиотекуой, использующей локаль для рендеринга "специфического" текста, корректного отображения местных денежных знаков, формата даты и времени, алфавитных спецсимволов, и других локально-определяемых стандартов. Возможность установить стандартную локаль является огромным преимуществом <code>UNIX</code>-ообразных операционных систем.<br />
<br />
По умолчанию /etc/locale.gen является пустым файлом с закомментированной документаций. Однажды будучи отредактированным, файл больше в изменениях не нуждается. '''locale-gen''' запускается при каждом обновлении '''glibc''', создавая все заданные локали в /etc/locale.gen.<br />
<br />
Выбере локаль(локали), которые вам нужны, убрав символ # перед соотвествующей строчкой. К примеру:<br />
ru_RU.UTF-8 UTF-8 <br />
<br />
Инсталлятор запустит специальный скрипт генерации локали, который сгенерирует те, которые вы задали. Вы сможете сменить свою локаль, отредактировав /etc/locale.gen и запустив 'locale-gen' под root'ом.<br />
<br />
{{Box Note |'''''Если вы не задали локаль, это приведет к ошибке: "The current locale is invalid...". Это одна из самых распространненых ошибок пользователей ArchLinux и плодит дофига просьб о помощи на форумах. Читайте мануалы!'''''}}<br />
<br />
=====Пароль root'а=====<br />
Наконец, установите пароль суперпользователя (root'а) и, прошу ваш, НЕ ЗАБУДЬТЕ ЕГО! Вернитесь в главное меню и продолжите инталляцию bootloader'а.<br />
<br />
=====Зеркало для Pacman'а=====<br />
Выберите зеркало репозитория для '''pacman'''. <br />
*''archlinux.org ограничен по скорости - не более 50KB/s. Используйте yandex'овский репозиторий!'' <br />
<br />
Вернитесь в главное меню.<br />
<br />
===Установка загрузчика===<br />
Поскольку в нашем примере второй операционной системы на компьютере нет, нам понадобится Загрузчик. [http://www.gnu.org/software/grub/ GNU GRUB] является рекомендованным загрузчиком. Как вариант, вы можете использовать [http://lilo.go.dyndns.org/ LILO].<br />
<br />
===GRUB===<br />
GRUB - не потому что он грубый! :) Он расшифровывается как GRand Unified Bootloader и, на самом деле, пушистый, покладистый и надежный загрузчик, который используется почти во всех UNIX'ообразных системах. Конфигурация '''GRUB''' в файле ('''/boot/grub/menu.lst''') вполне, так сказать, исчерпывающая и в изменениях не нуждается. Только одну вещь вы можете возжелать настроить: экранное разрешение консоли. Добавьте<br />
vga=<number> в первую строчку ядра. (Таблица разрешений и соотвествующих номеров находится в menu.lst.)<br />
<br />
Пример: <br />
title Arch Linux (Main)<br />
root (hd0,0)<br />
kernel /boot/vmlinuz26 root=/dev/disk/by-uuid/0ec1-9339.. ro vga=773<br />
initrd /boot/kernel26.img<br />
Трактовка:<br />
<br />
Строка 1: '''title''': Пункт выбора в меню. "Arch Linux (Main)" будет выведено меню на экран как вариант выбора.<br />
<br />
Line 2: '''root''': Корневая директория GRUB; Диск и раздел. где располагается ядро (/boot). '''НЕ ОБЯЗАТЕЛЬНО располагать его в корневой директории файловой системы''' (/) - он может располагаться вообще на отдельном разделе жесткого диска. Схема нумерации GRUB'а начинается с нуля (0), и используется по формату hd''x,x'' независимо, чего там у вас, IDE и SATA, заключенному в круглые скобки.<br />
<br />
В примере видно, что /boot находится на первом разделе первого диска, или, (hd0,0).<br />
<br />
Строчка 3: '''kernel''': Строка определяет:<br />
<br />
* Путь и имя файла ядра '''''относительно расположения GRUB'а''''' (в пределах раздела, содержащего ядро). <br />
<br />
К примеру, /boot это просто каталог, находящийся на одном разделе с / ,а '''vmlinuz26''' (имя файла ядра) будет в '''/boot/vmlinuz26'''. ''Если /boot находится на отдельном разделе, путь и имя файла будут просто '''/vmlinuz26''', будучи относительными к '''GRUB''''овской корневой директории.'' <br />
<br />
* Root= определяет раздел, содержающий корневую директорию (/) загружаемой системы, (точнее, раздел, содержающий '''/sbin/init'''), ''соотвественно схеме нумерации UUID'' как указано в 2008-04rc, в которой используется формат /dev/disk/by-uuid/xxxx-xxxx-xxxx. <br />
<br />
* Опции ядра. <br />
<br />
К примеру, '''ro''' монтирует файловую систему с параметром "только для чтения" во время загрузки, а '''"vga=773"''' выведет фреймбуфер с разрешением 1024x768 и глубиной в 256 цветов.<br />
<br />
Строка 4: '''initrd''': (Для загрузочного RAM диска) Путь и имя файла для загрузочной файловой системы RAM '''относительно корневой директории GRUB''''а (в пределах раздела, содержащего ядро). Опять-таки, к примеру, /boot это просто каталог, расположенный на одном разделе с / и '''kernel26.img''' является именем файла initrd; тогда путь такой: '''/boot/kernel26.img'''. ''Если /boot была бы на отдельном разделе, путь и имя файла были бы просто '''/kernel26.img''', будучи относительными к '''GRUB''''овской корневой директории.'' <br />
<br />
Инсталлируйте загрузчик '''GRUB''' на первичную загрузочную запись, (в нашем примере sda).<br />
<br />
Вот и всё! Вы поставили и настроили Arch Linux. Откройте бутылочку пивка, погладьте кота, почешите бороду, почитайте ithappends.ru, habrahabr.ru и bash.org.ru. Матюгнитесь на "проклятых ubuntu'йщиков"!Покиньте инсталлятор, выньте CD из дисковода и, затаив дыхание, введите сокровенное слово:<br />
<br />
reboot<br />
<br />
Ваша система ArchLinux перезагрузится и поприветствует вас просьбой о вводе имени пользователя (не забудьте вернуть порядок загрузки в '''BIOS''' на загрузку с жесткого диска).<br />
<br />
'''Поздравляем и добро пожаловать в вашу новую, сверкающую и благоухающую систему Arch Linux! Теперь вы настоящий Линуксоид! Отныне можете смело опускать Виндусятников. Bill Gates Must Die!'''<br />
<br />
==The Base System ==<br />
Your new Arch Linux base system is now a functional GNU/Linux environment ready for customization. From here, you may build this elegant set of tools into whatever you wish or require for your purposes. <br />
<br />
Let's begin.<br />
<br />
Login with your root account. We will configure pacman and update the system as root, then add a normal user. <br />
{{Box Note |Virtual consoles 1-6 are available, as is the '''links''' command line web browser.}}<br />
<br />
===Configuring the network (if necessary)===<br />
*''This section will assist you in configuring most types of networks, if your network configuration is not working for you.''<br />
<br />
If you properly configured your system, you should have a working network. Try to ping www.google.com to verify this.<br />
ping -c 3 www.google.com<br />
<br />
''If you have successfully established a network connection, continue with '''[[#Update, Sync and Upgrade the system with pacman|Update, Sync and Upgrade the system with pacman]]'''.''<br />
<br />
If, after trying to ping www.google.com, you get an "unknown host" error, you may conclude that your network is not properly configured. You may choose to double-check the following files for integrity and proper settings:<br />
<br />
'''/etc/rc.conf''' # Specifically, check your HOSTNAME= and NETWORKING section for typos and errors.<br />
<br />
'''/etc/hosts''' # Double-check your format. (See above.)<br />
<br />
'''/etc/resolv.conf''' # If you are using a static IP. If you are using DHCP, this file will be dynamically created and destroyed by default, but can be changed to your preference. (See [[Network]].)<br />
<br />
Advanced instructions for configuring the network can be found in the [[Network]] article.<br />
<br />
====Wired LAN====<br />
<br />
Check your Ethernet with<br />
ifconfig -a<br />
All interfaces will be listed. You should see an entry for eth0, or perhaps eth1. If required, you can set a new static IP with<br />
ifconfig eth0 <ip address> netmask <netmask> up <br />
and the default gateway with<br />
route add default gw <ip address of the gateway><br />
Check to see if /etc/resolv.conf contains your DNS server and add it if it is missing. <br />
Check your network again with ping www.google.de. If everything is working now, adjust /etc/rc.conf as described above for static IP. If you have a DHCP server/router in your network try<br />
dhcpcd eth0<br />
If this is working, adjust /etc/rc.conf as described above, for dynamic IP.<br />
<br />
====Wireless LAN====<br />
Detailed setup guide: [[Wireless Setup]]<br />
<br />
====Analog Modem====<br />
To be able to use a Hayes-compatible, external, analog modem, you need to at least have the ppp package installed. Modify the file /etc/ppp/options to suit your needs and according to man pppd. You will need to define a chat script to supply your username and password to the ISP after the initial connection has been established. The manpages for pppd and chat have examples in them that should suffice to get a connection up and running if you're either experienced or stubborn enough. With udev, your serial ports usually are /dev/tts/0 and /dev/tts/1.<br />
Tip: Read [[Dialup without a dialer HOWTO]].<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt to install wvdial or a similar tool to ease the setup process considerably. In case you're using a so-called WinModem, which is basically a PCI plugin card working as an internal analog modem, you should indulge in the vast information found on the [http://www.linmodems.org/ LinModem] homepage.<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, meaning that you won't need to recompile your kernel unless you're about to use rather odd ISDN hardware. After physically installing your ISDN card in your machine or plugging in your USB ISDN-Box, you can try loading the modules with modprobe. Nearly all passive ISDN PCI cards are handled by the hisax module, which needs two parameters: type and protocol. You must set protocol to '1' if your country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3' if you're hooked to a so-called leased-line without D-channel, and '4' for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the kernel documentation, more specifically in the isdn subdirectory, and available online. The type parameter depends on your card; a list of all possible types can be found in the README.HiSax kernel documentation. Choose your card and load the module with the appropriate options like this:<br />
<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my ELSA Quickstep 1000PCI, being used in Germany with the EDSS1 protocol. You should find helpful debugging output in your /var/log/everything.log file, in which you should see your card being prepared for action. Please note that you will probably need to load some USB modules before you can work with an external USB ISDN Adapter.<br />
<br />
Once you have confirmed that your card works with certain settings, you can add the module options to your /etc/modprobe.conf:<br />
<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively, you can add only the options line here, and add hisax to your MODULES array in the rc.conf. It's your choice, really, but this example has the advantage that the module will not be loaded until it's really needed.<br />
<br />
That being done, you should have working, supported hardware. Now you need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl; it'll get you started. Further down in the manpage you will find explanations on how to create a configuration file that can be parsed by isdnctrl, as well as some helpful setup examples. Please note that you have to add your SPID to your MSN setting separated by a colon if you use US NI1.<br />
<br />
After you have configured your ISDN card with the isdnctrl utility, you should be able to dial into the machine you specified with the PHONE_OUT parameter, but fail the username and password authentication. To make this work add your username and password to /etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were configuring a normal analogous PPP link, depending on which protocol your ISP uses for authentication. If in doubt, put your data into both files.<br />
<br />
If you set up everything correctly, you should now be able to establish a dial-up connection with<br />
isdnctrl dial ippp0<br />
as root. If you have any problems, remember to check the logfiles!<br />
<br />
====DSL (PPPoE)====<br />
<br />
These instructions are relevant to you only if your PC itself is supposed to manage the connection to your ISP. You do not need to do anything but define a correct default gateway if you are using a separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to physically install the network card that is supposed to be connected to the DSL-Modem into your computer. After adding your newly installed network card to the modules.conf/modprobe.conf or the MODULES array, you should install the rp-pppoe package and run the pppoe-setup script to configure your connection. After you have entered all the data, you can connect and disconnect your line with<br />
<br />
/etc/rc.d/adsl start<br />
<br />
and<br />
<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward, but feel free to read the manpages for hints. If you want to automatically dial in on boot-up, add adsl to your DAEMONS array.<br />
<br />
==Update, Sync and Upgrade the system with [[pacman]]==<br />
Now we will update the system using [[pacman]]. <br />
<br />
=====What is pacman ?=====<br />
[[Pacman]] is the '''pac'''kage '''man'''ager of Arch Linux. Pacman is written in C and is fast, simple, and extremely powerful. It manages your entire package system and handles installation, removal, package downgrade (through cache), custom compiled package handling, automatic dependency resolution, remote and local searches and much more. Arch uses the .tar.gz package format, which further enhances pacman's speed; Gzipped tarballs, though slightly larger, are decompressed much faster than their Bzipped counterparts, and are therefore generally installed more expediently. <br />
<br />
We will use pacman to download software packages from remote repositories and install them onto your system.<br />
<br />
Pacman is the most important tool in your Arch Linux toolbox for building the base system into whatsoever you please.<br />
<br />
===Configuring pacman===<br />
<br />
=====Package Repositories and /etc/pacman.conf=====<br />
Arch currently offers the following repositories readily accessible through pacman:<br />
<br />
'''[core]'''<br />
<br />
The simple principle behind [core] is to provide only one of each necessary tool for a base Arch Linux system; The GNU toolchain, the Linux kernel, one editor, one command line browser, etc. (There are a few exceptions to this. For instance, both vi and nano are provided, allowing the user to choose one or both.) Developer maintained.<br />
<br />
*''The Core installation cd simply contains an installer script, and a snapshot of the core repository.''<br />
<br />
'''[extra]'''<br />
<br />
The [extra] repository contains all Arch packages that are not themselves necessary for a base Arch system, but contribute to a more full-featured environment. '''X''', KDE and GNOME, for instance, can be found here. Developer maintained.<br />
<br />
'''[unstable]'''<br />
<br />
The [unstable] repository contains experimental and unstable software, especially if the development version of a package has become popular for some reason. For example, perhaps the upstream stable version is hopelessly out of date, or the unstable version has some groundbreaking changes that a lot of users seem interested in, like experimental kernel drivers or -svn package versions. Developer maintained.<br />
<br />
{{Box Note |'''Contrary to popular belief, it is perfectly safe to enable the unstable repository, as there are no name collisions with [core], [community] or [extra]. Packages from [unstable] are only installed if you explicitly do so. If there is a conflict between an [Unstable] package and an installed package, pacman will warn you and resolve the conflict, if prompted, by removing the installed package.'''}}<br />
<br />
The [unstable] repository is currently not maintained for ''x86_64''.<br />
<br />
'''[testing]'''<br />
<br />
The [testing] repository contains packages that are candidates for the [core], [extra] or [unstable] repositories. New packages go into [testing] if:<br />
* they are expected to break something on update and need to be tested first<br />
* they require other packages to be rebuilt. In this case, all packages that need to be rebuilt are put into [testing] first and when all rebuilds are done, they are moved back to the other repositories. Developer maintained.<br />
<br />
[testing] is the only repository that can have name collisions with any of the other official repositories. If enabled, it has to be the first repo listed in your ''pacman.conf'' file.<br />
<br />
{{Box Note|'''''Be careful when enabling [testing]. Your system may break after you update with [testing] enabled. Only experienced users should use it.'''''}}<br />
<br />
'''[community]'''<br />
<br />
The [community] repository is maintained by the ''Trusted Users (TUs)'' and is part of the ''Arch User Repository ([[AUR]])''. It contains binary packages from the ''AUR'' that have enough votes and were adopted by a ''TU''. Like all repos listed above, [community] may be readily accessed by pacman.<br />
<br />
The '''[[AUR]]''' also contains the '''unsupported''' branch, which cannot be accessed directly by pacman*. [unsupported] contains more than 8 thousand PKGBUILD scripts for building packages from source, that may be unavailable through the other repos. <br />
<br />
<nowiki>*</nowiki>''The '''''[[#Install Yaourt| yaourt]]''''' tool, an extremely popular, community contributed wrapper for pacman, can seamlessly access the '''AUR'''.''<br />
<br />
'''/etc/pacman.conf'''<br />
<br />
pacman will attempt to read /etc/pacman.conf each time it is invoked. This configuration file is divided into sections, or repositories. Each section defines a package [[Official Repositories|repository]] that pacman can use when searching for packages. The exception to this is the options section, which defines global options.<br />
nano /etc/pacman.conf<br />
Example:<br />
[core]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[extra]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
#[unstable]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[community]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
Enable all desired repositories (remove the # in front of the 'Include =' and '[repository]' lines).<br />
<br />
<br />
*'''''When choosing repos, be sure to uncomment both the repository header lines in [brackets] as well as the 'Include =' lines. Failure to do so will result in the selected repository being omitted! This is a very common error.'' '''<br />
<br />
====/etc/pacman.d/mirrorlist====<br />
Faster mirrors will dramatically improve pacman performance, and your overall Arch Linux experience.<br />
<br />
Edit /etc/pacman.d/mirrorlist:<br />
nano /etc/pacman.d/mirrorlist<br />
Remove all mirrors which are not on your continent, or are extremely distant. (Using nano, you may use CTRL-K to cut each unneeded line.) <br />
<br />
Edit /etc/pacman.d/mirrorlist by placing the best mirror at the top of the list. (Recall that archlinux.org is throttled to 50KB/s). If using nano, you can cut a line with CTRL-K and paste with CTRL-U. <br />
<br />
After changing mirrors, issue the following command:<br />
pacman -Syy<br />
This will force pacman to resynchronize with the new repo. Issuing pacman -Syy ''whenever a mirror is changed'', is good practice and will avoid possible headaches.<br />
=====Ignoring packages=====<br />
When you execute the command "pacman -Syu", your entire system will be updated. It is possible that you want to prevent a package from being upgraded. An example could be the kernel (kernel26) or a package for which an upgrade may prove problematic for your system. In this case, you have two options; indicate the packages you want to skip in the pacman command line using the --ignore switch (do pacman -S --help for details) or permanently indicate the packages you want to skip in your /etc.pacman.conf file:<br />
<br />
IgnorePkg = kernel26<br />
The typical way to use Arch is to use pacman to install all packages unless there is no package available, in which case you can build your own package using [[ABS]]. Many user-contributed packages are available in the Arch User Repository. You are expected to keep your system up to date with pacman -Syu, rather than selectively upgrading packages. Use of '''IgnorePkg''' in /etc/pacman.conf is therefore discouraged, and should be used sparingly, if you know what you are doing.<br />
<br />
You may diverge from this typical usage as you wish; just be warned that there is a greater chance that things will not work as intended and that it could break your system. The majority of complaints happen when selective upgrading or unusual compilation is performed.<br />
<br />
=====Ignoring Configuration Files=====<br />
In the same vein, you can also "protect" your configuration/system files from being overwritten during "pacman -Su" using the following option in your /etc/pacman.conf<br />
<br />
NoUpgrade = etc/lilo.conf boot/grub/menu.lst<br />
<br />
==Update System==<br />
Update, sync, and '''upgrade''' your entire new system with:<br />
pacman -Syu<br />
pacman will now fetch the latest information about available packages and perform all available upgrades. (You may be prompted to upgrade pacman itself at this point. If so, say yes, and then reissue the pacman -Syu command when finished.) <br />
Reboot if a kernel upgrade has occurred. <br />
{{Box Note|'''''Occasionally, configuration changes may take place requiring user action during an update; read pacman's output for any pertinent information.'''''}}<br />
<br />
=====Прелесть Arch'овой Rolling-release'ной модели=====<br />
Запомните, что Arch это дистрибутив с '''rolling release''' моделью. Это значит, что у вас никогда не возникнет причин для переустановки или or или разбираться в очередном релизе для обновления вашей системы. Просто переодически используйте '''pacman -Syu''' и ваша система будет всегда свежа, обновлена (и хорошо пахнуть :). После данного обновления все компоненты вашей системы будут иметь текущие версии.<br />
Если было также обновлено и ядро, перезагрузитесь (команда reboot).<br />
<br />
=====Get familiar with pacman=====<br />
Pacman is the Arch user's best friend. It is highly recommended to study and learn how to use the pacman tool. Try:<br />
man pacman<br />
Check out the bottom of this article, and look up the [[pacman]] wiki entries at your leisure.<br />
<br />
<br />
<br />
===Add a user and setup groups===<br />
You should not do your everyday work using the root account. It is more than poor practice; it is dangerous. Root is for administrative tasks. Instead, add a normal user account using:<br />
adduser<br />
While most default options are safe to use, you may want to add storage, audio, video, optical, and wheel to your additional groups- especially if you are planning on having a full-featured desktop environment. <br />
<br />
Groups and users thereof are defined in /etc/group. <br />
<br />
They include:<br />
<br />
*'''audio''' - for tasks involving sound card and related software<br />
<br />
*'''wheel''' - for using sudo<br />
<br />
*'''storage''' - for managing storage devices<br />
<br />
*'''video''' - for video tasks and 3d acceleration<br />
<br />
*'''optical''' - for managing tasks pertaining to the optical drive(s)<br />
<br />
*'''floppy''' - for access to a floppy if applicable<br />
<br />
*'''lp''' - for managing printing tasks<br />
<br />
See the [[Groups]] article to understand what groups you need to be a member of. <br />
<br />
Check the man pages for usermod and gpasswd for more information.<br />
=====Install and setup Sudo=====<br />
<br />
See [[Sudo]]<br />
<br />
==Часть II: Ставим X и настраиваем ALSA==<br />
<br />
<br />
===Настройка звуковой карты с помощью alsamixer===<br />
Advanced Linux Sound Architecture (известная под акронимом '''ALSA''') это компонент ядра систему Linux, призванный заменить Open Sound System (OSS) представляющий драйвера для звуковых карт. Кроме драйверов, '''ALSA''' так же предоставляет библиотеки для разработчиков, которые хотят использовать возможности драйвера на более высоком уровне API, нежели прямое взаимодействие с драйверами ядра.<br />
-----<br />
{{Box Note|udev автоматически проверит ваше устройство во время загрузки, загрузив соотвествующий драйвер для вашей звуковой карты. Ваша аудиосистема, скорее всего, уже работает, но по умолчанию звук отключен (mute).}} <br />
Пакет утилит alsa содержит alsamixer, который позволяет настраивать звук прямо из консоли. (Вы сможете загружать aslamixer также из окружения '''X''' несколько позже.)<br />
<br />
Установка пакета утилит alsa:<br />
pacman -S alsa-utils<br />
Вы добавили-то обычного пользователя в группу audio? Если нет, то сейчас самое время! Под root'ом выполните:<br />
gpasswd -a yourusername audio<br />
Завершите сеанс (exit) и снова войдите под обычным пользователем, дабы удостоверится, что группа audio загрузилась верно.<br />
<br />
Под '''''простым, не root'овым''''' пользователем, выполните: <br />
'''[root@myhost ~]#''' alsamixer<br />
Включите каналы MASTER и PCM, подведя к ним курсор стрелочками лево/право и нажатием английской '''M'''. Увеличьте громкость клавишей "вверх" (70-90% должно быть в самый раз). Закройте микшер нажатием ESC.<br />
<br />
==== Проверка звука ====<br />
Проверьте настройку вашей аудиокарты коммандой aplay:<br />
aplay /usr/share/sounds/alsa/Front_Center.wav<br />
Вы услышите чарующий, манящий, жаркий и нежный, искрящийся всеми цветами радуги и клубящийся утренним туманом на горе Фудзи в лучах восходящего солнца, женский голос, прозносящий: "Front, center."<br />
<br />
Теперь залогинтесь под root'ом и выполните комманду alsactl:<br />
alsactl store<br />
Это приведет к созданию '/etc/asound.state', сохраняя найстроки asla-микшера.<br />
<br />
Также, добавте ''daemon'' alsa в вашу DAEMONS-секцию (демоническая секция, а-а-а!) в /etc/rc.conf дабы настройки микшера восстанавливались при каждой загрузке автоматически.<br />
nano /etc/rc.conf<br />
DAEMONS=(syslog-ng network crond '''alsa''')<br />
''Учтите, что демон alsa'ы просто восстанавливает уровни громкости микшера при загрузки путем чтения /etc/asound.state. Это происходит независимо от аудио-библиотеки alsa (и уровня громкости API ядра).''<br />
<br />
Дополнительную информацию можно найти в wiki-записи [[ALSA]].<br />
<br />
===Устанавливаем и настраиваем X-ы===<br />
О, великие '''X''' Window System (обычно '''X11''', или '''X''', или просто '''Иксы''') это сетевой и экранный протокол, который поддерживает оконную систему на bitmap-дисплеях. Иксы предоставляют арсенал утилит и протокол для создания Графического Интефейса Пользователя (GUI) на <code>UNIX</code>'овых операционных системах.<br />
<br />
'''X''' представляет базовый фреймворк, на примитивах, для создания GUI'овых сред: отрисовка и перемещение окон по экрану и взаимодействие с мышкой/клавиатурой. '''X''' не предоставляет пользовательский интерфейс — это поддерживает индивидуальная клиент-программа. <br />
<br />
'''X''' так назван, поскольку им предшествовала '''W''' Window System, разработанна в Стендфорском Университете. <br />
-----<br />
<br />
{{Box Note| Если вы планировали использовать '''open-source''' видео-драйвер, и если вам нужно 3d-ускорение, рекомендуется инсталлировать библиотеку libgl перед установкой Xorg:}}<br />
pacman -S libgl<br />
''(Проприетанрные видеодрайверы обеспечивают свои собственные реализации этой библиотеки)''<br />
----- <br />
Теперь мы установим основные пакеты Xorg, используя pacman. Это - первый шаг в построении GUI.<br />
<br />
pacman -S xorg<br />
3d-утилиты, такие как glxgears включены пакет '''mesa''':<br />
pacman -S mesa<br />
<br />
Теперь у нас есть основные пакеты, в которых мы нуждаемся для того, чтобы запустить '''X''' Server. Сейчас вы должны добавить драйвер для своей видеокарты (к примеру xf86-video-<имя>). Самый простой способ конфигурировать X.org, устанавливая корретные пакеты драйвера сначала, а затем генерируя /etc/X11/xorg.conf испольуя скрипт автоконфигурации, такой как Xorg - configure.<br />
<br />
Если вы хотите увидеть весь список '''open-source''' видеодрайверов, используйте: <br />
pacman -Ss xf86-video | less<br />
Вам нужно знать, какой видеочипсет на вашем компьютере. Если вы не знаете, выполните:<br />
lspci | grep VGA<br />
Здесь приведен список '''open source''' драйверов и соотвествующих графических чипсетов..<br />
*'''xf86-video-apm''' Alliance ProMotion video driver<br />
*'''xf86-video-ark''' ark video driver<br />
*'''xf86-video-ati''' ati video driver<br />
*'''xf86-video-chips''' Chips and Technologies video driver<br />
*'''xf86-video-cirrus''' Cirrus Logic video driver<br />
*'''xf86-video-dummy''' dummy video driver<br />
*'''xf86-video-fbdev''' framebuffer video driver<br />
*'''xf86-video-glint''' GLINT/Permedia video driver<br />
*'''xf86-video-i128''' Number 0 i128 video driver<br />
*'''xf86-video-i740''' Intel i740 video driver<br />
*'''xf86-video-i810''' Intel i810/i830/i9xx video drivers (deprecated - use -intel)<br />
*'''xf86-video-intel''' Newer Version of Intel i810/i830/i9xx video drivers<br />
*'''xf86-video-imstt''' Integrated Micro Solutions Twin Turbo vidoe driver<br />
*'''xf86-video-mga''' mga video driver (Matrox Graphics Adapter)<br />
*'''xf86-video-neomagic''' neomagic video driver<br />
*'''xf86-video-nv''' nvidia nv video driver<br />
*'''xf86-video-rendition''' Rendition video driver<br />
*'''xf86-video-s3''' S3 video driver<br />
*'''xf86-video-s3virge''' S3 Virge video driver<br />
*'''xf86-video-savage''' savage video driver<br />
*'''xf86-video-siliconmotion''' siliconmotion video driver<br />
*'''xf86-video-sis''' SiS video driver<br />
*'''xf86-video-sisusb''' SiS USB video driver<br />
*'''xf86-video-tdfx''' tdfx video driver<br />
*'''xf86-video-trident''' Trident video driver<br />
*'''xf86-video-tseng''' tseng video driver<br />
*'''xf86-video-unichrome''' Unichrome video drivers<br />
*'''xf86-video-v4l''' v4l video driver<br />
*'''xf86-video-vesa''' vesa video driver<br />
*'''xf86-video-vga''' VGA 16 color video driver<br />
*'''xf86-video-via''' via video driver<br />
*'''xf86-video-vmware ''' vmware video driver<br />
*'''xf86-video-voodoo ''' voodoo video driver<br />
<br />
* Отмечу, что '''vesa''' драйвера являются самыми универсальными, и будут работать почти со всеми современными графическими чипсетами. Если вы не смогли найти подходящий драйвер, то уж vesa '''должна''' работать.<br />
<br />
*Если у Вас есть NVIDIA или видеоадаптер ATI, Вы можете установить проприетарных NVIDIA или ATI драйвер. '''Установка проприетарных видеодрайверов освещена в [[#Использование проприетарных графических драйверов (NVIDIA, ATI)|чуть ниже]].'''<br />
<br />
Используйте pacman для инсталляции подходящего видеодрайвера для вашей видеокарты:<br />
pacman -S xf86-video-savage<br />
(для драйвера от Savage)<br />
<br />
==Создание /etc/X11/xorg.conf==<br />
=====Что такое /etc/X11/xorg.conf?=====<br />
/etc/X11/xorg.conf это главный конфигурационный файл вашей '''X''' Window System, основа основ вашего '''G'''raphical '''U'''ser '''I'''nterface. Это текстовой файл, разбитый на секции и подсекции. Важными являются секции ''Files, InputDevice, Module, Monitor, Modes, Screen, Device, и ServerLayout''. Секции могут располагаться в любом порядке, может быть несколько секций одного типа, к примеру, если у вас более одного монитора или если у вашего ноутбука кроме мышки есть еще и тачпад. <br />
------<br />
По умолчанию, у вас не будет конфигурационного xorg-файла. В последних версиях xorg он не нужен, ''если'' автоопределение ''работает нормально'' и вам не нужно вручную включать такие штуки, как aiglx и тому подобное. <br />
<br />
''Большинство людей считают, что им все равно необходимо сгенерировать этот файл.''<br />
<br />
<br />
Опытные пользователи обычно желают вручную сгенерировать свой собственный xorg.conf. Вы так же можете использовать скрипт Xorg -configure для базовой конфигурации. Под root'ом исполните:<br />
Xorg -configure<br />
Будет создан конфиг-файл в /root/xorg.conf.new <br />
<br />
Для теста сервера, введите:<br />
X -config /root/xorg.conf.new<br />
'''X''' запустится. Вы получите на экране бело-черный мышиный курсор в виде буквы '''X''', который будет откликаться на движение мышки/тачпада. Используйте CTRL-Alt-Backspace дабы покинуть '''X'''.<br />
<br />
Просмотр вашего конфиг-файла на предмет ошибок:<br />
<br />
nano /root/xorg.conf.new<br />
<br />
Убедитесь, что скрипт Xorg -configure корректно определил ваш видеодрайвер. к примеру:<br />
Section "Device"<br />
<br />
...<br />
<br />
Driver "vesa"<br />
VendorName "VM Ware Inc" #если вы запускаете ArchLinux в эмуляторе VM Ware<br />
<br />
...<br />
<br />
EndSection<br />
<br />
Убедитесь, что горизонтальная синхронизация и вертикальная частота обновления заданы под секцией "Monitor". Если нет, то задайте их:<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
VendorName "Monitor Vendor"<br />
ModelName "Monitor Model"<br />
HorizSync 30.0 - 130.0 # Подходит для большиства LCD мониторов<br />
VertRefresh 50.0 - 100.0 # Подходит для большинства LCD и CRT мониторов.<br />
EndSection<br />
(Если вы точно не знаете этих настроек, откройте инструкцию от вашего монитора.)<br />
<br />
Задайте глубину цвета под секцией "Screen":<br />
Section "Screen"<br />
Identifier "Screen0"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
(Значит, что мы установили 24битный цвет, что соотвествует true color (миллионы цветов)<br />
<br />
Также, добавьте желаемые режимы в подсекцию "Display" , в конце, под Depth 24 , к примеру:<br />
SubSection "Display"<br />
Viewport 0 0<br />
Depth 24<br />
Modes "1024x768" "800x600" "640x480"<br />
Добавьте следующий раздел, если Вы желаете включить eye candy, который требует дополнительного расширения: <br />
Section "Extensions"<br />
Option "Composite" "Enable"<br />
EndSection<br />
Испытайте ваш конфиг снова, после изменения:<br />
X -config /root/xorg.conf.new<br />
Убедитесь, что сессия '''X''' открылась без ошибок и переместите сгенерированный конфиг-файл в /etc/X11/:<br />
mv /root/xorg.conf.new /etc/X11/xorg.conf<br />
Подробные инструкции смотрите в статье [[Xorg]].<br />
<br />
====Alternative xorg.conf generation====<br />
If Xorg -configure is not generating a usable xorg.conf, you may alternatively use the hwd tool. Install with:<br />
pacman -S hwd<br />
And run with<br />
hwd -xa <br />
Lastly, you may choose xorgconfig, which will interactively prompt you for hardware information to create a basic xorg.conf:<br />
xorgconfig<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
===Using proprietary Graphics Driver (NVIDIA, ATI)===<br />
You may choose to use the proprietary video drivers from NVIDIA or ATI. <br />
====NVIDIA Graphic Cards====<br />
The NVIDIA proprietary drivers are generally considered to be of good quality, and offer 3D performance, whereas the open source '''nv''' driver offers only 2d support at this time. <br />
<br />
Before you configure your Graphics Card you will need to know which driver fits. Arch currently has 3 different driver packages that each match a certain subset of Cards: <br />
<br />
'''1. nvidia-71xx''' ''for very old Cards like TNT and TNT2''<br />
<br />
'''2. nvidia-96xx''' ''slightly newer cards up to the GF 4''<br />
<br />
'''3. nvidia''' ''newest GPUs after the GF 4''<br />
<br />
Consult the NVIDIA-Homepage to see which one is for you. The difference is only for the installation; Configuration works the same with every driver.<br />
<br />
Select and install the appropriate NVIDIA driver ''for your card'', e.g.: <br />
pacman -S nvidia-96xx<br />
<br />
The NVIDIA package has a utility for updating your existing /etc/X11/xorg.conf for use with the NVIDIA driver:<br />
nvidia-xconfig<br />
<br />
It also has several options which will further specify the contents and options of the xorg.conf file.<br />
For example,<br />
nvidia-xconfig --composite --add-argb-glx-visuals<br />
<br />
For more detailed information, see nvidia-xconfig(1).<br />
<br />
Some useful tweaking options in the device section are (beware that these may not work on your system):<br />
Option "RenderAccel" "true"<br />
Option "NoLogo" "true"<br />
Option "AGPFastWrite" "true"<br />
Option "EnablePageFlip" "true"<br />
Make sure all instances of DRI are commented out:<br />
# Load "dri"<br />
Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
Update kernel module dependencies:<br />
depmod -a<br />
<br />
Advanced instructions for nvidia configuration can be found in the [[NVIDIA]] article.<br />
<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
====ATI Graphic Cards====<br />
ATI owners have two options for drivers. If you are unsure which driver to use, please try the open-source one first. The open-source driver will suit most needs along with being generally less problematic.<br />
<br />
Install the '''proprietary''' ATI Driver with<br />
pacman -S catalyst<br />
Use the aticonfig tool to modify the xorg.conf.<br />
<br />
Install the '''open-source''' ATI Driver with<br />
pacman -S xf86-video-ati<br />
Currently, the performance of the open-source driver is not on par with that of the proprietary one. It also lacks TV-out, dual-link DVI support, and possibly other features. On the other hand, it supports Aiglx and has better dual-head support.<br />
{{Box Note| The latest proprietary driver does support [[AIGLX]] now. To use [[Compiz]] or [[Beryl]] add Option "AIGLX" "True" to Section ServerFlags and Option "Composite" "True" to Section Extensions.}}<br />
Advanced instructions for ATI configuration can be found in the [[ATI | ATI wiki]].<br />
<br />
===Simple baseline X test===<br />
<br />
At this point, you should have xorg installed, with a suitable video driver and an /etc/X11/xorg.conf configuration file. If you want to test your configuration quickly, to ensure your ability to start '''X''' from the command line before installing a complete desktop environment, you can do so by invoking '''xterm'''. Xterm is a very simple terminal emulator which runs in the '''X '''Server environment; it is installed as part of the base xorg packages.<br />
<br />
Prepare for the test by configuring a ~/.xinitrc:<br />
<br />
===== ~/.xinitrc =====<br />
This file dictates what '''X''' Window client is invoked with the '''startx''' and/or '''xinit''' command ''on a per-user basis''. (The '''startx''' script is merely a front end to the more versatile '''xinit''' command.) <br />
<br />
To determine the client to run, '''startx/xinit''' will first look for a .xinitrc file in the user's home directory. In the absence of file ~/.xinitrc, it defaults to the global xinitrc in the xinit library directory; /etc/X11/xinit/xinitrc, which defaults to using the TWM window manager. (Hence, if you invoke startx without a ~/.xinitrc file, a TWM session will start.)<br />
<br />
Switch to your '''''normal, non-root''''' user:<br />
su yourusername<br />
* /etc/skel/ contains files and directories to provide sane defaults for newly created user accounts. The name '''skel''' is derived from the word '''skeleton''', because the files it contains form the basic structure for users' home directories.<br />
Copy the sample xinitrc file from /etc/skel/ to your home directory: <br />
<br />
cp /etc/skel/.xinitrc ~/<br />
Edit the file: <br />
nano ~/.xinitrc<br />
and add:<br />
<br />
exec xterm<br />
<br />
So that it looks like this:<br />
<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
#<br />
exec xterm<br />
# exec wmaker<br />
# exec startkde<br />
# exec icewm<br />
# exec blackbox<br />
# exec fluxbox<br />
<br />
''Be sure to have only one uncommented '''exec''' line in your ~/.xinitrc at this time''. Below, we shall edit this file again to specify the appropriate desktop environment/window manager of your choice.<br />
<br />
Start '''X''' Server as '''normal, non-root''' user, with:<br />
<br />
startx<br />
or<br />
xinit<br />
You should have an '''xterm''' session open up. You can exit the '''X''' Server with Ctrl+Alt+Backspace, or by typing "exit". If you have problems starting '''X''', you can look for errors in the /var/log/Xorg.0.log file and on the console output of the console you started '''X''' from.<br />
<br />
If you prove a properly configured /etc/X11/xorg.conf by successfully running the test, you can be assured that your DE/WM of choice will work smoothly.<br />
<br />
Advanced instructions for Xorg configuration can be found in the [[Xorg]] article.<br />
<br />
==Part III: Installing and configuring a Desktop Environment ==<br />
While The '''X''' Window System provides the basic framework for building a ''graphical user interface'' (GUI), a '''Desktop Environment''' (DE), works atop and in conjunction with '''X''', to provide a completely functional and dynamic GUI. A DE typically provides icons, applets, windows, toolbars, folders, wallpapers, applications and abilities like drag and drop. The particular functionalities and designs of each DE will uniquely affect your overall environment and experience. Therefore, choosing a DE is a very subjective and personal decision. Choose the best environment for ''your'' needs.<br />
<br />
* If you want something full-featured and similar to Windows and Mac OSX, '''[[#KDE|KDE]]''' is a good choice<br />
* If you want something slightly more minimalist, which follows the K.I.S.S. principle more closely, '''[[#GNOME|GNOME]]''' is a good choice<br />
* '''[[#Xfce|Xfce]]''' is generally perceived as similar to GNOME, but lighter and less demanding on system resources, yet still visually pleasing and providing a very complete environment.<br />
<br />
If you have an older machine, or desire a lighter, less demanding GUI, you may choose to simply install a '''Window Manager''', or WM. A WM controls the placement and appearance of application windows in conjunction with the X Window System but does NOT provide such additions as panels, applets, icons, applications, etc.<br />
* Lightweight WM's include: '''Openbox, Fluxbox, fvwm2''', '''Windowmaker, Awesome and TWM'''.<br />
* If you need something completely different, try '''ion, wmii, dwm, or xmonad'''.<br />
<br />
===Install Fonts===<br />
At this point, you may want to install some good-looking fonts, '''before''' installing a desktop environment/window manager, (so you don't have to stare at ugly bitmap fonts in X). Dejavu and bitstream-vera are nice font sets. For websites, you may want to have the Microsoft fonts too. Install with:<br />
pacman -S ttf-ms-fonts ttf-dejavu ttf-bitstream-vera<br />
<br />
===~/.xinitrc (again)===<br />
<br />
As '''non-root user''', edit your /home/username/.xinitrc to utilize the DE you wish to use. This will allow you to use '''startx/xinit''' from the shell to open your DE/WM of choice:<br />
<br />
nano ~/.xinitrc<br />
<br />
Uncomment or add the ''''exec''' ..' line of the appropriate desktop environment/window manager. Some examples are below.<br />
<br />
For the Xfce4 desktop environment:<br />
exec startxfce4 <br />
<br />
For the KDE desktop environment:<br />
exec startkde<br />
A '''startkde''' or '''startxfce4''' command starts the KDE or Xfce4 desktop environment. This command does not finish until you logout of the DE. Normally the shell would wait for KDE to finish, then run the next command. The "exec" prefix to this command tells the shell that this is the last command, so the shell does not need to wait to run a subsequent command.<br />
<br />
Remember to have only one uncommented '''exec''' line in your ~/.xinitrc for now. <br />
<br />
Continue below, installing the DE/WM of your choice.<br />
<br />
===GNOME===<br />
====О проекте GNOME====<br />
'''G'''NU '''N'''etwork '''O'''bject '''M'''odel '''E'''nvironment. Проект GNOME сочетает в себе две вещи: интуитивно-понятное и приятное окружение рабочего стола, а также платформу для разработки, позволяющую создавать полностью интегрированные между собой и остальным окружением приложения.<br />
<br />
<br />
====Установка====<br />
Установить базовый набор пакетов GNOME можно следующей командой:<br />
pacman -S gnome<br />
<br />
Рекомендуется установить пакет gnome-utils, в котором в частности содержится пакет, позволяющий делать скриншоты нажатием клавиши Print Screen :<br />
pacman -S gnome-utils<br />
<br />
Дополнительные пакеты (эмулятор терминала, текстовый редактор и т.д.) находятся в группе gnome-extra:<br />
pacman -S gnome-extra<br />
<br />
=====Полезные демоны для GNOME=====<br />
Демон - это исполняемая в фоне программа, которая дожидается определенных событий и обрабатывает их. Демон '''hal''', кроме всего прочего, автоматизирует монтирование жестких дисков, оптических приводов и флэш-накопителей. Демон '''fam''' обрабатывает изменения в структуре данных файловой системы, позволяя в реальном времени отслеживать изменения в файлах или директориях. Оба этих демона позволяют сильно упростить работу с окружением. Они устанавливаются при установке GNOME, но должны быть запущены для начала работы:<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
<br />
В качестве менеджера сессий хорошим выбором будет '''gdm'''.<br />
<br />
Установка:<br />
pacman -S gdm<br />
<br />
Для запуска этих демонов при загрузке, следует добавить их в секцию DAEMONS конфигурационного файла /etc/rc.conf :<br />
nano /etc/rc.conf<br />
<br />
DAEMONS=(syslog-ng network crond alsa '''hal fam gdm''')<br />
<br />
Демон gdm автоматически загружает графическую среду. Если вы попробуете её покинуть, используя ctrl+alt+backspace, он снова её загрузит. Если в этого не хотите, а хотите загружать граф.среду вручную, то ставьте в файле rc.conf перед именем этого демона (gdm) восклицательный знак (!). <br />
<br />
Чтобы запустить графическое окружение выполните:<br />
startx<br />
Если файл ~/.xinitrc не настроен для запуска GNOME, то окружение можно запустить командой xinit:<br />
xinit /usr/bin/gnome-session<br />
<br />
Дополнительные инструкции по установке и настройке могут быть найдены в статье [[GNOME_(Русский)|GNOME]].<br />
<br />
Поздравляем! Добро пожаловать в среду GNOME на вашей свежеустановленной системе Arch Linux! Также вы можете захотеть узнать о '''[[#Tweaks/Finishing touches|дополнительных настройках]]'''. Рекомендуется прочитать [[Post Installation Tips|советы]] после окончания установки и настройки.<br />
<br />
====Украшения====<br />
Вы можете захотеть поменять стандартную тему графического окружения. В данном случае, хорошим выбором будет тема "murrine".<br />
Установить можно следующей командой:<br />
pacman -S gtk-engine-murrine<br />
А затем выбрать данную тему в меню Система->Параметры->Внешний вид. Найти больше разнообразных тем оформления, наборов значков, фоновых изображений и т.п., вы можете на сайте [http://www.gnome-look.org Gnome Look].<br />
<br />
===KDE===<br />
====О KDE====<br />
'''K''' '''D'''esktop '''E'''nvironment. KDE - это мощное свободное окружение рабочего стола для рабочих станций GNU/Linux и <code>UNIX</code>. KDE сочетает лёгкость в использовании, современную функциональность и выдающийся графический дизайн с технологическим превосходством UNIX-подобных операционных систем.<br />
<br />
====Установка====<br />
Arch предлагает несколько вариантов kde: '''kde, kdebase, и KDEmod'''. Выберите '''один''' из представленных ниже, и продолжите дальше с '''[[#Useful KDE DAEMONS|Useful KDE DAEMONS]]''': <br />
<br />
'''1.)''' Пакет '''kde''' это полный, стандартнй KDE, ~300MB.<br />
pacman -S kde<br />
'''2.)''' Пакет '''kdebase''' это урезанная версия с меньшим количеством приложений, ~80MB.<br />
pacman -S kdebase<br />
'''3.)''' Наконец, '''KDEmod''' - это эксклюзив для Arch Linux, созданный по инициативе сообщества, которое модифицировало KDE для максимальной производительности и модульности. Веб-сайт проекта KDEmod может быть найден на [http://kdemod.ath.cx/ http://kdemod.ath.cx/]. KDEmod очень быстрый, легкий и гибкий, с приятной, собственной темой оформления<br />
<br />
====Useful KDE DAEMONS====<br />
<br />
KDE will require the '''hal''' ('''H'''ardware '''A'''bstraction '''L'''ayer) and '''fam''' ('''F'''ile '''A'''lteration '''M'''onitor) daemons. The '''kdm''' daemon is the '''K''' '''D'''isplay '''M'''anager, which provides a '''graphical login''', if desired.<br />
<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system.. Both '''hal''' and '''fam''' make life easier for the KDE user. The hal, fam and kdm packages are installed when you install KDE, but must be invoked to become useful.<br />
-----<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup. If you prefer a graphical login, add '''kdm''' as well: <br />
DAEMONS=(syslog-ng network crond alsa '''hal fam kdm''')<br />
*This method will start the system at runlevel 3, (/etc/inittab default, multiuser mode), and then start KDM as a daemon. <br />
<br />
*Some users prefer an alternative method of starting a display manager like KDM on bootup by utilizing the /etc/inittab method and starting the system at runlevel 5. See [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]] for more.<br />
<br />
*If you prefer to log into the '''console''' at runlevel 3, and manually start X in the 'Slackware tradition', leave out kdm, or comment it out with an exclamation. ( ! )<br />
<br />
Now try starting your X Server as normal user:<br />
startx<br />
Advanced instructions for installing and configuring KDE can be found in the [[KDE]] article.<br />
<br />
Congratulations! Welcome to your KDE desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===Xfce===<br />
====About Xfce====<br />
The cholesterol-free '''X''' environment. Xfce, like GNOME or KDE, is a desktop environment, but aims to be fast and lightweight while remaining visually appealing and easy to use. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit (like GNOME) and contains its own development environment (libraries, daemons, etc) similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and extremely fast. Xfce is great for older hardware, and will fly with especially great speed on newer machines as well.<br />
<br />
====Installation====<br />
Install Xfce: <br />
pacman -S xfce4 <br />
You may also wish to install themes and extras:<br />
pacman -S xfce4-goodies gtk2-themes-collection<br />
If you want to admire 'Tips and Tricks' on login, you must install the '''fortune-mod''' package:<br />
pacman -S fortune-mod <br />
====Useful DAEMONS====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. The hal and fam packages are installed when you install Xfce, but must be invoked to become useful.<br />
<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup.<br />
<br />
Advanced instructions for installing and configuring Xfce can be found in the [[Xfce]] article.<br />
<br />
If you wish to install one, see [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]]<br />
<br />
Congratulations! Welcome to your Xfce desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===*box===<br />
====Fluxbox====<br />
Fluxbox © is yet another windowmanager for X.<br />
It's based on the Blackbox 0.61.1 code. Fluxbox looks like blackbox and handles styles, colors, window placement and similar things exactly like blackbox (100% theme/style compability).<br />
<br />
Install Fluxbox using <br />
pacman -S fluxbox fluxconf<br />
<br />
If you use gdm/kdm a new fluxbox session will be automatically added. Otherwise, you should modify your user's .xinitrc and add this to it:<br />
exec startfluxbox <br />
<br />
More information is available in the [[Fluxbox]] article.<br />
<br />
====Openbox====<br />
Openbox is a standards compliant, fast, light-weight, extensible window manager.<br />
<br />
Openbox works with your applications, and makes your desktop easier to manage. This is because the approach to its development was the opposite of what seems to be the general case for window managers. Openbox was written first to comply with standards and to work properly. Only when that was in place did the team turn to the visual interface.<br />
<br />
Openbox is fully functional as a stand-alone working environment, or can be used as a drop-in replacement for the default window manager in the GNOME or KDE desktop environments. <br />
<br />
Install openbox using<br />
pacman -S openbox obconf obmenu<br />
<br />
Once openbox is installed you will get a message to move menu.xml & rc.xml to ~/.config/openbox/ in your home directory:<br />
<br />
mkdir -p ~/.config/openbox/<br />
cp /etc/xdg/openbox/rc.xml ~/.config/openbox/<br />
cp /etc/xdg/openbox/menu.xml ~/.config/openbox/<br />
<br />
In the file "rc.xml" you can change various settings for Openbox (or you can use OBconf). In "menu.xml" you can change your right-click menu.<br />
<br />
To be able to log into openbox you can either go via graphical login using KDM/GDM or startx, in which case you will need to edit your ~/.xinitrc (as user) and add the following:<br />
<br />
exec openbox<br />
You may also start openbox from the shell using '''xinit''':<br />
xinit /usr/bin/openbox-session<br />
* Openbox may also be used as the window manager for GNOME, KDE, and Xfce.<br />
For KDM there is nothing left to do; openbox is listed in the sessions menu in KDM.<br />
<br />
Useful programs for openbox are:<br />
* PyPanel or LXpanel if you want a panel<br />
* feh if you want to set the background<br />
* ROX if you want a simple file manager and desktop icons<br />
<br />
More information is available in the [[Openbox]] article.<br />
<br />
===fvwm2===<br />
FVWM is an extremely powerful ICCCM-compliant multiple virtual desktop window manager for the X Window system. Development is active, and support is excellent. <br />
<br />
Install fvwm2 with<br />
pacman -S fvwm <br />
<br />
fvwm will automatically be listed in kdm/gdm in the sessions menu. Otherwise, add <br />
exec fvwm <br />
<br />
to your user's .xinitrc.<br />
<br />
Note that this stable version of fvwm is a few years old. If you want a more recent version of fvwm, there is a fvwm-devel package in the unstable repo.<br />
<br />
=APPENDIX=<br />
==Tweaks/Finishing touches==<br />
===Install [http://archlinux.fr/yaourt-en# Yaourt]===<br />
'''Y'''et '''A'''n'''O'''ther '''U'''ser '''R'''epository '''T'''ool. Yaourt is a community-contributed wrapper for pacman which adds seamless access to the [[AUR]], allowing and automating package compilation and installation from your choice of the 8000+ PKGBUILDs in the [[AUR]], in addition to the many thousands of available Arch binary packages. Yaourt uses the same exact syntax as pacman, which saves you from relearning an entirely new method of system maintenance, but also adds new options. Yaourt expands the power and simplicity of pacman by adding even more useful features and provides pleasing, colorized output, interactive search mode, and much more. You will almost certainly want this. <br />
<br />
The easiest way to install Yaourt is to add the yaourt repository to your /etc/pacman.conf:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/i686<br />
for i686 or:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/x86_64<br />
for x86-64.<br />
<br />
Sync and install:<br />
pacman -Sy yaourt<br />
<br />
If you wish, you may then create your own command aliases in ~/.bashrc to save typing: <br />
nano ~/.bashrc<br />
<br />
alias p="pacman"<br />
alias y="yaourt" <br />
Save and then source:<br />
source ~/.bashrc<br />
See the [http://archlinux.fr/yaourt-en# yaourt] man page for more.<br />
<br />
===HAL===<br />
Since you have now installed a desktop environment, and if you did not do so earlier, now would be a good time to also install HAL. HAL allows plug-and-play for your mobile phone, your iPod, your external HD's, etc. It will mount the device and make a nice visual icon on your desktop and/or in 'My Computer', allowing you to access the device after you have plugged it in instead of having to manually configure the /etc/fstab file or udev rules for each and every new device.<br />
<br />
KDE, GNOME and XFCE all use HAL.<br />
<br />
The installation procedure is described in the [[HAL]] article. Some information can also be found at [http://en.wikipedia.org/wiki/HAL_(software) Wikipedia].<br />
<br />
===Backgrounding DAEMONS on startup===<br />
<br />
To speed up system start up procedure, background selected DAEMONS in /etc/rc.conf by prefixing them with a '@' e.g.:<br />
<br />
DAEMONS=(syslog-ng @network crond @alsa @hal @fam @kdm)<br />
This will enable daemons to load in the background, without waiting for the preceding daemon to load first.<br />
<br />
Prefix any daemons which you do not need with a bang (!) e.g.:<br />
<br />
DAEMONS=(syslog-ng @network !netfs !crond @alsa @hal @fam @kdm)<br />
<br />
Alternatively, you may also simply remove unneeded daemons.<br />
<br />
===Beautifying Fonts for LCD's===<br />
See [[Fonts]]<br />
<br />
===Adjusting Mouse for scroll wheel===<br />
While your mouse should be working out of the box, you may want to use your scroll wheel. Add this to your Input Section (mouse0):<br />
Option "ZAxisMapping" "4 5 6 7"<br />
<br />
===Get All Mouse Buttons Working===<br />
See [[Get All Mouse Buttons Working]]<br />
<br />
===Configuring Touchpad for Laptops===<br />
See [[Touchpad Synaptics]]<br />
<br />
===Adjusting Keyboard Layout===<br />
You may want to change your keyboard layout. To do this edit your /etc/X11/xorg.conf and add these lines in the InputDevice Section (Keyboard0) (the example shows a German keyboard layout with no dead keys; alter this to fit your needs).<br />
Option "XkbLayout" "de"<br />
Option "XkbVariant" "nodeadkeys"<br />
<br />
===Additional tweaks for laptops===<br />
ACPI support is needed if you want to use some special functions on your notebook (e.g. sleep, sleep when lid is closed, special keys...). Install <tt>acpid</tt> using<br />
pacman -S acpid<br />
and add it to the daemons in /etc/rc.conf. <tt>acpid</tt> should be started before <tt>hal</tt> and <tt>dbus</tt>, so take care to place it before any calls to hal and dbus. Manually, it can be started by<br />
/etc/rc.d/acpid start<br />
<br />
More-specific information about Arch Linux on various Laptops can be found at [[:Category:Laptops (English)]]<br />
<br />
===Configuring CPU frequency scaling===<br />
Modern processors can decrease their frequency and voltage to reduce heat and power consumption. Less heat leads to a quieter system; Laptop users will definitely want this, but even a desktop system will benefit from it. Install cpufrequtils with<br />
pacman -S cpufrequtils<br />
Edit the config file /etc/conf.d/cpufreq and change <br />
governor="ondemand"<br />
which dynamically increases the CPU frequency if needed (which is a safe choice on desktop systems too). Alter min_freq and max_freq to match your system's CPU spec. If you don't know the frequencies, run ''cpufreq-info'' after loading one of the frequency scaling modules. You can also comment out or delete the min_freq and max_freq lines: things will work automatically. Add the frequency scaling modules to your /etc/rc.conf modules line. Most modern notebooks and desktops can simply use the ''acpi-cpufreq'' driver, however other options include the ''p4-clockmod, powernow-k6, powernow-k7, powernow-k8, and speedstep-centrino'' drivers. Load the module with<br />
modprobe <modulname> <br />
and start cpufreq with<br />
/etc/rc.d/cpufreq start<br />
For more details, see [[Cpufrequtils]]<br />
<br />
===Pm-Utils===<br />
The pm-utils package will allow you to suspend-to-RAM and hibernate: <br />
pacman -S pm-utils<br />
[[Pm-utils]] wiki page.<br />
<br />
===Laptop-Mode===<br />
The laptop-mode-tools package is sort of a one-stop configuration for all laptop power management utilities. It works in conjunction with other installed tools to fully configure everything from hard disk spin-down to X display DPMS standby times, if desired.<br />
pacman -S laptop-mode-tools<br />
Add laptop-mode to your DAEMONS= line in /etc/rc.conf and configure /etc/laptop-mode/laptop-mode.conf.<br />
<br />
==File and directory explanation==<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, (as dictated by BIOS) just like the sda, sdb, etc.<br />
names in /dev. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 corresponding to the first entity. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding. <br />
<br />
{{ Box Note | The first appearance of 'root (hdx,x)' may be misleading. The '''root''' command is specifying '''''GRUB''''''s root, which corresponds to ''where the kernel resides, i.e. '''/boot'''''. Ensure that the drive and partition are correct, since '''''/boot''', does not necessarily share the same partition as the root filesystem, or /''.}}<br />
<br />
Once you have grasped the concept of device naming, choose a title for your boot section(s), create a kernel line that includes the partition and path to where the kernel resides, and supply the correct root filesystem device and partition as a parameter to the kernel root option to have it mounted as / on bootup, 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 to the initramfs on the initrd line will be the same as<br />
the path to vmlinuz26 that you provide on the kernel line, since both reside under /boot. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines.<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 />
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 also globally defines PS1, $PATH, bash aliases, etc. It is kept quite simple under Arch Linux, as most things are. You may wish 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 runlevels. 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 mounting filesystems, running udev, activating swap, loading modules, setting localization parameters, etc. You will most likely never need 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 started in single-user mode, for example with the kernel parameter 1 before booting or during normal multi-user operation with the command init 1, this script makes sure no daemons are running except for the bare minimum; syslog-ng and udev. The single-user mode is useful if you need to make any changes to the system while making sure that no remote user can do anything that might cause data loss or damage. <br />
For desktop users, this mode is usually quite useless. You should most likely have no need to edit this script.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the DAEMONS array (set in /etc/rc.conf) after which it calls /etc/rc.local. You shouldn't feel a pressing need to edit this file. <br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any last-minute commands you want the system to run at the very end of the bootup process. This is finally the one and only script you should modify if needed, and you have total freedom on what to add to this script. Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place where they belong. To avoid confusion, you should make sure that whatever you intend to add to your rc.local isn't feeling just as home in /etc/profile.d/ or any other already existant config location instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems, deactivates the swap, etc. <br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any commands you want to run right before the common rc.shutdown is executed. Please note that this file does not exist by default, and 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 rc.conf's DAEMONS= array. In addition to being called on bootup, you can use these scripts when the system is running to manage the services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. This directory is not in the $PATH by default, but may be added for convenience. Obviously a corresponding daemon script only exists when the appropriate package has been installed (in this case postfix). With a base system install, you don't have many scripts in here, but rest assured that all relevant daemon scripts end up here. If you wish, you can, of course, create your own scripts and place them here, to be called by the DAEMONS= array in /etc/rc.conf on system startup. <br />
<br />
This directory is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/ directories of other distributions, but without all the symlink hassle. The lack of symlink requirement is a defining difference of a *BSD-style init framework, vs a sysvinit.<br />
<br />
==Useful Applications==<br />
This section will never be complete. It just shows some good applications for the everyday user. <br />
<br />
'''KDE users NOTE''': Since KDE resides in /opt, you will most likely have to log out and in after initial installation to update your PATH before these programs can be used.<br />
===Internet===<br />
<br />
=====Firefox=====<br />
The ever-popular Firefox web browser is available through pacman, although it doesnt have its official branding, so the program appears when opened as Bon Echo. Install with:<br />
<br />
pacman -S firefox<br />
Be sure and install 'flashplugin', 'mplayer', 'mplayer-plugin', and the 'codecs' packages for a complete web experience:<br />
pacman -S flashplugin mplayer mplayer-plugin codecs<br />
(The codecs package contains codecs for Quicktime and Realplayer content.)<br />
<br />
Thunderbird is useful for managing your emails. If you are using GNOME you may want to take a look at Epiphany and Evolution; if you are using KDE Konqueror and KMail could be your choice. If you want something completely different you can still use Opera. Finally, if you are working on the system console - or in a terminal session - you could use various text-based browsers like ELinks, Links and Lynx, and manage your emails with [[Mutt]]. Pidgin (previously known as Gaim) and Kopete are good instant messengers for GNOME and KDE, respectively. PSI and Gajim are perfect if you are using only Jabber or Google Talk.<br />
<br />
===Office===<br />
OpenOffice is a complete office suite (similar to Microsoft Office). Abiword is a good, small alternative word processor, and Gnumeric an Excel replacement for the GNOME desktop. KOffice is a complete office suite for the KDE Desktop. GIMP (or GIMPShop) is a pixel-based graphics program (similar to Adobe Photoshop), while Inkscape is a vector-based graphics program (like Adobe Illustrator). And, of course, Arch comes with a full set of LaTeX Programs: tetex has been popular for many years and still works, and its successor [[Texlive]] is available from the [[AUR]] repository.<br />
<br />
==Multimedia ==<br />
<br />
<br />
===Video Player===<br />
====VLC====<br />
VLC Player is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S vlc<br />
<br />
(TODO) Instructions for VLC mozilla plug-in<br />
<br />
====Mplayer====<br />
MPlayer is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S mplayer<br />
<br />
It also has a Mozilla plug-in for videos and streams embedded in web pages. To install it, simply type the code below.<br />
<br />
pacman -S mplayer-plugin<br />
<br />
If you use KDE, KMplayer is a better choice. It comes with a plug-in for videos and streams embedded in web pages, which works with Konqueror. To install it, simply type the code below.<br />
<br />
pacman -S kmplayer<br />
<br />
(TODO) GMPlayer instructions<br />
<br />
====Xine====<br />
<br />
Xine is an excellent player, especially for DVDs.<br />
<br />
pacman -S xine-ui<br />
The libdvdcss library provides DVD decoding for encrypted DVDs. ''Ensure the legality of using libdvdcss in your country before installing!''<br />
pacman -S libdvdcss<br />
<br />
====GNOME====<br />
=====Totem=====<br />
[http://www.gnome.org/projects/totem/ Totem] is the official movie player of the GNOME desktop environment based on xine-lib or GStreamer (gstreamer is the default which installs with the arch totem package). It features a playlist, a full-screen mode, seek and volume controls, as well as keyboard navigation.<br />
It comes with added functionality such as:<br />
<br />
* Video thumbnailer for the file manager<br />
* Nautilus properties tab<br />
* Epiphany / Mozilla (Firefox) plugin to view movies inside your browser <br />
* Webcam utility (in development)<br />
<br />
Totem-xine is still the better choice if you want to watch DVDs.<br />
<br />
Totem is part of the gnome-extra group; the Totem webbrowser plugin isn't.<br />
<br />
To install separately:<br />
pacman -S totem<br />
<br />
To install the Totem webbrowser plugin:<br />
pacman -S totem-plugin<br />
<br />
====KDE====<br />
=====Kaffeine=====<br />
Kaffeine is a good option for KDE users. To install it, simply type the code below.<br />
<br />
pacman -S kaffeine<br />
<br />
===Audio Player===<br />
====Gnome/Xfce====<br />
=====Exaile=====<br />
[[Exaile]] is a music player written in Python that makes use of the GTK+ toolkit. It tries to be close to the popular Amarok, but in GTK. It is in [community], so install with:<br />
pacman -S exaile<br />
<br />
=====Rhythmbox=====<br />
[http://www.gnome.org/projects/rhythmbox/ Rhythmbox] is an integrated music management application, originally inspired by Apple's iTunes. It is free software, designed to work well under the GNOME Desktop, and based on the powerful GStreamer media framework.<br />
<br />
Rhythmbox has a number of features, including:<br />
<br />
* Easy-to-use music browser<br />
* Searching and sorting<br />
* Comprehensive audio format support through GStreamer<br />
* Internet radio support<br />
* Playlists<br />
<br />
To install rhythmbox:<br />
pacman -S rhythmbox<br />
<br />
=====Quod Libet=====<br />
[http://www.sacredchao.net/quodlibet Quod Libet] is a music manager that uses the GStreamer media framework to play audio files. This allows it to play all the file-types that Rhythmbox (which uses GStreamer too) can play. Quod Libet is more suited to non-Gnome desktops since it has a smaller footprint and fewer dependencies than Rhythmbox (Rhythmbox depends on nautilus, which requires a lot of GNOME to be installed).<br />
<br />
In addition to the music player/manager, Quod Libet also includes Ex Falso, a tag editor.<br />
<br />
Quod Libet's features include:<br />
<br />
* Easy-to-use music browser<br />
* Searching<br />
* Comprehensive audio format support through GStreamer<br />
* Easy Playlist management<br />
<br />
To install Quod Libet:<br />
pacman -S quodlibet<br />
<br />
Other good audio players are Banshee and Listen. See [http://gnomefiles.org/ Gnomefiles] to compare them.<br />
<br />
====KDE====<br />
=====Amarok=====<br />
[http://amarok.kde.org/ Amarok] is one of the best audio players and music library systems available for KDE. To install it, simply type the code below.<br />
<br />
pacman -S amarok-base<br />
<br />
====Console====<br />
[http://moc.daper.net/ Moc] is a ncurses-based audio player for the console; another good choice is [http://musicpd.org/ mpd].<br />
<br />
Another excellent choice is [http://freshmeat.net/projects/cmus/ cmus].<br />
<br />
====Other X-based====<br />
(TODO) Xmms, audacious, bmpx.<br />
<br />
===Codecs and other multimedia content types (i686 only) ===<br />
====DVD====<br />
You can use xine-ui, totem-xine, mplayer or kaffeine (just to name three of the big ones) to watch DVDs. The only thing you may miss is libdvdcss. Beware that using it may be illegal in some countries.<br />
<br />
====Flash====<br />
Install the flash plugin using<br />
pacman -S flashplugin<br />
to enable Macromedia (now Adobe) Flash in your browser, if you run KDE you should see this after installing flash. http://wiki.archlinux.org/index.php/Flash_and_Adobe_Acrobat_browser_plugins#Fixing_Flash_in_Konqueror<br />
<br />
====Quicktime====<br />
Quicktime codecs are contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them.<br />
====Realplayer====<br />
The codec for Realplayer 9 is contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them. Realplayer 10 is available as a binary package for Linux. You can get it from AUR [http://aur.archlinux.org/packages.php?do_Details=1&ID=1590&O=0&L=0&C=0&K=realplay&SB=&SO=&PP=25&do_MyPackages=0&do_Orphans=0&SeB=nd here].<br />
<br />
===CD and DVD Burning===<br />
====GNOME====<br />
=====Brasero=====<br />
[http://www.gnome.org/projects/brasero/ Brasero] is an application that burns CDs/DVDs for the GNOME Desktop. It is designed to be as simple as possible and has some unique features to enable users to create their discs easily and quickly.<br />
<br />
To install:<br />
pacman -S brasero<br />
<br />
====KDE====<br />
=====K3b=====<br />
K3b (from '''K'''DE '''B'''urn '''B'''aby '''B'''urn) is a free software CD and DVD authoring application for GNU/Linux and other <code>UNIX</code>-like operating systems designed for KDE. As is the case with most KDE applications, K3b is written in the C++ programming language and uses the Qt GUI toolkit. K3b provides a graphical user interface to perform most CD/DVD burning tasks like creating an Audio CD from a set of audio files or copying a CD/DVD, as well as more advanced tasks such as burning eMoviX CD/DVDs. It can also perform direct disc-to-disc copies. The program has many default settings which can be customized by more experienced users. The actual disc recording in K3b is done by the command line utilities cdrecord or wodim, cdrdao, and growisofs. As of version 1.0, K3b features a built-in DVD ripper.- licensed under the GPL.<br />
<br />
K3b was voted LinuxQuestions.org's Multimedia Utility of the Year (2006) by the majority (70%) of voters. <br />
-----<br />
To install:<br />
pacman -S k3b<br />
<br />
=====(Todo) cdrecord, graveman...=====<br />
<br />
<br />
<br />
<br />
Most CD burners are wrappers for cdrecord:<br />
<br />
pacman -S cdrkit<br />
<br />
If you install packages for CD/DVD burning applications like Brasero or K3B it also installs the CD/DVD burning library for it, like libburn or cdrkit.<br />
<br />
A good command-line DVD-burning tool is growisofs:<br />
<br />
pacman -S dvd+rw-tools<br />
<br />
===TV-Cards===<br />
<br />
There are several things to do if you want to watch TV under (Arch) Linux. The most important task is to find out which chip your tuner is using. However, quite a lot are supported. Be sure to check at a Hardware Database to be sure (see [http://en.opensuse.org/HCL/TV_Cards this list], for example). Once you know your Model, there are just a few steps ahead to get you going.<br />
<br />
In most cases, you will need to use the bttv-drivers (other drivers exist, like [http://linux.bytesex.org/v4l2/drivers.html V4L]) together with the I2C-modules. Configuring those is the hardest task. If you are lucky, a<br />
modprobe bttv<br />
will autodetect the card (check dmesg for results). In that case, you need only to install an application to watch TV. We will look at that later, though.<br />
If the autodetection did not work, you will need to check the file CARDLIST, which is included in the tarball of [http://dl.bytesex.org/releases/video4linux/ bttv] to find out the right parameters for your card. A PV951 without radio support would need this line:<br />
modprobe bttv card=42 radio=0<br />
Some cards need the following line to produce sound:<br />
modprobe tvaudio<br />
However, that varies. So just try it out. Some other cards demand the following line:<br />
modprobe tuner<br />
This is subject to trial-and-error, too.<br />
<br />
TODO: clarify the installation-procedure<br />
<br />
To actually watch TV, install the xawtv-package with<br />
pacman -S xawtv <br />
and read its manpage.<br />
<br />
TODO: clarify some possible problems and procedures. Introduction to XAWTV on another page?<br />
<br />
===Digital Cameras===<br />
Most newer digital cameras are supported as USB mass storage devices, which means that you can simply plug it in and copy the images. Older cameras may use the PTP (Picture Transfer Protocol) which requires a "special driver". gPhoto2 provides this driver and allows a shell-based transfer of the images; digikam (for KDE) and gthumb (for GNOME, gtkam would be another choice) use this driver and offer a nice GUI.<br />
<br />
===USB Memory Sticks / Hard Disks===<br />
USB Memory Sticks and hard disks are supported out of the box with the USB mass storage device driver and will appear as a new SCSI device (/dev/sdX). If you are using KDE or GNOME you should use dbus and hal (add them to your daemons in /etc/rc.conf), and they will be automatically mounted. If you use a different Desktop Environment you may have a look at ivman.<br />
<br />
==Maintaining the system==<br />
===Pacman===<br />
[[Pacman]] is both a binary and source package manager which is able to download, install, and upgrade packages from both remote and local repositories with full dependency handling, and has easy-to-understand tools for crafting your own packages too.<br />
<br />
A more-detailed description of Pacman can be found in [[Pacman|its article]].<br />
<br />
====Useful commands====<br />
To view the options available for a particular operational command, say '''-Q''', just append it with '''-h''':<br />
pacman -Qh<br />
<br />
To synchronize and update the local packages database with the remote repositories (it is a good idea to do this before installing and upgrading packages):<br />
pacman -Sy<br />
<br />
To '''upgrade''' all packages on the system:<br />
pacman -Su<br />
<br />
To sync, update, and '''upgrade''' all the packages on the system with one command:<br />
pacman -Syu<br />
<br />
To install or upgrade a single package or list of packages (including dependencies):<br />
pacman -S packageA packageB<br />
<br />
You can also sync, update the package database, and install packages in one command:<br />
pacman -Sy packageA packageB<br />
<br />
To remove a single package, leaving all of its dependencies installed:<br />
pacman -R package<br />
<br />
To remove a package and all of the package's dependencies which aren't used by any other installed package:<br />
pacman -Rs package<br />
('''-Rs''' is typically preferred vs '''R''' to remove any package as it will clean up all unused dependencies)<br />
<br />
To remove all of the package's now unneeded dependencies and also instruct pacman to ignore file backup designations. (Normally, when a file is removed from the system the database is checked to see if the file should be renamed with a ".pacsave" extension.):<br />
pacman -Rsn package<br />
<br />
To search the remote (repo) package database for a list of packages matching a given keyword:<br />
pacman -Ss keyword<br />
<br />
To list all packages on your system<br />
pacman -Q<br />
<br />
To list all packages on your system without the version strings, we add the '''-q''' option:<br />
pacman -Qq<br />
<br />
To search (query) the local (your machine) package database for a given package:<br />
pacman -Q package <br />
<br />
To search (query) the local (your machine) package database for a given package and list all pertinent information:<br />
pacman -Qi package<br />
<br />
To list all files installed by a given ''package'':<br />
<tt>pacman -Ql ''package''</tt><br />
Conversely, to find the package that owns a given file (in this example, the ''ls'' executable):<br />
<tt>pacman -Qo /bin/ls</tt><br />
To find all unused packages (orphans):<br />
pacman -Qdt<br />
Missing libraries: Suppose you receive an error message like this:<br />
<tt>mplayer: error while loading shared libraries: ''libgssapi.so.2'': cannot open shared object file: No such file or directory</tt><br />
This may be an indication that a package you have previously installed is now corrupt (some or all of its files are missing). You should try to find the package name that provides the missing shared library. In this example, you could type:<br />
<tt>pacman -Ql | grep ''libgssapi.so.2''</tt><br />
The first column in the output is the package name:<br />
<tt>heimdal /usr/lib/libgssapi.so.2<br />
heimdal /usr/lib/libgssapi.so.2.0.0<br />
</tt><br />
Then, you can just re-install it:<br />
<tt>pacman -Sy heimdal</tt><br />
<br />
To defragment pacman's cache database and optimize for speed:<br />
pacman-optimize<br />
<br />
To count how many packages are currently on your system:<br />
pacman -Q | wc -l<br />
<br />
To install a package compiled from source using ABS and makepkg:<br />
pacman -U packagename.pkg.tar.gz<br />
<br />
Note: There are countless additional pacman functions and commands. Try man pacman and consult the [[pacman]] wiki entries.<br />
<br />
====Files====<br />
There are a number of files left and created by pacman and other programs to facilitate maintenance and to conform to a safe computing practice. When pacman is installing something, the package contains information on whether to back up a particular file. Such files will have the '''.pacsave''' extension. When you force a "NoUpgrade" on a file via [http://www.archlinux.org/pacman/pacman.conf.5.html pacman.conf], it will not be replaced during an upgrade and the new file will come with the '''.pacnew''' extension. For example, you have edited a configuration file thoroughly and you do not want an upgrade of the respective package to replace the file with a new one, we must have the following line in '''/etc/pacman.conf''':<br />
NoUpgrade = /path/to/config/file<br />
To view the differences of the old and new versions of these files, we can either edit them manually or use a '''diff''' utility to take note of the differences. There is an automated tool to find and view such files available from the '''community''' repository:<br />
pacman -S pacman-contrib<br />
cd ~/<br />
pacdiff # as root<br />
There is a bug in the above tool where if you navigate to '''/etc''' and run it from there, the paths will be messed up. We remain on the safer side by being at "home". You may want to run it as user first in case you happen to be a careless person (you may just overwrite or remove files because you ''think'' that is the right way).<br><br />
<br />
There are other types of leftovers depending on the programs available on your system. Some will create backups with a '''.bak''' extension, while others with something like "'''~'''" or "'''-'''". Unfortunately, there is currently no way to "automatically" find and review them. Fear not, as we have no need for automated tools to deal with such trivial tasks. Simply use '''locate''' to search for them:<br />
locate -e *.~ *.- *.bak<br />
And we can use something useful like '''vimdiff''' to look at the differences manually:<br />
pacman -S vim<br />
vimdiff file1 file2<br />
<br />
==Прочая информация==<br />
За дополнительной инфорацией обращайтесь к [http://archlinux.org.ru/ Русскоязычному сообществу Arch], а также [http://archlinux.org.ru/forum/ на русскоязычный фоум]. Также по любым вопросам обращайтесь на IRC-канал:<br />
Сервер: irc.freenode.org, канал #archlinux-ru, кодировка UTF-8.<br />
Опытные, добрые, отзывчивые админы всегда окажут вам полное содействие и помощь.<br />
=====FAQ=====<br />
Смотрите [[ЧаВо]]<br />
<br />
<br />
=====Что еще почитать?=====<br />
[http://www.cyber39.ru/os/linux/3716-linux_dlja_nachinajushhikh.html Linux для начинающих.]<br />
<br />
[http://www.cyber39.ru/2008/02/16/setevoe_administrirovanie_linux.html Сетевое администрирование Linux.]<br />
<br />
[http://www.cyber39.ru/2008/02/16/jadro_linux_3e_izd.html Ядро Linux.]<br />
<br />
[http://www.cyber39.ru/os/linux/1204-linux_polnoe_rukovodstvo.html Linux: Полное руководство.]<br />
<br />
[http://www.cyber39.ru/2008/02/13/operacionnaja_sistema_unix_nastolnyjj_spravochnik.html Операционная система UNIX. Настольный справочник.]<br />
<br />
[http://ru.wikibooks.org/wiki/Введение_в_администрирование_UNIX#.D0.92.D0.B2.D0.B5.D0.B4.D0.B5.D0.BD.D0.B8.D0.B5_.D0.B2_.D0.AE.D0.BD.D0.B8.D0.BA.D1.81 Введение в администрирование UNIX.]<br />
<br />
[http://www.cyber39.ru/os/linux/19037-linux_osnovnye_komandy_karmannyjj_spravochnik.html LINUX: Основные комманды. Карманный справочник.]<br />
<br />
[http://www.cyber39.ru/coding/cpp/16946-programmirovanie_na_c_v_linux.html Программирование на C в Linux.]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Beginners%27_guide_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=53612
Beginners' guide (Русский)
2008-11-15T23:36:22Z
<p>Cucullus: </p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
{{Box Note |'''По возможности, пользуйтесь английской версией этого документа, т.к. именно она обновляется в первую очередь, содержит все последние изменения и самую актуальную на данный момент информацию.'''}}<br />
{{Box Note|'''Уважаемые переводчики, прежде чем переводить какой-либо раздел, сравните его с английской версией ибо информация в нём могла устареть'''}}<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|Dansk_Begynderguide}}<br />
{{i18n_entry|简体中文|Beginners Guide 新手指南}}<br />
{{i18n_entry|Deutsch|Beginners Guide (Deutsch)}}<br />
{{i18n_entry|English|Beginners Guide}}<br />
{{i18n_entry|Español|Guía para Principiantes (Español)}}<br />
{{i18n_entry|Česky|Průvodce začátečníka (Česky)}}<br />
{{i18n_entry|Italiano|Beginners Guide (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Pradedančiųjų gidas (Lietuviškai)}}<br />
{{i18n_entry|Português Brasil|Guia do Iniciante(Português do Brasil)}}<br />
{{i18n_entry|Русский|Руководство для новичков}}<br />
{{i18n_links_end}}<br />
<br />
=====Всё, что вы хотели знать об установке Arch, но боялись спросить=====<br />
Добро пожаловать. Этот документ проведёт вас через процесс установки и настройки [[ArchLinux|Arch Linux]]; простого, быстрого и лёгкого GNU/Linux дистрибутива, <code>UNIX</code>-подобной операционной системы. Это больше, чем установочное руководство; Arch Linux требует определённого уровня глубоких знаний о его конфигурации, а так же методологии системы GNU/Linux и по этой причине, на этом пути содержится много дополнительной пояснительной информации. Он направлен на новых пользователей Arch, но стремится выступать как сильная справочная и информационная база для всех. Хоть это руководство предназначено для того, чтобы показать как получить полностью сконфигурированную систему Arch Linux (графическое окружени рабочего стола, возможность просмотра DVD, использования Интернет, работа с электронной почтой и прослушивания музыки), невозможно показать (или даже предположить) все возможности и варианты. По замыслу авторов, это руководство должно сфокусироваться на крайне полезных шагах; возможно вы захотите получить глубокие знания используя [[Main Page|Arch Linux Wiki]] или [http://bbs.archlinux.org/ Arch Linux Forums]. Вы также можете быть заинтересованы в чтении статьи [[Путь Arch]], в которой изложены основные принципы дистрибутива Arch Linux.<br />
<br />
Так как Arch Linux и все <code>UNIX</code>-подобные операционные системы являются в своей основе 'модульными', статья логически разбита на три основных части:<br />
<br />
'''[[#Часть 1: Установка базовой системы|Часть 1: Установка базовой системы]]'''<br />
<br />
'''[[#Часть 2: Установка X и установка ALSA|Часть 2: Установка X и установка ALSA]]'''<br />
<br />
'''[[#Часть 3: Установка и настройка окружения рабочего стола|Часть 3: Установка и настройка окружения рабочего стола]]'''<br />
<br />
=====DON'T PANIC!=====<br />
Имейте в виду, что процедура установки Arch Linux может сильно отличаться от установки других GNU/Linux дистрибутивов и вы можете запутаться, особенно, если вы новичок. Обычно, GNU/Linux дистрибутивы распространяются вместе с большим набором софта на CD (или даже DVD), включающим стандартное Рабочее Окружение(DE), стандартный набор программ и установок, автонастройщик оборудования и графический установщик, все что выбрано за вас. Для различия, система Arch Linux создаётся '''пользователем''', из установщика с псевдографикой и базовой системы в которой нет ничего кроме bash и простых консольных программ. Это — '''[[Путь Arch]].''' В отличие от большинства других дистрибутивов с жёсткой структурой, здесь нет ни стандартного окружения, ни конфигурации сделанной за пользователя. Попросту говоря, Arch ждет вашего вклада. Из командной строки, ''вы'' можете установить необходимые пакеты из репозитория используя [[pacman]] и ''вручную'' настроить вашу систему под ''свои'' потребности, до того как это сделает кто-то другой. Этот метод дает вам максимум гибкости, выбора и контроля за вашей системой. Потому что когда '''вы''' настраиваете систему, вы всегда знаете все "гайки и болты" вашей системы и вам знакомо то, что находится "под капотом". <br />
<br />
Arch Linux настраивается редактированием текстовых файлов. Из-за этого не требуются графические инструменты для настройки. <br />
Также запомните, что Arch Linux направлен на опытных пользователей GNU/Linux, на тех кто хочет минимального 'разделения' оборудования и софта, на тех пользователей, которые могут тратить своё время на чтение манов о своей системе.<br />
<br />
''Arch — это инструмент созданный пользователем.''<br />
<br />
=====[[Путь Arch]]=====<br />
<br />
'''''Принципы разработки Arch Linux направлены на сохранение [[Путь Arch|простоты]].'' '''<br />
<br />
Стоит учитывать, что 'простота' не означает 'легкость' или 'дружелюбие' в данном контексте. Но подразумевает 'отсутствие лишних сущностей, модификаций или надуманной сложности' и стремление к элегантному и минималистичному окружению.<br />
<br />
''"Простота подразумевается не с позиции конечного использования, а с технической точки зрения. Лучше стремиться к технической элегантности, нежели быть простым в использовании, но мусором с технической точки зрения." -Aaron Griffin''<br />
<br />
''"Значимая часть [моего метода] подразумевает простоту..Я всегда верил в то, что простой путь - правильный путь."'' - Bruce Lee<br />
<br />
Принцип "Бритвы Оккама": ''Entia non sunt multiplicanda praeter necessitatem'' или "Не следует множить сущности без необходимости." "Бритва" в данном случае означает отбрасывание, вырезание из предмета лишних усложнений и домыслов для того, чтобы добиться наиболее простого объяснения, метода или теории.<br />
<br />
{{Box Note |'''Для успешной установки и правильной настройки дистрибутива необходимо в точности выполнять приведённые инструкции. ''Пожалуйста'', читайте их внимательно.'''}}<br />
* Вы можете распечатать данную статью, она уместится примерно на 58 страницах, которые послужат полезным руководством использования Arch Linux.<br />
* ''Если вы хотите добавить что-то в данную инструкцию, пожалуйста, указывайте не только "Как" что-либо делать, но и "Зачем" именно может понадобиться это делать.''<br />
* Arch Wiki поможет вам разобраться с возникающими проблемами, ответы на которые сначала стоит поискать на [http://wiki.archlinux.org/index.php/Main_Page_(Русский) главной странице]. Также вам доступны каналы IRC и [http://bbs.archlinux.org/ форум].<br />
----<br />
Добро пожаловать в Arch Linux! Давайте приступим.<br />
<br />
==Часть 1: Установка базовой системы==<br />
===Скачайте самый последний установочный образ ===<br />
<br />
Вы можете получить самый последний образ Arch Linux'а [http://archlinux.org/download/ здесь.]<br />
<br />
*Core-iso и FTP-downloads включают в себя только самые необходимые пакеты для создания '''базовой системы Arch Linux'''. ''Нужно заметить что в Базовую Систему не включен GUI. Сюда главным образом входит GNU инструментарий, (компилятор, ассемблер, линковщик, библиотеки и немного полезных утилит) ядро Linux, и немного дополнительных библиотек и модулей.'' Остальное в Arch Linux, включая GUI, может быть установлено из консоли, ''пользователем'', используя менеджер пакетов - pacman для загрузки и установки i686/x86-64 бинарных пакетов. Процесс описывается в деталях ниже.<br />
<br />
Запишите образ системы на CD. <br />
{{Box Note| При записи не используйте скорость больше чем 8x - это рекомендованная скорость для надёжной записи, также некоторые пользователи рекомендуют устанавливать очень низкую скорость '''''4x или 2x!''''' Если вам встретились неожиданные проблемы с установкой, попытайтесь записать образ с самой низкой скоростью поддерживаемой вашей системой.}}<br />
<br />
===Загрузка с Arch Linux CD===<br />
Вы должны следовать этим инструкциям, но также вы можете найти весьма полезным [[Руководство_по_установке|Официальное руководство по установке Arch Linux]]. <br />
Вставьте CD в ваш CD-ROM и загрузитесь с CD. Если ваш компьютер по умолчанию загружается не с CD, вы можете исправить это <br />
изменив порядок загрузки в биосе (чтобы войти в биос используйте клавиши DEL, F1, F2, F11 или F12 при запуске компьютера (в зависимости от типа биоса)).<br />
<br />
Полезные опции загрузки:<br />
* '''ide-legacy''' если у вас возникают проблемы с IDE приводами<br />
* '''noapic acpi=off pci=routeirq nosmp''' если ваша система зависает при загрузке системы<br />
* '''acpi=nommconf''' если у вас возникают "задержки" после загрузки pci:mmconfig <br />
* '''memtest86+''' если вы хотите проверить вашу оперативную память на ошибки<br />
* '''lowmem''' полезно для старых компьютеров с ограниченным объёмом оперативной памяти<br />
<br />
Требования к памяти:<br />
* CORE ISO: lowmem-загрузка образа - 64 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* CORE ISO: обычная загрузка образа - 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* FTP ISO : 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
<br />
Выберите "Arch Linux Installation / Rescue System". Если вы нуждаетесь в изменениях опций загрузки, нажмите "e" для редактирования конфигурации загрузки.<br />
Система будет загружена и вам будет представлено сообщение приветствия с некоторыми пояснениями.<br />
<br />
===Вход в систему и изменение раскладки===<br />
Войдите в систему как 'root'. Если ваша клавиатура не имеет американскую раскладку, выполните в командной строке следующее:<br />
{{Box Note| Скорее всего, у вас клавиатура с "американской" раскладкой (если ваша клавиатура приобретена в России)}}<br />
loadkeys <ваша раскладка><br />
<br />
===Запуск установки===<br />
Введите<br />
/arch/setup <br />
чтобы начать установку Arch Linux. <br />
<br />
<br />
====Выбор источника установки====<br />
После экрана приветствия вам будет предложено выбрать источник установки. Выберите CD, если хотите использовать диск. Или выберите FTP, если хотите использовать образ из FTP. <br />
* В первом случае, переходите к чтению главы о [[#Подготовка жёсткого диска|Подготовке жесткого диска]].<br />
* Во втором случае, вам будет предложено загрузить драйвер для сетевой карты вручную. Но, как правило, Udev автоматически вполне успешно определяет комплектующие - вы можете проверить это выполнив "ifconfig -a" из vc2. Для продолжения установки нажмите "OK".<br />
<br />
====FTP: Настройка Сети====<br />
Вам будут показаны доступные интерфейсы. Если нужный интерфейс присутствует в списке - значит он определился правильно. В обратном случае, вы можете попробовать определить его прямо из установщика или из другой виртуальной консоли (vc).<br />
<br />
Далее выберите нужный интерфейс и продолжайте установку.<br />
<br />
Затем вам будет предложено использовать DHCP для автоматического получения сетевых настроек. В случае отказа, вам будет предложено вручную ввести ваш статический IP-адрес, маску подсети, адрес шлюза и т.д. И, наконец, вы сможете пересмотреть проделанные настройки и удостовериться в их правильности.<br />
<br />
Переходите к чтению о [[#Подготовка жёсткого диска|Подготовке жёсткого диска]].<br />
<br />
====Подготовка жёсткого диска====<br />
Выберите первый пункт меню - "Prepare Hard Drive". Вам будет предложено автоматически подготовить ваш жёсткий диск к установке Arch Linux, либо вручную переразбить и подготовить разделы.<br />
* 1. Автоматическая подготовка<br />
Установщик сам разобъёт ваш жесткий диск на следующие разделы:<br />
* Загрузочный раздел /boot c файловой системой ext2 и размером по умолчанию в 32 мегабайта. Вы сможете изменить это значение. <br />
* Раздел подкачки swap с размером по умолчанию в 256 мегабайтов. Вы также сможете изменить это значение.<br />
* Отдельные разделы для корня / и домашней директории пользователей /home. Размеры вы определяете сами. Также вам будет предоставлен выбор из файловых систем: ext2, ext3, reiserfs, xfs и jfs. Но следует учесть, что оба этих раздела должны быть отформатированы в одинаковой файловой системе.<br />
<br />
Не забывайте - автоматическая подготовка сотрёт все данные на вашем жёстком диске! Внимательно читайте предупреждение установщика.<br />
<br />
* 2. '''(Рекомендуется)''' Ручная подготовка<br />
<br />
Выберите из списка жёсткий диск, на который будет произведена установка (/dev/sd''x'').<br />
<br />
''На этом этапе более опытные пользователи могут сразу перейти к главе о '''[[#Выбор Пакетов|выборе пакетов]]'''.''<br />
<br />
=====Информация о разбивке=====<br />
Разбивка жёсткого диска заключается в создании отдельных зон (разделов) на жёстком диске. Они будут выглядеть как отдельные диски со своими файловыми системами. Разделы подразделяются на "Основные" (Primary), "Расширенные" (Extended) и "Логические" (Logical).<br />
<br />
'''Основные''' разделы могут быть загрузочными и их количество ограничено четырьмя. Больше четырёх главных разделов создать нельзя и нужно использовать '''Расширенные''' разделы, которые будут содержать '''Логические'''.<br />
<br />
Расширенные разделы не могут быть использованы сами по себе - они всего лишь "контейнеры" для логических. Жёсткий диск может содержать только один расширенный раздел, который может быть разделён на логические.<br />
<br />
Во время разбивки диска можно заметить схему нумерации разделов. Главные получают названия sda1-3, расширенный раздел - sda4, а логические, соответственно, sda5, sda6 и т.д.<br />
<br />
=====Раздел Подкачки (swap)=====<br />
Данный раздел является чем-то вроде "виртуального ОЗУ". На нем хранятся данные, которые не умещаются, либо не подходят для хранения в оперативной памяти.<br />
<br />
Исторически сложилось, что размер раздела подкачки определяется по схеме 2ХОЗУ. То есть, двойной объем оперативной памяти. Затем, с развитием компьютерной техники, данное правило не всегда стало являться необходимым. На компьютере с 512 мегабайтами памяти правило 2Х все еще действует эффективно. Однако, на машинах с 1 гигабайтом памяти обычно наиболее эффективна схема 1ХОЗУ. Если размер вашего ОЗУ больше или равен 1 гигабайту, то можно вообще обойтись без раздела подкачки, однако это не рекомендуется. Мы создадим раздел размером в 1 гигабайт в нашем примере.<br />
<br />
{{Box Note|Если вы планируете использовать технологии suspend-to-disk или hibernate, то размер раздела подкачки, по меньшей мере, должен соответствовать размеру вашей оперативной памяти. Но рекомендуется задать размер хотя бы на 15% больший, чтобы учесть появление испорченных секторов на диске (bad sectors).}}<br />
=====Схема Разбивки=====<br />
Схема разбивки разделов довольно индивидуальна и во многом зависит от предпочтений и нужд конкретного пользователя. Но, как минимум, вам нужны два раздела: один для корня ( / ), второй для раздела подкачки (swap). Однако, вы можете захотеть иметь отдельные разделы для /boot (на нем обычно находится ядро Linux), /var и /home (пользовательская директория). Обычно иметь два раздела отдельно для корня ( / ) и отдельно для /home считается хорошей практикой и более удобным и безопасным решением.<br />
В нашем примере мы создадим три отдельных раздела: для корня, для /home и один раздел подкачки swap.<br />
<br />
=====cfdisk===== <br />
Итак, начнём с создания главного раздела, содержащего корневую файловую систему.<br />
<br />
Для создания нового раздела выберите пункт '''N'''ew, затем Primary. Далее задайте желаемый размер раздела (что-то между 4 и 12 гигабайт будет хорошим выбором). Выберите только что созданный раздел и сделайте его загрузочным, выбрав пункт '''B'''ootable.<br />
<br />
Также выберите пункт '''T'''ype и задайте значение '83 Linux'. Нашему разделу должно присвоится имя sda1.<br />
<br />
Затем создадим раздел подкачки. Задайте размер между 512 мегабайт и 1 гигабайтом, выберите '''T'''ype - 82 (Linux swap / Solaris). Наш раздел должен быть теперь виден как sda2.<br />
<br />
Теперь ещё один раздел для /home. Выберите главный раздел и установите желаемый размер в зависимости от того, что пользователи вашего компьютера будут хранить в своих персональных директориях. Также, как и для корня, задайте '''T'''ype - 83 Linux. Данный раздел появится как sda3.<br />
<br />
<br />
<br />
Вот как должна выглядеть наша таблица разделов (размеры могут отличаться):<br />
<br />
Name Flags Part Type FS Type [Label] Size (MB)<br />
-------------------------------------------------------------------------<br />
sda1 Boot Primary Linux (4096 - 8192)<br />
sda2 Primary Linux swap / Solaris (512 - 1024)<br />
sda3 Primary Linux (> 100 or remaining space)<br />
<br />
Выберите '''W'''rite и нажмите ''''yes''''. Или нажмите '''Q'''uit для выхода из программы разбивки.<br />
<br />
<br />
=====Мои IDE-диски выглядят как SCSI, почему?=====<br />
В последних версиях ядра Linux все диски (IDE, SATA, SCSI) именуются как sd''x''. Пусть это вас не волнует, это нормально.<br />
<br />
====Назначение точек монтирования====<br />
Во-первых, выберите нужный раздел под раздел подкачки (в нашем примере это sda3). Во-вторых, выберите раздел для монтирования корневой ФС (sda1 в нашем примере). Вам будет предложено выбрать желаемую файловую систему.<br />
<br />
=====Файловые системы=====<br />
<br />
Выбор файловой системы достаточно субъективен. Каждая из предложенных ФС имеет свои достоинства и недостатки, всё зависит целиком от ваших предпочтений. Далее мы кратко рассмотрим поддерживаемые ФС:<br />
<br />
1. '''[http://ru.wikipedia.org/wiki/Ext2 ext2]''' - старая и надежная файловая система для ОС GNU/Linux. Очень стабильна, но без поддержки журналирования - это значит, что в случае аппаратных сбоев или перепадов напряжения ваша информация может пострадать. Не слишком хороший выбор для корневого и /home разделов. Данная ФС может быть легко преобразована в ext3.<br />
<br />
2. '''[http://ru.wikipedia.org/wiki/Ext2 ext3]''' - наследница ext2, но с поддержкой журналирования. Она полностью совместима с ext2. Однако, по некоторым тестам немного медленнее, нежели остальные ФС. Тем не менее, очень стабильна и активно используется, поддерживается и разрабатывается сообществом GNU/Linux.<br />
<br />
3. '''[http://ru.wikipedia.org/wiki/ReiserFS ReiserFS]''' - высокопроизводительная файловая система, разработанная Гансом Райзером. Считается очень быстрой, особенно при операциях с файлами маленького размера, однако сравнительно медленно монтируется. Вполне готова к использованию и стабильна. Однако, не слишком активно разрабатывается на данный момент (все силы отданы Reiser4).<br />
<br />
4. '''[http://ru.wikipedia.org/wiki/JFS JFS]''' - '''J'''ournaled '''F'''ile'''S'''ystem, файловая система от IBM. Использует наименьшее количество ресурсов центрального процессора, нежели остальные ФС. Очень быстра в монтировании и использовании. Однако, не так широко используется, как ext или ReiserFS.<br />
<br />
5. '''[http://ru.wikipedia.org/wiki/JFS XFS]''' - журналируемая ФС, которая показывает наибольшую скорость при операциях с большими файлами. Хороший выбор для разделов с большим их количеством.<br />
<br />
Наиболее значимое отличие между ними - журналирование. Все, кроме ext2, его поддерживают, однако техника журналирования не у всех одинакова. Только ext3 поддерживает хранение в журнале данных и мета-данных (информация о директориях). Это значит, что только она в случае сбоя сможет восстановить полностью в точной мере ту информационную структуру, которая была до сбоя.<br />
<br />
Выберите и создайте ФС для корня. Далее вам будет предложено создать дополнительные разделы. В нашем примере, нам понадобится создать еще sda2. Выберите файловую систему и примонтируйте ее как /home. Нажмите Done и возвращайтесь в главное меню установщика.<br />
<br />
===Выбор пакетов===<br />
На данном этапе вам предстоит выбрать пакеты, которые будут установлены на вашу систему.<br />
* Установка из Core ISO: выберите подходящее устройство CD-ROM из списка.<br />
* Установка из FTP ISO: выберите FTP/HTTP-зеркало для получения пакетов.<br />
<br />
Процесс выбора пакетов разбит на две стадии: выбор категорий пакетов, а затем - выбор отдельных пакетов в этих категориях. С помощью клавиши пробела вы можете устанавливать и снимать выделение пакетов и категорий. Ниже приведен список категорий пакетов с объяснениями:<br />
<br />
* '''BASE:''' содержит только базовые, необходимые системные пакеты. Минимальный набор для базовой системы.<br />
*'''SUPPORT:''' здесь находятся дополнительные пакеты для работы с сетью и файловыми системами. Например, такие как gpm, fuse, dnsutils, ndiswrapper, ntfs-3g, драйвера для wi-fi адаптеров и т.п.<br />
*'''DEVEL:''' пакеты для сборки программ. То есть, GCC, autoconf, automake, make и т.п.<br />
*'''LIB:''' различные системные библиотеки - gmp, libelf, libevent и т.п.<br />
<br />
Нажмите OK и далее выберите опцию 'yes', когда вам будет предложено выбрать все пакеты по умолчанию ('Select all packages by default').<br />
<br />
Далее вам будет показан список пакетов в выбранных категориях. Для новичка будет лучшим выбором оставить всё как есть. Тогда как более опытные пользователи могут убрать ненужные им пакеты из данного списка.<br />
<br />
===Установка пакетов===<br />
Теперь выберите пункт 'Install Packages', чтобы начать установку пакетов. Вам будет предложено сохранить загруженные из источника установки пакеты в системном кэше. Это хороший выбор, который может очень вам помочь, если какой-либо новый установленный пакет будет работать не так, как надо. Тогда можно просто восстановить старую версию из кэша. Помните, что вы всегда можете очистить ваш кэш вручную при необходимости.<br />
Установщик произведет установку выбранных вами пакетов и ядра Arch Linux в вашу новую систему.<br />
<br />
*FTP ISO: менеджер пакетов [[Pacman_(Русский)|Pacman]] установит пакеты с сетевого зеркала (прогресс вы можете наблюдать на vc5, а чтобы вернуться назад к установщику - перейдите на vc1).<br />
*CORE ISO: пакеты будут установлены с оптического диска.<br />
<br />
===Конфигурация системы===<br />
''Чёткое следование и понимание следующих шагов является ключем к корректной работе системы.'' <br />
<br />
Установщик спросит вас о необходимости использования [[Hwdetect|hwdetect]] для сбора информации о параметрах компьютера. Новичку следует выбрать 'yes'. <br />
<br />
Опытные пользователи, которые хорошо знают свое железо, требующиеся модули, а так же те, что могут вручную отладить /etc/rc.conf, /etc/mkinitcpio и /etc/fstab, и т.д. с нуля могут выбрать'no'. (Не требует напоминания тот факт, что сия опция крайне сложна, выходит за рамки этого руководства и поэтому не освещается им)<br />
<br />
Далее будут заданы вопросы, необходимо ли вам будет загружаться с USB-устройств, FireWire-устройств, PCMCIA-устройств, общих папок NFS, программных RAID-массивов, LVM2 разделов, шифрованных разделов и о поддержке DSDT. Выбирайте 'yes' если вам что-то из вышеописанного требуется. В рамках нашего руководства не требуется ничего из описанного. <br />
<br />
Теперь вас спросят, какой текстовый редактор вы желаете использовать; выбирайте [http://en.wikipedia.org/wiki/Nano_%28text_editor%29 nano] (проще для освоения) или [http://en.wikipedia.org/wiki/Vim_%28text_editor%29 vi/vim] (рекомендуется, сложнее для освоения). Перед вами появится меню, включающее список наиболее важных конфигурационных файлов системы. Если вы хотите просмотреть возможные настройки, указанные в /etc/rc.conf, то просто нажмите Alt+F2, чтобы попасть в консоль, просмотрите файл и вернитесь в установщик с помощью Alt+F1. <br />
<br />
=====Почему установщик не делает это всё автоматически?=====<br />
Сокрытие процесса установки является прямой противоположностью [[пути Arch|Путь Arch]]. Пока имеет место факт, что последние версии ядра и средства определения оборудования замечательным образом поддерживают различное оборудование и автоконфигурацию, Arch будет представлять пользователю все соотвествующие конфигурационные файлы в течение установки с целью ''прозрачности''. К тому времени, как вы закончите настройку этих файлов под свои нужды, вы будете знать элементарные методы ручной настройки Arch Linux'а и будете знакомы с базовой структурой, будучи хорошо подготовленны к продуктивному использованию вашей новой системы.<br />
<br />
====='''/etc/rc.conf'''=====<br />
Arch Linux следует трациям '''*BSD''' использования '''/etc/rc.conf''' в качестве принципиального расположения системной конфигурации. Этот небольшой файл содержит обширный набор различных параметров, используемых при запуске системы. Как становится ясно из его имени, этот файл так же содержит настройки /etc/rc* файлов, а так же и вызывает эти файлы. Файл /etc/rc.conf предлагает простой, элегантный метод поточной конфигурации системных ресурсов включая широкие возможности контроля, охотно представляя их пользователям Arch Linux.<br />
<br />
* Секция '''LOCALIZATION''' <br />
** '''LOCALE'''=: Устанавливает системную локаль, которая будет использоватся для всех i18n приложений и утилит. Вы можете просмотреть список доступных локалей, введя комманду 'locale -a' в коммандой строке. Начальные настройки подходят для англоязычных пользователей (процесс локализации системы описан в [http://wiki.archlinux.org/index.php/Интернационализация соотвествующем руководстве]).<br />
<br />
** '''HARDWARECLOCK'''=: Определяет, каким образом аппаратные часы вашего компьютера, которые синхронизируются при загрузке и выключении, хранят время: '''UTC''' или '''localtime'''. UTC может сильно упростить смену часовых поясов, а так же переход на летнее/зимнее время. localtime необходим, если вы используете несколько операционных систем (скажем, у вас так же установлен Windows), которые хранят в аппаратных часах лишь localtime.<br />
** '''TIMEZONE'''=: Определяет ваш часовой пояс. Для Москвы, скажем, это "Europe/Moscow". (Все возможные часовые пояса хранятся в /usr/share/zoneinfo/).<br />
** '''KEYMAP'''=: Все возможные раскладки хранятся в /usr/share/kbd/keymaps. Учтите, что эта опция определяется только для TTY (текстовой консоли), а не графического оконого менеджера и X-ов!<br />
** '''CONSOLEFONT'''=: Возможные консольные шрифты хранятся в /usr/share/kbd/consolefonts/ если вам вдруг требуется замена. Для поддержки русского языка требуется указать "/usr/share/kbd/consolefonts/cyr-sun16".<br />
** '''CONSOLEMAP'''=: Определяет, какую console map загрузить с программой установки шрифтов при загрузке системы. Возможные map'ы можно найти в /usr/share/kbd/consoletrans, если вдруг необходимо. По умолчанию поле пустое, что считается безопасным. <br />
** '''USECOLOR'''=: Установите "yes", если у вас цветной монитор и вы хотите, что бы в консоли отображались цвета.<br />
<br />
LOCALE="ru_RU.UTF-8"<br />
HARDWARECLOCK="UTC"<br />
TIMEZONE="Europe/Moscow"<br />
KEYMAP="ru" # Или ru-mab для раскладки с переключением по Ctrl-Shift<br />
CONSOLEFONT="/usr/share/kbd/consolefonts/cyr-sun16"<br />
CONSOLEMAP=""<br />
USECOLOR="yes"<br />
<br />
* Секция '''HARDWARE'''<br />
** '''MOD_AUTOLOAD'''=: Если установлена как "yes", то '''udev''' будет автоматически проверять устройства и загружать соотвествующие модули во время загрузки системы. Установка в положение "no" возложит на пользователя возможность определят эту информацию самостоятельно или скомпилировать свое собственное ядро и модули, и т.д. <br />
** '''MOD_BLACKLIST'''=: Крайне не рекомендуется добавление blacklist'овых модулей прямо в строчку '''MODULES=''' далее. <br />
** '''MODULES'''=: Определяет дополнительные модули, если известно, что важный модуль пропущен, ('''hwdetect''' должен быть заполнен в наиболее важных модулях). Так же задайте какие-либо blacklist'овые модули, ставя перед ними восклицательный знак (!). Udev НЕ будет загружать blacklist'овые модули. К примеру, IPv6-модуль, так же как и надоедливый pc-спикер, отключены. <br />
# Сканирует устройства и загружает соотвествующие модули<br />
MOD_AUTOLOAD="yes"<br />
# Blacklist-модуль - Крайне не рекомендуется<br />
MOD_BLACKLIST=()<br />
#<br />
MODULES=(e100 eepro100 mii slhc snd-ac97-codec snd-intel8x0 soundcore !net-pf-10 !pcspkr)<br />
* Секция '''NETWORKING'''<br />
** '''HOSTNAME'''=: Задайте имя хоста (HOSTNAME) на свой вкус.<br />
** '''eth0'''=: 'Ethernet, card 0'. Задайте IP адрес интерфейса, сетевую маску и широковещательный адрес ''если'' вы используете '''статический IP'''. Задайте eth0="dhcp" если вы используете '''DHCP'''<br />
** '''INTERFACES'''=: Здесь задайте какие-либо/все интерфейсы. Если вы НЕ используете DHCP для конфигурации устройства, просто запомните, что значение переменной (имя которой должно совпадать с именем устройства, которое вы настраиваете) совпадает со строкой, которая будет следовать за коммандой "ifconfig", если вы решите настраивать устройство вручную в коммандой строке. <br />
** '''gateway'''=: Если вы используете '''статический IP''', установите адрес шлюза. Не трогайте этот параметр, если вы используете'''DHCP'''<br />
** '''ROUTES'''=: Если вы используете статический '''IP''', уберите '''!''' перед 'gateway'. Оставьте'''!''', если используете '''DHCP'''<br />
<br />
К примеру, если используется '''DHCP''':<br />
HOSTNAME="arch"<br />
#eth0="eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255" <br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
gateway="default gw 192.168.0.1"<br />
ROUTES=(!gateway)<br />
* Секция '''DAEMONS'''<br />
Этот массив задает список имен скриптов в /etc/rc.d/ которые будут запускаться во время загрузки системы, а так же порядок их запуска. <br />
DAEMONS=(@network syslog-ng netfs crond)<br />
*Если перед именем скрипта стоит восклицательный знак (!), он не исполняется. <br />
*Если перед скриптом стоит символ "at" (выглядит как "@"), тогда он будет запущен в фоновом режиме; очередь загрузки не будет ожидать успешного завершения демона перед переходом к загрузке следующего. Полезно для ускорения загрузки системы.<br />
*Редактируете этот массив, когда устанавливаете новые системные сервисы, если желаете, чтобы они загружались во время запуска системы.<br />
<br />
Это загрузка в 'стиле BSD', с особым Arch-способом обращения, в то время как остальные обращаются с помощью symlinks к директории /etc/init.d<br />
<br />
=====О Демонах=====<br />
Потушите свечу, уберите распятие, унесите иконы. Да, разговор пойдет о Демонах, но вовсе не о тех, о которых вы подумали сначала. И, да, вам не обязательно изменять строчку [[daemons]] в этот раз, но будет полезно объяснить, кто такие Демоны, поскольку они пригодятся нам далее в этом руководстве. <br />
<br />
По аналогии с сервисами Windows, ''демоны'' это программы, работающие в фоновом режиме, ожидающие наступления определенного события и предоставляющие сервисы. Отличный пример - вебсервер, который ожидает запроса на получение страницы или SSH-сервер, ожидающий, пока кто-нибудь не попробует войти в систему. В отличие от этих "полноценных" программ, их работа не так заметна. К примеру демон, который записывает что-либо в log-файл (к примеру, syslog, metalog), демон, понижающий частоту вашего CPU, когда система ничем не занята (к примеру:cpufreq), и демоны, которые представляют вам графический вариант входа в систему (log on) (к примеру: gdm, kdm). Все эти программы могут быть добавлены в строку "daemons" и будут запущены во время загрузки операционной системы. Всячекие полезные демоны будут представлены далее в этом руководстве. (Призыв Азазеля, Велиара, Асмодея, Маммона, Балтазара и других высших демонов в этом руководстве не рассматривается).<br />
<br />
Обращаясь к истории, термин ''daemon'' был предложен программистами MIT's Project MAC. Они заимствовали имя из ''Maxwell's demon'', мысленный эксперимент, главным персонажем которого является гипотетическое разумное существо ростом c молекулу. Выдумано Джеймсом Максвеллом с целью проиллюстрировать Второе начало термодинамики. <code>UNIX</code> системы унаследовали терминологию и создали бэкроним '''d'''isk '''a'''nd '''e'''xecution '''mon'''itor. <br />
<br />
*'''''Подсказка: Все демоны в Arch проживают в директории /etc/rc.d/ Звоните! :)'''''<br />
<br />
=====Про /etc/fstab=====<br />
Так называемый '''fstab''' ('''f'''ile '''s'''ystems '''tab'''le) это часть конфигурации системы, отображающая все доступные диски и дисковые разделы; показывающая, как они инициализированны/интегрированны в системную файловую систему. Данный '''/etc/fstab''' обычно используется коммандой '''mount''', которая читает /etc/fstab дабы определить, какие настройки нужно использовать для монтирования определенного устройства.<br />
<br />
<br />
К примеру, '''/etc/fstab''':<br />
<br />
#<br />
# /etc/fstab: static file system information<br />
#<br />
# <file system> <dir> <type> <options> <dump> <pass><br />
none /dev/pts devpts defaults 0 0<br />
none /dev/shm tmpfs defaults 0 0<br />
#/dev/cdrom /mnt/cdrom iso9660 ro,user,noauto,unhide 0 0<br />
#/dev/dvd /mnt/dvd udf ro,user,noauto,unhide 0 0<br />
#/dev/fd0 /mnt/fd0 vfat user,noauto 0 0<br />
/dev/disk/by-uuid/0ec-9339 / jfs defaults,noatime,nodiratime 0 1<br />
/dev/disk/by-uuid/7ef-223-0 /home jfs defaults,noatime,nodiratime 0 2<br />
/dev/disk/by-uuid/530-1e-2c2 swap swap defaults 0 0<br />
<br />
Измените '''fstab''' под себя, если желаете.<br />
{{Box Note | Как было писано в 2008-04rc, Arch теперь использует UUID, или Universally Unique Identifier конвертацию имен для повышения совместимости. Крайне полезно при активной работе над ядром и udev, что может повлечь случайное изменение в порядке загрузки драйверов storage-контроллеров и невозможности загрузки системы из-за kernel-panic. Почти все материнские платы имеют несколько контроллеров (SATA, IDE), и в вышеуказанных случаях, /dev/sda мог запросто стать /dev/sdb при следующей загрузке - с тех пор была введена UUID.}}<br />
ls -lF /dev/disk/by-uuid/<br />
Отобразит разделы, отсортированные по uuid.<br />
<br />
*Если вы планируете использование '''hal''' для автоматического монтирования всякой всячины (вроде DVD дисков), вы, возможно, изволите закомментить записи, касающиеся cdrom и dvd для подготовки к установке '''hal''', который будет инсталлирован нами далее в этом руководстве.<br />
<br />
{{Box Note | '''''The 'noatime' and 'nodiratime' options may safely be appended to / and /home regardless of your specified filesystem type for increased speed, performance, and power efficiency, for laptops as well as desktops.'''''}}<br />
<br />
Expanded information available in the [[Fstab]] wiki entry.<br />
<br />
====='''/etc/mkinitcpio.conf and /etc/modprobe.conf'''=====<br />
We shouldn't need to edit these configurations at this point. <br />
<br />
* '''mkinitcpio.conf''' This file allows you to fine-tune the initial ram filesystem (also commonly referred to as the initial ramdisk or "initrd") for your system. The initrd is a gzipped image that is read by the kernel during bootup. The purpose of the initrd is to bootstrap the system to the point where it can access the root filesystem. This means it has to load any modules that are required for devices like IDE, SCSI, or SATA drives (or USB/FW, if you are booting off a USB/FW drive). Once the initrd loads the proper modules, either manually or through udev, it passes control to the Arch system and your bootup continues. For this reason, the initrd only needs to contain the modules necessary to access the root filesystem. It does not need to contain every module you would ever want to use. The majority of your everyday modules will be loaded later on by udev, during the init process.<br />
<br />
* '''modprobe.conf''' can be used to set special configuration options for the kernel modules <br />
<br />
=====/etc/resolv.conf (for Static IP)=====<br />
The ''resolver'' is a set of routines in the C library that provide access to the Internet Domain Name System (DNS). One of the main functions of DNS is to translate domain names into IP addresses, to make the Web a friendlier place. The resolver configuration file, or /etc/resolv.conf, contains information that is read by the resolver routines the first time they are invoked by a process.<br />
<br />
*''If you are using DHCP, you may safely ignore this file, as by default, it will be dynamically created and destroyed by the dhcpcd daemon. You may change this default behavior if you wish. (See [[Network]]).''<br />
<br />
If you use a static IP, set your DNS servers in /etc/resolv.conf (nameserver <ip-address>). You may have as many as you wish, e.g.:<br />
nameserver 4.2.2.1<br />
nameserver 4.2.2.2<br />
<br />
If you are using a router, you will probably want to specify your DNS servers in the router itself, and merely point to it from your '''/etc/resolv.conf''', using your router's IP (which is also your gateway from '''/etc/rc.conf'''), e.g.:<br />
nameserver 192.168.1.1<br />
<br />
If using '''DHCP''', you may also specify your DNS servers in the router, or allow automatic assignment from your ISP, if your ISP is so equipped.<br />
<br />
=====/etc/hosts=====<br />
<br />
This file associates IP addresses with hostnames and aliases, one line per IP address. For each host a single line should be present with the following information:<br />
<IP-address> <hostname> [aliases...]<br />
Add your ''hostname'', coinciding with the one specified in /etc/rc.conf, as an alias, so that it looks like this:<br />
127.0.0.1 localhost.localdomain localhost '''''yourhostname'''''<br />
{{Box Note |''This format, '''including the 'localhost' and your actual host name''', is required for program compatibility! Errors in this entry may cause poor network performance and/or certain programs to open very slowly, or not work at all. This is a very common error for beginners.''}}<br />
<br />
If you use a static IP, add another line using the syntax: <static-IP> <hostname.domainname.org> <hostname> e.g.:<br />
192.168.1.100 '''''yourhostname'''''.domain.org '''''yourhostname'''''<br />
<br />
*'''TIP''': For convenience, you may also use /etc/hosts aliases for hosts on your network, and/or on the Web, e.g.:<br />
64.233.169.103 www.google.com g<br />
192.168.1.90 media<br />
192.168.1.88 data<br />
The above example would allow you to access google simply by typing 'g' into your browser, and access to a media and data server on your network by name and without the need for typing out their respective IP addresses.<br />
<br />
=====/etc/hosts.deny and /etc/hosts.allow=====<br />
Modify these configurations according to your needs if you plan on using the [[SSH|ssh]] daemon. The default configuration will reject all incoming connections, not only ssh connections. Edit your '''/etc/hosts.allow '''file and add: <br />
sshd:all <br />
This will allow all incoming ssh connections.<br />
<br />
If you do not plan on using the [[SSH|ssh]] daemon, leave this file at the default, (empty), for added security.<br />
<br />
=====/etc/locale.gen=====<br />
<br />
The '''locale-gen''' command reads from '''/etc/locale.gen''' to generate specific locales. They can then be used by '''glibc''' and any other locale-aware program or library for rendering "peculiar" text, correctly displaying regional monetary values, time and date formats, alphabetic idiosyncrasies, and other locale-specific standards. The ability to setup a default locale is a great built-in privilege of using a <code>UNIX</code>-like operating system.<br />
<br />
By default /etc/locale.gen is an empty file with commented documentation. Once edited, the file won't get touched again. '''locale-gen''' runs on every '''glibc''' upgrade, generating all the locales specified in /etc/locale.gen.<br />
<br />
Choose the locale(s) you need (remove the # in front of the lines you want), e.g.:<br />
en_US ISO-8859-1<br />
en_US.UTF-8 <br />
<br />
The installer will now run the locale-gen script, which will generate the locales you specified. You may change your locale in the future by editing /etc/locale.gen and subsequently running 'locale-gen' as root.<br />
<br />
{{Box Note |'''''If you fail to choose your locale, this will lead to a "The current locale is invalid..." error. This is perhaps the most common mistake by new Arch users, and also leads to the most commonly asked questions on the forum.'''''}}<br />
<br />
=====Root password=====<br />
Finally, set a root password and make sure that you remember it later. Return to the main menu and continue with installing bootloader.<br />
<br />
=====Pacman-Mirror=====<br />
Choose a mirror repository for '''pacman'''. <br />
*''archlinux.org is throttled, limiting downloads to 50KB/s'' <br />
<br />
Return to the main menu.<br />
<br />
===Install Bootloader===<br />
Because we have no secondary operating system in our example, we will need a bootloader. [http://www.gnu.org/software/grub/ GNU GRUB] is the recommended bootloader. Alternatively, you may choose [http://lilo.go.dyndns.org/ LILO]. <br />
===GRUB===<br />
The provided '''GRUB''' configuration ('''/boot/grub/menu.lst''') should be sufficient. The only thing you may want to alter is the resolution of the console. Add<br />
a vga=<number> to the first kernel line. (A table of resolutions and the corresponding numbers is printed in the menu.lst.)<br />
<br />
Example: <br />
title Arch Linux (Main)<br />
root (hd0,0)<br />
kernel /boot/vmlinuz26 root=/dev/disk/by-uuid/0ec1-9339.. ro vga=773<br />
initrd /boot/kernel26.img<br />
Explanation:<br />
<br />
Line 1: '''title''': A printed menu selection. "Arch Linux (Main)" will be printed on the screen as a menu selection.<br />
<br />
Line 2: '''root''': GRUB's root; the drive and partition where the kernel (/boot) resides. '''NOT necesarily the root''' (/) file system, as they can reside on separate partitions. GRUB's numbering scheme starts at 0, and uses an hd''x,x'' format regardless of IDE or SATA, enclosed within parentheses. <br />
<br />
The example indicates that /boot is on the first partition of the first drive, or, (hd0,0).<br />
<br />
Line 3: '''kernel''': This line specifies:<br />
<br />
* The path and filename of the kernel '''''relative to GRUB's root''''' (within the partition containing the kernel). <br />
<br />
In the example, /boot is merely a directory residing on the same partition as / and '''vmlinuz26''' is the kernel filename; '''/boot/vmlinuz26'''. ''If /boot were on a separate partition, the path and filename would be simply '''/vmlinuz26''', being relative to '''GRUB''''s root.'' <br />
<br />
* The root= argument to the kernel statement specifies the partition containing the root (/) directory in the booted system, (more accurately, the partition containing '''/sbin/init'''), ''according to the UUID numbering scheme'' as of 2008-04rc, which uses the /dev/disk/by-uuid/xxxx-xxxx-xxxx format. <br />
<br />
* Kernel options. <br />
<br />
In our example, '''ro''' mounts the filesystem as read only during startup, and the '''"vga=773"''' argument will give a 1024x768 framebuffer with 256 color depth.<br />
<br />
Line 4: '''initrd''': (For Initial RAM disk) The path and filename of the initial RAM filesystem '''relative to GRUB''''s root (within the partition containing the kernel). Again, in the example, /boot is merely a directory residing on the same partition as / and '''kernel26.img''' is the initrd filename; '''/boot/kernel26.img'''. ''If /boot were on a separate partition, the path and filename would be simply '''/kernel26.img''', being relative to '''GRUB''''s root.'' <br />
<br />
Install the '''GRUB''' bootloader to the master boot record, (sda in our example).<br />
<br />
That's it; You have configured and installed your Arch Linux base system. Exit the install, eject the installer CD, and type the magic word:<br />
<br />
reboot<br />
<br />
Your new Arch Linux system will boot up and finish with a login prompt (you may want to change the boot order in your '''BIOS''' back to booting from hard disk).<br />
<br />
'''Congratulations, and welcome to your shiny, new Arch Linux base system!'''<br />
<br />
==The Base System ==<br />
Your new Arch Linux base system is now a functional GNU/Linux environment ready for customization. From here, you may build this elegant set of tools into whatever you wish or require for your purposes. <br />
<br />
Let's begin.<br />
<br />
Login with your root account. We will configure pacman and update the system as root, then add a normal user. <br />
{{Box Note |Virtual consoles 1-6 are available, as is the '''links''' command line web browser.}}<br />
<br />
===Configuring the network (if necessary)===<br />
*''This section will assist you in configuring most types of networks, if your network configuration is not working for you.''<br />
<br />
If you properly configured your system, you should have a working network. Try to ping www.google.com to verify this.<br />
ping -c 3 www.google.com<br />
<br />
''If you have successfully established a network connection, continue with '''[[#Update, Sync and Upgrade the system with pacman|Update, Sync and Upgrade the system with pacman]]'''.''<br />
<br />
If, after trying to ping www.google.com, you get an "unknown host" error, you may conclude that your network is not properly configured. You may choose to double-check the following files for integrity and proper settings:<br />
<br />
'''/etc/rc.conf''' # Specifically, check your HOSTNAME= and NETWORKING section for typos and errors.<br />
<br />
'''/etc/hosts''' # Double-check your format. (See above.)<br />
<br />
'''/etc/resolv.conf''' # If you are using a static IP. If you are using DHCP, this file will be dynamically created and destroyed by default, but can be changed to your preference. (See [[Network]].)<br />
<br />
Advanced instructions for configuring the network can be found in the [[Network]] article.<br />
<br />
====Wired LAN====<br />
<br />
Check your Ethernet with<br />
ifconfig -a<br />
All interfaces will be listed. You should see an entry for eth0, or perhaps eth1. If required, you can set a new static IP with<br />
ifconfig eth0 <ip address> netmask <netmask> up <br />
and the default gateway with<br />
route add default gw <ip address of the gateway><br />
Check to see if /etc/resolv.conf contains your DNS server and add it if it is missing. <br />
Check your network again with ping www.google.de. If everything is working now, adjust /etc/rc.conf as described above for static IP. If you have a DHCP server/router in your network try<br />
dhcpcd eth0<br />
If this is working, adjust /etc/rc.conf as described above, for dynamic IP.<br />
<br />
====Wireless LAN====<br />
Detailed setup guide: [[Wireless Setup]]<br />
<br />
====Analog Modem====<br />
To be able to use a Hayes-compatible, external, analog modem, you need to at least have the ppp package installed. Modify the file /etc/ppp/options to suit your needs and according to man pppd. You will need to define a chat script to supply your username and password to the ISP after the initial connection has been established. The manpages for pppd and chat have examples in them that should suffice to get a connection up and running if you're either experienced or stubborn enough. With udev, your serial ports usually are /dev/tts/0 and /dev/tts/1.<br />
Tip: Read [[Dialup without a dialer HOWTO]].<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt to install wvdial or a similar tool to ease the setup process considerably. In case you're using a so-called WinModem, which is basically a PCI plugin card working as an internal analog modem, you should indulge in the vast information found on the [http://www.linmodems.org/ LinModem] homepage.<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, meaning that you won't need to recompile your kernel unless you're about to use rather odd ISDN hardware. After physically installing your ISDN card in your machine or plugging in your USB ISDN-Box, you can try loading the modules with modprobe. Nearly all passive ISDN PCI cards are handled by the hisax module, which needs two parameters: type and protocol. You must set protocol to '1' if your country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3' if you're hooked to a so-called leased-line without D-channel, and '4' for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the kernel documentation, more specifically in the isdn subdirectory, and available online. The type parameter depends on your card; a list of all possible types can be found in the README.HiSax kernel documentation. Choose your card and load the module with the appropriate options like this:<br />
<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my ELSA Quickstep 1000PCI, being used in Germany with the EDSS1 protocol. You should find helpful debugging output in your /var/log/everything.log file, in which you should see your card being prepared for action. Please note that you will probably need to load some USB modules before you can work with an external USB ISDN Adapter.<br />
<br />
Once you have confirmed that your card works with certain settings, you can add the module options to your /etc/modprobe.conf:<br />
<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively, you can add only the options line here, and add hisax to your MODULES array in the rc.conf. It's your choice, really, but this example has the advantage that the module will not be loaded until it's really needed.<br />
<br />
That being done, you should have working, supported hardware. Now you need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl; it'll get you started. Further down in the manpage you will find explanations on how to create a configuration file that can be parsed by isdnctrl, as well as some helpful setup examples. Please note that you have to add your SPID to your MSN setting separated by a colon if you use US NI1.<br />
<br />
After you have configured your ISDN card with the isdnctrl utility, you should be able to dial into the machine you specified with the PHONE_OUT parameter, but fail the username and password authentication. To make this work add your username and password to /etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were configuring a normal analogous PPP link, depending on which protocol your ISP uses for authentication. If in doubt, put your data into both files.<br />
<br />
If you set up everything correctly, you should now be able to establish a dial-up connection with<br />
isdnctrl dial ippp0<br />
as root. If you have any problems, remember to check the logfiles!<br />
<br />
====DSL (PPPoE)====<br />
<br />
These instructions are relevant to you only if your PC itself is supposed to manage the connection to your ISP. You do not need to do anything but define a correct default gateway if you are using a separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to physically install the network card that is supposed to be connected to the DSL-Modem into your computer. After adding your newly installed network card to the modules.conf/modprobe.conf or the MODULES array, you should install the rp-pppoe package and run the pppoe-setup script to configure your connection. After you have entered all the data, you can connect and disconnect your line with<br />
<br />
/etc/rc.d/adsl start<br />
<br />
and<br />
<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward, but feel free to read the manpages for hints. If you want to automatically dial in on boot-up, add adsl to your DAEMONS array.<br />
<br />
==Update, Sync and Upgrade the system with [[pacman]]==<br />
Now we will update the system using [[pacman]]. <br />
<br />
=====What is pacman ?=====<br />
[[Pacman]] is the '''pac'''kage '''man'''ager of Arch Linux. Pacman is written in C and is fast, simple, and extremely powerful. It manages your entire package system and handles installation, removal, package downgrade (through cache), custom compiled package handling, automatic dependency resolution, remote and local searches and much more. Arch uses the .tar.gz package format, which further enhances pacman's speed; Gzipped tarballs, though slightly larger, are decompressed much faster than their Bzipped counterparts, and are therefore generally installed more expediently. <br />
<br />
We will use pacman to download software packages from remote repositories and install them onto your system.<br />
<br />
Pacman is the most important tool in your Arch Linux toolbox for building the base system into whatsoever you please.<br />
<br />
===Configuring pacman===<br />
<br />
=====Package Repositories and /etc/pacman.conf=====<br />
Arch currently offers the following repositories readily accessible through pacman:<br />
<br />
'''[core]'''<br />
<br />
The simple principle behind [core] is to provide only one of each necessary tool for a base Arch Linux system; The GNU toolchain, the Linux kernel, one editor, one command line browser, etc. (There are a few exceptions to this. For instance, both vi and nano are provided, allowing the user to choose one or both.) Developer maintained.<br />
<br />
*''The Core installation cd simply contains an installer script, and a snapshot of the core repository.''<br />
<br />
'''[extra]'''<br />
<br />
The [extra] repository contains all Arch packages that are not themselves necessary for a base Arch system, but contribute to a more full-featured environment. '''X''', KDE and GNOME, for instance, can be found here. Developer maintained.<br />
<br />
'''[unstable]'''<br />
<br />
The [unstable] repository contains experimental and unstable software, especially if the development version of a package has become popular for some reason. For example, perhaps the upstream stable version is hopelessly out of date, or the unstable version has some groundbreaking changes that a lot of users seem interested in, like experimental kernel drivers or -svn package versions. Developer maintained.<br />
<br />
{{Box Note |'''Contrary to popular belief, it is perfectly safe to enable the unstable repository, as there are no name collisions with [core], [community] or [extra]. Packages from [unstable] are only installed if you explicitly do so. If there is a conflict between an [Unstable] package and an installed package, pacman will warn you and resolve the conflict, if prompted, by removing the installed package.'''}}<br />
<br />
The [unstable] repository is currently not maintained for ''x86_64''.<br />
<br />
'''[testing]'''<br />
<br />
The [testing] repository contains packages that are candidates for the [core], [extra] or [unstable] repositories. New packages go into [testing] if:<br />
* they are expected to break something on update and need to be tested first<br />
* they require other packages to be rebuilt. In this case, all packages that need to be rebuilt are put into [testing] first and when all rebuilds are done, they are moved back to the other repositories. Developer maintained.<br />
<br />
[testing] is the only repository that can have name collisions with any of the other official repositories. If enabled, it has to be the first repo listed in your ''pacman.conf'' file.<br />
<br />
{{Box Note|'''''Be careful when enabling [testing]. Your system may break after you update with [testing] enabled. Only experienced users should use it.'''''}}<br />
<br />
'''[community]'''<br />
<br />
The [community] repository is maintained by the ''Trusted Users (TUs)'' and is part of the ''Arch User Repository ([[AUR]])''. It contains binary packages from the ''AUR'' that have enough votes and were adopted by a ''TU''. Like all repos listed above, [community] may be readily accessed by pacman.<br />
<br />
The '''[[AUR]]''' also contains the '''unsupported''' branch, which cannot be accessed directly by pacman*. [unsupported] contains more than 8 thousand PKGBUILD scripts for building packages from source, that may be unavailable through the other repos. <br />
<br />
<nowiki>*</nowiki>''The '''''[[#Install Yaourt| yaourt]]''''' tool, an extremely popular, community contributed wrapper for pacman, can seamlessly access the '''AUR'''.''<br />
<br />
'''/etc/pacman.conf'''<br />
<br />
pacman will attempt to read /etc/pacman.conf each time it is invoked. This configuration file is divided into sections, or repositories. Each section defines a package [[Official Repositories|repository]] that pacman can use when searching for packages. The exception to this is the options section, which defines global options.<br />
nano /etc/pacman.conf<br />
Example:<br />
[core]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[extra]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
#[unstable]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[community]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
Enable all desired repositories (remove the # in front of the 'Include =' and '[repository]' lines).<br />
<br />
<br />
*'''''When choosing repos, be sure to uncomment both the repository header lines in [brackets] as well as the 'Include =' lines. Failure to do so will result in the selected repository being omitted! This is a very common error.'' '''<br />
<br />
====/etc/pacman.d/mirrorlist====<br />
Faster mirrors will dramatically improve pacman performance, and your overall Arch Linux experience.<br />
<br />
Edit /etc/pacman.d/mirrorlist:<br />
nano /etc/pacman.d/mirrorlist<br />
Remove all mirrors which are not on your continent, or are extremely distant. (Using nano, you may use CTRL-K to cut each unneeded line.) <br />
<br />
Edit /etc/pacman.d/mirrorlist by placing the best mirror at the top of the list. (Recall that archlinux.org is throttled to 50KB/s). If using nano, you can cut a line with CTRL-K and paste with CTRL-U. <br />
<br />
After changing mirrors, issue the following command:<br />
pacman -Syy<br />
This will force pacman to resynchronize with the new repo. Issuing pacman -Syy ''whenever a mirror is changed'', is good practice and will avoid possible headaches.<br />
=====Ignoring packages=====<br />
When you execute the command "pacman -Syu", your entire system will be updated. It is possible that you want to prevent a package from being upgraded. An example could be the kernel (kernel26) or a package for which an upgrade may prove problematic for your system. In this case, you have two options; indicate the packages you want to skip in the pacman command line using the --ignore switch (do pacman -S --help for details) or permanently indicate the packages you want to skip in your /etc.pacman.conf file:<br />
<br />
IgnorePkg = kernel26<br />
The typical way to use Arch is to use pacman to install all packages unless there is no package available, in which case you can build your own package using [[ABS]]. Many user-contributed packages are available in the Arch User Repository. You are expected to keep your system up to date with pacman -Syu, rather than selectively upgrading packages. Use of '''IgnorePkg''' in /etc/pacman.conf is therefore discouraged, and should be used sparingly, if you know what you are doing.<br />
<br />
You may diverge from this typical usage as you wish; just be warned that there is a greater chance that things will not work as intended and that it could break your system. The majority of complaints happen when selective upgrading or unusual compilation is performed.<br />
<br />
=====Ignoring Configuration Files=====<br />
In the same vein, you can also "protect" your configuration/system files from being overwritten during "pacman -Su" using the following option in your /etc/pacman.conf<br />
<br />
NoUpgrade = etc/lilo.conf boot/grub/menu.lst<br />
<br />
==Update System==<br />
Update, sync, and '''upgrade''' your entire new system with:<br />
pacman -Syu<br />
pacman will now fetch the latest information about available packages and perform all available upgrades. (You may be prompted to upgrade pacman itself at this point. If so, say yes, and then reissue the pacman -Syu command when finished.) <br />
Reboot if a kernel upgrade has occurred. <br />
{{Box Note|'''''Occasionally, configuration changes may take place requiring user action during an update; read pacman's output for any pertinent information.'''''}}<br />
<br />
=====Прелесть Arch'овой Rolling-release'ной модели=====<br />
Запомните, что Arch это дистрибутив с '''rolling release''' моделью. Это значит, что у вас никогда не возникнет причин для переустановки или or или разбираться в очередном релизе для обновления вашей системы. Просто переодически используйте '''pacman -Syu''' и ваша система будет всегда свежа, обновлена (и хорошо пахнуть :). После данного обновления все компоненты вашей системы будут иметь текущие версии.<br />
Если было также обновлено и ядро, перезагрузитесь (команда reboot).<br />
<br />
=====Get familiar with pacman=====<br />
Pacman is the Arch user's best friend. It is highly recommended to study and learn how to use the pacman tool. Try:<br />
man pacman<br />
Check out the bottom of this article, and look up the [[pacman]] wiki entries at your leisure.<br />
<br />
<br />
<br />
===Add a user and setup groups===<br />
You should not do your everyday work using the root account. It is more than poor practice; it is dangerous. Root is for administrative tasks. Instead, add a normal user account using:<br />
adduser<br />
While most default options are safe to use, you may want to add storage, audio, video, optical, and wheel to your additional groups- especially if you are planning on having a full-featured desktop environment. <br />
<br />
Groups and users thereof are defined in /etc/group. <br />
<br />
They include:<br />
<br />
*'''audio''' - for tasks involving sound card and related software<br />
<br />
*'''wheel''' - for using sudo<br />
<br />
*'''storage''' - for managing storage devices<br />
<br />
*'''video''' - for video tasks and 3d acceleration<br />
<br />
*'''optical''' - for managing tasks pertaining to the optical drive(s)<br />
<br />
*'''floppy''' - for access to a floppy if applicable<br />
<br />
*'''lp''' - for managing printing tasks<br />
<br />
See the [[Groups]] article to understand what groups you need to be a member of. <br />
<br />
Check the man pages for usermod and gpasswd for more information.<br />
=====Install and setup Sudo=====<br />
<br />
See [[Sudo]]<br />
<br />
==Часть II: Ставим X и настраиваем ALSA==<br />
<br />
<br />
===Настройка звуковой карты с помощью alsamixer===<br />
Advanced Linux Sound Architecture (известная под акронимом '''ALSA''') это компонент ядра систему Linux, призванный заменить Open Sound System (OSS) представляющий драйвера для звуковых карт. Кроме драйверов, '''ALSA''' так же предоставляет библиотеки для разработчиков, которые хотят использовать возможности драйвера на более высоком уровне API, нежели прямое взаимодействие с драйверами ядра.<br />
-----<br />
{{Box Note|udev автоматически проверит ваше устройство во время загрузки, загрузив соотвествующий драйвер для вашей звуковой карты. Ваша аудиосистема, скорее всего, уже работает, но по умолчанию звук отключен (mute).}} <br />
Пакет утилит alsa содержит alsamixer, который позволяет настраивать звук прямо из консоли. (Вы сможете загружать aslamixer также из окружения '''X''' несколько позже.)<br />
<br />
Установка пакета утилит alsa:<br />
pacman -S alsa-utils<br />
Вы добавили-то обычного пользователя в группу audio? Если нет, то сейчас самое время! Под root'ом выполните:<br />
gpasswd -a yourusername audio<br />
Завершите сеанс (exit) и снова войдите под обычным пользователем, дабы удостоверится, что группа audio загрузилась верно.<br />
<br />
Под '''''простым, не root'овым''''' пользователем, выполните: <br />
'''[root@myhost ~]#''' alsamixer<br />
Включите каналы MASTER и PCM, подведя к ним курсор стрелочками лево/право и нажатием английской '''M'''. Увеличьте громкость клавишей "вверх" (70-90% должно быть в самый раз). Закройте микшер нажатием ESC.<br />
<br />
==== Проверка звука ====<br />
Проверьте настройку вашей аудиокарты коммандой aplay:<br />
aplay /usr/share/sounds/alsa/Front_Center.wav<br />
Вы услышите чарующий, манящий, жаркий и нежный, искрящийся всеми цветами радуги и клубящийся утренним туманом на горе Фудзи в лучах восходящего солнца, женский голос, прозносящий: "Front, center."<br />
<br />
Теперь залогинтесь под root'ом и выполните комманду alsactl:<br />
alsactl store<br />
Это приведет к созданию '/etc/asound.state', сохраняя найстроки asla-микшера.<br />
<br />
Также, добавте ''daemon'' alsa в вашу DAEMONS-секцию (демоническая секция, а-а-а!) в /etc/rc.conf дабы настройки микшера восстанавливались при каждой загрузке автоматически.<br />
nano /etc/rc.conf<br />
DAEMONS=(syslog-ng network crond '''alsa''')<br />
''Учтите, что демон alsa'ы просто восстанавливает уровни громкости микшера при загрузки путем чтения /etc/asound.state. Это происходит независимо от аудио-библиотеки alsa (и уровня громкости API ядра).''<br />
<br />
Дополнительную информацию можно найти в wiki-записи [[ALSA]].<br />
<br />
===Устанавливаем и настраиваем X-ы===<br />
О, великие '''X''' Window System (обычно '''X11''', или '''X''', или просто '''Иксы''') это сетевой и экранный протокол, который поддерживает оконную систему на bitmap-дисплеях. Иксы предоставляют арсенал утилит и протокол для создания Графического Интефейса Пользователя (GUI) на <code>UNIX</code>'овых операционных системах.<br />
<br />
'''X''' представляет базовый фреймворк, на примитивах, для создания GUI'овых сред: отрисовка и перемещение окон по экрану и взаимодействие с мышкой/клавиатурой. '''X''' не предоставляет пользовательский интерфейс — это поддерживает индивидуальная клиент-программа. <br />
<br />
'''X''' так назван, поскольку им предшествовала '''W''' Window System, разработанна в Стендфорском Университете. <br />
-----<br />
<br />
{{Box Note| Если вы планировали использовать '''open-source''' видео-драйвер, и если вам нужно 3d-ускорение, рекомендуется инсталлировать библиотеку libgl перед установкой Xorg:}}<br />
pacman -S libgl<br />
''(Проприетанрные видеодрайверы обеспечивают свои собственные реализации этой библиотеки)''<br />
----- <br />
Теперь мы установим основные пакеты Xorg, используя pacman. Это - первый шаг в построении GUI.<br />
<br />
pacman -S xorg<br />
3d-утилиты, такие как glxgears включены пакет '''mesa''':<br />
pacman -S mesa<br />
<br />
Теперь у нас есть основные пакеты, в которых мы нуждаемся для того, чтобы запустить '''X''' Server. Сейчас вы должны добавить драйвер для своей видеокарты (к примеру xf86-video-<имя>). Самый простой способ конфигурировать X.org, устанавливая корретные пакеты драйвера сначала, а затем генерируя /etc/X11/xorg.conf испольуя скрипт автоконфигурации, такой как Xorg - configure.<br />
<br />
Если вы хотите увидеть весь список '''open-source''' видеодрайверов, используйте: <br />
pacman -Ss xf86-video | less<br />
Вам нужно знать, какой видеочипсет на вашем компьютере. Если вы не знаете, выполните:<br />
lspci | grep VGA<br />
Здесь приведен список '''open source''' драйверов и соотвествующих графических чипсетов..<br />
*'''xf86-video-apm''' Alliance ProMotion video driver<br />
*'''xf86-video-ark''' ark video driver<br />
*'''xf86-video-ati''' ati video driver<br />
*'''xf86-video-chips''' Chips and Technologies video driver<br />
*'''xf86-video-cirrus''' Cirrus Logic video driver<br />
*'''xf86-video-dummy''' dummy video driver<br />
*'''xf86-video-fbdev''' framebuffer video driver<br />
*'''xf86-video-glint''' GLINT/Permedia video driver<br />
*'''xf86-video-i128''' Number 0 i128 video driver<br />
*'''xf86-video-i740''' Intel i740 video driver<br />
*'''xf86-video-i810''' Intel i810/i830/i9xx video drivers (deprecated - use -intel)<br />
*'''xf86-video-intel''' Newer Version of Intel i810/i830/i9xx video drivers<br />
*'''xf86-video-imstt''' Integrated Micro Solutions Twin Turbo vidoe driver<br />
*'''xf86-video-mga''' mga video driver (Matrox Graphics Adapter)<br />
*'''xf86-video-neomagic''' neomagic video driver<br />
*'''xf86-video-nv''' nvidia nv video driver<br />
*'''xf86-video-rendition''' Rendition video driver<br />
*'''xf86-video-s3''' S3 video driver<br />
*'''xf86-video-s3virge''' S3 Virge video driver<br />
*'''xf86-video-savage''' savage video driver<br />
*'''xf86-video-siliconmotion''' siliconmotion video driver<br />
*'''xf86-video-sis''' SiS video driver<br />
*'''xf86-video-sisusb''' SiS USB video driver<br />
*'''xf86-video-tdfx''' tdfx video driver<br />
*'''xf86-video-trident''' Trident video driver<br />
*'''xf86-video-tseng''' tseng video driver<br />
*'''xf86-video-unichrome''' Unichrome video drivers<br />
*'''xf86-video-v4l''' v4l video driver<br />
*'''xf86-video-vesa''' vesa video driver<br />
*'''xf86-video-vga''' VGA 16 color video driver<br />
*'''xf86-video-via''' via video driver<br />
*'''xf86-video-vmware ''' vmware video driver<br />
*'''xf86-video-voodoo ''' voodoo video driver<br />
<br />
* Отмечу, что '''vesa''' драйвера являются самыми универсальными, и будут работать почти со всеми современными графическими чипсетами. Если вы не смогли найти подходящий драйвер, то уж vesa '''должна''' работать.<br />
<br />
*Если у Вас есть NVIDIA или видеоадаптер ATI, Вы можете установить проприетарных NVIDIA или ATI драйвер. '''Установка проприетарных видеодрайверов освещена в [[#Использование проприетарных графических драйверов (NVIDIA, ATI)|чуть ниже]].'''<br />
<br />
Используйте pacman для инсталляции подходящего видеодрайвера для вашей видеокарты:<br />
pacman -S xf86-video-savage<br />
(для драйвера от Savage)<br />
<br />
==Создание /etc/X11/xorg.conf==<br />
=====Что такое /etc/X11/xorg.conf?=====<br />
/etc/X11/xorg.conf это главный конфигурационный файл вашей '''X''' Window System, основа основ вашего '''G'''raphical '''U'''ser '''I'''nterface. Это текстовой файл, разбитый на секции и подсекции. Важными являются секции ''Files, InputDevice, Module, Monitor, Modes, Screen, Device, и ServerLayout''. Секции могут располагаться в любом порядке, может быть несколько секций одного типа, к примеру, если у вас более одного монитора или если у вашего ноутбука кроме мышки есть еще и тачпад. <br />
------<br />
По умолчанию, у вас не будет конфигурационного xorg-файла. В последних версиях xorg он не нужен, ''если'' автоопределение ''работает нормально'' и вам не нужно вручную включать такие штуки, как aiglx и тому подобное. <br />
<br />
''Большинство людей считают, что им все равно необходимо сгенерировать этот файл.''<br />
<br />
<br />
Опытные пользователи обычно желают вручную сгенерировать свой собственный xorg.conf. Вы так же можете использовать скрипт Xorg -configure для базовой конфигурации. Под root'ом исполните:<br />
Xorg -configure<br />
Будет создан конфиг-файл в /root/xorg.conf.new <br />
<br />
Для теста сервера, введите:<br />
X -config /root/xorg.conf.new<br />
'''X''' запустится. Вы получите на экране бело-черный мышиный курсор в виде буквы '''X''', который будет откликаться на движение мышки/тачпада. Используйте CTRL-Alt-Backspace дабы покинуть '''X'''.<br />
<br />
Просмотр вашего конфиг-файла на предмет ошибок:<br />
<br />
nano /root/xorg.conf.new<br />
<br />
Убедитесь, что скрипт Xorg -configure корректно определил ваш видеодрайвер. к примеру:<br />
Section "Device"<br />
<br />
...<br />
<br />
Driver "vesa"<br />
VendorName "VM Ware Inc" #если вы запускаете ArchLinux в эмуляторе VM Ware<br />
<br />
...<br />
<br />
EndSection<br />
<br />
Убедитесь, что горизонтальная синхронизация и вертикальная частота обновления заданы под секцией "Monitor". Если нет, то задайте их:<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
VendorName "Monitor Vendor"<br />
ModelName "Monitor Model"<br />
HorizSync 30.0 - 130.0 # Подходит для большиства LCD мониторов<br />
VertRefresh 50.0 - 100.0 # Подходит для большинства LCD и CRT мониторов.<br />
EndSection<br />
(Если вы точно не знаете этих настроек, откройте инструкцию от вашего монитора.)<br />
<br />
Задайте глубину цвета под секцией "Screen":<br />
Section "Screen"<br />
Identifier "Screen0"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
(Значит, что мы установили 24битный цвет, что соотвествует true color (миллионы цветов)<br />
<br />
Также, добавьте желаемые режимы в подсекцию "Display" , в конце, под Depth 24 , к примеру:<br />
SubSection "Display"<br />
Viewport 0 0<br />
Depth 24<br />
Modes "1024x768" "800x600" "640x480"<br />
Добавьте следующий раздел, если Вы желаете включить eye candy, который требует дополнительного расширения: <br />
Section "Extensions"<br />
Option "Composite" "Enable"<br />
EndSection<br />
Испытайте ваш конфиг снова, после изменения:<br />
X -config /root/xorg.conf.new<br />
Убедитесь, что сессия '''X''' открылась без ошибок и переместите сгенерированный конфиг-файл в /etc/X11/:<br />
mv /root/xorg.conf.new /etc/X11/xorg.conf<br />
Подробные инструкции смотрите в статье [[Xorg]].<br />
<br />
====Alternative xorg.conf generation====<br />
If Xorg -configure is not generating a usable xorg.conf, you may alternatively use the hwd tool. Install with:<br />
pacman -S hwd<br />
And run with<br />
hwd -xa <br />
Lastly, you may choose xorgconfig, which will interactively prompt you for hardware information to create a basic xorg.conf:<br />
xorgconfig<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
===Using proprietary Graphics Driver (NVIDIA, ATI)===<br />
You may choose to use the proprietary video drivers from NVIDIA or ATI. <br />
====NVIDIA Graphic Cards====<br />
The NVIDIA proprietary drivers are generally considered to be of good quality, and offer 3D performance, whereas the open source '''nv''' driver offers only 2d support at this time. <br />
<br />
Before you configure your Graphics Card you will need to know which driver fits. Arch currently has 3 different driver packages that each match a certain subset of Cards: <br />
<br />
'''1. nvidia-71xx''' ''for very old Cards like TNT and TNT2''<br />
<br />
'''2. nvidia-96xx''' ''slightly newer cards up to the GF 4''<br />
<br />
'''3. nvidia''' ''newest GPUs after the GF 4''<br />
<br />
Consult the NVIDIA-Homepage to see which one is for you. The difference is only for the installation; Configuration works the same with every driver.<br />
<br />
Select and install the appropriate NVIDIA driver ''for your card'', e.g.: <br />
pacman -S nvidia-96xx<br />
<br />
The NVIDIA package has a utility for updating your existing /etc/X11/xorg.conf for use with the NVIDIA driver:<br />
nvidia-xconfig<br />
<br />
It also has several options which will further specify the contents and options of the xorg.conf file.<br />
For example,<br />
nvidia-xconfig --composite --add-argb-glx-visuals<br />
<br />
For more detailed information, see nvidia-xconfig(1).<br />
<br />
Some useful tweaking options in the device section are (beware that these may not work on your system):<br />
Option "RenderAccel" "true"<br />
Option "NoLogo" "true"<br />
Option "AGPFastWrite" "true"<br />
Option "EnablePageFlip" "true"<br />
Make sure all instances of DRI are commented out:<br />
# Load "dri"<br />
Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
Update kernel module dependencies:<br />
depmod -a<br />
<br />
Advanced instructions for nvidia configuration can be found in the [[NVIDIA]] article.<br />
<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
====ATI Graphic Cards====<br />
ATI owners have two options for drivers. If you are unsure which driver to use, please try the open-source one first. The open-source driver will suit most needs along with being generally less problematic.<br />
<br />
Install the '''proprietary''' ATI Driver with<br />
pacman -S catalyst<br />
Use the aticonfig tool to modify the xorg.conf.<br />
<br />
Install the '''open-source''' ATI Driver with<br />
pacman -S xf86-video-ati<br />
Currently, the performance of the open-source driver is not on par with that of the proprietary one. It also lacks TV-out, dual-link DVI support, and possibly other features. On the other hand, it supports Aiglx and has better dual-head support.<br />
{{Box Note| The latest proprietary driver does support [[AIGLX]] now. To use [[Compiz]] or [[Beryl]] add Option "AIGLX" "True" to Section ServerFlags and Option "Composite" "True" to Section Extensions.}}<br />
Advanced instructions for ATI configuration can be found in the [[ATI | ATI wiki]].<br />
<br />
===Simple baseline X test===<br />
<br />
At this point, you should have xorg installed, with a suitable video driver and an /etc/X11/xorg.conf configuration file. If you want to test your configuration quickly, to ensure your ability to start '''X''' from the command line before installing a complete desktop environment, you can do so by invoking '''xterm'''. Xterm is a very simple terminal emulator which runs in the '''X '''Server environment; it is installed as part of the base xorg packages.<br />
<br />
Prepare for the test by configuring a ~/.xinitrc:<br />
<br />
===== ~/.xinitrc =====<br />
This file dictates what '''X''' Window client is invoked with the '''startx''' and/or '''xinit''' command ''on a per-user basis''. (The '''startx''' script is merely a front end to the more versatile '''xinit''' command.) <br />
<br />
To determine the client to run, '''startx/xinit''' will first look for a .xinitrc file in the user's home directory. In the absence of file ~/.xinitrc, it defaults to the global xinitrc in the xinit library directory; /etc/X11/xinit/xinitrc, which defaults to using the TWM window manager. (Hence, if you invoke startx without a ~/.xinitrc file, a TWM session will start.)<br />
<br />
Switch to your '''''normal, non-root''''' user:<br />
su yourusername<br />
* /etc/skel/ contains files and directories to provide sane defaults for newly created user accounts. The name '''skel''' is derived from the word '''skeleton''', because the files it contains form the basic structure for users' home directories.<br />
Copy the sample xinitrc file from /etc/skel/ to your home directory: <br />
<br />
cp /etc/skel/.xinitrc ~/<br />
Edit the file: <br />
nano ~/.xinitrc<br />
and add:<br />
<br />
exec xterm<br />
<br />
So that it looks like this:<br />
<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
#<br />
exec xterm<br />
# exec wmaker<br />
# exec startkde<br />
# exec icewm<br />
# exec blackbox<br />
# exec fluxbox<br />
<br />
''Be sure to have only one uncommented '''exec''' line in your ~/.xinitrc at this time''. Below, we shall edit this file again to specify the appropriate desktop environment/window manager of your choice.<br />
<br />
Start '''X''' Server as '''normal, non-root''' user, with:<br />
<br />
startx<br />
or<br />
xinit<br />
You should have an '''xterm''' session open up. You can exit the '''X''' Server with Ctrl+Alt+Backspace, or by typing "exit". If you have problems starting '''X''', you can look for errors in the /var/log/Xorg.0.log file and on the console output of the console you started '''X''' from.<br />
<br />
If you prove a properly configured /etc/X11/xorg.conf by successfully running the test, you can be assured that your DE/WM of choice will work smoothly.<br />
<br />
Advanced instructions for Xorg configuration can be found in the [[Xorg]] article.<br />
<br />
==Part III: Installing and configuring a Desktop Environment ==<br />
While The '''X''' Window System provides the basic framework for building a ''graphical user interface'' (GUI), a '''Desktop Environment''' (DE), works atop and in conjunction with '''X''', to provide a completely functional and dynamic GUI. A DE typically provides icons, applets, windows, toolbars, folders, wallpapers, applications and abilities like drag and drop. The particular functionalities and designs of each DE will uniquely affect your overall environment and experience. Therefore, choosing a DE is a very subjective and personal decision. Choose the best environment for ''your'' needs.<br />
<br />
* If you want something full-featured and similar to Windows and Mac OSX, '''[[#KDE|KDE]]''' is a good choice<br />
* If you want something slightly more minimalist, which follows the K.I.S.S. principle more closely, '''[[#GNOME|GNOME]]''' is a good choice<br />
* '''[[#Xfce|Xfce]]''' is generally perceived as similar to GNOME, but lighter and less demanding on system resources, yet still visually pleasing and providing a very complete environment.<br />
<br />
If you have an older machine, or desire a lighter, less demanding GUI, you may choose to simply install a '''Window Manager''', or WM. A WM controls the placement and appearance of application windows in conjunction with the X Window System but does NOT provide such additions as panels, applets, icons, applications, etc.<br />
* Lightweight WM's include: '''Openbox, Fluxbox, fvwm2''', '''Windowmaker, Awesome and TWM'''.<br />
* If you need something completely different, try '''ion, wmii, dwm, or xmonad'''.<br />
<br />
===Install Fonts===<br />
At this point, you may want to install some good-looking fonts, '''before''' installing a desktop environment/window manager, (so you don't have to stare at ugly bitmap fonts in X). Dejavu and bitstream-vera are nice font sets. For websites, you may want to have the Microsoft fonts too. Install with:<br />
pacman -S ttf-ms-fonts ttf-dejavu ttf-bitstream-vera<br />
<br />
===~/.xinitrc (again)===<br />
<br />
As '''non-root user''', edit your /home/username/.xinitrc to utilize the DE you wish to use. This will allow you to use '''startx/xinit''' from the shell to open your DE/WM of choice:<br />
<br />
nano ~/.xinitrc<br />
<br />
Uncomment or add the ''''exec''' ..' line of the appropriate desktop environment/window manager. Some examples are below.<br />
<br />
For the Xfce4 desktop environment:<br />
exec startxfce4 <br />
<br />
For the KDE desktop environment:<br />
exec startkde<br />
A '''startkde''' or '''startxfce4''' command starts the KDE or Xfce4 desktop environment. This command does not finish until you logout of the DE. Normally the shell would wait for KDE to finish, then run the next command. The "exec" prefix to this command tells the shell that this is the last command, so the shell does not need to wait to run a subsequent command.<br />
<br />
Remember to have only one uncommented '''exec''' line in your ~/.xinitrc for now. <br />
<br />
Continue below, installing the DE/WM of your choice.<br />
<br />
===GNOME===<br />
====О проекте GNOME====<br />
'''G'''NU '''N'''etwork '''O'''bject '''M'''odel '''E'''nvironment. Проект GNOME сочетает в себе две вещи: интуитивно-понятное и приятное окружение рабочего стола, а также платформу для разработки, позволяющую создавать полностью интегрированные между собой и остальным окружением приложения.<br />
<br />
<br />
====Установка====<br />
Установить базовый набор пакетов GNOME можно следующей командой:<br />
pacman -S gnome<br />
<br />
Дополнительные пакеты (эмулятор терминала, текстовый редактор и т.д.) находятся в группе gnome-extra:<br />
pacman -S gnome-extra<br />
<br />
=====Полезные демоны для GNOME=====<br />
Демон - это исполняемая в фоне программа, которая дожидается определенных событий и обрабатывает их. Демон '''hal''', кроме всего прочего, автоматизирует монтирование жестких дисков, оптических приводов и флэш-накопителей. Демон '''fam''' обрабатывает изменения в структуре данных файловой системы, позволяя в реальном времени отслеживать изменения в файлах или директориях. Оба этих демона позволяют сильно упростить работу с окружением. Они устанавливаются при установке GNOME, но должны быть запущены для начала работы:<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
<br />
В качестве менеджера сессий хорошим выбором будет '''gdm'''.<br />
<br />
Установка:<br />
pacman -S gdm<br />
<br />
Для запуска этих демонов при загрузке, следует добавить их в секцию DAEMONS конфигурационного файла /etc/rc.conf :<br />
nano /etc/rc.conf<br />
<br />
DAEMONS=(syslog-ng network crond alsa '''hal fam gdm''')<br />
<br />
Демон gdm автоматически загружает графическую среду. Если вы попробуете её покинуть, используя ctrl+alt+backspace, он снова её загрузит. Если в этого не хотите, а хотите загружать граф.среду вручную, то ставьте в файле rc.conf перед именем этого демона (gdm) восклицательный знак (!). <br />
<br />
Чтобы запустить графическое окружение выполните:<br />
startx<br />
Если файл ~/.xinitrc не настроен для запуска GNOME, то окружение можно запустить командой xinit:<br />
xinit /usr/bin/gnome-session<br />
<br />
Дополнительные инструкции по установке и настройке могут быть найдены в статье [[GNOME_(Русский)|GNOME]].<br />
<br />
Поздравляем! Добро пожаловать в среду GNOME на вашей свежеустановленной системе Arch Linux! Также вы можете захотеть узнать о '''[[#Tweaks/Finishing touches|дополнительных настройках]]'''. Рекомендуется прочитать [[Post Installation Tips|советы]] после окончания установки и настройки.<br />
<br />
====Украшения====<br />
Вы можете захотеть поменять стандартную тему графического окружения. В данном случае, хорошим выбором будет тема "murrine".<br />
Установить можно следующей командой:<br />
pacman -S gtk-engine-murrine<br />
А затем выбрать данную тему в меню Система->Параметры->Внешний вид. Найти больше разнообразных тем оформления, наборов значков, фоновых изображений и т.п., вы можете на сайте [http://www.gnome-look.org Gnome Look].<br />
<br />
===KDE===<br />
====О KDE====<br />
'''K''' '''D'''esktop '''E'''nvironment. KDE - это мощное свободное окружение рабочего стола для рабочих станций GNU/Linux и <code>UNIX</code>. KDE сочетает лёгкость в использовании, современную функциональность и выдающийся графический дизайн с технологическим превосходством UNIX-подобных операционных систем.<br />
<br />
====Установка====<br />
Arch предлагает несколько вариантов kde: '''kde, kdebase, и KDEmod'''. Выберите '''один''' из представленных ниже, и продолжите дальше с '''[[#Useful KDE DAEMONS|Useful KDE DAEMONS]]''': <br />
<br />
'''1.)''' Пакет '''kde''' это полный, стандартнй KDE, ~300MB.<br />
pacman -S kde<br />
'''2.)''' Пакет '''kdebase''' это урезанная версия с меньшим количеством приложений, ~80MB.<br />
pacman -S kdebase<br />
'''3.)''' Наконец, '''KDEmod''' - это эксклюзив для Arch Linux, созданный по инициативе сообщества, которое модифицировало KDE для максимальной производительности и модульности. Веб-сайт проекта KDEmod может быть найден на [http://kdemod.ath.cx/ http://kdemod.ath.cx/]. KDEmod очень быстрый, легкий и гибкий, с приятной, собственной темой оформления<br />
<br />
====Useful KDE DAEMONS====<br />
<br />
KDE will require the '''hal''' ('''H'''ardware '''A'''bstraction '''L'''ayer) and '''fam''' ('''F'''ile '''A'''lteration '''M'''onitor) daemons. The '''kdm''' daemon is the '''K''' '''D'''isplay '''M'''anager, which provides a '''graphical login''', if desired.<br />
<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system.. Both '''hal''' and '''fam''' make life easier for the KDE user. The hal, fam and kdm packages are installed when you install KDE, but must be invoked to become useful.<br />
-----<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup. If you prefer a graphical login, add '''kdm''' as well: <br />
DAEMONS=(syslog-ng network crond alsa '''hal fam kdm''')<br />
*This method will start the system at runlevel 3, (/etc/inittab default, multiuser mode), and then start KDM as a daemon. <br />
<br />
*Some users prefer an alternative method of starting a display manager like KDM on bootup by utilizing the /etc/inittab method and starting the system at runlevel 5. See [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]] for more.<br />
<br />
*If you prefer to log into the '''console''' at runlevel 3, and manually start X in the 'Slackware tradition', leave out kdm, or comment it out with an exclamation. ( ! )<br />
<br />
Now try starting your X Server as normal user:<br />
startx<br />
Advanced instructions for installing and configuring KDE can be found in the [[KDE]] article.<br />
<br />
Congratulations! Welcome to your KDE desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===Xfce===<br />
====About Xfce====<br />
The cholesterol-free '''X''' environment. Xfce, like GNOME or KDE, is a desktop environment, but aims to be fast and lightweight while remaining visually appealing and easy to use. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit (like GNOME) and contains its own development environment (libraries, daemons, etc) similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and extremely fast. Xfce is great for older hardware, and will fly with especially great speed on newer machines as well.<br />
<br />
====Installation====<br />
Install Xfce: <br />
pacman -S xfce4 <br />
You may also wish to install themes and extras:<br />
pacman -S xfce4-goodies gtk2-themes-collection<br />
If you want to admire 'Tips and Tricks' on login, you must install the '''fortune-mod''' package:<br />
pacman -S fortune-mod <br />
====Useful DAEMONS====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. The hal and fam packages are installed when you install Xfce, but must be invoked to become useful.<br />
<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup.<br />
<br />
Advanced instructions for installing and configuring Xfce can be found in the [[Xfce]] article.<br />
<br />
If you wish to install one, see [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]]<br />
<br />
Congratulations! Welcome to your Xfce desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===*box===<br />
====Fluxbox====<br />
Fluxbox © is yet another windowmanager for X.<br />
It's based on the Blackbox 0.61.1 code. Fluxbox looks like blackbox and handles styles, colors, window placement and similar things exactly like blackbox (100% theme/style compability).<br />
<br />
Install Fluxbox using <br />
pacman -S fluxbox fluxconf<br />
<br />
If you use gdm/kdm a new fluxbox session will be automatically added. Otherwise, you should modify your user's .xinitrc and add this to it:<br />
exec startfluxbox <br />
<br />
More information is available in the [[Fluxbox]] article.<br />
<br />
====Openbox====<br />
Openbox is a standards compliant, fast, light-weight, extensible window manager.<br />
<br />
Openbox works with your applications, and makes your desktop easier to manage. This is because the approach to its development was the opposite of what seems to be the general case for window managers. Openbox was written first to comply with standards and to work properly. Only when that was in place did the team turn to the visual interface.<br />
<br />
Openbox is fully functional as a stand-alone working environment, or can be used as a drop-in replacement for the default window manager in the GNOME or KDE desktop environments. <br />
<br />
Install openbox using<br />
pacman -S openbox obconf obmenu<br />
<br />
Once openbox is installed you will get a message to move menu.xml & rc.xml to ~/.config/openbox/ in your home directory:<br />
<br />
mkdir -p ~/.config/openbox/<br />
cp /etc/xdg/openbox/rc.xml ~/.config/openbox/<br />
cp /etc/xdg/openbox/menu.xml ~/.config/openbox/<br />
<br />
In the file "rc.xml" you can change various settings for Openbox (or you can use OBconf). In "menu.xml" you can change your right-click menu.<br />
<br />
To be able to log into openbox you can either go via graphical login using KDM/GDM or startx, in which case you will need to edit your ~/.xinitrc (as user) and add the following:<br />
<br />
exec openbox<br />
You may also start openbox from the shell using '''xinit''':<br />
xinit /usr/bin/openbox-session<br />
* Openbox may also be used as the window manager for GNOME, KDE, and Xfce.<br />
For KDM there is nothing left to do; openbox is listed in the sessions menu in KDM.<br />
<br />
Useful programs for openbox are:<br />
* PyPanel or LXpanel if you want a panel<br />
* feh if you want to set the background<br />
* ROX if you want a simple file manager and desktop icons<br />
<br />
More information is available in the [[Openbox]] article.<br />
<br />
===fvwm2===<br />
FVWM is an extremely powerful ICCCM-compliant multiple virtual desktop window manager for the X Window system. Development is active, and support is excellent. <br />
<br />
Install fvwm2 with<br />
pacman -S fvwm <br />
<br />
fvwm will automatically be listed in kdm/gdm in the sessions menu. Otherwise, add <br />
exec fvwm <br />
<br />
to your user's .xinitrc.<br />
<br />
Note that this stable version of fvwm is a few years old. If you want a more recent version of fvwm, there is a fvwm-devel package in the unstable repo.<br />
<br />
=APPENDIX=<br />
==Tweaks/Finishing touches==<br />
===Install [http://archlinux.fr/yaourt-en# Yaourt]===<br />
'''Y'''et '''A'''n'''O'''ther '''U'''ser '''R'''epository '''T'''ool. Yaourt is a community-contributed wrapper for pacman which adds seamless access to the [[AUR]], allowing and automating package compilation and installation from your choice of the 8000+ PKGBUILDs in the [[AUR]], in addition to the many thousands of available Arch binary packages. Yaourt uses the same exact syntax as pacman, which saves you from relearning an entirely new method of system maintenance, but also adds new options. Yaourt expands the power and simplicity of pacman by adding even more useful features and provides pleasing, colorized output, interactive search mode, and much more. You will almost certainly want this. <br />
<br />
The easiest way to install Yaourt is to add the yaourt repository to your /etc/pacman.conf:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/i686<br />
for i686 or:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/x86_64<br />
for x86-64.<br />
<br />
Sync and install:<br />
pacman -Sy yaourt<br />
<br />
If you wish, you may then create your own command aliases in ~/.bashrc to save typing: <br />
nano ~/.bashrc<br />
<br />
alias p="pacman"<br />
alias y="yaourt" <br />
Save and then source:<br />
source ~/.bashrc<br />
See the [http://archlinux.fr/yaourt-en# yaourt] man page for more.<br />
<br />
===HAL===<br />
Since you have now installed a desktop environment, and if you did not do so earlier, now would be a good time to also install HAL. HAL allows plug-and-play for your mobile phone, your iPod, your external HD's, etc. It will mount the device and make a nice visual icon on your desktop and/or in 'My Computer', allowing you to access the device after you have plugged it in instead of having to manually configure the /etc/fstab file or udev rules for each and every new device.<br />
<br />
KDE, GNOME and XFCE all use HAL.<br />
<br />
The installation procedure is described in the [[HAL]] article. Some information can also be found at [http://en.wikipedia.org/wiki/HAL_(software) Wikipedia].<br />
<br />
===Backgrounding DAEMONS on startup===<br />
<br />
To speed up system start up procedure, background selected DAEMONS in /etc/rc.conf by prefixing them with a '@' e.g.:<br />
<br />
DAEMONS=(syslog-ng @network crond @alsa @hal @fam @kdm)<br />
This will enable daemons to load in the background, without waiting for the preceding daemon to load first.<br />
<br />
Prefix any daemons which you do not need with a bang (!) e.g.:<br />
<br />
DAEMONS=(syslog-ng @network !netfs !crond @alsa @hal @fam @kdm)<br />
<br />
Alternatively, you may also simply remove unneeded daemons.<br />
<br />
===Beautifying Fonts for LCD's===<br />
See [[Fonts]]<br />
<br />
===Adjusting Mouse for scroll wheel===<br />
While your mouse should be working out of the box, you may want to use your scroll wheel. Add this to your Input Section (mouse0):<br />
Option "ZAxisMapping" "4 5 6 7"<br />
<br />
===Get All Mouse Buttons Working===<br />
See [[Get All Mouse Buttons Working]]<br />
<br />
===Configuring Touchpad for Laptops===<br />
See [[Touchpad Synaptics]]<br />
<br />
===Adjusting Keyboard Layout===<br />
You may want to change your keyboard layout. To do this edit your /etc/X11/xorg.conf and add these lines in the InputDevice Section (Keyboard0) (the example shows a German keyboard layout with no dead keys; alter this to fit your needs).<br />
Option "XkbLayout" "de"<br />
Option "XkbVariant" "nodeadkeys"<br />
<br />
===Additional tweaks for laptops===<br />
ACPI support is needed if you want to use some special functions on your notebook (e.g. sleep, sleep when lid is closed, special keys...). Install <tt>acpid</tt> using<br />
pacman -S acpid<br />
and add it to the daemons in /etc/rc.conf. <tt>acpid</tt> should be started before <tt>hal</tt> and <tt>dbus</tt>, so take care to place it before any calls to hal and dbus. Manually, it can be started by<br />
/etc/rc.d/acpid start<br />
<br />
More-specific information about Arch Linux on various Laptops can be found at [[:Category:Laptops (English)]]<br />
<br />
===Configuring CPU frequency scaling===<br />
Modern processors can decrease their frequency and voltage to reduce heat and power consumption. Less heat leads to a quieter system; Laptop users will definitely want this, but even a desktop system will benefit from it. Install cpufrequtils with<br />
pacman -S cpufrequtils<br />
Edit the config file /etc/conf.d/cpufreq and change <br />
governor="ondemand"<br />
which dynamically increases the CPU frequency if needed (which is a safe choice on desktop systems too). Alter min_freq and max_freq to match your system's CPU spec. If you don't know the frequencies, run ''cpufreq-info'' after loading one of the frequency scaling modules. You can also comment out or delete the min_freq and max_freq lines: things will work automatically. Add the frequency scaling modules to your /etc/rc.conf modules line. Most modern notebooks and desktops can simply use the ''acpi-cpufreq'' driver, however other options include the ''p4-clockmod, powernow-k6, powernow-k7, powernow-k8, and speedstep-centrino'' drivers. Load the module with<br />
modprobe <modulname> <br />
and start cpufreq with<br />
/etc/rc.d/cpufreq start<br />
For more details, see [[Cpufrequtils]]<br />
<br />
===Pm-Utils===<br />
The pm-utils package will allow you to suspend-to-RAM and hibernate: <br />
pacman -S pm-utils<br />
[[Pm-utils]] wiki page.<br />
<br />
===Laptop-Mode===<br />
The laptop-mode-tools package is sort of a one-stop configuration for all laptop power management utilities. It works in conjunction with other installed tools to fully configure everything from hard disk spin-down to X display DPMS standby times, if desired.<br />
pacman -S laptop-mode-tools<br />
Add laptop-mode to your DAEMONS= line in /etc/rc.conf and configure /etc/laptop-mode/laptop-mode.conf.<br />
<br />
==File and directory explanation==<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, (as dictated by BIOS) just like the sda, sdb, etc.<br />
names in /dev. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 corresponding to the first entity. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding. <br />
<br />
{{ Box Note | The first appearance of 'root (hdx,x)' may be misleading. The '''root''' command is specifying '''''GRUB''''''s root, which corresponds to ''where the kernel resides, i.e. '''/boot'''''. Ensure that the drive and partition are correct, since '''''/boot''', does not necessarily share the same partition as the root filesystem, or /''.}}<br />
<br />
Once you have grasped the concept of device naming, choose a title for your boot section(s), create a kernel line that includes the partition and path to where the kernel resides, and supply the correct root filesystem device and partition as a parameter to the kernel root option to have it mounted as / on bootup, 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 to the initramfs on the initrd line will be the same as<br />
the path to vmlinuz26 that you provide on the kernel line, since both reside under /boot. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines.<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 />
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 also globally defines PS1, $PATH, bash aliases, etc. It is kept quite simple under Arch Linux, as most things are. You may wish 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 runlevels. 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 mounting filesystems, running udev, activating swap, loading modules, setting localization parameters, etc. You will most likely never need 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 started in single-user mode, for example with the kernel parameter 1 before booting or during normal multi-user operation with the command init 1, this script makes sure no daemons are running except for the bare minimum; syslog-ng and udev. The single-user mode is useful if you need to make any changes to the system while making sure that no remote user can do anything that might cause data loss or damage. <br />
For desktop users, this mode is usually quite useless. You should most likely have no need to edit this script.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the DAEMONS array (set in /etc/rc.conf) after which it calls /etc/rc.local. You shouldn't feel a pressing need to edit this file. <br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any last-minute commands you want the system to run at the very end of the bootup process. This is finally the one and only script you should modify if needed, and you have total freedom on what to add to this script. Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place where they belong. To avoid confusion, you should make sure that whatever you intend to add to your rc.local isn't feeling just as home in /etc/profile.d/ or any other already existant config location instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems, deactivates the swap, etc. <br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any commands you want to run right before the common rc.shutdown is executed. Please note that this file does not exist by default, and 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 rc.conf's DAEMONS= array. In addition to being called on bootup, you can use these scripts when the system is running to manage the services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. This directory is not in the $PATH by default, but may be added for convenience. Obviously a corresponding daemon script only exists when the appropriate package has been installed (in this case postfix). With a base system install, you don't have many scripts in here, but rest assured that all relevant daemon scripts end up here. If you wish, you can, of course, create your own scripts and place them here, to be called by the DAEMONS= array in /etc/rc.conf on system startup. <br />
<br />
This directory is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/ directories of other distributions, but without all the symlink hassle. The lack of symlink requirement is a defining difference of a *BSD-style init framework, vs a sysvinit.<br />
<br />
==Useful Applications==<br />
This section will never be complete. It just shows some good applications for the everyday user. <br />
<br />
'''KDE users NOTE''': Since KDE resides in /opt, you will most likely have to log out and in after initial installation to update your PATH before these programs can be used.<br />
===Internet===<br />
<br />
=====Firefox=====<br />
The ever-popular Firefox web browser is available through pacman, although it doesnt have its official branding, so the program appears when opened as Bon Echo. Install with:<br />
<br />
pacman -S firefox<br />
Be sure and install 'flashplugin', 'mplayer', 'mplayer-plugin', and the 'codecs' packages for a complete web experience:<br />
pacman -S flashplugin mplayer mplayer-plugin codecs<br />
(The codecs package contains codecs for Quicktime and Realplayer content.)<br />
<br />
Thunderbird is useful for managing your emails. If you are using GNOME you may want to take a look at Epiphany and Evolution; if you are using KDE Konqueror and KMail could be your choice. If you want something completely different you can still use Opera. Finally, if you are working on the system console - or in a terminal session - you could use various text-based browsers like ELinks, Links and Lynx, and manage your emails with [[Mutt]]. Pidgin (previously known as Gaim) and Kopete are good instant messengers for GNOME and KDE, respectively. PSI and Gajim are perfect if you are using only Jabber or Google Talk.<br />
<br />
===Office===<br />
OpenOffice is a complete office suite (similar to Microsoft Office). Abiword is a good, small alternative word processor, and Gnumeric an Excel replacement for the GNOME desktop. KOffice is a complete office suite for the KDE Desktop. GIMP (or GIMPShop) is a pixel-based graphics program (similar to Adobe Photoshop), while Inkscape is a vector-based graphics program (like Adobe Illustrator). And, of course, Arch comes with a full set of LaTeX Programs: tetex has been popular for many years and still works, and its successor [[Texlive]] is available from the [[AUR]] repository.<br />
<br />
==Multimedia ==<br />
<br />
<br />
===Video Player===<br />
====VLC====<br />
VLC Player is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S vlc<br />
<br />
(TODO) Instructions for VLC mozilla plug-in<br />
<br />
====Mplayer====<br />
MPlayer is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S mplayer<br />
<br />
It also has a Mozilla plug-in for videos and streams embedded in web pages. To install it, simply type the code below.<br />
<br />
pacman -S mplayer-plugin<br />
<br />
If you use KDE, KMplayer is a better choice. It comes with a plug-in for videos and streams embedded in web pages, which works with Konqueror. To install it, simply type the code below.<br />
<br />
pacman -S kmplayer<br />
<br />
(TODO) GMPlayer instructions<br />
<br />
====Xine====<br />
<br />
Xine is an excellent player, especially for DVDs.<br />
<br />
pacman -S xine-ui<br />
The libdvdcss library provides DVD decoding for encrypted DVDs. ''Ensure the legality of using libdvdcss in your country before installing!''<br />
pacman -S libdvdcss<br />
<br />
====GNOME====<br />
=====Totem=====<br />
[http://www.gnome.org/projects/totem/ Totem] is the official movie player of the GNOME desktop environment based on xine-lib or GStreamer (gstreamer is the default which installs with the arch totem package). It features a playlist, a full-screen mode, seek and volume controls, as well as keyboard navigation.<br />
It comes with added functionality such as:<br />
<br />
* Video thumbnailer for the file manager<br />
* Nautilus properties tab<br />
* Epiphany / Mozilla (Firefox) plugin to view movies inside your browser <br />
* Webcam utility (in development)<br />
<br />
Totem-xine is still the better choice if you want to watch DVDs.<br />
<br />
Totem is part of the gnome-extra group; the Totem webbrowser plugin isn't.<br />
<br />
To install separately:<br />
pacman -S totem<br />
<br />
To install the Totem webbrowser plugin:<br />
pacman -S totem-plugin<br />
<br />
====KDE====<br />
=====Kaffeine=====<br />
Kaffeine is a good option for KDE users. To install it, simply type the code below.<br />
<br />
pacman -S kaffeine<br />
<br />
===Audio Player===<br />
====Gnome/Xfce====<br />
=====Exaile=====<br />
[[Exaile]] is a music player written in Python that makes use of the GTK+ toolkit. It tries to be close to the popular Amarok, but in GTK. It is in [community], so install with:<br />
pacman -S exaile<br />
<br />
=====Rhythmbox=====<br />
[http://www.gnome.org/projects/rhythmbox/ Rhythmbox] is an integrated music management application, originally inspired by Apple's iTunes. It is free software, designed to work well under the GNOME Desktop, and based on the powerful GStreamer media framework.<br />
<br />
Rhythmbox has a number of features, including:<br />
<br />
* Easy-to-use music browser<br />
* Searching and sorting<br />
* Comprehensive audio format support through GStreamer<br />
* Internet radio support<br />
* Playlists<br />
<br />
To install rhythmbox:<br />
pacman -S rhythmbox<br />
<br />
=====Quod Libet=====<br />
[http://www.sacredchao.net/quodlibet Quod Libet] is a music manager that uses the GStreamer media framework to play audio files. This allows it to play all the file-types that Rhythmbox (which uses GStreamer too) can play. Quod Libet is more suited to non-Gnome desktops since it has a smaller footprint and fewer dependencies than Rhythmbox (Rhythmbox depends on nautilus, which requires a lot of GNOME to be installed).<br />
<br />
In addition to the music player/manager, Quod Libet also includes Ex Falso, a tag editor.<br />
<br />
Quod Libet's features include:<br />
<br />
* Easy-to-use music browser<br />
* Searching<br />
* Comprehensive audio format support through GStreamer<br />
* Easy Playlist management<br />
<br />
To install Quod Libet:<br />
pacman -S quodlibet<br />
<br />
Other good audio players are Banshee and Listen. See [http://gnomefiles.org/ Gnomefiles] to compare them.<br />
<br />
====KDE====<br />
=====Amarok=====<br />
[http://amarok.kde.org/ Amarok] is one of the best audio players and music library systems available for KDE. To install it, simply type the code below.<br />
<br />
pacman -S amarok-base<br />
<br />
====Console====<br />
[http://moc.daper.net/ Moc] is a ncurses-based audio player for the console; another good choice is [http://musicpd.org/ mpd].<br />
<br />
Another excellent choice is [http://freshmeat.net/projects/cmus/ cmus].<br />
<br />
====Other X-based====<br />
(TODO) Xmms, audacious, bmpx.<br />
<br />
===Codecs and other multimedia content types (i686 only) ===<br />
====DVD====<br />
You can use xine-ui, totem-xine, mplayer or kaffeine (just to name three of the big ones) to watch DVDs. The only thing you may miss is libdvdcss. Beware that using it may be illegal in some countries.<br />
<br />
====Flash====<br />
Install the flash plugin using<br />
pacman -S flashplugin<br />
to enable Macromedia (now Adobe) Flash in your browser, if you run KDE you should see this after installing flash. http://wiki.archlinux.org/index.php/Flash_and_Adobe_Acrobat_browser_plugins#Fixing_Flash_in_Konqueror<br />
<br />
====Quicktime====<br />
Quicktime codecs are contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them.<br />
====Realplayer====<br />
The codec for Realplayer 9 is contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them. Realplayer 10 is available as a binary package for Linux. You can get it from AUR [http://aur.archlinux.org/packages.php?do_Details=1&ID=1590&O=0&L=0&C=0&K=realplay&SB=&SO=&PP=25&do_MyPackages=0&do_Orphans=0&SeB=nd here].<br />
<br />
===CD and DVD Burning===<br />
====GNOME====<br />
=====Brasero=====<br />
[http://www.gnome.org/projects/brasero/ Brasero] is an application that burns CDs/DVDs for the GNOME Desktop. It is designed to be as simple as possible and has some unique features to enable users to create their discs easily and quickly.<br />
<br />
To install:<br />
pacman -S brasero<br />
<br />
====KDE====<br />
=====K3b=====<br />
K3b (from '''K'''DE '''B'''urn '''B'''aby '''B'''urn) is a free software CD and DVD authoring application for GNU/Linux and other <code>UNIX</code>-like operating systems designed for KDE. As is the case with most KDE applications, K3b is written in the C++ programming language and uses the Qt GUI toolkit. K3b provides a graphical user interface to perform most CD/DVD burning tasks like creating an Audio CD from a set of audio files or copying a CD/DVD, as well as more advanced tasks such as burning eMoviX CD/DVDs. It can also perform direct disc-to-disc copies. The program has many default settings which can be customized by more experienced users. The actual disc recording in K3b is done by the command line utilities cdrecord or wodim, cdrdao, and growisofs. As of version 1.0, K3b features a built-in DVD ripper.- licensed under the GPL.<br />
<br />
K3b was voted LinuxQuestions.org's Multimedia Utility of the Year (2006) by the majority (70%) of voters. <br />
-----<br />
To install:<br />
pacman -S k3b<br />
<br />
=====(Todo) cdrecord, graveman...=====<br />
<br />
<br />
<br />
<br />
Most CD burners are wrappers for cdrecord:<br />
<br />
pacman -S cdrkit<br />
<br />
If you install packages for CD/DVD burning applications like Brasero or K3B it also installs the CD/DVD burning library for it, like libburn or cdrkit.<br />
<br />
A good command-line DVD-burning tool is growisofs:<br />
<br />
pacman -S dvd+rw-tools<br />
<br />
===TV-Cards===<br />
<br />
There are several things to do if you want to watch TV under (Arch) Linux. The most important task is to find out which chip your tuner is using. However, quite a lot are supported. Be sure to check at a Hardware Database to be sure (see [http://en.opensuse.org/HCL/TV_Cards this list], for example). Once you know your Model, there are just a few steps ahead to get you going.<br />
<br />
In most cases, you will need to use the bttv-drivers (other drivers exist, like [http://linux.bytesex.org/v4l2/drivers.html V4L]) together with the I2C-modules. Configuring those is the hardest task. If you are lucky, a<br />
modprobe bttv<br />
will autodetect the card (check dmesg for results). In that case, you need only to install an application to watch TV. We will look at that later, though.<br />
If the autodetection did not work, you will need to check the file CARDLIST, which is included in the tarball of [http://dl.bytesex.org/releases/video4linux/ bttv] to find out the right parameters for your card. A PV951 without radio support would need this line:<br />
modprobe bttv card=42 radio=0<br />
Some cards need the following line to produce sound:<br />
modprobe tvaudio<br />
However, that varies. So just try it out. Some other cards demand the following line:<br />
modprobe tuner<br />
This is subject to trial-and-error, too.<br />
<br />
TODO: clarify the installation-procedure<br />
<br />
To actually watch TV, install the xawtv-package with<br />
pacman -S xawtv <br />
and read its manpage.<br />
<br />
TODO: clarify some possible problems and procedures. Introduction to XAWTV on another page?<br />
<br />
===Digital Cameras===<br />
Most newer digital cameras are supported as USB mass storage devices, which means that you can simply plug it in and copy the images. Older cameras may use the PTP (Picture Transfer Protocol) which requires a "special driver". gPhoto2 provides this driver and allows a shell-based transfer of the images; digikam (for KDE) and gthumb (for GNOME, gtkam would be another choice) use this driver and offer a nice GUI.<br />
<br />
===USB Memory Sticks / Hard Disks===<br />
USB Memory Sticks and hard disks are supported out of the box with the USB mass storage device driver and will appear as a new SCSI device (/dev/sdX). If you are using KDE or GNOME you should use dbus and hal (add them to your daemons in /etc/rc.conf), and they will be automatically mounted. If you use a different Desktop Environment you may have a look at ivman.<br />
<br />
==Maintaining the system==<br />
===Pacman===<br />
[[Pacman]] is both a binary and source package manager which is able to download, install, and upgrade packages from both remote and local repositories with full dependency handling, and has easy-to-understand tools for crafting your own packages too.<br />
<br />
A more-detailed description of Pacman can be found in [[Pacman|its article]].<br />
<br />
====Useful commands====<br />
To view the options available for a particular operational command, say '''-Q''', just append it with '''-h''':<br />
pacman -Qh<br />
<br />
To synchronize and update the local packages database with the remote repositories (it is a good idea to do this before installing and upgrading packages):<br />
pacman -Sy<br />
<br />
To '''upgrade''' all packages on the system:<br />
pacman -Su<br />
<br />
To sync, update, and '''upgrade''' all the packages on the system with one command:<br />
pacman -Syu<br />
<br />
To install or upgrade a single package or list of packages (including dependencies):<br />
pacman -S packageA packageB<br />
<br />
You can also sync, update the package database, and install packages in one command:<br />
pacman -Sy packageA packageB<br />
<br />
To remove a single package, leaving all of its dependencies installed:<br />
pacman -R package<br />
<br />
To remove a package and all of the package's dependencies which aren't used by any other installed package:<br />
pacman -Rs package<br />
('''-Rs''' is typically preferred vs '''R''' to remove any package as it will clean up all unused dependencies)<br />
<br />
To remove all of the package's now unneeded dependencies and also instruct pacman to ignore file backup designations. (Normally, when a file is removed from the system the database is checked to see if the file should be renamed with a ".pacsave" extension.):<br />
pacman -Rsn package<br />
<br />
To search the remote (repo) package database for a list of packages matching a given keyword:<br />
pacman -Ss keyword<br />
<br />
To list all packages on your system<br />
pacman -Q<br />
<br />
To list all packages on your system without the version strings, we add the '''-q''' option:<br />
pacman -Qq<br />
<br />
To search (query) the local (your machine) package database for a given package:<br />
pacman -Q package <br />
<br />
To search (query) the local (your machine) package database for a given package and list all pertinent information:<br />
pacman -Qi package<br />
<br />
To list all files installed by a given ''package'':<br />
<tt>pacman -Ql ''package''</tt><br />
Conversely, to find the package that owns a given file (in this example, the ''ls'' executable):<br />
<tt>pacman -Qo /bin/ls</tt><br />
To find all unused packages (orphans):<br />
pacman -Qdt<br />
Missing libraries: Suppose you receive an error message like this:<br />
<tt>mplayer: error while loading shared libraries: ''libgssapi.so.2'': cannot open shared object file: No such file or directory</tt><br />
This may be an indication that a package you have previously installed is now corrupt (some or all of its files are missing). You should try to find the package name that provides the missing shared library. In this example, you could type:<br />
<tt>pacman -Ql | grep ''libgssapi.so.2''</tt><br />
The first column in the output is the package name:<br />
<tt>heimdal /usr/lib/libgssapi.so.2<br />
heimdal /usr/lib/libgssapi.so.2.0.0<br />
</tt><br />
Then, you can just re-install it:<br />
<tt>pacman -Sy heimdal</tt><br />
<br />
To defragment pacman's cache database and optimize for speed:<br />
pacman-optimize<br />
<br />
To count how many packages are currently on your system:<br />
pacman -Q | wc -l<br />
<br />
To install a package compiled from source using ABS and makepkg:<br />
pacman -U packagename.pkg.tar.gz<br />
<br />
Note: There are countless additional pacman functions and commands. Try man pacman and consult the [[pacman]] wiki entries.<br />
<br />
====Files====<br />
There are a number of files left and created by pacman and other programs to facilitate maintenance and to conform to a safe computing practice. When pacman is installing something, the package contains information on whether to back up a particular file. Such files will have the '''.pacsave''' extension. When you force a "NoUpgrade" on a file via [http://www.archlinux.org/pacman/pacman.conf.5.html pacman.conf], it will not be replaced during an upgrade and the new file will come with the '''.pacnew''' extension. For example, you have edited a configuration file thoroughly and you do not want an upgrade of the respective package to replace the file with a new one, we must have the following line in '''/etc/pacman.conf''':<br />
NoUpgrade = /path/to/config/file<br />
To view the differences of the old and new versions of these files, we can either edit them manually or use a '''diff''' utility to take note of the differences. There is an automated tool to find and view such files available from the '''community''' repository:<br />
pacman -S pacman-contrib<br />
cd ~/<br />
pacdiff # as root<br />
There is a bug in the above tool where if you navigate to '''/etc''' and run it from there, the paths will be messed up. We remain on the safer side by being at "home". You may want to run it as user first in case you happen to be a careless person (you may just overwrite or remove files because you ''think'' that is the right way).<br><br />
<br />
There are other types of leftovers depending on the programs available on your system. Some will create backups with a '''.bak''' extension, while others with something like "'''~'''" or "'''-'''". Unfortunately, there is currently no way to "automatically" find and review them. Fear not, as we have no need for automated tools to deal with such trivial tasks. Simply use '''locate''' to search for them:<br />
locate -e *.~ *.- *.bak<br />
And we can use something useful like '''vimdiff''' to look at the differences manually:<br />
pacman -S vim<br />
vimdiff file1 file2<br />
<br />
==Прочая информация==<br />
За дополнительной инфорацией обращайтесь к [http://archlinux.org.ru/ Русскоязычному сообществу Arch], а также [http://archlinux.org.ru/forum/ на русскоязычный фоум]. Также по любым вопросам обращайтесь на IRC-канал:<br />
Сервер: irc.freenode.org, канал #archlinux-ru, кодировка UTF-8.<br />
Опытные, добрые, отзывчивые админы всегда окажут вам полное содействие и помощь.<br />
=====FAQ=====<br />
Смотрите [[ЧаВо]]<br />
<br />
<br />
=====Что еще почитать?=====<br />
[http://www.cyber39.ru/os/linux/3716-linux_dlja_nachinajushhikh.html Linux для начинающих.]<br />
<br />
[http://www.cyber39.ru/2008/02/16/setevoe_administrirovanie_linux.html Сетевое администрирование Linux.]<br />
<br />
[http://www.cyber39.ru/2008/02/16/jadro_linux_3e_izd.html Ядро Linux.]<br />
<br />
[http://www.cyber39.ru/os/linux/1204-linux_polnoe_rukovodstvo.html Linux: Полное руководство.]<br />
<br />
[http://www.cyber39.ru/2008/02/13/operacionnaja_sistema_unix_nastolnyjj_spravochnik.html Операционная система UNIX. Настольный справочник.]<br />
<br />
[http://ru.wikibooks.org/wiki/Введение_в_администрирование_UNIX#.D0.92.D0.B2.D0.B5.D0.B4.D0.B5.D0.BD.D0.B8.D0.B5_.D0.B2_.D0.AE.D0.BD.D0.B8.D0.BA.D1.81 Введение в администрирование UNIX.]<br />
<br />
[http://www.cyber39.ru/os/linux/19037-linux_osnovnye_komandy_karmannyjj_spravochnik.html LINUX: Основные комманды. Карманный справочник.]<br />
<br />
[http://www.cyber39.ru/coding/cpp/16946-programmirovanie_na_c_v_linux.html Программирование на C в Linux.]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Beginners%27_guide_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=53611
Beginners' guide (Русский)
2008-11-15T23:35:30Z
<p>Cucullus: </p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
<br />
{{Box Note |'''По возможности, пользуйтесь английской версией этого документа, т.к. именно она обновляется в первую очередь, содержит все последние изменения и самую актуальную на данный момент информацию.'''}}<br />
{{Box Note|'''Уважаемые переводчики, прежде чем переводить какой-либо раздел, сравните его с английской версией ибо информация в нём могла устареть'''}}<br />
<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|Dansk_Begynderguide}}<br />
{{i18n_entry|简体中文|Beginners Guide 新手指南}}<br />
{{i18n_entry|Deutsch|Beginners Guide (Deutsch)}}<br />
{{i18n_entry|English|Beginners Guide}}<br />
{{i18n_entry|Español|Guía para Principiantes (Español)}}<br />
{{i18n_entry|Česky|Průvodce začátečníka (Česky)}}<br />
{{i18n_entry|Italiano|Beginners Guide (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Pradedančiųjų gidas (Lietuviškai)}}<br />
{{i18n_entry|Português Brasil|Guia do Iniciante(Português do Brasil)}}<br />
{{i18n_entry|Русский|Руководство для новичков}}<br />
{{i18n_links_end}}<br />
<br />
=====Всё, что вы хотели знать об установке Arch, но боялись спросить=====<br />
Добро пожаловать. Этот документ проведёт вас через процесс установки и настройки [[ArchLinux|Arch Linux]]; простого, быстрого и лёгкого GNU/Linux дистрибутива, <code>UNIX</code>-подобной операционной системы. Это больше, чем установочное руководство; Arch Linux требует определённого уровня глубоких знаний о его конфигурации, а так же методологии системы GNU/Linux и по этой причине, на этом пути содержится много дополнительной пояснительной информации. Он направлен на новых пользователей Arch, но стремится выступать как сильная справочная и информационная база для всех. Хоть это руководство предназначено для того, чтобы показать как получить полностью сконфигурированную систему Arch Linux (графическое окружени рабочего стола, возможность просмотра DVD, использования Интернет, работа с электронной почтой и прослушивания музыки), невозможно показать (или даже предположить) все возможности и варианты. По замыслу авторов, это руководство должно сфокусироваться на крайне полезных шагах; возможно вы захотите получить глубокие знания используя [[Main Page|Arch Linux Wiki]] или [http://bbs.archlinux.org/ Arch Linux Forums]. Вы также можете быть заинтересованы в чтении статьи [[Путь Arch]], в которой изложены основные принципы дистрибутива Arch Linux.<br />
<br />
Так как Arch Linux и все <code>UNIX</code>-подобные операционные системы являются в своей основе 'модульными', статья логически разбита на три основных части:<br />
<br />
'''[[#Часть 1: Установка базовой системы|Часть 1: Установка базовой системы]]'''<br />
<br />
'''[[#Часть 2: Установка X и установка ALSA|Часть 2: Установка X и установка ALSA]]'''<br />
<br />
'''[[#Часть 3: Установка и настройка окружения рабочего стола|Часть 3: Установка и настройка окружения рабочего стола]]'''<br />
<br />
=====DON'T PANIC!=====<br />
Имейте в виду, что процедура установки Arch Linux может сильно отличаться от установки других GNU/Linux дистрибутивов и вы можете запутаться, особенно, если вы новичок. Обычно, GNU/Linux дистрибутивы распространяются вместе с большим набором софта на CD (или даже DVD), включающим стандартное Рабочее Окружение(DE), стандартный набор программ и установок, автонастройщик оборудования и графический установщик, все что выбрано за вас. Для различия, система Arch Linux создаётся '''пользователем''', из установщика с псевдографикой и базовой системы в которой нет ничего кроме bash и простых консольных программ. Это — '''[[Путь Arch]].''' В отличие от большинства других дистрибутивов с жёсткой структурой, здесь нет ни стандартного окружения, ни конфигурации сделанной за пользователя. Попросту говоря, Arch ждет вашего вклада. Из командной строки, ''вы'' можете установить необходимые пакеты из репозитория используя [[pacman]] и ''вручную'' настроить вашу систему под ''свои'' потребности, до того как это сделает кто-то другой. Этот метод дает вам максимум гибкости, выбора и контроля за вашей системой. Потому что когда '''вы''' настраиваете систему, вы всегда знаете все "гайки и болты" вашей системы и вам знакомо то, что находится "под капотом". <br />
<br />
Arch Linux настраивается редактированием текстовых файлов. Из-за этого не требуются графические инструменты для настройки. <br />
Также запомните, что Arch Linux направлен на опытных пользователей GNU/Linux, на тех кто хочет минимального 'разделения' оборудования и софта, на тех пользователей, которые могут тратить своё время на чтение манов о своей системе.<br />
<br />
''Arch — это инструмент созданный пользователем.''<br />
<br />
=====[[Путь Arch]]=====<br />
<br />
'''''Принципы разработки Arch Linux направлены на сохранение [[Путь Arch|простоты]].'' '''<br />
<br />
Стоит учитывать, что 'простота' не означает 'легкость' или 'дружелюбие' в данном контексте. Но подразумевает 'отсутствие лишних сущностей, модификаций или надуманной сложности' и стремление к элегантному и минималистичному окружению.<br />
<br />
''"Простота подразумевается не с позиции конечного использования, а с технической точки зрения. Лучше стремиться к технической элегантности, нежели быть простым в использовании, но мусором с технической точки зрения." -Aaron Griffin''<br />
<br />
''"Значимая часть [моего метода] подразумевает простоту..Я всегда верил в то, что простой путь - правильный путь."'' - Bruce Lee<br />
<br />
Принцип "Бритвы Оккама": ''Entia non sunt multiplicanda praeter necessitatem'' или "Не следует множить сущности без необходимости." "Бритва" в данном случае означает отбрасывание, вырезание из предмета лишних усложнений и домыслов для того, чтобы добиться наиболее простого объяснения, метода или теории.<br />
<br />
{{Box Note |'''Для успешной установки и правильной настройки дистрибутива необходимо в точности выполнять приведённые инструкции. ''Пожалуйста'', читайте их внимательно.'''}}<br />
* Вы можете распечатать данную статью, она уместится примерно на 58 страницах, которые послужат полезным руководством использования Arch Linux.<br />
* ''Если вы хотите добавить что-то в данную инструкцию, пожалуйста, указывайте не только "Как" что-либо делать, но и "Зачем" именно может понадобиться это делать.''<br />
* Arch Wiki поможет вам разобраться с возникающими проблемами, ответы на которые сначала стоит поискать на [http://wiki.archlinux.org/index.php/Main_Page_(Русский) главной странице]. Также вам доступны каналы IRC и [http://bbs.archlinux.org/ форум].<br />
----<br />
Добро пожаловать в Arch Linux! Давайте приступим.<br />
<br />
==Часть 1: Установка базовой системы==<br />
===Скачайте самый последний установочный образ ===<br />
<br />
Вы можете получить самый последний образ Arch Linux'а [http://archlinux.org/download/ здесь.]<br />
<br />
*Core-iso и FTP-downloads включают в себя только самые необходимые пакеты для создания '''базовой системы Arch Linux'''. ''Нужно заметить что в Базовую Систему не включен GUI. Сюда главным образом входит GNU инструментарий, (компилятор, ассемблер, линковщик, библиотеки и немного полезных утилит) ядро Linux, и немного дополнительных библиотек и модулей.'' Остальное в Arch Linux, включая GUI, может быть установлено из консоли, ''пользователем'', используя менеджер пакетов - pacman для загрузки и установки i686/x86-64 бинарных пакетов. Процесс описывается в деталях ниже.<br />
<br />
Запишите образ системы на CD. <br />
{{Box Note| При записи не используйте скорость больше чем 8x - это рекомендованная скорость для надёжной записи, также некоторые пользователи рекомендуют устанавливать очень низкую скорость '''''4x или 2x!''''' Если вам встретились неожиданные проблемы с установкой, попытайтесь записать образ с самой низкой скоростью поддерживаемой вашей системой.}}<br />
<br />
===Загрузка с Arch Linux CD===<br />
Вы должны следовать этим инструкциям, но также вы можете найти весьма полезным [[Руководство_по_установке|Официальное руководство по установке Arch Linux]]. <br />
Вставьте CD в ваш CD-ROM и загрузитесь с CD. Если ваш компьютер по умолчанию загружается не с CD, вы можете исправить это <br />
изменив порядок загрузки в биосе (чтобы войти в биос используйте клавиши DEL, F1, F2, F11 или F12 при запуске компьютера (в зависимости от типа биоса)).<br />
<br />
Полезные опции загрузки:<br />
* '''ide-legacy''' если у вас возникают проблемы с IDE приводами<br />
* '''noapic acpi=off pci=routeirq nosmp''' если ваша система зависает при загрузке системы<br />
* '''acpi=nommconf''' если у вас возникают "задержки" после загрузки pci:mmconfig <br />
* '''memtest86+''' если вы хотите проверить вашу оперативную память на ошибки<br />
* '''lowmem''' полезно для старых компьютеров с ограниченным объёмом оперативной памяти<br />
<br />
Требования к памяти:<br />
* CORE ISO: lowmem-загрузка образа - 64 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* CORE ISO: обычная загрузка образа - 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* FTP ISO : 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
<br />
Выберите "Arch Linux Installation / Rescue System". Если вы нуждаетесь в изменениях опций загрузки, нажмите "e" для редактирования конфигурации загрузки.<br />
Система будет загружена и вам будет представлено сообщение приветствия с некоторыми пояснениями.<br />
<br />
===Вход в систему и изменение раскладки===<br />
Войдите в систему как 'root'. Если ваша клавиатура не имеет американскую раскладку, выполните в командной строке следующее:<br />
{{Box Note| Скорее всего, у вас клавиатура с "американской" раскладкой (если ваша клавиатура приобретена в России)}}<br />
loadkeys <ваша раскладка><br />
<br />
===Запуск установки===<br />
Введите<br />
/arch/setup <br />
чтобы начать установку Arch Linux. <br />
<br />
<br />
====Выбор источника установки====<br />
После экрана приветствия вам будет предложено выбрать источник установки. Выберите CD, если хотите использовать диск. Или выберите FTP, если хотите использовать образ из FTP. <br />
* В первом случае, переходите к чтению главы о [[#Подготовка жёсткого диска|Подготовке жесткого диска]].<br />
* Во втором случае, вам будет предложено загрузить драйвер для сетевой карты вручную. Но, как правило, Udev автоматически вполне успешно определяет комплектующие - вы можете проверить это выполнив "ifconfig -a" из vc2. Для продолжения установки нажмите "OK".<br />
<br />
====FTP: Настройка Сети====<br />
Вам будут показаны доступные интерфейсы. Если нужный интерфейс присутствует в списке - значит он определился правильно. В обратном случае, вы можете попробовать определить его прямо из установщика или из другой виртуальной консоли (vc).<br />
<br />
Далее выберите нужный интерфейс и продолжайте установку.<br />
<br />
Затем вам будет предложено использовать DHCP для автоматического получения сетевых настроек. В случае отказа, вам будет предложено вручную ввести ваш статический IP-адрес, маску подсети, адрес шлюза и т.д. И, наконец, вы сможете пересмотреть проделанные настройки и удостовериться в их правильности.<br />
<br />
Переходите к чтению о [[#Подготовка жёсткого диска|Подготовке жёсткого диска]].<br />
<br />
====Подготовка жёсткого диска====<br />
Выберите первый пункт меню - "Prepare Hard Drive". Вам будет предложено автоматически подготовить ваш жёсткий диск к установке Arch Linux, либо вручную переразбить и подготовить разделы.<br />
* 1. Автоматическая подготовка<br />
Установщик сам разобъёт ваш жесткий диск на следующие разделы:<br />
* Загрузочный раздел /boot c файловой системой ext2 и размером по умолчанию в 32 мегабайта. Вы сможете изменить это значение. <br />
* Раздел подкачки swap с размером по умолчанию в 256 мегабайтов. Вы также сможете изменить это значение.<br />
* Отдельные разделы для корня / и домашней директории пользователей /home. Размеры вы определяете сами. Также вам будет предоставлен выбор из файловых систем: ext2, ext3, reiserfs, xfs и jfs. Но следует учесть, что оба этих раздела должны быть отформатированы в одинаковой файловой системе.<br />
<br />
Не забывайте - автоматическая подготовка сотрёт все данные на вашем жёстком диске! Внимательно читайте предупреждение установщика.<br />
<br />
* 2. '''(Рекомендуется)''' Ручная подготовка<br />
<br />
Выберите из списка жёсткий диск, на который будет произведена установка (/dev/sd''x'').<br />
<br />
''На этом этапе более опытные пользователи могут сразу перейти к главе о '''[[#Выбор Пакетов|выборе пакетов]]'''.''<br />
<br />
=====Информация о разбивке=====<br />
Разбивка жёсткого диска заключается в создании отдельных зон (разделов) на жёстком диске. Они будут выглядеть как отдельные диски со своими файловыми системами. Разделы подразделяются на "Основные" (Primary), "Расширенные" (Extended) и "Логические" (Logical).<br />
<br />
'''Основные''' разделы могут быть загрузочными и их количество ограничено четырьмя. Больше четырёх главных разделов создать нельзя и нужно использовать '''Расширенные''' разделы, которые будут содержать '''Логические'''.<br />
<br />
Расширенные разделы не могут быть использованы сами по себе - они всего лишь "контейнеры" для логических. Жёсткий диск может содержать только один расширенный раздел, который может быть разделён на логические.<br />
<br />
Во время разбивки диска можно заметить схему нумерации разделов. Главные получают названия sda1-3, расширенный раздел - sda4, а логические, соответственно, sda5, sda6 и т.д.<br />
<br />
=====Раздел Подкачки (swap)=====<br />
Данный раздел является чем-то вроде "виртуального ОЗУ". На нем хранятся данные, которые не умещаются, либо не подходят для хранения в оперативной памяти.<br />
<br />
Исторически сложилось, что размер раздела подкачки определяется по схеме 2ХОЗУ. То есть, двойной объем оперативной памяти. Затем, с развитием компьютерной техники, данное правило не всегда стало являться необходимым. На компьютере с 512 мегабайтами памяти правило 2Х все еще действует эффективно. Однако, на машинах с 1 гигабайтом памяти обычно наиболее эффективна схема 1ХОЗУ. Если размер вашего ОЗУ больше или равен 1 гигабайту, то можно вообще обойтись без раздела подкачки, однако это не рекомендуется. Мы создадим раздел размером в 1 гигабайт в нашем примере.<br />
<br />
{{Box Note|Если вы планируете использовать технологии suspend-to-disk или hibernate, то размер раздела подкачки, по меньшей мере, должен соответствовать размеру вашей оперативной памяти. Но рекомендуется задать размер хотя бы на 15% больший, чтобы учесть появление испорченных секторов на диске (bad sectors).}}<br />
=====Схема Разбивки=====<br />
Схема разбивки разделов довольно индивидуальна и во многом зависит от предпочтений и нужд конкретного пользователя. Но, как минимум, вам нужны два раздела: один для корня ( / ), второй для раздела подкачки (swap). Однако, вы можете захотеть иметь отдельные разделы для /boot (на нем обычно находится ядро Linux), /var и /home (пользовательская директория). Обычно иметь два раздела отдельно для корня ( / ) и отдельно для /home считается хорошей практикой и более удобным и безопасным решением.<br />
В нашем примере мы создадим три отдельных раздела: для корня, для /home и один раздел подкачки swap.<br />
<br />
=====cfdisk===== <br />
Итак, начнём с создания главного раздела, содержащего корневую файловую систему.<br />
<br />
Для создания нового раздела выберите пункт '''N'''ew, затем Primary. Далее задайте желаемый размер раздела (что-то между 4 и 12 гигабайт будет хорошим выбором). Выберите только что созданный раздел и сделайте его загрузочным, выбрав пункт '''B'''ootable.<br />
<br />
Также выберите пункт '''T'''ype и задайте значение '83 Linux'. Нашему разделу должно присвоится имя sda1.<br />
<br />
Затем создадим раздел подкачки. Задайте размер между 512 мегабайт и 1 гигабайтом, выберите '''T'''ype - 82 (Linux swap / Solaris). Наш раздел должен быть теперь виден как sda2.<br />
<br />
Теперь ещё один раздел для /home. Выберите главный раздел и установите желаемый размер в зависимости от того, что пользователи вашего компьютера будут хранить в своих персональных директориях. Также, как и для корня, задайте '''T'''ype - 83 Linux. Данный раздел появится как sda3.<br />
<br />
<br />
<br />
Вот как должна выглядеть наша таблица разделов (размеры могут отличаться):<br />
<br />
Name Flags Part Type FS Type [Label] Size (MB)<br />
-------------------------------------------------------------------------<br />
sda1 Boot Primary Linux (4096 - 8192)<br />
sda2 Primary Linux swap / Solaris (512 - 1024)<br />
sda3 Primary Linux (> 100 or remaining space)<br />
<br />
Выберите '''W'''rite и нажмите ''''yes''''. Или нажмите '''Q'''uit для выхода из программы разбивки.<br />
<br />
<br />
=====Мои IDE-диски выглядят как SCSI, почему?=====<br />
В последних версиях ядра Linux все диски (IDE, SATA, SCSI) именуются как sd''x''. Пусть это вас не волнует, это нормально.<br />
<br />
====Назначение точек монтирования====<br />
Во-первых, выберите нужный раздел под раздел подкачки (в нашем примере это sda3). Во-вторых, выберите раздел для монтирования корневой ФС (sda1 в нашем примере). Вам будет предложено выбрать желаемую файловую систему.<br />
<br />
=====Файловые системы=====<br />
<br />
Выбор файловой системы достаточно субъективен. Каждая из предложенных ФС имеет свои достоинства и недостатки, всё зависит целиком от ваших предпочтений. Далее мы кратко рассмотрим поддерживаемые ФС:<br />
<br />
1. '''[http://ru.wikipedia.org/wiki/Ext2 ext2]''' - старая и надежная файловая система для ОС GNU/Linux. Очень стабильна, но без поддержки журналирования - это значит, что в случае аппаратных сбоев или перепадов напряжения ваша информация может пострадать. Не слишком хороший выбор для корневого и /home разделов. Данная ФС может быть легко преобразована в ext3.<br />
<br />
2. '''[http://ru.wikipedia.org/wiki/Ext2 ext3]''' - наследница ext2, но с поддержкой журналирования. Она полностью совместима с ext2. Однако, по некоторым тестам немного медленнее, нежели остальные ФС. Тем не менее, очень стабильна и активно используется, поддерживается и разрабатывается сообществом GNU/Linux.<br />
<br />
3. '''[http://ru.wikipedia.org/wiki/ReiserFS ReiserFS]''' - высокопроизводительная файловая система, разработанная Гансом Райзером. Считается очень быстрой, особенно при операциях с файлами маленького размера, однако сравнительно медленно монтируется. Вполне готова к использованию и стабильна. Однако, не слишком активно разрабатывается на данный момент (все силы отданы Reiser4).<br />
<br />
4. '''[http://ru.wikipedia.org/wiki/JFS JFS]''' - '''J'''ournaled '''F'''ile'''S'''ystem, файловая система от IBM. Использует наименьшее количество ресурсов центрального процессора, нежели остальные ФС. Очень быстра в монтировании и использовании. Однако, не так широко используется, как ext или ReiserFS.<br />
<br />
5. '''[http://ru.wikipedia.org/wiki/JFS XFS]''' - журналируемая ФС, которая показывает наибольшую скорость при операциях с большими файлами. Хороший выбор для разделов с большим их количеством.<br />
<br />
Наиболее значимое отличие между ними - журналирование. Все, кроме ext2, его поддерживают, однако техника журналирования не у всех одинакова. Только ext3 поддерживает хранение в журнале данных и мета-данных (информация о директориях). Это значит, что только она в случае сбоя сможет восстановить полностью в точной мере ту информационную структуру, которая была до сбоя.<br />
<br />
Выберите и создайте ФС для корня. Далее вам будет предложено создать дополнительные разделы. В нашем примере, нам понадобится создать еще sda2. Выберите файловую систему и примонтируйте ее как /home. Нажмите Done и возвращайтесь в главное меню установщика.<br />
<br />
===Выбор пакетов===<br />
На данном этапе вам предстоит выбрать пакеты, которые будут установлены на вашу систему.<br />
* Установка из Core ISO: выберите подходящее устройство CD-ROM из списка.<br />
* Установка из FTP ISO: выберите FTP/HTTP-зеркало для получения пакетов.<br />
<br />
Процесс выбора пакетов разбит на две стадии: выбор категорий пакетов, а затем - выбор отдельных пакетов в этих категориях. С помощью клавиши пробела вы можете устанавливать и снимать выделение пакетов и категорий. Ниже приведен список категорий пакетов с объяснениями:<br />
<br />
* '''BASE:''' содержит только базовые, необходимые системные пакеты. Минимальный набор для базовой системы.<br />
*'''SUPPORT:''' здесь находятся дополнительные пакеты для работы с сетью и файловыми системами. Например, такие как gpm, fuse, dnsutils, ndiswrapper, ntfs-3g, драйвера для wi-fi адаптеров и т.п.<br />
*'''DEVEL:''' пакеты для сборки программ. То есть, GCC, autoconf, automake, make и т.п.<br />
*'''LIB:''' различные системные библиотеки - gmp, libelf, libevent и т.п.<br />
<br />
Нажмите OK и далее выберите опцию 'yes', когда вам будет предложено выбрать все пакеты по умолчанию ('Select all packages by default').<br />
<br />
Далее вам будет показан список пакетов в выбранных категориях. Для новичка будет лучшим выбором оставить всё как есть. Тогда как более опытные пользователи могут убрать ненужные им пакеты из данного списка.<br />
<br />
===Установка пакетов===<br />
Теперь выберите пункт 'Install Packages', чтобы начать установку пакетов. Вам будет предложено сохранить загруженные из источника установки пакеты в системном кэше. Это хороший выбор, который может очень вам помочь, если какой-либо новый установленный пакет будет работать не так, как надо. Тогда можно просто восстановить старую версию из кэша. Помните, что вы всегда можете очистить ваш кэш вручную при необходимости.<br />
Установщик произведет установку выбранных вами пакетов и ядра Arch Linux в вашу новую систему.<br />
<br />
*FTP ISO: менеджер пакетов [[Pacman_(Русский)|Pacman]] установит пакеты с сетевого зеркала (прогресс вы можете наблюдать на vc5, а чтобы вернуться назад к установщику - перейдите на vc1).<br />
*CORE ISO: пакеты будут установлены с оптического диска.<br />
<br />
===Конфигурация системы===<br />
''Чёткое следование и понимание следующих шагов является ключем к корректной работе системы.'' <br />
<br />
Установщик спросит вас о необходимости использования [[Hwdetect|hwdetect]] для сбора информации о параметрах компьютера. Новичку следует выбрать 'yes'. <br />
<br />
Опытные пользователи, которые хорошо знают свое железо, требующиеся модули, а так же те, что могут вручную отладить /etc/rc.conf, /etc/mkinitcpio и /etc/fstab, и т.д. с нуля могут выбрать'no'. (Не требует напоминания тот факт, что сия опция крайне сложна, выходит за рамки этого руководства и поэтому не освещается им)<br />
<br />
Далее будут заданы вопросы, необходимо ли вам будет загружаться с USB-устройств, FireWire-устройств, PCMCIA-устройств, общих папок NFS, программных RAID-массивов, LVM2 разделов, шифрованных разделов и о поддержке DSDT. Выбирайте 'yes' если вам что-то из вышеописанного требуется. В рамках нашего руководства не требуется ничего из описанного. <br />
<br />
Теперь вас спросят, какой текстовый редактор вы желаете использовать; выбирайте [http://en.wikipedia.org/wiki/Nano_%28text_editor%29 nano] (проще для освоения) или [http://en.wikipedia.org/wiki/Vim_%28text_editor%29 vi/vim] (рекомендуется, сложнее для освоения). Перед вами появится меню, включающее список наиболее важных конфигурационных файлов системы. Если вы хотите просмотреть возможные настройки, указанные в /etc/rc.conf, то просто нажмите Alt+F2, чтобы попасть в консоль, просмотрите файл и вернитесь в установщик с помощью Alt+F1. <br />
<br />
=====Почему установщик не делает это всё автоматически?=====<br />
Сокрытие процесса установки является прямой противоположностью [[пути Arch|Путь Arch]]. Пока имеет место факт, что последние версии ядра и средства определения оборудования замечательным образом поддерживают различное оборудование и автоконфигурацию, Arch будет представлять пользователю все соотвествующие конфигурационные файлы в течение установки с целью ''прозрачности''. К тому времени, как вы закончите настройку этих файлов под свои нужды, вы будете знать элементарные методы ручной настройки Arch Linux'а и будете знакомы с базовой структурой, будучи хорошо подготовленны к продуктивному использованию вашей новой системы.<br />
<br />
====='''/etc/rc.conf'''=====<br />
Arch Linux следует трациям '''*BSD''' использования '''/etc/rc.conf''' в качестве принципиального расположения системной конфигурации. Этот небольшой файл содержит обширный набор различных параметров, используемых при запуске системы. Как становится ясно из его имени, этот файл так же содержит настройки /etc/rc* файлов, а так же и вызывает эти файлы. Файл /etc/rc.conf предлагает простой, элегантный метод поточной конфигурации системных ресурсов включая широкие возможности контроля, охотно представляя их пользователям Arch Linux.<br />
<br />
* Секция '''LOCALIZATION''' <br />
** '''LOCALE'''=: Устанавливает системную локаль, которая будет использоватся для всех i18n приложений и утилит. Вы можете просмотреть список доступных локалей, введя комманду 'locale -a' в коммандой строке. Начальные настройки подходят для англоязычных пользователей (процесс локализации системы описан в [http://wiki.archlinux.org/index.php/Интернационализация соотвествующем руководстве]).<br />
<br />
** '''HARDWARECLOCK'''=: Определяет, каким образом аппаратные часы вашего компьютера, которые синхронизируются при загрузке и выключении, хранят время: '''UTC''' или '''localtime'''. UTC может сильно упростить смену часовых поясов, а так же переход на летнее/зимнее время. localtime необходим, если вы используете несколько операционных систем (скажем, у вас так же установлен Windows), которые хранят в аппаратных часах лишь localtime.<br />
** '''TIMEZONE'''=: Определяет ваш часовой пояс. Для Москвы, скажем, это "Europe/Moscow". (Все возможные часовые пояса хранятся в /usr/share/zoneinfo/).<br />
** '''KEYMAP'''=: Все возможные раскладки хранятся в /usr/share/kbd/keymaps. Учтите, что эта опция определяется только для TTY (текстовой консоли), а не графического оконого менеджера и X-ов!<br />
** '''CONSOLEFONT'''=: Возможные консольные шрифты хранятся в /usr/share/kbd/consolefonts/ если вам вдруг требуется замена. Для поддержки русского языка требуется указать "/usr/share/kbd/consolefonts/cyr-sun16".<br />
** '''CONSOLEMAP'''=: Определяет, какую console map загрузить с программой установки шрифтов при загрузке системы. Возможные map'ы можно найти в /usr/share/kbd/consoletrans, если вдруг необходимо. По умолчанию поле пустое, что считается безопасным. <br />
** '''USECOLOR'''=: Установите "yes", если у вас цветной монитор и вы хотите, что бы в консоли отображались цвета.<br />
<br />
LOCALE="ru_RU.UTF-8"<br />
HARDWARECLOCK="UTC"<br />
TIMEZONE="Europe/Moscow"<br />
KEYMAP="ru" # Или ru-mab для раскладки с переключением по Ctrl-Shift<br />
CONSOLEFONT="/usr/share/kbd/consolefonts/cyr-sun16"<br />
CONSOLEMAP=""<br />
USECOLOR="yes"<br />
<br />
* Секция '''HARDWARE'''<br />
** '''MOD_AUTOLOAD'''=: Если установлена как "yes", то '''udev''' будет автоматически проверять устройства и загружать соотвествующие модули во время загрузки системы. Установка в положение "no" возложит на пользователя возможность определят эту информацию самостоятельно или скомпилировать свое собственное ядро и модули, и т.д. <br />
** '''MOD_BLACKLIST'''=: Крайне не рекомендуется добавление blacklist'овых модулей прямо в строчку '''MODULES=''' далее. <br />
** '''MODULES'''=: Определяет дополнительные модули, если известно, что важный модуль пропущен, ('''hwdetect''' должен быть заполнен в наиболее важных модулях). Так же задайте какие-либо blacklist'овые модули, ставя перед ними восклицательный знак (!). Udev НЕ будет загружать blacklist'овые модули. К примеру, IPv6-модуль, так же как и надоедливый pc-спикер, отключены. <br />
# Сканирует устройства и загружает соотвествующие модули<br />
MOD_AUTOLOAD="yes"<br />
# Blacklist-модуль - Крайне не рекомендуется<br />
MOD_BLACKLIST=()<br />
#<br />
MODULES=(e100 eepro100 mii slhc snd-ac97-codec snd-intel8x0 soundcore !net-pf-10 !pcspkr)<br />
* Секция '''NETWORKING'''<br />
** '''HOSTNAME'''=: Задайте имя хоста (HOSTNAME) на свой вкус.<br />
** '''eth0'''=: 'Ethernet, card 0'. Задайте IP адрес интерфейса, сетевую маску и широковещательный адрес ''если'' вы используете '''статический IP'''. Задайте eth0="dhcp" если вы используете '''DHCP'''<br />
** '''INTERFACES'''=: Здесь задайте какие-либо/все интерфейсы. Если вы НЕ используете DHCP для конфигурации устройства, просто запомните, что значение переменной (имя которой должно совпадать с именем устройства, которое вы настраиваете) совпадает со строкой, которая будет следовать за коммандой "ifconfig", если вы решите настраивать устройство вручную в коммандой строке. <br />
** '''gateway'''=: Если вы используете '''статический IP''', установите адрес шлюза. Не трогайте этот параметр, если вы используете'''DHCP'''<br />
** '''ROUTES'''=: Если вы используете статический '''IP''', уберите '''!''' перед 'gateway'. Оставьте'''!''', если используете '''DHCP'''<br />
<br />
К примеру, если используется '''DHCP''':<br />
HOSTNAME="arch"<br />
#eth0="eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255" <br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
gateway="default gw 192.168.0.1"<br />
ROUTES=(!gateway)<br />
* Секция '''DAEMONS'''<br />
Этот массив задает список имен скриптов в /etc/rc.d/ которые будут запускаться во время загрузки системы, а так же порядок их запуска. <br />
DAEMONS=(@network syslog-ng netfs crond)<br />
*Если перед именем скрипта стоит восклицательный знак (!), он не исполняется. <br />
*Если перед скриптом стоит символ "at" (выглядит как "@"), тогда он будет запущен в фоновом режиме; очередь загрузки не будет ожидать успешного завершения демона перед переходом к загрузке следующего. Полезно для ускорения загрузки системы.<br />
*Редактируете этот массив, когда устанавливаете новые системные сервисы, если желаете, чтобы они загружались во время запуска системы.<br />
<br />
Это загрузка в 'стиле BSD', с особым Arch-способом обращения, в то время как остальные обращаются с помощью symlinks к директории /etc/init.d<br />
<br />
=====О Демонах=====<br />
Потушите свечу, уберите распятие, унесите иконы. Да, разговор пойдет о Демонах, но вовсе не о тех, о которых вы подумали сначала. И, да, вам не обязательно изменять строчку [[daemons]] в этот раз, но будет полезно объяснить, кто такие Демоны, поскольку они пригодятся нам далее в этом руководстве. <br />
<br />
По аналогии с сервисами Windows, ''демоны'' это программы, работающие в фоновом режиме, ожидающие наступления определенного события и предоставляющие сервисы. Отличный пример - вебсервер, который ожидает запроса на получение страницы или SSH-сервер, ожидающий, пока кто-нибудь не попробует войти в систему. В отличие от этих "полноценных" программ, их работа не так заметна. К примеру демон, который записывает что-либо в log-файл (к примеру, syslog, metalog), демон, понижающий частоту вашего CPU, когда система ничем не занята (к примеру:cpufreq), и демоны, которые представляют вам графический вариант входа в систему (log on) (к примеру: gdm, kdm). Все эти программы могут быть добавлены в строку "daemons" и будут запущены во время загрузки операционной системы. Всячекие полезные демоны будут представлены далее в этом руководстве. (Призыв Азазеля, Велиара, Асмодея, Маммона, Балтазара и других высших демонов в этом руководстве не рассматривается).<br />
<br />
Обращаясь к истории, термин ''daemon'' был предложен программистами MIT's Project MAC. Они заимствовали имя из ''Maxwell's demon'', мысленный эксперимент, главным персонажем которого является гипотетическое разумное существо ростом c молекулу. Выдумано Джеймсом Максвеллом с целью проиллюстрировать Второе начало термодинамики. <code>UNIX</code> системы унаследовали терминологию и создали бэкроним '''d'''isk '''a'''nd '''e'''xecution '''mon'''itor. <br />
<br />
*'''''Подсказка: Все демоны в Arch проживают в директории /etc/rc.d/ Звоните! :)'''''<br />
<br />
=====Про /etc/fstab=====<br />
Так называемый '''fstab''' ('''f'''ile '''s'''ystems '''tab'''le) это часть конфигурации системы, отображающая все доступные диски и дисковые разделы; показывающая, как они инициализированны/интегрированны в системную файловую систему. Данный '''/etc/fstab''' обычно используется коммандой '''mount''', которая читает /etc/fstab дабы определить, какие настройки нужно использовать для монтирования определенного устройства.<br />
<br />
<br />
К примеру, '''/etc/fstab''':<br />
<br />
#<br />
# /etc/fstab: static file system information<br />
#<br />
# <file system> <dir> <type> <options> <dump> <pass><br />
none /dev/pts devpts defaults 0 0<br />
none /dev/shm tmpfs defaults 0 0<br />
#/dev/cdrom /mnt/cdrom iso9660 ro,user,noauto,unhide 0 0<br />
#/dev/dvd /mnt/dvd udf ro,user,noauto,unhide 0 0<br />
#/dev/fd0 /mnt/fd0 vfat user,noauto 0 0<br />
/dev/disk/by-uuid/0ec-9339 / jfs defaults,noatime,nodiratime 0 1<br />
/dev/disk/by-uuid/7ef-223-0 /home jfs defaults,noatime,nodiratime 0 2<br />
/dev/disk/by-uuid/530-1e-2c2 swap swap defaults 0 0<br />
<br />
Измените '''fstab''' под себя, если желаете.<br />
{{Box Note | Как было писано в 2008-04rc, Arch теперь использует UUID, или Universally Unique Identifier конвертацию имен для повышения совместимости. Крайне полезно при активной работе над ядром и udev, что может повлечь случайное изменение в порядке загрузки драйверов storage-контроллеров и невозможности загрузки системы из-за kernel-panic. Почти все материнские платы имеют несколько контроллеров (SATA, IDE), и в вышеуказанных случаях, /dev/sda мог запросто стать /dev/sdb при следующей загрузке - с тех пор была введена UUID.}}<br />
ls -lF /dev/disk/by-uuid/<br />
Отобразит разделы, отсортированные по uuid.<br />
<br />
*Если вы планируете использование '''hal''' для автоматического монтирования всякой всячины (вроде DVD дисков), вы, возможно, изволите закомментить записи, касающиеся cdrom и dvd для подготовки к установке '''hal''', который будет инсталлирован нами далее в этом руководстве.<br />
<br />
{{Box Note | '''''The 'noatime' and 'nodiratime' options may safely be appended to / and /home regardless of your specified filesystem type for increased speed, performance, and power efficiency, for laptops as well as desktops.'''''}}<br />
<br />
Expanded information available in the [[Fstab]] wiki entry.<br />
<br />
====='''/etc/mkinitcpio.conf and /etc/modprobe.conf'''=====<br />
We shouldn't need to edit these configurations at this point. <br />
<br />
* '''mkinitcpio.conf''' This file allows you to fine-tune the initial ram filesystem (also commonly referred to as the initial ramdisk or "initrd") for your system. The initrd is a gzipped image that is read by the kernel during bootup. The purpose of the initrd is to bootstrap the system to the point where it can access the root filesystem. This means it has to load any modules that are required for devices like IDE, SCSI, or SATA drives (or USB/FW, if you are booting off a USB/FW drive). Once the initrd loads the proper modules, either manually or through udev, it passes control to the Arch system and your bootup continues. For this reason, the initrd only needs to contain the modules necessary to access the root filesystem. It does not need to contain every module you would ever want to use. The majority of your everyday modules will be loaded later on by udev, during the init process.<br />
<br />
* '''modprobe.conf''' can be used to set special configuration options for the kernel modules <br />
<br />
=====/etc/resolv.conf (for Static IP)=====<br />
The ''resolver'' is a set of routines in the C library that provide access to the Internet Domain Name System (DNS). One of the main functions of DNS is to translate domain names into IP addresses, to make the Web a friendlier place. The resolver configuration file, or /etc/resolv.conf, contains information that is read by the resolver routines the first time they are invoked by a process.<br />
<br />
*''If you are using DHCP, you may safely ignore this file, as by default, it will be dynamically created and destroyed by the dhcpcd daemon. You may change this default behavior if you wish. (See [[Network]]).''<br />
<br />
If you use a static IP, set your DNS servers in /etc/resolv.conf (nameserver <ip-address>). You may have as many as you wish, e.g.:<br />
nameserver 4.2.2.1<br />
nameserver 4.2.2.2<br />
<br />
If you are using a router, you will probably want to specify your DNS servers in the router itself, and merely point to it from your '''/etc/resolv.conf''', using your router's IP (which is also your gateway from '''/etc/rc.conf'''), e.g.:<br />
nameserver 192.168.1.1<br />
<br />
If using '''DHCP''', you may also specify your DNS servers in the router, or allow automatic assignment from your ISP, if your ISP is so equipped.<br />
<br />
=====/etc/hosts=====<br />
<br />
This file associates IP addresses with hostnames and aliases, one line per IP address. For each host a single line should be present with the following information:<br />
<IP-address> <hostname> [aliases...]<br />
Add your ''hostname'', coinciding with the one specified in /etc/rc.conf, as an alias, so that it looks like this:<br />
127.0.0.1 localhost.localdomain localhost '''''yourhostname'''''<br />
{{Box Note |''This format, '''including the 'localhost' and your actual host name''', is required for program compatibility! Errors in this entry may cause poor network performance and/or certain programs to open very slowly, or not work at all. This is a very common error for beginners.''}}<br />
<br />
If you use a static IP, add another line using the syntax: <static-IP> <hostname.domainname.org> <hostname> e.g.:<br />
192.168.1.100 '''''yourhostname'''''.domain.org '''''yourhostname'''''<br />
<br />
*'''TIP''': For convenience, you may also use /etc/hosts aliases for hosts on your network, and/or on the Web, e.g.:<br />
64.233.169.103 www.google.com g<br />
192.168.1.90 media<br />
192.168.1.88 data<br />
The above example would allow you to access google simply by typing 'g' into your browser, and access to a media and data server on your network by name and without the need for typing out their respective IP addresses.<br />
<br />
=====/etc/hosts.deny and /etc/hosts.allow=====<br />
Modify these configurations according to your needs if you plan on using the [[SSH|ssh]] daemon. The default configuration will reject all incoming connections, not only ssh connections. Edit your '''/etc/hosts.allow '''file and add: <br />
sshd:all <br />
This will allow all incoming ssh connections.<br />
<br />
If you do not plan on using the [[SSH|ssh]] daemon, leave this file at the default, (empty), for added security.<br />
<br />
=====/etc/locale.gen=====<br />
<br />
The '''locale-gen''' command reads from '''/etc/locale.gen''' to generate specific locales. They can then be used by '''glibc''' and any other locale-aware program or library for rendering "peculiar" text, correctly displaying regional monetary values, time and date formats, alphabetic idiosyncrasies, and other locale-specific standards. The ability to setup a default locale is a great built-in privilege of using a <code>UNIX</code>-like operating system.<br />
<br />
By default /etc/locale.gen is an empty file with commented documentation. Once edited, the file won't get touched again. '''locale-gen''' runs on every '''glibc''' upgrade, generating all the locales specified in /etc/locale.gen.<br />
<br />
Choose the locale(s) you need (remove the # in front of the lines you want), e.g.:<br />
en_US ISO-8859-1<br />
en_US.UTF-8 <br />
<br />
The installer will now run the locale-gen script, which will generate the locales you specified. You may change your locale in the future by editing /etc/locale.gen and subsequently running 'locale-gen' as root.<br />
<br />
{{Box Note |'''''If you fail to choose your locale, this will lead to a "The current locale is invalid..." error. This is perhaps the most common mistake by new Arch users, and also leads to the most commonly asked questions on the forum.'''''}}<br />
<br />
=====Root password=====<br />
Finally, set a root password and make sure that you remember it later. Return to the main menu and continue with installing bootloader.<br />
<br />
=====Pacman-Mirror=====<br />
Choose a mirror repository for '''pacman'''. <br />
*''archlinux.org is throttled, limiting downloads to 50KB/s'' <br />
<br />
Return to the main menu.<br />
<br />
===Install Bootloader===<br />
Because we have no secondary operating system in our example, we will need a bootloader. [http://www.gnu.org/software/grub/ GNU GRUB] is the recommended bootloader. Alternatively, you may choose [http://lilo.go.dyndns.org/ LILO]. <br />
===GRUB===<br />
The provided '''GRUB''' configuration ('''/boot/grub/menu.lst''') should be sufficient. The only thing you may want to alter is the resolution of the console. Add<br />
a vga=<number> to the first kernel line. (A table of resolutions and the corresponding numbers is printed in the menu.lst.)<br />
<br />
Example: <br />
title Arch Linux (Main)<br />
root (hd0,0)<br />
kernel /boot/vmlinuz26 root=/dev/disk/by-uuid/0ec1-9339.. ro vga=773<br />
initrd /boot/kernel26.img<br />
Explanation:<br />
<br />
Line 1: '''title''': A printed menu selection. "Arch Linux (Main)" will be printed on the screen as a menu selection.<br />
<br />
Line 2: '''root''': GRUB's root; the drive and partition where the kernel (/boot) resides. '''NOT necesarily the root''' (/) file system, as they can reside on separate partitions. GRUB's numbering scheme starts at 0, and uses an hd''x,x'' format regardless of IDE or SATA, enclosed within parentheses. <br />
<br />
The example indicates that /boot is on the first partition of the first drive, or, (hd0,0).<br />
<br />
Line 3: '''kernel''': This line specifies:<br />
<br />
* The path and filename of the kernel '''''relative to GRUB's root''''' (within the partition containing the kernel). <br />
<br />
In the example, /boot is merely a directory residing on the same partition as / and '''vmlinuz26''' is the kernel filename; '''/boot/vmlinuz26'''. ''If /boot were on a separate partition, the path and filename would be simply '''/vmlinuz26''', being relative to '''GRUB''''s root.'' <br />
<br />
* The root= argument to the kernel statement specifies the partition containing the root (/) directory in the booted system, (more accurately, the partition containing '''/sbin/init'''), ''according to the UUID numbering scheme'' as of 2008-04rc, which uses the /dev/disk/by-uuid/xxxx-xxxx-xxxx format. <br />
<br />
* Kernel options. <br />
<br />
In our example, '''ro''' mounts the filesystem as read only during startup, and the '''"vga=773"''' argument will give a 1024x768 framebuffer with 256 color depth.<br />
<br />
Line 4: '''initrd''': (For Initial RAM disk) The path and filename of the initial RAM filesystem '''relative to GRUB''''s root (within the partition containing the kernel). Again, in the example, /boot is merely a directory residing on the same partition as / and '''kernel26.img''' is the initrd filename; '''/boot/kernel26.img'''. ''If /boot were on a separate partition, the path and filename would be simply '''/kernel26.img''', being relative to '''GRUB''''s root.'' <br />
<br />
Install the '''GRUB''' bootloader to the master boot record, (sda in our example).<br />
<br />
That's it; You have configured and installed your Arch Linux base system. Exit the install, eject the installer CD, and type the magic word:<br />
<br />
reboot<br />
<br />
Your new Arch Linux system will boot up and finish with a login prompt (you may want to change the boot order in your '''BIOS''' back to booting from hard disk).<br />
<br />
'''Congratulations, and welcome to your shiny, new Arch Linux base system!'''<br />
<br />
==The Base System ==<br />
Your new Arch Linux base system is now a functional GNU/Linux environment ready for customization. From here, you may build this elegant set of tools into whatever you wish or require for your purposes. <br />
<br />
Let's begin.<br />
<br />
Login with your root account. We will configure pacman and update the system as root, then add a normal user. <br />
{{Box Note |Virtual consoles 1-6 are available, as is the '''links''' command line web browser.}}<br />
<br />
===Configuring the network (if necessary)===<br />
*''This section will assist you in configuring most types of networks, if your network configuration is not working for you.''<br />
<br />
If you properly configured your system, you should have a working network. Try to ping www.google.com to verify this.<br />
ping -c 3 www.google.com<br />
<br />
''If you have successfully established a network connection, continue with '''[[#Update, Sync and Upgrade the system with pacman|Update, Sync and Upgrade the system with pacman]]'''.''<br />
<br />
If, after trying to ping www.google.com, you get an "unknown host" error, you may conclude that your network is not properly configured. You may choose to double-check the following files for integrity and proper settings:<br />
<br />
'''/etc/rc.conf''' # Specifically, check your HOSTNAME= and NETWORKING section for typos and errors.<br />
<br />
'''/etc/hosts''' # Double-check your format. (See above.)<br />
<br />
'''/etc/resolv.conf''' # If you are using a static IP. If you are using DHCP, this file will be dynamically created and destroyed by default, but can be changed to your preference. (See [[Network]].)<br />
<br />
Advanced instructions for configuring the network can be found in the [[Network]] article.<br />
<br />
====Wired LAN====<br />
<br />
Check your Ethernet with<br />
ifconfig -a<br />
All interfaces will be listed. You should see an entry for eth0, or perhaps eth1. If required, you can set a new static IP with<br />
ifconfig eth0 <ip address> netmask <netmask> up <br />
and the default gateway with<br />
route add default gw <ip address of the gateway><br />
Check to see if /etc/resolv.conf contains your DNS server and add it if it is missing. <br />
Check your network again with ping www.google.de. If everything is working now, adjust /etc/rc.conf as described above for static IP. If you have a DHCP server/router in your network try<br />
dhcpcd eth0<br />
If this is working, adjust /etc/rc.conf as described above, for dynamic IP.<br />
<br />
====Wireless LAN====<br />
Detailed setup guide: [[Wireless Setup]]<br />
<br />
====Analog Modem====<br />
To be able to use a Hayes-compatible, external, analog modem, you need to at least have the ppp package installed. Modify the file /etc/ppp/options to suit your needs and according to man pppd. You will need to define a chat script to supply your username and password to the ISP after the initial connection has been established. The manpages for pppd and chat have examples in them that should suffice to get a connection up and running if you're either experienced or stubborn enough. With udev, your serial ports usually are /dev/tts/0 and /dev/tts/1.<br />
Tip: Read [[Dialup without a dialer HOWTO]].<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt to install wvdial or a similar tool to ease the setup process considerably. In case you're using a so-called WinModem, which is basically a PCI plugin card working as an internal analog modem, you should indulge in the vast information found on the [http://www.linmodems.org/ LinModem] homepage.<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, meaning that you won't need to recompile your kernel unless you're about to use rather odd ISDN hardware. After physically installing your ISDN card in your machine or plugging in your USB ISDN-Box, you can try loading the modules with modprobe. Nearly all passive ISDN PCI cards are handled by the hisax module, which needs two parameters: type and protocol. You must set protocol to '1' if your country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3' if you're hooked to a so-called leased-line without D-channel, and '4' for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the kernel documentation, more specifically in the isdn subdirectory, and available online. The type parameter depends on your card; a list of all possible types can be found in the README.HiSax kernel documentation. Choose your card and load the module with the appropriate options like this:<br />
<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my ELSA Quickstep 1000PCI, being used in Germany with the EDSS1 protocol. You should find helpful debugging output in your /var/log/everything.log file, in which you should see your card being prepared for action. Please note that you will probably need to load some USB modules before you can work with an external USB ISDN Adapter.<br />
<br />
Once you have confirmed that your card works with certain settings, you can add the module options to your /etc/modprobe.conf:<br />
<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively, you can add only the options line here, and add hisax to your MODULES array in the rc.conf. It's your choice, really, but this example has the advantage that the module will not be loaded until it's really needed.<br />
<br />
That being done, you should have working, supported hardware. Now you need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl; it'll get you started. Further down in the manpage you will find explanations on how to create a configuration file that can be parsed by isdnctrl, as well as some helpful setup examples. Please note that you have to add your SPID to your MSN setting separated by a colon if you use US NI1.<br />
<br />
After you have configured your ISDN card with the isdnctrl utility, you should be able to dial into the machine you specified with the PHONE_OUT parameter, but fail the username and password authentication. To make this work add your username and password to /etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were configuring a normal analogous PPP link, depending on which protocol your ISP uses for authentication. If in doubt, put your data into both files.<br />
<br />
If you set up everything correctly, you should now be able to establish a dial-up connection with<br />
isdnctrl dial ippp0<br />
as root. If you have any problems, remember to check the logfiles!<br />
<br />
====DSL (PPPoE)====<br />
<br />
These instructions are relevant to you only if your PC itself is supposed to manage the connection to your ISP. You do not need to do anything but define a correct default gateway if you are using a separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to physically install the network card that is supposed to be connected to the DSL-Modem into your computer. After adding your newly installed network card to the modules.conf/modprobe.conf or the MODULES array, you should install the rp-pppoe package and run the pppoe-setup script to configure your connection. After you have entered all the data, you can connect and disconnect your line with<br />
<br />
/etc/rc.d/adsl start<br />
<br />
and<br />
<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward, but feel free to read the manpages for hints. If you want to automatically dial in on boot-up, add adsl to your DAEMONS array.<br />
<br />
==Update, Sync and Upgrade the system with [[pacman]]==<br />
Now we will update the system using [[pacman]]. <br />
<br />
=====What is pacman ?=====<br />
[[Pacman]] is the '''pac'''kage '''man'''ager of Arch Linux. Pacman is written in C and is fast, simple, and extremely powerful. It manages your entire package system and handles installation, removal, package downgrade (through cache), custom compiled package handling, automatic dependency resolution, remote and local searches and much more. Arch uses the .tar.gz package format, which further enhances pacman's speed; Gzipped tarballs, though slightly larger, are decompressed much faster than their Bzipped counterparts, and are therefore generally installed more expediently. <br />
<br />
We will use pacman to download software packages from remote repositories and install them onto your system.<br />
<br />
Pacman is the most important tool in your Arch Linux toolbox for building the base system into whatsoever you please.<br />
<br />
===Configuring pacman===<br />
<br />
=====Package Repositories and /etc/pacman.conf=====<br />
Arch currently offers the following repositories readily accessible through pacman:<br />
<br />
'''[core]'''<br />
<br />
The simple principle behind [core] is to provide only one of each necessary tool for a base Arch Linux system; The GNU toolchain, the Linux kernel, one editor, one command line browser, etc. (There are a few exceptions to this. For instance, both vi and nano are provided, allowing the user to choose one or both.) Developer maintained.<br />
<br />
*''The Core installation cd simply contains an installer script, and a snapshot of the core repository.''<br />
<br />
'''[extra]'''<br />
<br />
The [extra] repository contains all Arch packages that are not themselves necessary for a base Arch system, but contribute to a more full-featured environment. '''X''', KDE and GNOME, for instance, can be found here. Developer maintained.<br />
<br />
'''[unstable]'''<br />
<br />
The [unstable] repository contains experimental and unstable software, especially if the development version of a package has become popular for some reason. For example, perhaps the upstream stable version is hopelessly out of date, or the unstable version has some groundbreaking changes that a lot of users seem interested in, like experimental kernel drivers or -svn package versions. Developer maintained.<br />
<br />
{{Box Note |'''Contrary to popular belief, it is perfectly safe to enable the unstable repository, as there are no name collisions with [core], [community] or [extra]. Packages from [unstable] are only installed if you explicitly do so. If there is a conflict between an [Unstable] package and an installed package, pacman will warn you and resolve the conflict, if prompted, by removing the installed package.'''}}<br />
<br />
The [unstable] repository is currently not maintained for ''x86_64''.<br />
<br />
'''[testing]'''<br />
<br />
The [testing] repository contains packages that are candidates for the [core], [extra] or [unstable] repositories. New packages go into [testing] if:<br />
* they are expected to break something on update and need to be tested first<br />
* they require other packages to be rebuilt. In this case, all packages that need to be rebuilt are put into [testing] first and when all rebuilds are done, they are moved back to the other repositories. Developer maintained.<br />
<br />
[testing] is the only repository that can have name collisions with any of the other official repositories. If enabled, it has to be the first repo listed in your ''pacman.conf'' file.<br />
<br />
{{Box Note|'''''Be careful when enabling [testing]. Your system may break after you update with [testing] enabled. Only experienced users should use it.'''''}}<br />
<br />
'''[community]'''<br />
<br />
The [community] repository is maintained by the ''Trusted Users (TUs)'' and is part of the ''Arch User Repository ([[AUR]])''. It contains binary packages from the ''AUR'' that have enough votes and were adopted by a ''TU''. Like all repos listed above, [community] may be readily accessed by pacman.<br />
<br />
The '''[[AUR]]''' also contains the '''unsupported''' branch, which cannot be accessed directly by pacman*. [unsupported] contains more than 8 thousand PKGBUILD scripts for building packages from source, that may be unavailable through the other repos. <br />
<br />
<nowiki>*</nowiki>''The '''''[[#Install Yaourt| yaourt]]''''' tool, an extremely popular, community contributed wrapper for pacman, can seamlessly access the '''AUR'''.''<br />
<br />
'''/etc/pacman.conf'''<br />
<br />
pacman will attempt to read /etc/pacman.conf each time it is invoked. This configuration file is divided into sections, or repositories. Each section defines a package [[Official Repositories|repository]] that pacman can use when searching for packages. The exception to this is the options section, which defines global options.<br />
nano /etc/pacman.conf<br />
Example:<br />
[core]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[extra]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
#[unstable]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[community]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
Enable all desired repositories (remove the # in front of the 'Include =' and '[repository]' lines).<br />
<br />
<br />
*'''''When choosing repos, be sure to uncomment both the repository header lines in [brackets] as well as the 'Include =' lines. Failure to do so will result in the selected repository being omitted! This is a very common error.'' '''<br />
<br />
====/etc/pacman.d/mirrorlist====<br />
Faster mirrors will dramatically improve pacman performance, and your overall Arch Linux experience.<br />
<br />
Edit /etc/pacman.d/mirrorlist:<br />
nano /etc/pacman.d/mirrorlist<br />
Remove all mirrors which are not on your continent, or are extremely distant. (Using nano, you may use CTRL-K to cut each unneeded line.) <br />
<br />
Edit /etc/pacman.d/mirrorlist by placing the best mirror at the top of the list. (Recall that archlinux.org is throttled to 50KB/s). If using nano, you can cut a line with CTRL-K and paste with CTRL-U. <br />
<br />
After changing mirrors, issue the following command:<br />
pacman -Syy<br />
This will force pacman to resynchronize with the new repo. Issuing pacman -Syy ''whenever a mirror is changed'', is good practice and will avoid possible headaches.<br />
=====Ignoring packages=====<br />
When you execute the command "pacman -Syu", your entire system will be updated. It is possible that you want to prevent a package from being upgraded. An example could be the kernel (kernel26) or a package for which an upgrade may prove problematic for your system. In this case, you have two options; indicate the packages you want to skip in the pacman command line using the --ignore switch (do pacman -S --help for details) or permanently indicate the packages you want to skip in your /etc.pacman.conf file:<br />
<br />
IgnorePkg = kernel26<br />
The typical way to use Arch is to use pacman to install all packages unless there is no package available, in which case you can build your own package using [[ABS]]. Many user-contributed packages are available in the Arch User Repository. You are expected to keep your system up to date with pacman -Syu, rather than selectively upgrading packages. Use of '''IgnorePkg''' in /etc/pacman.conf is therefore discouraged, and should be used sparingly, if you know what you are doing.<br />
<br />
You may diverge from this typical usage as you wish; just be warned that there is a greater chance that things will not work as intended and that it could break your system. The majority of complaints happen when selective upgrading or unusual compilation is performed.<br />
<br />
=====Ignoring Configuration Files=====<br />
In the same vein, you can also "protect" your configuration/system files from being overwritten during "pacman -Su" using the following option in your /etc/pacman.conf<br />
<br />
NoUpgrade = etc/lilo.conf boot/grub/menu.lst<br />
<br />
==Update System==<br />
Update, sync, and '''upgrade''' your entire new system with:<br />
pacman -Syu<br />
pacman will now fetch the latest information about available packages and perform all available upgrades. (You may be prompted to upgrade pacman itself at this point. If so, say yes, and then reissue the pacman -Syu command when finished.) <br />
Reboot if a kernel upgrade has occurred. <br />
{{Box Note|'''''Occasionally, configuration changes may take place requiring user action during an update; read pacman's output for any pertinent information.'''''}}<br />
<br />
=====Прелесть Arch'овой Rolling-release'ной модели=====<br />
Запомните, что Arch это дистрибутив с '''rolling release''' моделью. Это значит, что у вас никогда не возникнет причин для переустановки или or или разбираться в очередном релизе для обновления вашей системы. Просто переодически используйте '''pacman -Syu''' и ваша система будет всегда свежа, обновлена (и хорошо пахнуть :). После данного обновления все компоненты вашей системы будут иметь текущие версии.<br />
Если было также обновлено и ядро, перезагрузитесь (команда reboot).<br />
<br />
=====Get familiar with pacman=====<br />
Pacman is the Arch user's best friend. It is highly recommended to study and learn how to use the pacman tool. Try:<br />
man pacman<br />
Check out the bottom of this article, and look up the [[pacman]] wiki entries at your leisure.<br />
<br />
<br />
<br />
===Add a user and setup groups===<br />
You should not do your everyday work using the root account. It is more than poor practice; it is dangerous. Root is for administrative tasks. Instead, add a normal user account using:<br />
adduser<br />
While most default options are safe to use, you may want to add storage, audio, video, optical, and wheel to your additional groups- especially if you are planning on having a full-featured desktop environment. <br />
<br />
Groups and users thereof are defined in /etc/group. <br />
<br />
They include:<br />
<br />
*'''audio''' - for tasks involving sound card and related software<br />
<br />
*'''wheel''' - for using sudo<br />
<br />
*'''storage''' - for managing storage devices<br />
<br />
*'''video''' - for video tasks and 3d acceleration<br />
<br />
*'''optical''' - for managing tasks pertaining to the optical drive(s)<br />
<br />
*'''floppy''' - for access to a floppy if applicable<br />
<br />
*'''lp''' - for managing printing tasks<br />
<br />
See the [[Groups]] article to understand what groups you need to be a member of. <br />
<br />
Check the man pages for usermod and gpasswd for more information.<br />
=====Install and setup Sudo=====<br />
<br />
See [[Sudo]]<br />
<br />
==Часть II: Ставим X и настраиваем ALSA==<br />
<br />
<br />
===Настройка звуковой карты с помощью alsamixer===<br />
Advanced Linux Sound Architecture (известная под акронимом '''ALSA''') это компонент ядра систему Linux, призванный заменить Open Sound System (OSS) представляющий драйвера для звуковых карт. Кроме драйверов, '''ALSA''' так же предоставляет библиотеки для разработчиков, которые хотят использовать возможности драйвера на более высоком уровне API, нежели прямое взаимодействие с драйверами ядра.<br />
-----<br />
{{Box Note|udev автоматически проверит ваше устройство во время загрузки, загрузив соотвествующий драйвер для вашей звуковой карты. Ваша аудиосистема, скорее всего, уже работает, но по умолчанию звук отключен (mute).}} <br />
Пакет утилит alsa содержит alsamixer, который позволяет настраивать звук прямо из консоли. (Вы сможете загружать aslamixer также из окружения '''X''' несколько позже.)<br />
<br />
Установка пакета утилит alsa:<br />
pacman -S alsa-utils<br />
Вы добавили-то обычного пользователя в группу audio? Если нет, то сейчас самое время! Под root'ом выполните:<br />
gpasswd -a yourusername audio<br />
Завершите сеанс (exit) и снова войдите под обычным пользователем, дабы удостоверится, что группа audio загрузилась верно.<br />
<br />
Под '''''простым, не root'овым''''' пользователем, выполните: <br />
'''[root@myhost ~]#''' alsamixer<br />
Включите каналы MASTER и PCM, подведя к ним курсор стрелочками лево/право и нажатием английской '''M'''. Увеличьте громкость клавишей "вверх" (70-90% должно быть в самый раз). Закройте микшер нажатием ESC.<br />
<br />
==== Проверка звука ====<br />
Проверьте настройку вашей аудиокарты коммандой aplay:<br />
aplay /usr/share/sounds/alsa/Front_Center.wav<br />
Вы услышите чарующий, манящий, жаркий и нежный, искрящийся всеми цветами радуги и клубящийся утренним туманом на горе Фудзи в лучах восходящего солнца, женский голос, прозносящий: "Front, center."<br />
<br />
Теперь залогинтесь под root'ом и выполните комманду alsactl:<br />
alsactl store<br />
Это приведет к созданию '/etc/asound.state', сохраняя найстроки asla-микшера.<br />
<br />
Также, добавте ''daemon'' alsa в вашу DAEMONS-секцию (демоническая секция, а-а-а!) в /etc/rc.conf дабы настройки микшера восстанавливались при каждой загрузке автоматически.<br />
nano /etc/rc.conf<br />
DAEMONS=(syslog-ng network crond '''alsa''')<br />
''Учтите, что демон alsa'ы просто восстанавливает уровни громкости микшера при загрузки путем чтения /etc/asound.state. Это происходит независимо от аудио-библиотеки alsa (и уровня громкости API ядра).''<br />
<br />
Дополнительную информацию можно найти в wiki-записи [[ALSA]].<br />
<br />
===Устанавливаем и настраиваем X-ы===<br />
О, великие '''X''' Window System (обычно '''X11''', или '''X''', или просто '''Иксы''') это сетевой и экранный протокол, который поддерживает оконную систему на bitmap-дисплеях. Иксы предоставляют арсенал утилит и протокол для создания Графического Интефейса Пользователя (GUI) на <code>UNIX</code>'овых операционных системах.<br />
<br />
'''X''' представляет базовый фреймворк, на примитивах, для создания GUI'овых сред: отрисовка и перемещение окон по экрану и взаимодействие с мышкой/клавиатурой. '''X''' не предоставляет пользовательский интерфейс — это поддерживает индивидуальная клиент-программа. <br />
<br />
'''X''' так назван, поскольку им предшествовала '''W''' Window System, разработанна в Стендфорском Университете. <br />
-----<br />
<br />
{{Box Note| Если вы планировали использовать '''open-source''' видео-драйвер, и если вам нужно 3d-ускорение, рекомендуется инсталлировать библиотеку libgl перед установкой Xorg:}}<br />
pacman -S libgl<br />
''(Проприетанрные видеодрайверы обеспечивают свои собственные реализации этой библиотеки)''<br />
----- <br />
Теперь мы установим основные пакеты Xorg, используя pacman. Это - первый шаг в построении GUI.<br />
<br />
pacman -S xorg<br />
3d-утилиты, такие как glxgears включены пакет '''mesa''':<br />
pacman -S mesa<br />
<br />
Теперь у нас есть основные пакеты, в которых мы нуждаемся для того, чтобы запустить '''X''' Server. Сейчас вы должны добавить драйвер для своей видеокарты (к примеру xf86-video-<имя>). Самый простой способ конфигурировать X.org, устанавливая корретные пакеты драйвера сначала, а затем генерируя /etc/X11/xorg.conf испольуя скрипт автоконфигурации, такой как Xorg - configure.<br />
<br />
Если вы хотите увидеть весь список '''open-source''' видеодрайверов, используйте: <br />
pacman -Ss xf86-video | less<br />
Вам нужно знать, какой видеочипсет на вашем компьютере. Если вы не знаете, выполните:<br />
lspci | grep VGA<br />
Здесь приведен список '''open source''' драйверов и соотвествующих графических чипсетов..<br />
*'''xf86-video-apm''' Alliance ProMotion video driver<br />
*'''xf86-video-ark''' ark video driver<br />
*'''xf86-video-ati''' ati video driver<br />
*'''xf86-video-chips''' Chips and Technologies video driver<br />
*'''xf86-video-cirrus''' Cirrus Logic video driver<br />
*'''xf86-video-dummy''' dummy video driver<br />
*'''xf86-video-fbdev''' framebuffer video driver<br />
*'''xf86-video-glint''' GLINT/Permedia video driver<br />
*'''xf86-video-i128''' Number 0 i128 video driver<br />
*'''xf86-video-i740''' Intel i740 video driver<br />
*'''xf86-video-i810''' Intel i810/i830/i9xx video drivers (deprecated - use -intel)<br />
*'''xf86-video-intel''' Newer Version of Intel i810/i830/i9xx video drivers<br />
*'''xf86-video-imstt''' Integrated Micro Solutions Twin Turbo vidoe driver<br />
*'''xf86-video-mga''' mga video driver (Matrox Graphics Adapter)<br />
*'''xf86-video-neomagic''' neomagic video driver<br />
*'''xf86-video-nv''' nvidia nv video driver<br />
*'''xf86-video-rendition''' Rendition video driver<br />
*'''xf86-video-s3''' S3 video driver<br />
*'''xf86-video-s3virge''' S3 Virge video driver<br />
*'''xf86-video-savage''' savage video driver<br />
*'''xf86-video-siliconmotion''' siliconmotion video driver<br />
*'''xf86-video-sis''' SiS video driver<br />
*'''xf86-video-sisusb''' SiS USB video driver<br />
*'''xf86-video-tdfx''' tdfx video driver<br />
*'''xf86-video-trident''' Trident video driver<br />
*'''xf86-video-tseng''' tseng video driver<br />
*'''xf86-video-unichrome''' Unichrome video drivers<br />
*'''xf86-video-v4l''' v4l video driver<br />
*'''xf86-video-vesa''' vesa video driver<br />
*'''xf86-video-vga''' VGA 16 color video driver<br />
*'''xf86-video-via''' via video driver<br />
*'''xf86-video-vmware ''' vmware video driver<br />
*'''xf86-video-voodoo ''' voodoo video driver<br />
<br />
* Отмечу, что '''vesa''' драйвера являются самыми универсальными, и будут работать почти со всеми современными графическими чипсетами. Если вы не смогли найти подходящий драйвер, то уж vesa '''должна''' работать.<br />
<br />
*Если у Вас есть NVIDIA или видеоадаптер ATI, Вы можете установить проприетарных NVIDIA или ATI драйвер. '''Установка проприетарных видеодрайверов освещена в [[#Использование проприетарных графических драйверов (NVIDIA, ATI)|чуть ниже]].'''<br />
<br />
Используйте pacman для инсталляции подходящего видеодрайвера для вашей видеокарты:<br />
pacman -S xf86-video-savage<br />
(для драйвера от Savage)<br />
<br />
==Создание /etc/X11/xorg.conf==<br />
=====Что такое /etc/X11/xorg.conf?=====<br />
/etc/X11/xorg.conf это главный конфигурационный файл вашей '''X''' Window System, основа основ вашего '''G'''raphical '''U'''ser '''I'''nterface. Это текстовой файл, разбитый на секции и подсекции. Важными являются секции ''Files, InputDevice, Module, Monitor, Modes, Screen, Device, и ServerLayout''. Секции могут располагаться в любом порядке, может быть несколько секций одного типа, к примеру, если у вас более одного монитора или если у вашего ноутбука кроме мышки есть еще и тачпад. <br />
------<br />
По умолчанию, у вас не будет конфигурационного xorg-файла. В последних версиях xorg он не нужен, ''если'' автоопределение ''работает нормально'' и вам не нужно вручную включать такие штуки, как aiglx и тому подобное. <br />
<br />
''Большинство людей считают, что им все равно необходимо сгенерировать этот файл.''<br />
<br />
<br />
Опытные пользователи обычно желают вручную сгенерировать свой собственный xorg.conf. Вы так же можете использовать скрипт Xorg -configure для базовой конфигурации. Под root'ом исполните:<br />
Xorg -configure<br />
Будет создан конфиг-файл в /root/xorg.conf.new <br />
<br />
Для теста сервера, введите:<br />
X -config /root/xorg.conf.new<br />
'''X''' запустится. Вы получите на экране бело-черный мышиный курсор в виде буквы '''X''', который будет откликаться на движение мышки/тачпада. Используйте CTRL-Alt-Backspace дабы покинуть '''X'''.<br />
<br />
Просмотр вашего конфиг-файла на предмет ошибок:<br />
<br />
nano /root/xorg.conf.new<br />
<br />
Убедитесь, что скрипт Xorg -configure корректно определил ваш видеодрайвер. к примеру:<br />
Section "Device"<br />
<br />
...<br />
<br />
Driver "vesa"<br />
VendorName "VM Ware Inc" #если вы запускаете ArchLinux в эмуляторе VM Ware<br />
<br />
...<br />
<br />
EndSection<br />
<br />
Убедитесь, что горизонтальная синхронизация и вертикальная частота обновления заданы под секцией "Monitor". Если нет, то задайте их:<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
VendorName "Monitor Vendor"<br />
ModelName "Monitor Model"<br />
HorizSync 30.0 - 130.0 # Подходит для большиства LCD мониторов<br />
VertRefresh 50.0 - 100.0 # Подходит для большинства LCD и CRT мониторов.<br />
EndSection<br />
(Если вы точно не знаете этих настроек, откройте инструкцию от вашего монитора.)<br />
<br />
Задайте глубину цвета под секцией "Screen":<br />
Section "Screen"<br />
Identifier "Screen0"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
(Значит, что мы установили 24битный цвет, что соотвествует true color (миллионы цветов)<br />
<br />
Также, добавьте желаемые режимы в подсекцию "Display" , в конце, под Depth 24 , к примеру:<br />
SubSection "Display"<br />
Viewport 0 0<br />
Depth 24<br />
Modes "1024x768" "800x600" "640x480"<br />
Добавьте следующий раздел, если Вы желаете включить eye candy, который требует дополнительного расширения: <br />
Section "Extensions"<br />
Option "Composite" "Enable"<br />
EndSection<br />
Испытайте ваш конфиг снова, после изменения:<br />
X -config /root/xorg.conf.new<br />
Убедитесь, что сессия '''X''' открылась без ошибок и переместите сгенерированный конфиг-файл в /etc/X11/:<br />
mv /root/xorg.conf.new /etc/X11/xorg.conf<br />
Подробные инструкции смотрите в статье [[Xorg]].<br />
<br />
====Alternative xorg.conf generation====<br />
If Xorg -configure is not generating a usable xorg.conf, you may alternatively use the hwd tool. Install with:<br />
pacman -S hwd<br />
And run with<br />
hwd -xa <br />
Lastly, you may choose xorgconfig, which will interactively prompt you for hardware information to create a basic xorg.conf:<br />
xorgconfig<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
===Using proprietary Graphics Driver (NVIDIA, ATI)===<br />
You may choose to use the proprietary video drivers from NVIDIA or ATI. <br />
====NVIDIA Graphic Cards====<br />
The NVIDIA proprietary drivers are generally considered to be of good quality, and offer 3D performance, whereas the open source '''nv''' driver offers only 2d support at this time. <br />
<br />
Before you configure your Graphics Card you will need to know which driver fits. Arch currently has 3 different driver packages that each match a certain subset of Cards: <br />
<br />
'''1. nvidia-71xx''' ''for very old Cards like TNT and TNT2''<br />
<br />
'''2. nvidia-96xx''' ''slightly newer cards up to the GF 4''<br />
<br />
'''3. nvidia''' ''newest GPUs after the GF 4''<br />
<br />
Consult the NVIDIA-Homepage to see which one is for you. The difference is only for the installation; Configuration works the same with every driver.<br />
<br />
Select and install the appropriate NVIDIA driver ''for your card'', e.g.: <br />
pacman -S nvidia-96xx<br />
<br />
The NVIDIA package has a utility for updating your existing /etc/X11/xorg.conf for use with the NVIDIA driver:<br />
nvidia-xconfig<br />
<br />
It also has several options which will further specify the contents and options of the xorg.conf file.<br />
For example,<br />
nvidia-xconfig --composite --add-argb-glx-visuals<br />
<br />
For more detailed information, see nvidia-xconfig(1).<br />
<br />
Some useful tweaking options in the device section are (beware that these may not work on your system):<br />
Option "RenderAccel" "true"<br />
Option "NoLogo" "true"<br />
Option "AGPFastWrite" "true"<br />
Option "EnablePageFlip" "true"<br />
Make sure all instances of DRI are commented out:<br />
# Load "dri"<br />
Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
Update kernel module dependencies:<br />
depmod -a<br />
<br />
Advanced instructions for nvidia configuration can be found in the [[NVIDIA]] article.<br />
<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
====ATI Graphic Cards====<br />
ATI owners have two options for drivers. If you are unsure which driver to use, please try the open-source one first. The open-source driver will suit most needs along with being generally less problematic.<br />
<br />
Install the '''proprietary''' ATI Driver with<br />
pacman -S catalyst<br />
Use the aticonfig tool to modify the xorg.conf.<br />
<br />
Install the '''open-source''' ATI Driver with<br />
pacman -S xf86-video-ati<br />
Currently, the performance of the open-source driver is not on par with that of the proprietary one. It also lacks TV-out, dual-link DVI support, and possibly other features. On the other hand, it supports Aiglx and has better dual-head support.<br />
{{Box Note| The latest proprietary driver does support [[AIGLX]] now. To use [[Compiz]] or [[Beryl]] add Option "AIGLX" "True" to Section ServerFlags and Option "Composite" "True" to Section Extensions.}}<br />
Advanced instructions for ATI configuration can be found in the [[ATI | ATI wiki]].<br />
<br />
===Simple baseline X test===<br />
<br />
At this point, you should have xorg installed, with a suitable video driver and an /etc/X11/xorg.conf configuration file. If you want to test your configuration quickly, to ensure your ability to start '''X''' from the command line before installing a complete desktop environment, you can do so by invoking '''xterm'''. Xterm is a very simple terminal emulator which runs in the '''X '''Server environment; it is installed as part of the base xorg packages.<br />
<br />
Prepare for the test by configuring a ~/.xinitrc:<br />
<br />
===== ~/.xinitrc =====<br />
This file dictates what '''X''' Window client is invoked with the '''startx''' and/or '''xinit''' command ''on a per-user basis''. (The '''startx''' script is merely a front end to the more versatile '''xinit''' command.) <br />
<br />
To determine the client to run, '''startx/xinit''' will first look for a .xinitrc file in the user's home directory. In the absence of file ~/.xinitrc, it defaults to the global xinitrc in the xinit library directory; /etc/X11/xinit/xinitrc, which defaults to using the TWM window manager. (Hence, if you invoke startx without a ~/.xinitrc file, a TWM session will start.)<br />
<br />
Switch to your '''''normal, non-root''''' user:<br />
su yourusername<br />
* /etc/skel/ contains files and directories to provide sane defaults for newly created user accounts. The name '''skel''' is derived from the word '''skeleton''', because the files it contains form the basic structure for users' home directories.<br />
Copy the sample xinitrc file from /etc/skel/ to your home directory: <br />
<br />
cp /etc/skel/.xinitrc ~/<br />
Edit the file: <br />
nano ~/.xinitrc<br />
and add:<br />
<br />
exec xterm<br />
<br />
So that it looks like this:<br />
<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
#<br />
exec xterm<br />
# exec wmaker<br />
# exec startkde<br />
# exec icewm<br />
# exec blackbox<br />
# exec fluxbox<br />
<br />
''Be sure to have only one uncommented '''exec''' line in your ~/.xinitrc at this time''. Below, we shall edit this file again to specify the appropriate desktop environment/window manager of your choice.<br />
<br />
Start '''X''' Server as '''normal, non-root''' user, with:<br />
<br />
startx<br />
or<br />
xinit<br />
You should have an '''xterm''' session open up. You can exit the '''X''' Server with Ctrl+Alt+Backspace, or by typing "exit". If you have problems starting '''X''', you can look for errors in the /var/log/Xorg.0.log file and on the console output of the console you started '''X''' from.<br />
<br />
If you prove a properly configured /etc/X11/xorg.conf by successfully running the test, you can be assured that your DE/WM of choice will work smoothly.<br />
<br />
Advanced instructions for Xorg configuration can be found in the [[Xorg]] article.<br />
<br />
==Part III: Installing and configuring a Desktop Environment ==<br />
While The '''X''' Window System provides the basic framework for building a ''graphical user interface'' (GUI), a '''Desktop Environment''' (DE), works atop and in conjunction with '''X''', to provide a completely functional and dynamic GUI. A DE typically provides icons, applets, windows, toolbars, folders, wallpapers, applications and abilities like drag and drop. The particular functionalities and designs of each DE will uniquely affect your overall environment and experience. Therefore, choosing a DE is a very subjective and personal decision. Choose the best environment for ''your'' needs.<br />
<br />
* If you want something full-featured and similar to Windows and Mac OSX, '''[[#KDE|KDE]]''' is a good choice<br />
* If you want something slightly more minimalist, which follows the K.I.S.S. principle more closely, '''[[#GNOME|GNOME]]''' is a good choice<br />
* '''[[#Xfce|Xfce]]''' is generally perceived as similar to GNOME, but lighter and less demanding on system resources, yet still visually pleasing and providing a very complete environment.<br />
<br />
If you have an older machine, or desire a lighter, less demanding GUI, you may choose to simply install a '''Window Manager''', or WM. A WM controls the placement and appearance of application windows in conjunction with the X Window System but does NOT provide such additions as panels, applets, icons, applications, etc.<br />
* Lightweight WM's include: '''Openbox, Fluxbox, fvwm2''', '''Windowmaker, Awesome and TWM'''.<br />
* If you need something completely different, try '''ion, wmii, dwm, or xmonad'''.<br />
<br />
===Install Fonts===<br />
At this point, you may want to install some good-looking fonts, '''before''' installing a desktop environment/window manager, (so you don't have to stare at ugly bitmap fonts in X). Dejavu and bitstream-vera are nice font sets. For websites, you may want to have the Microsoft fonts too. Install with:<br />
pacman -S ttf-ms-fonts ttf-dejavu ttf-bitstream-vera<br />
<br />
===~/.xinitrc (again)===<br />
<br />
As '''non-root user''', edit your /home/username/.xinitrc to utilize the DE you wish to use. This will allow you to use '''startx/xinit''' from the shell to open your DE/WM of choice:<br />
<br />
nano ~/.xinitrc<br />
<br />
Uncomment or add the ''''exec''' ..' line of the appropriate desktop environment/window manager. Some examples are below.<br />
<br />
For the Xfce4 desktop environment:<br />
exec startxfce4 <br />
<br />
For the KDE desktop environment:<br />
exec startkde<br />
A '''startkde''' or '''startxfce4''' command starts the KDE or Xfce4 desktop environment. This command does not finish until you logout of the DE. Normally the shell would wait for KDE to finish, then run the next command. The "exec" prefix to this command tells the shell that this is the last command, so the shell does not need to wait to run a subsequent command.<br />
<br />
Remember to have only one uncommented '''exec''' line in your ~/.xinitrc for now. <br />
<br />
Continue below, installing the DE/WM of your choice.<br />
<br />
===GNOME===<br />
====О проекте GNOME====<br />
'''G'''NU '''N'''etwork '''O'''bject '''M'''odel '''E'''nvironment. Проект GNOME сочетает в себе две вещи: интуитивно-понятное и приятное окружение рабочего стола, а также платформу для разработки, позволяющую создавать полностью интегрированные между собой и остальным окружением приложения.<br />
<br />
<br />
====Установка====<br />
Установить базовый набор пакетов GNOME можно следующей командой:<br />
pacman -S gnome<br />
<br />
Дополнительные пакеты (эмулятор терминала, текстовый редактор и т.д.) находятся в группе gnome-extra:<br />
pacman -S gnome-extra<br />
<br />
=====Полезные демоны для GNOME=====<br />
Демон - это исполняемая в фоне программа, которая дожидается определенных событий и обрабатывает их. Демон '''hal''', кроме всего прочего, автоматизирует монтирование жестких дисков, оптических приводов и флэш-накопителей. Демон '''fam''' обрабатывает изменения в структуре данных файловой системы, позволяя в реальном времени отслеживать изменения в файлах или директориях. Оба этих демона позволяют сильно упростить работу с окружением. Они устанавливаются при установке GNOME, но должны быть запущены для начала работы:<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
<br />
В качестве менеджера сессий хорошим выбором будет '''gdm'''.<br />
<br />
Установка:<br />
pacman -S gdm<br />
<br />
Для запуска этих демонов при загрузке, следует добавить их в секцию DAEMONS конфигурационного файла /etc/rc.conf :<br />
nano /etc/rc.conf<br />
<br />
DAEMONS=(syslog-ng network crond alsa '''hal fam gdm''')<br />
<br />
Демон gdm автоматически загружает графическую среду. Если вы попробуете её покинуть, используя ctrl+alt+backspace, он снова её загрузит. Если в этого не хотите, а хотите загружать граф.среду вручную, то ставьте в файле rc.conf перед именем этого демона (gdm) восклицательный знак (!). <br />
<br />
Чтобы запустить графическое окружение выполните:<br />
startx<br />
Если файл ~/.xinitrc не настроен для запуска GNOME, то окружение можно запустить командой xinit:<br />
xinit /usr/bin/gnome-session<br />
<br />
Дополнительные инструкции по установке и настройке могут быть найдены в статье [[GNOME_(Русский)|GNOME]].<br />
<br />
Поздравляем! Добро пожаловать в среду GNOME на вашей свежеустановленной системе Arch Linux! Также вы можете захотеть узнать о '''[[#Tweaks/Finishing touches|дополнительных настройках]]'''. Рекомендуется прочитать [[Post Installation Tips|советы]] после окончания установки и настройки.<br />
<br />
====Украшения====<br />
Вы можете захотеть поменять стандартную тему графического окружения. В данном случае, хорошим выбором будет тема "murrine".<br />
Установить можно следующей командой:<br />
pacman -S gtk-engine-murrine<br />
А затем выбрать данную тему в меню Система->Параметры->Внешний вид. Найти больше разнообразных тем оформления, наборов значков, фоновых изображений и т.п., вы можете на сайте [http://www.gnome-look.org Gnome Look].<br />
<br />
===KDE===<br />
====О KDE====<br />
'''K''' '''D'''esktop '''E'''nvironment. KDE - это мощное свободное окружение рабочего стола для рабочих станций GNU/Linux и <code>UNIX</code>. KDE сочетает лёгкость в использовании, современную функциональность и выдающийся графический дизайн с технологическим превосходством UNIX-подобных операционных систем.<br />
<br />
====Установка====<br />
Arch предлагает несколько вариантов kde: '''kde, kdebase, и KDEmod'''. Выберите '''один''' из представленных ниже, и продолжите дальше с '''[[#Useful KDE DAEMONS|Useful KDE DAEMONS]]''': <br />
<br />
'''1.)''' Пакет '''kde''' это полный, стандартнй KDE, ~300MB.<br />
pacman -S kde<br />
'''2.)''' Пакет '''kdebase''' это урезанная версия с меньшим количеством приложений, ~80MB.<br />
pacman -S kdebase<br />
'''3.)''' Наконец, '''KDEmod''' - это эксклюзив для Arch Linux, созданный по инициативе сообщества, которое модифицировало KDE для максимальной производительности и модульности. Веб-сайт проекта KDEmod может быть найден на [http://kdemod.ath.cx/ http://kdemod.ath.cx/]. KDEmod очень быстрый, легкий и гибкий, с приятной, собственной темой оформления<br />
<br />
====Useful KDE DAEMONS====<br />
<br />
KDE will require the '''hal''' ('''H'''ardware '''A'''bstraction '''L'''ayer) and '''fam''' ('''F'''ile '''A'''lteration '''M'''onitor) daemons. The '''kdm''' daemon is the '''K''' '''D'''isplay '''M'''anager, which provides a '''graphical login''', if desired.<br />
<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system.. Both '''hal''' and '''fam''' make life easier for the KDE user. The hal, fam and kdm packages are installed when you install KDE, but must be invoked to become useful.<br />
-----<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup. If you prefer a graphical login, add '''kdm''' as well: <br />
DAEMONS=(syslog-ng network crond alsa '''hal fam kdm''')<br />
*This method will start the system at runlevel 3, (/etc/inittab default, multiuser mode), and then start KDM as a daemon. <br />
<br />
*Some users prefer an alternative method of starting a display manager like KDM on bootup by utilizing the /etc/inittab method and starting the system at runlevel 5. See [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]] for more.<br />
<br />
*If you prefer to log into the '''console''' at runlevel 3, and manually start X in the 'Slackware tradition', leave out kdm, or comment it out with an exclamation. ( ! )<br />
<br />
Now try starting your X Server as normal user:<br />
startx<br />
Advanced instructions for installing and configuring KDE can be found in the [[KDE]] article.<br />
<br />
Congratulations! Welcome to your KDE desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===Xfce===<br />
====About Xfce====<br />
The cholesterol-free '''X''' environment. Xfce, like GNOME or KDE, is a desktop environment, but aims to be fast and lightweight while remaining visually appealing and easy to use. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit (like GNOME) and contains its own development environment (libraries, daemons, etc) similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and extremely fast. Xfce is great for older hardware, and will fly with especially great speed on newer machines as well.<br />
<br />
====Installation====<br />
Install Xfce: <br />
pacman -S xfce4 <br />
You may also wish to install themes and extras:<br />
pacman -S xfce4-goodies gtk2-themes-collection<br />
If you want to admire 'Tips and Tricks' on login, you must install the '''fortune-mod''' package:<br />
pacman -S fortune-mod <br />
====Useful DAEMONS====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. The hal and fam packages are installed when you install Xfce, but must be invoked to become useful.<br />
<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup.<br />
<br />
Advanced instructions for installing and configuring Xfce can be found in the [[Xfce]] article.<br />
<br />
If you wish to install one, see [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]]<br />
<br />
Congratulations! Welcome to your Xfce desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===*box===<br />
====Fluxbox====<br />
Fluxbox © is yet another windowmanager for X.<br />
It's based on the Blackbox 0.61.1 code. Fluxbox looks like blackbox and handles styles, colors, window placement and similar things exactly like blackbox (100% theme/style compability).<br />
<br />
Install Fluxbox using <br />
pacman -S fluxbox fluxconf<br />
<br />
If you use gdm/kdm a new fluxbox session will be automatically added. Otherwise, you should modify your user's .xinitrc and add this to it:<br />
exec startfluxbox <br />
<br />
More information is available in the [[Fluxbox]] article.<br />
<br />
====Openbox====<br />
Openbox is a standards compliant, fast, light-weight, extensible window manager.<br />
<br />
Openbox works with your applications, and makes your desktop easier to manage. This is because the approach to its development was the opposite of what seems to be the general case for window managers. Openbox was written first to comply with standards and to work properly. Only when that was in place did the team turn to the visual interface.<br />
<br />
Openbox is fully functional as a stand-alone working environment, or can be used as a drop-in replacement for the default window manager in the GNOME or KDE desktop environments. <br />
<br />
Install openbox using<br />
pacman -S openbox obconf obmenu<br />
<br />
Once openbox is installed you will get a message to move menu.xml & rc.xml to ~/.config/openbox/ in your home directory:<br />
<br />
mkdir -p ~/.config/openbox/<br />
cp /etc/xdg/openbox/rc.xml ~/.config/openbox/<br />
cp /etc/xdg/openbox/menu.xml ~/.config/openbox/<br />
<br />
In the file "rc.xml" you can change various settings for Openbox (or you can use OBconf). In "menu.xml" you can change your right-click menu.<br />
<br />
To be able to log into openbox you can either go via graphical login using KDM/GDM or startx, in which case you will need to edit your ~/.xinitrc (as user) and add the following:<br />
<br />
exec openbox<br />
You may also start openbox from the shell using '''xinit''':<br />
xinit /usr/bin/openbox-session<br />
* Openbox may also be used as the window manager for GNOME, KDE, and Xfce.<br />
For KDM there is nothing left to do; openbox is listed in the sessions menu in KDM.<br />
<br />
Useful programs for openbox are:<br />
* PyPanel or LXpanel if you want a panel<br />
* feh if you want to set the background<br />
* ROX if you want a simple file manager and desktop icons<br />
<br />
More information is available in the [[Openbox]] article.<br />
<br />
===fvwm2===<br />
FVWM is an extremely powerful ICCCM-compliant multiple virtual desktop window manager for the X Window system. Development is active, and support is excellent. <br />
<br />
Install fvwm2 with<br />
pacman -S fvwm <br />
<br />
fvwm will automatically be listed in kdm/gdm in the sessions menu. Otherwise, add <br />
exec fvwm <br />
<br />
to your user's .xinitrc.<br />
<br />
Note that this stable version of fvwm is a few years old. If you want a more recent version of fvwm, there is a fvwm-devel package in the unstable repo.<br />
<br />
=APPENDIX=<br />
==Tweaks/Finishing touches==<br />
===Install [http://archlinux.fr/yaourt-en# Yaourt]===<br />
'''Y'''et '''A'''n'''O'''ther '''U'''ser '''R'''epository '''T'''ool. Yaourt is a community-contributed wrapper for pacman which adds seamless access to the [[AUR]], allowing and automating package compilation and installation from your choice of the 8000+ PKGBUILDs in the [[AUR]], in addition to the many thousands of available Arch binary packages. Yaourt uses the same exact syntax as pacman, which saves you from relearning an entirely new method of system maintenance, but also adds new options. Yaourt expands the power and simplicity of pacman by adding even more useful features and provides pleasing, colorized output, interactive search mode, and much more. You will almost certainly want this. <br />
<br />
The easiest way to install Yaourt is to add the yaourt repository to your /etc/pacman.conf:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/i686<br />
for i686 or:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/x86_64<br />
for x86-64.<br />
<br />
Sync and install:<br />
pacman -Sy yaourt<br />
<br />
If you wish, you may then create your own command aliases in ~/.bashrc to save typing: <br />
nano ~/.bashrc<br />
<br />
alias p="pacman"<br />
alias y="yaourt" <br />
Save and then source:<br />
source ~/.bashrc<br />
See the [http://archlinux.fr/yaourt-en# yaourt] man page for more.<br />
<br />
===HAL===<br />
Since you have now installed a desktop environment, and if you did not do so earlier, now would be a good time to also install HAL. HAL allows plug-and-play for your mobile phone, your iPod, your external HD's, etc. It will mount the device and make a nice visual icon on your desktop and/or in 'My Computer', allowing you to access the device after you have plugged it in instead of having to manually configure the /etc/fstab file or udev rules for each and every new device.<br />
<br />
KDE, GNOME and XFCE all use HAL.<br />
<br />
The installation procedure is described in the [[HAL]] article. Some information can also be found at [http://en.wikipedia.org/wiki/HAL_(software) Wikipedia].<br />
<br />
===Backgrounding DAEMONS on startup===<br />
<br />
To speed up system start up procedure, background selected DAEMONS in /etc/rc.conf by prefixing them with a '@' e.g.:<br />
<br />
DAEMONS=(syslog-ng @network crond @alsa @hal @fam @kdm)<br />
This will enable daemons to load in the background, without waiting for the preceding daemon to load first.<br />
<br />
Prefix any daemons which you do not need with a bang (!) e.g.:<br />
<br />
DAEMONS=(syslog-ng @network !netfs !crond @alsa @hal @fam @kdm)<br />
<br />
Alternatively, you may also simply remove unneeded daemons.<br />
<br />
===Beautifying Fonts for LCD's===<br />
See [[Fonts]]<br />
<br />
===Adjusting Mouse for scroll wheel===<br />
While your mouse should be working out of the box, you may want to use your scroll wheel. Add this to your Input Section (mouse0):<br />
Option "ZAxisMapping" "4 5 6 7"<br />
<br />
===Get All Mouse Buttons Working===<br />
See [[Get All Mouse Buttons Working]]<br />
<br />
===Configuring Touchpad for Laptops===<br />
See [[Touchpad Synaptics]]<br />
<br />
===Adjusting Keyboard Layout===<br />
You may want to change your keyboard layout. To do this edit your /etc/X11/xorg.conf and add these lines in the InputDevice Section (Keyboard0) (the example shows a German keyboard layout with no dead keys; alter this to fit your needs).<br />
Option "XkbLayout" "de"<br />
Option "XkbVariant" "nodeadkeys"<br />
<br />
===Additional tweaks for laptops===<br />
ACPI support is needed if you want to use some special functions on your notebook (e.g. sleep, sleep when lid is closed, special keys...). Install <tt>acpid</tt> using<br />
pacman -S acpid<br />
and add it to the daemons in /etc/rc.conf. <tt>acpid</tt> should be started before <tt>hal</tt> and <tt>dbus</tt>, so take care to place it before any calls to hal and dbus. Manually, it can be started by<br />
/etc/rc.d/acpid start<br />
<br />
More-specific information about Arch Linux on various Laptops can be found at [[:Category:Laptops (English)]]<br />
<br />
===Configuring CPU frequency scaling===<br />
Modern processors can decrease their frequency and voltage to reduce heat and power consumption. Less heat leads to a quieter system; Laptop users will definitely want this, but even a desktop system will benefit from it. Install cpufrequtils with<br />
pacman -S cpufrequtils<br />
Edit the config file /etc/conf.d/cpufreq and change <br />
governor="ondemand"<br />
which dynamically increases the CPU frequency if needed (which is a safe choice on desktop systems too). Alter min_freq and max_freq to match your system's CPU spec. If you don't know the frequencies, run ''cpufreq-info'' after loading one of the frequency scaling modules. You can also comment out or delete the min_freq and max_freq lines: things will work automatically. Add the frequency scaling modules to your /etc/rc.conf modules line. Most modern notebooks and desktops can simply use the ''acpi-cpufreq'' driver, however other options include the ''p4-clockmod, powernow-k6, powernow-k7, powernow-k8, and speedstep-centrino'' drivers. Load the module with<br />
modprobe <modulname> <br />
and start cpufreq with<br />
/etc/rc.d/cpufreq start<br />
For more details, see [[Cpufrequtils]]<br />
<br />
===Pm-Utils===<br />
The pm-utils package will allow you to suspend-to-RAM and hibernate: <br />
pacman -S pm-utils<br />
[[Pm-utils]] wiki page.<br />
<br />
===Laptop-Mode===<br />
The laptop-mode-tools package is sort of a one-stop configuration for all laptop power management utilities. It works in conjunction with other installed tools to fully configure everything from hard disk spin-down to X display DPMS standby times, if desired.<br />
pacman -S laptop-mode-tools<br />
Add laptop-mode to your DAEMONS= line in /etc/rc.conf and configure /etc/laptop-mode/laptop-mode.conf.<br />
<br />
==File and directory explanation==<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, (as dictated by BIOS) just like the sda, sdb, etc.<br />
names in /dev. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 corresponding to the first entity. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding. <br />
<br />
{{ Box Note | The first appearance of 'root (hdx,x)' may be misleading. The '''root''' command is specifying '''''GRUB''''''s root, which corresponds to ''where the kernel resides, i.e. '''/boot'''''. Ensure that the drive and partition are correct, since '''''/boot''', does not necessarily share the same partition as the root filesystem, or /''.}}<br />
<br />
Once you have grasped the concept of device naming, choose a title for your boot section(s), create a kernel line that includes the partition and path to where the kernel resides, and supply the correct root filesystem device and partition as a parameter to the kernel root option to have it mounted as / on bootup, 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 to the initramfs on the initrd line will be the same as<br />
the path to vmlinuz26 that you provide on the kernel line, since both reside under /boot. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines.<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 />
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 also globally defines PS1, $PATH, bash aliases, etc. It is kept quite simple under Arch Linux, as most things are. You may wish 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 runlevels. 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 mounting filesystems, running udev, activating swap, loading modules, setting localization parameters, etc. You will most likely never need 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 started in single-user mode, for example with the kernel parameter 1 before booting or during normal multi-user operation with the command init 1, this script makes sure no daemons are running except for the bare minimum; syslog-ng and udev. The single-user mode is useful if you need to make any changes to the system while making sure that no remote user can do anything that might cause data loss or damage. <br />
For desktop users, this mode is usually quite useless. You should most likely have no need to edit this script.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the DAEMONS array (set in /etc/rc.conf) after which it calls /etc/rc.local. You shouldn't feel a pressing need to edit this file. <br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any last-minute commands you want the system to run at the very end of the bootup process. This is finally the one and only script you should modify if needed, and you have total freedom on what to add to this script. Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place where they belong. To avoid confusion, you should make sure that whatever you intend to add to your rc.local isn't feeling just as home in /etc/profile.d/ or any other already existant config location instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems, deactivates the swap, etc. <br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any commands you want to run right before the common rc.shutdown is executed. Please note that this file does not exist by default, and 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 rc.conf's DAEMONS= array. In addition to being called on bootup, you can use these scripts when the system is running to manage the services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. This directory is not in the $PATH by default, but may be added for convenience. Obviously a corresponding daemon script only exists when the appropriate package has been installed (in this case postfix). With a base system install, you don't have many scripts in here, but rest assured that all relevant daemon scripts end up here. If you wish, you can, of course, create your own scripts and place them here, to be called by the DAEMONS= array in /etc/rc.conf on system startup. <br />
<br />
This directory is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/ directories of other distributions, but without all the symlink hassle. The lack of symlink requirement is a defining difference of a *BSD-style init framework, vs a sysvinit.<br />
<br />
==Useful Applications==<br />
This section will never be complete. It just shows some good applications for the everyday user. <br />
<br />
'''KDE users NOTE''': Since KDE resides in /opt, you will most likely have to log out and in after initial installation to update your PATH before these programs can be used.<br />
===Internet===<br />
<br />
=====Firefox=====<br />
The ever-popular Firefox web browser is available through pacman, although it doesnt have its official branding, so the program appears when opened as Bon Echo. Install with:<br />
<br />
pacman -S firefox<br />
Be sure and install 'flashplugin', 'mplayer', 'mplayer-plugin', and the 'codecs' packages for a complete web experience:<br />
pacman -S flashplugin mplayer mplayer-plugin codecs<br />
(The codecs package contains codecs for Quicktime and Realplayer content.)<br />
<br />
Thunderbird is useful for managing your emails. If you are using GNOME you may want to take a look at Epiphany and Evolution; if you are using KDE Konqueror and KMail could be your choice. If you want something completely different you can still use Opera. Finally, if you are working on the system console - or in a terminal session - you could use various text-based browsers like ELinks, Links and Lynx, and manage your emails with [[Mutt]]. Pidgin (previously known as Gaim) and Kopete are good instant messengers for GNOME and KDE, respectively. PSI and Gajim are perfect if you are using only Jabber or Google Talk.<br />
<br />
===Office===<br />
OpenOffice is a complete office suite (similar to Microsoft Office). Abiword is a good, small alternative word processor, and Gnumeric an Excel replacement for the GNOME desktop. KOffice is a complete office suite for the KDE Desktop. GIMP (or GIMPShop) is a pixel-based graphics program (similar to Adobe Photoshop), while Inkscape is a vector-based graphics program (like Adobe Illustrator). And, of course, Arch comes with a full set of LaTeX Programs: tetex has been popular for many years and still works, and its successor [[Texlive]] is available from the [[AUR]] repository.<br />
<br />
==Multimedia ==<br />
<br />
<br />
===Video Player===<br />
====VLC====<br />
VLC Player is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S vlc<br />
<br />
(TODO) Instructions for VLC mozilla plug-in<br />
<br />
====Mplayer====<br />
MPlayer is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S mplayer<br />
<br />
It also has a Mozilla plug-in for videos and streams embedded in web pages. To install it, simply type the code below.<br />
<br />
pacman -S mplayer-plugin<br />
<br />
If you use KDE, KMplayer is a better choice. It comes with a plug-in for videos and streams embedded in web pages, which works with Konqueror. To install it, simply type the code below.<br />
<br />
pacman -S kmplayer<br />
<br />
(TODO) GMPlayer instructions<br />
<br />
====Xine====<br />
<br />
Xine is an excellent player, especially for DVDs.<br />
<br />
pacman -S xine-ui<br />
The libdvdcss library provides DVD decoding for encrypted DVDs. ''Ensure the legality of using libdvdcss in your country before installing!''<br />
pacman -S libdvdcss<br />
<br />
====GNOME====<br />
=====Totem=====<br />
[http://www.gnome.org/projects/totem/ Totem] is the official movie player of the GNOME desktop environment based on xine-lib or GStreamer (gstreamer is the default which installs with the arch totem package). It features a playlist, a full-screen mode, seek and volume controls, as well as keyboard navigation.<br />
It comes with added functionality such as:<br />
<br />
* Video thumbnailer for the file manager<br />
* Nautilus properties tab<br />
* Epiphany / Mozilla (Firefox) plugin to view movies inside your browser <br />
* Webcam utility (in development)<br />
<br />
Totem-xine is still the better choice if you want to watch DVDs.<br />
<br />
Totem is part of the gnome-extra group; the Totem webbrowser plugin isn't.<br />
<br />
To install separately:<br />
pacman -S totem<br />
<br />
To install the Totem webbrowser plugin:<br />
pacman -S totem-plugin<br />
<br />
====KDE====<br />
=====Kaffeine=====<br />
Kaffeine is a good option for KDE users. To install it, simply type the code below.<br />
<br />
pacman -S kaffeine<br />
<br />
===Audio Player===<br />
====Gnome/Xfce====<br />
=====Exaile=====<br />
[[Exaile]] is a music player written in Python that makes use of the GTK+ toolkit. It tries to be close to the popular Amarok, but in GTK. It is in [community], so install with:<br />
pacman -S exaile<br />
<br />
=====Rhythmbox=====<br />
[http://www.gnome.org/projects/rhythmbox/ Rhythmbox] is an integrated music management application, originally inspired by Apple's iTunes. It is free software, designed to work well under the GNOME Desktop, and based on the powerful GStreamer media framework.<br />
<br />
Rhythmbox has a number of features, including:<br />
<br />
* Easy-to-use music browser<br />
* Searching and sorting<br />
* Comprehensive audio format support through GStreamer<br />
* Internet radio support<br />
* Playlists<br />
<br />
To install rhythmbox:<br />
pacman -S rhythmbox<br />
<br />
=====Quod Libet=====<br />
[http://www.sacredchao.net/quodlibet Quod Libet] is a music manager that uses the GStreamer media framework to play audio files. This allows it to play all the file-types that Rhythmbox (which uses GStreamer too) can play. Quod Libet is more suited to non-Gnome desktops since it has a smaller footprint and fewer dependencies than Rhythmbox (Rhythmbox depends on nautilus, which requires a lot of GNOME to be installed).<br />
<br />
In addition to the music player/manager, Quod Libet also includes Ex Falso, a tag editor.<br />
<br />
Quod Libet's features include:<br />
<br />
* Easy-to-use music browser<br />
* Searching<br />
* Comprehensive audio format support through GStreamer<br />
* Easy Playlist management<br />
<br />
To install Quod Libet:<br />
pacman -S quodlibet<br />
<br />
Other good audio players are Banshee and Listen. See [http://gnomefiles.org/ Gnomefiles] to compare them.<br />
<br />
====KDE====<br />
=====Amarok=====<br />
[http://amarok.kde.org/ Amarok] is one of the best audio players and music library systems available for KDE. To install it, simply type the code below.<br />
<br />
pacman -S amarok-base<br />
<br />
====Console====<br />
[http://moc.daper.net/ Moc] is a ncurses-based audio player for the console; another good choice is [http://musicpd.org/ mpd].<br />
<br />
Another excellent choice is [http://freshmeat.net/projects/cmus/ cmus].<br />
<br />
====Other X-based====<br />
(TODO) Xmms, audacious, bmpx.<br />
<br />
===Codecs and other multimedia content types (i686 only) ===<br />
====DVD====<br />
You can use xine-ui, totem-xine, mplayer or kaffeine (just to name three of the big ones) to watch DVDs. The only thing you may miss is libdvdcss. Beware that using it may be illegal in some countries.<br />
<br />
====Flash====<br />
Install the flash plugin using<br />
pacman -S flashplugin<br />
to enable Macromedia (now Adobe) Flash in your browser, if you run KDE you should see this after installing flash. http://wiki.archlinux.org/index.php/Flash_and_Adobe_Acrobat_browser_plugins#Fixing_Flash_in_Konqueror<br />
<br />
====Quicktime====<br />
Quicktime codecs are contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them.<br />
====Realplayer====<br />
The codec for Realplayer 9 is contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them. Realplayer 10 is available as a binary package for Linux. You can get it from AUR [http://aur.archlinux.org/packages.php?do_Details=1&ID=1590&O=0&L=0&C=0&K=realplay&SB=&SO=&PP=25&do_MyPackages=0&do_Orphans=0&SeB=nd here].<br />
<br />
===CD and DVD Burning===<br />
====GNOME====<br />
=====Brasero=====<br />
[http://www.gnome.org/projects/brasero/ Brasero] is an application that burns CDs/DVDs for the GNOME Desktop. It is designed to be as simple as possible and has some unique features to enable users to create their discs easily and quickly.<br />
<br />
To install:<br />
pacman -S brasero<br />
<br />
====KDE====<br />
=====K3b=====<br />
K3b (from '''K'''DE '''B'''urn '''B'''aby '''B'''urn) is a free software CD and DVD authoring application for GNU/Linux and other <code>UNIX</code>-like operating systems designed for KDE. As is the case with most KDE applications, K3b is written in the C++ programming language and uses the Qt GUI toolkit. K3b provides a graphical user interface to perform most CD/DVD burning tasks like creating an Audio CD from a set of audio files or copying a CD/DVD, as well as more advanced tasks such as burning eMoviX CD/DVDs. It can also perform direct disc-to-disc copies. The program has many default settings which can be customized by more experienced users. The actual disc recording in K3b is done by the command line utilities cdrecord or wodim, cdrdao, and growisofs. As of version 1.0, K3b features a built-in DVD ripper.- licensed under the GPL.<br />
<br />
K3b was voted LinuxQuestions.org's Multimedia Utility of the Year (2006) by the majority (70%) of voters. <br />
-----<br />
To install:<br />
pacman -S k3b<br />
<br />
=====(Todo) cdrecord, graveman...=====<br />
<br />
<br />
<br />
<br />
Most CD burners are wrappers for cdrecord:<br />
<br />
pacman -S cdrkit<br />
<br />
If you install packages for CD/DVD burning applications like Brasero or K3B it also installs the CD/DVD burning library for it, like libburn or cdrkit.<br />
<br />
A good command-line DVD-burning tool is growisofs:<br />
<br />
pacman -S dvd+rw-tools<br />
<br />
===TV-Cards===<br />
<br />
There are several things to do if you want to watch TV under (Arch) Linux. The most important task is to find out which chip your tuner is using. However, quite a lot are supported. Be sure to check at a Hardware Database to be sure (see [http://en.opensuse.org/HCL/TV_Cards this list], for example). Once you know your Model, there are just a few steps ahead to get you going.<br />
<br />
In most cases, you will need to use the bttv-drivers (other drivers exist, like [http://linux.bytesex.org/v4l2/drivers.html V4L]) together with the I2C-modules. Configuring those is the hardest task. If you are lucky, a<br />
modprobe bttv<br />
will autodetect the card (check dmesg for results). In that case, you need only to install an application to watch TV. We will look at that later, though.<br />
If the autodetection did not work, you will need to check the file CARDLIST, which is included in the tarball of [http://dl.bytesex.org/releases/video4linux/ bttv] to find out the right parameters for your card. A PV951 without radio support would need this line:<br />
modprobe bttv card=42 radio=0<br />
Some cards need the following line to produce sound:<br />
modprobe tvaudio<br />
However, that varies. So just try it out. Some other cards demand the following line:<br />
modprobe tuner<br />
This is subject to trial-and-error, too.<br />
<br />
TODO: clarify the installation-procedure<br />
<br />
To actually watch TV, install the xawtv-package with<br />
pacman -S xawtv <br />
and read its manpage.<br />
<br />
TODO: clarify some possible problems and procedures. Introduction to XAWTV on another page?<br />
<br />
===Digital Cameras===<br />
Most newer digital cameras are supported as USB mass storage devices, which means that you can simply plug it in and copy the images. Older cameras may use the PTP (Picture Transfer Protocol) which requires a "special driver". gPhoto2 provides this driver and allows a shell-based transfer of the images; digikam (for KDE) and gthumb (for GNOME, gtkam would be another choice) use this driver and offer a nice GUI.<br />
<br />
===USB Memory Sticks / Hard Disks===<br />
USB Memory Sticks and hard disks are supported out of the box with the USB mass storage device driver and will appear as a new SCSI device (/dev/sdX). If you are using KDE or GNOME you should use dbus and hal (add them to your daemons in /etc/rc.conf), and they will be automatically mounted. If you use a different Desktop Environment you may have a look at ivman.<br />
<br />
==Maintaining the system==<br />
===Pacman===<br />
[[Pacman]] is both a binary and source package manager which is able to download, install, and upgrade packages from both remote and local repositories with full dependency handling, and has easy-to-understand tools for crafting your own packages too.<br />
<br />
A more-detailed description of Pacman can be found in [[Pacman|its article]].<br />
<br />
====Useful commands====<br />
To view the options available for a particular operational command, say '''-Q''', just append it with '''-h''':<br />
pacman -Qh<br />
<br />
To synchronize and update the local packages database with the remote repositories (it is a good idea to do this before installing and upgrading packages):<br />
pacman -Sy<br />
<br />
To '''upgrade''' all packages on the system:<br />
pacman -Su<br />
<br />
To sync, update, and '''upgrade''' all the packages on the system with one command:<br />
pacman -Syu<br />
<br />
To install or upgrade a single package or list of packages (including dependencies):<br />
pacman -S packageA packageB<br />
<br />
You can also sync, update the package database, and install packages in one command:<br />
pacman -Sy packageA packageB<br />
<br />
To remove a single package, leaving all of its dependencies installed:<br />
pacman -R package<br />
<br />
To remove a package and all of the package's dependencies which aren't used by any other installed package:<br />
pacman -Rs package<br />
('''-Rs''' is typically preferred vs '''R''' to remove any package as it will clean up all unused dependencies)<br />
<br />
To remove all of the package's now unneeded dependencies and also instruct pacman to ignore file backup designations. (Normally, when a file is removed from the system the database is checked to see if the file should be renamed with a ".pacsave" extension.):<br />
pacman -Rsn package<br />
<br />
To search the remote (repo) package database for a list of packages matching a given keyword:<br />
pacman -Ss keyword<br />
<br />
To list all packages on your system<br />
pacman -Q<br />
<br />
To list all packages on your system without the version strings, we add the '''-q''' option:<br />
pacman -Qq<br />
<br />
To search (query) the local (your machine) package database for a given package:<br />
pacman -Q package <br />
<br />
To search (query) the local (your machine) package database for a given package and list all pertinent information:<br />
pacman -Qi package<br />
<br />
To list all files installed by a given ''package'':<br />
<tt>pacman -Ql ''package''</tt><br />
Conversely, to find the package that owns a given file (in this example, the ''ls'' executable):<br />
<tt>pacman -Qo /bin/ls</tt><br />
To find all unused packages (orphans):<br />
pacman -Qdt<br />
Missing libraries: Suppose you receive an error message like this:<br />
<tt>mplayer: error while loading shared libraries: ''libgssapi.so.2'': cannot open shared object file: No such file or directory</tt><br />
This may be an indication that a package you have previously installed is now corrupt (some or all of its files are missing). You should try to find the package name that provides the missing shared library. In this example, you could type:<br />
<tt>pacman -Ql | grep ''libgssapi.so.2''</tt><br />
The first column in the output is the package name:<br />
<tt>heimdal /usr/lib/libgssapi.so.2<br />
heimdal /usr/lib/libgssapi.so.2.0.0<br />
</tt><br />
Then, you can just re-install it:<br />
<tt>pacman -Sy heimdal</tt><br />
<br />
To defragment pacman's cache database and optimize for speed:<br />
pacman-optimize<br />
<br />
To count how many packages are currently on your system:<br />
pacman -Q | wc -l<br />
<br />
To install a package compiled from source using ABS and makepkg:<br />
pacman -U packagename.pkg.tar.gz<br />
<br />
Note: There are countless additional pacman functions and commands. Try man pacman and consult the [[pacman]] wiki entries.<br />
<br />
====Files====<br />
There are a number of files left and created by pacman and other programs to facilitate maintenance and to conform to a safe computing practice. When pacman is installing something, the package contains information on whether to back up a particular file. Such files will have the '''.pacsave''' extension. When you force a "NoUpgrade" on a file via [http://www.archlinux.org/pacman/pacman.conf.5.html pacman.conf], it will not be replaced during an upgrade and the new file will come with the '''.pacnew''' extension. For example, you have edited a configuration file thoroughly and you do not want an upgrade of the respective package to replace the file with a new one, we must have the following line in '''/etc/pacman.conf''':<br />
NoUpgrade = /path/to/config/file<br />
To view the differences of the old and new versions of these files, we can either edit them manually or use a '''diff''' utility to take note of the differences. There is an automated tool to find and view such files available from the '''community''' repository:<br />
pacman -S pacman-contrib<br />
cd ~/<br />
pacdiff # as root<br />
There is a bug in the above tool where if you navigate to '''/etc''' and run it from there, the paths will be messed up. We remain on the safer side by being at "home". You may want to run it as user first in case you happen to be a careless person (you may just overwrite or remove files because you ''think'' that is the right way).<br><br />
<br />
There are other types of leftovers depending on the programs available on your system. Some will create backups with a '''.bak''' extension, while others with something like "'''~'''" or "'''-'''". Unfortunately, there is currently no way to "automatically" find and review them. Fear not, as we have no need for automated tools to deal with such trivial tasks. Simply use '''locate''' to search for them:<br />
locate -e *.~ *.- *.bak<br />
And we can use something useful like '''vimdiff''' to look at the differences manually:<br />
pacman -S vim<br />
vimdiff file1 file2<br />
<br />
==Прочая информация==<br />
За дополнительной инфорацией обращайтесь к [http://archlinux.org.ru/ Русскоязычному сообществу Arch], а также [http://archlinux.org.ru/forum/ на русскоязычный фоум]. Также по любым вопросам обращайтесь на IRC-канал:<br />
Сервер: irc.freenode.org, канал #archlinux-ru, кодировка UTF-8.<br />
Опытные, добрые, отзывчивые админы всегда окажут вам полное содействие и помощь.<br />
=====FAQ=====<br />
Смотрите [[ЧаВо]]<br />
<br />
<br />
=====Что еще почитать?=====<br />
[http://www.cyber39.ru/os/linux/3716-linux_dlja_nachinajushhikh.html Linux для начинающих.]<br />
<br />
[http://www.cyber39.ru/2008/02/16/setevoe_administrirovanie_linux.html Сетевое администрирование Linux.]<br />
<br />
[http://www.cyber39.ru/2008/02/16/jadro_linux_3e_izd.html Ядро Linux.]<br />
<br />
[http://www.cyber39.ru/os/linux/1204-linux_polnoe_rukovodstvo.html Linux: Полное руководство.]<br />
<br />
[http://www.cyber39.ru/2008/02/13/operacionnaja_sistema_unix_nastolnyjj_spravochnik.html Операционная система UNIX. Настольный справочник.]<br />
<br />
[http://ru.wikibooks.org/wiki/Введение_в_администрирование_UNIX#.D0.92.D0.B2.D0.B5.D0.B4.D0.B5.D0.BD.D0.B8.D0.B5_.D0.B2_.D0.AE.D0.BD.D0.B8.D0.BA.D1.81 Введение в администрирование UNIX.]<br />
<br />
[http://www.cyber39.ru/os/linux/19037-linux_osnovnye_komandy_karmannyjj_spravochnik.html LINUX: Основные комманды. Карманный справочник.]<br />
<br />
[http://www.cyber39.ru/coding/cpp/16946-programmirovanie_na_c_v_linux.html Программирование на C в Linux.]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Beginners%27_guide_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=53078
Beginners' guide (Русский)
2008-11-10T14:24:08Z
<p>Cucullus: /* Всё, что вы хотели знать об установке Arch, но боялись спросить */</p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|Dansk_Begynderguide}}<br />
{{i18n_entry|简体中文|Beginners Guide 新手指南}}<br />
{{i18n_entry|Deutsch|Beginners Guide (Deutsch)}}<br />
{{i18n_entry|English|Beginners Guide}}<br />
{{i18n_entry|Español|Guía para Principiantes (Español)}}<br />
{{i18n_entry|Česky|Průvodce začátečníka (Česky)}}<br />
{{i18n_entry|Italiano|Beginners Guide (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Pradedančiųjų gidas (Lietuviškai)}}<br />
{{i18n_entry|Português Brasil|Guia do Iniciante(Português do Brasil)}}<br />
{{i18n_entry|Русский|Руководство для новичков}}<br />
{{i18n_links_end}}<br />
<br />
=====Всё, что вы хотели знать об установке Arch, но боялись спросить=====<br />
{{Box Note |'''По возможности, пользуйтесь английской версией этого документа, т.к. именно она обновляется в первую очередь, содержит все последние изменения и самую актуальную на данный момент информацию.'''}}<br />
Добро пожаловать. Этот документ проведёт вас через процесс установки и настройки [[ArchLinux|Arch Linux]]; простого, быстрого и лёгкого GNU/Linux дистрибутива, <code>UNIX</code>-подобной операционной системы. Это больше, чем установочное руководство; Arch Linux требует определённого уровня глубоких знаний о его конфигурации, а так же методологии системы GNU/Linux и по этой причине, на этом пути содержится много дополнительной пояснительной информации. Он направлен на новых пользователей Arch, но стремится выступать как сильная справочная и информационная база для всех. Хоть это руководство предназначено для того, чтобы показать как получить полностью сконфигурированную систему Arch Linux (графическое окружени рабочего стола, возможность просмотра DVD, использования Интернет, работа с электронной почтой и прослушивания музыки), невозможно показать (или даже предположить) все возможности и варианты. По замыслу авторов, это руководство должно сфокусироваться на крайне полезных шагах; возможно вы захотите получить глубокие знания используя [[Main Page|Arch Linux Wiki]] или [http://bbs.archlinux.org/ Arch Linux Forums]. Вы также можете быть заинтересованы в чтении статьи [[Путь Arch]], в которой изложены основные принципы дистрибутива Arch Linux.<br />
<br />
Так как Arch Linux и все <code>UNIX</code>-подобные операционные системы являются в своей основе 'модульными', статья логически разбита на три основных части:<br />
<br />
'''[[#Часть 1: Установка базовой системы|Часть 1: Установка базовой системы]]'''<br />
<br />
'''[[#Часть 2: Установка X и установка ALSA|Часть 2: Установка X и установка ALSA]]'''<br />
<br />
'''[[#Часть 3: Установка и настройка окружения рабочего стола|Часть 3: Установка и настройка окружения рабочего стола]]'''<br />
<br />
=====DON'T PANIC!=====<br />
Имейте в виду, что процедура установки Arch Linux может сильно отличаться от установки других GNU/Linux дистрибутивов и вы можете запутаться, особенно если вы новичок. Обычно, GNU/Linux дистрибутивы распространяются вместе с крупным набором софта на CD (или даже DVD), включающим стандартное Рабочее Окруженее(DE), стандартный набор программ и установок, автонастройщик оборудования и графический установщик, все что выбрано за вас. Для различия, система Arch Linux создаётся '''пользователем''', из установщика с псевдографикой и базовой системы в которой нет ничего кроме bash и простых консольных программ. Это — '''[[Путь Arch]].''' В отличие от большинства других дистрибутивов с жесткой структурой, здесь нет ни стандартного окружения, ни конфигурации сделанной за пользователя. По просту говоря, Arch ждет вашего вклада. Из командной строки, ''вы'' можете установить необходимые пакеты из репозитория используя [[pacman]] и ''вручную'' настроить вашу систему под ''свои'' потребности, до того как это сделает кто-то другой. Этот метод дает вам максимум гибкости, выбора и контроля за вашей системой. Потому что когда '''вы''' настраиваете систему, вы всегда знаете все "гайки и болты" вашей системы и вам знакомо то, что находится "под капотом". <br />
<br />
Arch Linux настраивается редактированием текстовых файлов. Из-за этого не требуются графические инструменты для настройки. <br />
Также запомните, что Arch Linux направлен на опытных пользователей GNU/Linux, на тех кто хочет минимального 'разделения' оборудования и софта, на тех пользователей, которые могут тратить своё время на чтение манов о своей системе.<br />
<br />
''Arch — это инструмент созданный пользователем.''<br />
<br />
=====[[Путь Arch]]=====<br />
<br />
'''''Принципы разработки Arch Linux направлены на сохранение [[Путь Arch|простоты]].'' '''<br />
<br />
Стоит учитывать, что 'простота' не означает 'легкость' или 'дружелюбие' в данном контексте. Но подразумевает 'отсутствие лишних сущностей, модификаций или надуманной сложности' и стремление к элегантному и минималистичному окружению.<br />
<br />
''"Простота подразумевается не с позиции конечного использования, а с технической точки зрения. Лучше стремиться к технической элегантности, нежели быть простым в использовании, но мусором с технической точки зрения." -Aaron Griffin''<br />
<br />
''"Значимая часть [моего метода] подразумевает простоту..Я всегда верил в то, что простой путь - правильный путь."'' - Bruce Lee<br />
<br />
Принцип "Бритвы Оккама": ''Entia non sunt multiplicanda praeter necessitatem'' или "Не следует множить сущности без необходимости." "Бритва" в данном случае означает отбрасывание, вырезание из предмета лишних усложнений и домыслов для того, чтобы добиться наиболее простого объяснения, метода или теории.<br />
<br />
{{Box Note |'''Для успешной установки и правильной настройки дистрибутива необходимо в точности выполнять приведенные инструкции. ''Пожалуйста'', читайте их внимательно.'''}}<br />
* Вы можете распечатать данную статью, она уместится примерно на 58 страницах, которые послужат полезным руководством использования Arch Linux.<br />
* ''Если вы хотите добавить что-то в данную инструкцию, пожалуйста, указывайте не только "Как" что-либо делать, но и "Зачем" именно может понадобиться это делать.''<br />
* Arch Wiki поможет вам разобраться с возникающими проблемами, ответы на которые сначала стоит поискать на [http://wiki.archlinux.org/index.php/Main_Page_(Русский) главной странице]. Также вам доступны каналы IRC и [http://bbs.archlinux.org/ форум].<br />
----<br />
Добро пожаловать в Arch Linux! Давайте приступим.<br />
<br />
==Часть 1: Установка базовой системы==<br />
===Скачайте самый последний установочный образ ===<br />
<br />
Вы можете получить самый последний образ Arch Linux'а [http://archlinux.org/download/ здесь.]<br />
<br />
*Core-iso и FTP-downloads включают в себя только самые необходимые пакеты для создания '''базовой системы Arch Linux'''. ''Нужно заметить что в Базовую Систему не включен GUI. Сюда главным образом входит GNU инструментарий, (компилятор, ассемблер, линковщик, библиотеки и немного полезных утилит) ядро Linux, и немного дополнительных библиотек и модулей.'' Остальное в Arch Linux, включая GUI, может быть установлено из консоли, ''пользователем'', используя менеджер пакетов - pacman для загрузки и установки i686/x86-64 бинарных пакетов. Процесс описывается в деталях ниже.<br />
<br />
Запишите образ системы на CD. <br />
{{Box Note| При записи не используйте скорость больше чем 8x - это рекомендованная скорость для надежной записи, также некоторые пользователи рекомендуют устанавливать очень низкую скорость '''''4x или 2x!''''' Если вам встретились неожиданные проблемы с установкой, попытайтесь записать образ с самой низкой скоростью поддерживаемой вашей системой.}}<br />
<br />
===Загрузка с Arch Linux CD===<br />
Вы должны следовать этим инструкциям, но также вы можете найти весьма полезное [[Руководство_по_установке|Официальное руководство по установке Arch Linux]]. <br />
Вставте CD в ваш CD-ROM и загрузитесь с CD. Если ваш компьютер по умолчанию загружается не с CD, вы можете исправить это <br />
изменив порядок загрузки в биосе (чтобы войти в биос используйте клавиши DEL, F1, F2, F11 или F12 при запуске компьютера (в зависимости от типа биоса)).<br />
<br />
Полезные опции загрузки:<br />
* '''ide-legacy''' если у вас возникают проблемы с IDE приводами<br />
* '''noapic acpi=off pci=routeirq nosmp''' если ваша система зависает при загрузке системы<br />
* '''acpi=nommconf''' если у вас возникают "задержки" после загрузки pci:mmconfig <br />
* '''memtest86+''' если вы хотите проверить вашу оперативную память на ошибки<br />
* '''lowmem''' полезно для старых компьютеров с ограниченным объёмом оперативной памяти<br />
<br />
Требования к памяти:<br />
* CORE ISO: lowmem-загрузка образа - 64 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* CORE ISO: обычная загрузка образа - 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* FTP ISO : 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
<br />
Выберите "Arch Linux Installation / Rescue System". Если вы нуждаетесь в изменениях опций загрузки, нажмите "e" для редактирования конфига загрузки.<br />
Система будет загружена и вам будет представлено сообщение приветствия с некоторыми пояснениями.<br />
<br />
===Вход в систему и изменение раскладки===<br />
Войдите в систему как 'root'. Если ваша клавиатура не имеет американскую раскладку, выполните в командной строке следующее:<br />
{{Box Note| Скорее всего, у вас клавиатура с "американской" раскладкой (если ваша клавиатура приобретена в России)}}<br />
loadkeys <ваша раскладка><br />
<br />
===Запуск установки===<br />
Введите<br />
/arch/setup <br />
чтобы начать установку Arch Linux. <br />
<br />
<br />
====Выбор источника установки====<br />
После экрана приветствия вам будет предложено выбрать источник установки. Выберите CD, если хотите использовать диск. Или выберите FTP, если хотите использовать образ из FTP. <br />
* В первом случае, переходите к чтению главы о [[#Подготовка жесткого диска|Подготовке жесткого диска]].<br />
* Во втором случае, вам будет предложено загрузить драйвер для сетевой карты вручную. Но, как правило, Udev автоматически вполне успешно определяет комплектующие - вы можете проверить это выполнив "ifconfig -a" из vc2. Для продолжения установки нажмите "OK".<br />
<br />
====FTP: Настройка Сети====<br />
Вам будут показаны доступные интерфейсы. Если нужный интерфейс присутствует в списке - значит он определился правильно. В обратном случае, вы можете попробовать определить его прямо из установщика или из другой виртуальной консоли (vc).<br />
<br />
Далее выберите нужный интерфейс и продолжайте установку.<br />
<br />
Затем вам будет предложено использовать DHCP для автоматического получения сетевых настроек. В случае отказа, вам будет предложено вручную ввести ваш статический IP-адрес, маску подсети, адрес шлюза и т.д. И, наконец, вы сможете пересмотреть проделанные настройки и удостовериться в их правильности.<br />
<br />
Переходите к чтению о [[#Подготовка жесткого диска|Подготовке жесткого диска]].<br />
<br />
====Подготовка жесткого диска====<br />
Выберите первый пункт меню - "Prepare Hard Drive". Вам будет предложено автоматически подготовить ваш жесткий диск к установке Arch Linux, либо вручную переразбить и подготовить разделы.<br />
* 1. Автоматическая подготовка<br />
Установщик сам разобъет ваш жесткий диск на следующие разделы:<br />
* Загрузочный раздел /boot c файловой системой ext2 и размером по умолчанию в 32 мегабайта. Вы сможете изменить это значение. <br />
* Раздел подкачки swap с размером по умолчанию в 256 мегабайтов. Вы также сможете изменить это значение.<br />
* Отдельные разделы для корня / и домашней директории пользователей /home. Размеры вы определяете сами. Также вам будет предоставлен выбор из файловых систем: ext2, ext3, reiserfs, xfs и jfs. Но следует учесть, что оба этих раздела должны быть отформатированы в одинаковой файловой системе.<br />
<br />
Не забывайте - автоматическая подготовка сотрет все данные на вашем жестком диске! Внимательно читайте предупреждение установщика.<br />
<br />
* 2. '''(Рекомендуется)''' Ручная подготовка<br />
<br />
Выберите из списка жесткий диск, на который будет произведена установка (/dev/sd''x'').<br />
<br />
''На этом этапе более опытные пользователи могут сразу перейти к главе о '''[[#Выбор Пакетов|выборе пакетов]]'''.''<br />
<br />
=====Информация о разбивке=====<br />
Разбивка жесткого диска заключается в создании отдельных зон (разделов) на жестком диске. Они будут выглядеть как отдельные диски со своими файловыми системами. Разделы подразделяются на "Главные" (Primary), "Расширенные" (Extended) и "Логические" (Logical).<br />
<br />
'''Главные''' разделы могут быть загрузочными и их количество ограничено четырьмя. Больше четырех главных разделов создать нельзя и нужно использовать '''Расширенные''' разделы, которые будут содержать '''Логические'''.<br />
<br />
Расширенные разделы не могут быть использованы сами по себе - они всего лишь "контейнеры" для логических. Жесткий диск может содержать только один расширенный раздел, который может быть разделен на логические.<br />
<br />
Во время разбивки диска можно заметить схему нумерации разделов. Главные получают названия sda1-3, расширенный раздел - sda4, а логические, соответственно, sda5, sda6 и т.д.<br />
<br />
=====Раздел Подкачки (swap)=====<br />
Данный раздел является чем-то вроде "виртуального ОЗУ". На нем хранятся данные, которые не умещаются, либо не подходят для хранения в оперативной памяти.<br />
<br />
Исторически сложилось, что размер раздела подкачки определяется по схеме 2ХОЗУ. То есть, двойной объем оперативной памяти. Затем, с развитием компьютерной техники, данное правило не всегда стало являться необходимым. На компьютере с 512 мегабайтами памяти правило 2Х все еще действует эффективно. Однако, на машинах с 1 гигабайтом памяти обычно наиболее эффективна схема 1ХОЗУ. Если размер вашего ОЗУ больше или равен 1 гигабайту, то можно вообще обойтись без раздела подкачки, однако это не рекомендуется. Мы создадим раздел размером в 1 гигабайт в нашем примере.<br />
<br />
{{Box Note|Если вы планируете использовать технологии suspend-to-disk или hibernate, то размер раздела подкачки, по меньшей мере, должен соответствовать размеру вашей оперативной памяти. Но рекомендуется задать размер хотя бы на 15% больший, чтобы учесть появление испорченных секторов на диске (bad sectors).}}<br />
=====Схема Разбивки=====<br />
Схема разбивки разделов довольно индивидуальна и во многом зависит от предпочтений и нужд конкретного пользователя. Но, как минимум, вам нужны два раздела: один для корня ( / ), второй для раздела подкачки (swap). Однако, вы можете захотеть иметь отдельные разделы для /boot (на нем обычно находится ядро Linux), /var и /home (пользовательская директория). Обычно иметь два раздела отдельно для корня ( / ) и отдельно для /home считается хорошей практикой и более удобным и безопасным решением.<br />
В нашем примере мы создадим три отдельных раздела: для корня, для /home и один раздел подкачки swap.<br />
<br />
=====cfdisk===== <br />
Итак, начнем с создания главного раздела, содержащего корневую файловую систему.<br />
<br />
Для создания нового раздела выберите пункт '''N'''ew, затем Primary. Далее задайте желаемый размер раздела (что-то между 4 и 12 гигабайт будет хорошим выбором). Выберите только что созданный раздел и сделайте его загрузочным, выбрав пункт '''B'''ootable.<br />
<br />
Также выберите пункт '''T'''ype и задайте значение '83 Linux'. Нашему разделу должно присвоиться имя sda1.<br />
<br />
Затем создадим раздел подкачки. Задайте размер между 512 мегабайт и 1 гигабайтом, выберите '''T'''ype - 82 (Linux swap / Solaris). Наш раздел должен быть теперь виден как sda2.<br />
<br />
Теперь еще один раздел для /home. Выберите главный раздел и установите желаемый размер в зависимости от того, что пользователи вашего компьютера будут хранить в своих персональных директориях. Также, как и для корня, задайте '''T'''ype - 83 Linux. Данный раздел появится как sda3.<br />
<br />
<br />
<br />
Вот как должна выглядеть наша таблица разделов (размеры могут отличаться):<br />
<br />
Name Flags Part Type FS Type [Label] Size (MB)<br />
-------------------------------------------------------------------------<br />
sda1 Boot Primary Linux (4096 - 8192)<br />
sda2 Primary Linux swap / Solaris (512 - 1024)<br />
sda3 Primary Linux (> 100 or remaining space)<br />
<br />
Выберите '''W'''rite и нажмите ''''yes''''. Или нажмите '''Q'''uit для выхода из программы разбивки.<br />
<br />
<br />
=====Мои IDE-диски выглядят как SCSI, почему?=====<br />
В последних версиях ядра Linux все диски (IDE, SATA, SCSI) именуются как sd''x''. Пусть это вас не волнует, это нормально.<br />
<br />
====Назначение точек монтирования====<br />
Во-первых, выберите нужный раздел под раздел подкачки (в нашем примере это sda3). Во-вторых, выберите раздел для монтирования корневой ФС (sda1 в нашем примере). Вам будет предложено выбрать желаемую файловую систему.<br />
<br />
=====Файловые системы=====<br />
<br />
Выбор файловой системы достаточно субъективен. Каждая из предложенных ФС имеет свои достоинства и недостатки, всё зависит целиком от ваших предпочтений. Далее мы кратко рассмотрим поддерживаемые ФС:<br />
<br />
1. '''[http://ru.wikipedia.org/wiki/Ext2 ext2]''' - старая и надежная файловая система для ОС GNU/Linux. Очень стабильна, но без поддержки журналирования - это значит, что в случае аппаратных сбоев или перепадов напряжения ваша информация может пострадать. Не слишком хороший выбор для корневого и /home разделов. Данная ФС может быть легко преобразована в ext3.<br />
<br />
2. '''[http://ru.wikipedia.org/wiki/Ext2 ext3]''' - наследница ext2, но с поддержкой журналирования. Она полностью совместима с ext2. Однако, по некоторым тестам немного медленнее, нежели остальные ФС. Тем не менее, очень стабильна и активно используется, поддерживается и разрабатывается сообществом GNU/Linux.<br />
<br />
3. '''[http://ru.wikipedia.org/wiki/ReiserFS ReiserFS]''' - высокопроизводительная файловая система, разработанная Гансом Райзером. Считается очень быстрой, особенно при операциях с файлами маленького размера, однако сравнительно медленно монтируется. Вполне готова к использованию и стабильна. Однако, не слишком активно разрабатывается на данный момент (все силы отданы Reiser4).<br />
<br />
4. '''[http://ru.wikipedia.org/wiki/ReiserFS JFS]''' - '''J'''ournaled '''F'''ile'''S'''ystem, файловая система от IBM. Использует наименьшее количество ресурсов центрального процессора, нежели остальные ФС. Очень быстра в монтировании и использовании. Однако, не так широко используется, как ext или ReiserFS.<br />
<br />
5. '''[http://ru.wikipedia.org/wiki/ReiserFS XFS]''' - журналируемая ФС, которая показывает наибольшую скорость при операциях с большими файлами. Хороший выбор для разделов с большим их количеством.<br />
<br />
Наиболее значимое отличие между ними - журналирование. Все, кроме ext2, его поддерживают, однако техника журналирования не у всех одинакова. Только ext3 поддерживает хранение в журнале данных и мета-данных (информация о директориях). Это значит, что только она в случае сбоя сможет восстановить полностью в точной мере ту информационную структуру, которая была до сбоя.<br />
<br />
Выберите и создайте ФС для корня. Далее вам будет предложено создать дополнительные разделы. В нашем примере, нам понадобится создать еще sda2. Выберите файловую систему и примонтируйте ее как /home. Нажмите Done и возвращайтесь в главное меню установщика.<br />
<br />
===Выбор пакетов===<br />
На данном этапе вам предстоит выбрать пакеты, которые будут установлены на вашу систему.<br />
* Установка из Core ISO: выберите подходящее устройство CD-ROM из списка.<br />
* Установка из FTP ISO: выберите FTP/HTTP-зеркало для получения пакетов.<br />
<br />
Процесс выбора пакетов разбит на две стадии: выбор категорий пакетов, а затем - выбор отдельных пакетов в этих категориях. С помощью клавиши пробела вы можете устанавливать и снимать выделение пакетов и категорий. Ниже приведен список категорий пакетов с объяснениями:<br />
<br />
* '''BASE:''' содержит только базовые, необходимые системные пакеты. Минимальный набор для базовой системы.<br />
*'''SUPPORT:''' здесь находятся дополнительные пакеты для работы с сетью и файловыми системами. Например, такие как gpm, fuse, dnsutils, ndiswrapper, ntfs-3g, драйвера для wi-fi адаптеров и т.п.<br />
*'''DEVEL:''' пакеты для сборки программ. То есть, GCC, autoconf, automake, make и т.п.<br />
*'''LIB:''' различные системные библиотеки - gmp, libelf, libevent и т.п.<br />
<br />
Нажмите OK и далее выберите опцию 'yes', когда вам будет предложено выбрать все пакеты по умолчанию ('Select all packages by default').<br />
<br />
Далее вам будет показан список пакетов в выбранных категориях. Для новичка будет лучшим выбором оставить всё как есть. Тогда как более опытные пользователи могут убрать ненужные им пакеты из данного списка.<br />
<br />
===Установка пакетов===<br />
Теперь выберите пункт 'Install Packages', чтобы начать установку пакетов. Вам будет предложено сохранить загруженные из источника установки пакеты в системном кэше. Это хороший выбор, который может очень вам помочь, если какой-либо новый установленный пакет будет работать не так, как надо. Тогда можно просто восстановить старую версию из кэша. Помните, что вы всегда можете очистить ваш кэш вручную при необходимости.<br />
Установщик произведет установку выбранных вами пакетов и ядра Arch Linux в вашу новую систему.<br />
<br />
*FTP ISO: менеджер пакетов [[Pacman_(Русский)|Pacman]] установит пакеты с сетевого зеркала (прогресс вы можете наблюдать на vc5, а чтобы вернуться назад к установщику - перейдите на vc1).<br />
*CORE ISO: пакеты будут установлены с оптического диска.<br />
<br />
===Configure The System===<br />
''Closely following and understanding these steps is of key importance to ensure a properly configured system.'' <br />
<br />
The installer will ask if you want to choose [[Hwdetect|hwdetect]] to gather information for your configuration. Beginners should choose 'yes'. <br />
<br />
Advanced users who are thoroughly familiar with their hardware, required modules, and who are able to manually configure /etc/rc.conf, /etc/mkinitcpio and /etc/fstab, etc. from scratch may wish to choose 'no'. (Needless to say, this option is very involved, beyond the scope of this guide, and therefore is not covered.)<br />
<br />
Next, you will be asked if you need support for booting from USB devices, FireWire devices, PCMCIA devices, NFS shares, software RAID arrays, LVM2 volumes, encrypted volumes, and DSDT support. Choose yes if you need it; in our example nothing is needed. <br />
<br />
Now you will be asked which text editor you want to use; choose [http://en.wikipedia.org/wiki/Nano_%28text_editor%29 nano] or [http://en.wikipedia.org/wiki/Vim_%28text_editor%29 vi/vim] (recommended). You will be presented with a menu including the most important configuration files for your system. If you want to look up the available options as stated in /etc/rc.conf just press Alt+F2 to get a shell, look it up, and switch back to the installer with Alt+F1. <br />
=====Why doesn't the installer handle this more automatically?=====<br />
Hiding the process of system configuration is in direct opposition to [[The Arch Way]]. While it is true that recent versions of the kernel and hardware probing tools offer excellent hardware support and autoconfiguration, Arch presents the user all pertinent configuration files during installation for the purpose of ''transparency''. By the time you have finished modifying these files to your specifications, you will have learned the simple method of manual Arch Linux system configuration and become more familiar with the base structure, leaving you better prepared to use your new installation productively.<br />
<br />
====='''/etc/rc.conf'''=====<br />
Arch Linux follows in the '''*BSD''' tradition of utilizing '''/etc/rc.conf''' as the principal location for system configuration. This one file contains a wide range of configuration information, principally used at system startup. As its name directly implies, it also contains settings for and invokes the /etc/rc* files, and is, of course, sourced ''by'' these files. /etc/rc.conf offers a simple, elegant method of streamlining system resource configuration by encompassing a wide range of control, readily accessible for the Arch user. <br />
* '''LOCALIZATION''' section<br />
** '''LOCALE'''=: This sets your system locale, which will be used by all i18n-aware applications and utilities. You can get a list of the available locales by running 'locale -a' from the command line. This setting's default is fine for US English users. <br />
** '''HARDWARECLOCK'''=: Specifies whether the hardware clock, which is synchronized on bootup and on shutdown, stores '''UTC''' time, or the '''localtime'''. UTC makes sense because it greatly simplifies changing timezones and daylight savings time. localtime is necessary if you dual boot with an operating system such as Windows, that only stores localtime to the hardware clock.<br />
** '''TIMEZONE'''=: Specify your TIMEZONE. (All available zones are under /usr/share/zoneinfo/).<br />
** '''KEYMAP'''=: The available keymaps are in /usr/share/kbd/keymaps. Please note that this setting is only valid for your TTYs, not any graphical window managers or X!<br />
** '''CONSOLEFONT'''=: Available console fonts reside under /usr/share/kbd/consolefonts/ if you must change. The default (blank) is safe.<br />
** '''CONSOLEMAP'''=: Defines the console map to load with the setfont program on bootup. Possible maps are found in /usr/share/kbd/consoletrans, if needed. The default (blank) is safe. <br />
** '''USECOLOR'''=: Select "yes" if you have a color monitor and wish to have colors in your consoles.<br />
<br />
LOCALE="en_US.utf8"<br />
HARDWARECLOCK="localtime"<br />
TIMEZONE="US/Eastern"<br />
KEYMAP="us"<br />
CONSOLEFONT=<br />
CONSOLEMAP=<br />
USECOLOR="yes"<br />
* '''HARDWARE''' section<br />
** '''MOD_AUTOLOAD'''=: Setting this to "yes" will utilize '''udev''' to automatically probe hardware and load the appropriate modules during boot-up, (convenient with the default modular kernel). Setting this to "no" will rely on the user's ability to specify this information manually, or compile their own custom kernel and modules, etc. <br />
** '''MOD_BLACKLIST'''=: This has become deprecated in favor of adding blacklisted modules directly to the '''MODULES=''' line below. <br />
** '''MODULES'''=: Specify additional MODULES if you know that an important module is missing, ('''hwdetect''' should have filled in the most important modules). Also specify any blacklisted modules by prefixing them with a bang (!). Udev will be forced NOT to load blacklisted modules. In the example, the IPv6 module as well as the annoying pcspeaker are blacklisted. <br />
# Scan hardware and load required modules at bootup<br />
MOD_AUTOLOAD="yes"<br />
# Module Blacklist - Deprecated<br />
MOD_BLACKLIST=()<br />
#<br />
MODULES=(e100 eepro100 mii slhc snd-ac97-codec snd-intel8x0 soundcore !net-pf-10 !pcspkr)<br />
* '''NETWORKING''' section<br />
** '''HOSTNAME'''=:Set your HOSTNAME to your liking.<br />
** '''eth0'''=: 'Ethernet, card 0'. Adjust the interface IP address, netmask and broadcast address ''if'' you are using '''static IP'''. Set eth0="dhcp" if you want to use '''DHCP'''<br />
** '''INTERFACES'''=: Specify any/all interfaces here. If you do not use DHCP to configure a device, just keep in mind that the value of the variable (whose name must be equal to the name of the device which is supposed to be configured) equals the line which would be appended to the ifconfig command if you were to configure the device manually in the shell.<br />
** '''gateway'''=: If you are using '''static IP''', set the gateway address. Ignore this entry if using '''DHCP'''<br />
** '''ROUTES'''=: If you are using static '''IP''', remove the '''!''' in front of 'gateway'. Leave the '''!''' if using '''DHCP'''<br />
<br />
Example, using '''DHCP''':<br />
HOSTNAME="arch"<br />
#eth0="eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255" <br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
gateway="default gw 192.168.0.1"<br />
ROUTES=(!gateway)<br />
* '''DAEMONS''' section<br />
This array simply lists the names of those scripts contained in /etc/rc.d/ which are to be started during the boot process, and the order in which they start. <br />
DAEMONS=(@network syslog-ng netfs crond)<br />
*If a script name is prefixed with a bang (!), it is not executed. <br />
*If a script is prefixed with an "at" symbol (@), then it will be executed in the background; the startup sequence will not wait for successful completion of each daemon before continuing to the next. (Useful for speeding up system boot).<br />
*Edit this array whenever new system services are installed, if starting them automatically during bootup is desired. <br />
<br />
This 'BSD-style' init, is the Arch way of handling what others handle with various symlinks to an /etc/init.d directory.<br />
<br />
=====About DAEMONS=====<br />
You don't have to change the [[daemons]] line at this time, but it is useful to explain what daemons are, because we need them later in this guide. <br />
<br />
Analogous to a Windows service, a ''daemon'' is a program that runs in the background, waiting for events to occur and offering services. A good example is a webserver that waits for a request to deliver a page or an SSH server waiting for someone trying to log in. While these are full-featured applications, there are daemons whose work is not that visible. Examples are a daemon which writes messages into a log file (e.g. syslog, metalog), a daemon which lowers your CPU's frequency if your system has nothing to do (e.g.:cpufreq), and a daemon which offers you a graphical login (e.g.: gdm, kdm). All these programs can be added to the daemons line and will be started when the system boots. Useful daemons will be presented during this guide.<br />
<br />
Historically, the term ''daemon'' was coined by the programmers of MIT's Project MAC. They took the name from ''Maxwell's demon'', an imaginary being from a famous thought experiment that constantly works in the background, sorting molecules. <code>UNIX</code> systems inherited this terminology and created the backronym '''d'''isk '''a'''nd '''e'''xecution '''mon'''itor. <br />
<br />
*'''''Tip: All Arch daemons reside under /etc/rc.d/'''''<br />
<br />
=====/etc/fstab=====<br />
The '''fstab''' (for '''f'''ile '''s'''ystems '''tab'''le) is part of the system configuration listing all available disks and disk partitions, and indicating how they are to be initialized or otherwise integrated into the overall system's file system. The '''/etc/fstab''' file is most commonly used by the '''mount''' command, which reads /etc/fstab to determine which options should be used when mounting the specified device.<br />
<br />
<br />
An example '''/etc/fstab''':<br />
<br />
#<br />
# /etc/fstab: static file system information<br />
#<br />
# <file system> <dir> <type> <options> <dump> <pass><br />
none /dev/pts devpts defaults 0 0<br />
none /dev/shm tmpfs defaults 0 0<br />
#/dev/cdrom /mnt/cdrom iso9660 ro,user,noauto,unhide 0 0<br />
#/dev/dvd /mnt/dvd udf ro,user,noauto,unhide 0 0<br />
#/dev/fd0 /mnt/fd0 vfat user,noauto 0 0<br />
/dev/disk/by-uuid/0ec-9339 / jfs defaults,noatime,nodiratime 0 1<br />
/dev/disk/by-uuid/7ef-223-0 /home jfs defaults,noatime,nodiratime 0 2<br />
/dev/disk/by-uuid/530-1e-2c2 swap swap defaults 0 0<br />
<br />
Modify your '''fstab''' to your requirements.<br />
{{Box Note | As of 2008-04rc, Arch is now utilizing the UUID, or Universally Unique Identifier naming convention, for consistent device mapping. This is due to active developments in the kernel and also udev, which may randomly change the ordering in which drivers for storage controllers are loaded, yielding an unbootable system/kernel panic. Nearly every motherboard has several controllers (onboard SATA, onboard IDE), and due to the aforementioned development updates, /dev/sda may become /dev/sdb on the next reboot- hence the persistent device naming convention of UUID has been adopted for reliability.}}<br />
ls -lF /dev/disk/by-uuid/<br />
Will list all partitions by uuid.<br />
<br />
*If you plan on using '''hal''' to automount media such as DVDs, you may wish to comment out the cdrom and dvd entries in preparation for '''hal''', which will be installed later in this guide.<br />
<br />
{{Box Note | '''''The 'noatime' and 'nodiratime' options may safely be appended to / and /home regardless of your specified filesystem type for increased speed, performance, and power efficiency, for laptops as well as desktops.'''''}}<br />
<br />
Expanded information available in the [[Fstab]] wiki entry.<br />
<br />
====='''/etc/mkinitcpio.conf and /etc/modprobe.conf'''=====<br />
We shouldn't need to edit these configurations at this point. <br />
<br />
* '''mkinitcpio.conf''' This file allows you to fine-tune the initial ram filesystem (also commonly referred to as the initial ramdisk or "initrd") for your system. The initrd is a gzipped image that is read by the kernel during bootup. The purpose of the initrd is to bootstrap the system to the point where it can access the root filesystem. This means it has to load any modules that are required for devices like IDE, SCSI, or SATA drives (or USB/FW, if you are booting off a USB/FW drive). Once the initrd loads the proper modules, either manually or through udev, it passes control to the Arch system and your bootup continues. For this reason, the initrd only needs to contain the modules necessary to access the root filesystem. It does not need to contain every module you would ever want to use. The majority of your everyday modules will be loaded later on by udev, during the init process.<br />
<br />
* '''modprobe.conf''' can be used to set special configuration options for the kernel modules <br />
<br />
=====/etc/resolv.conf (for Static IP)=====<br />
The ''resolver'' is a set of routines in the C library that provide access to the Internet Domain Name System (DNS). One of the main functions of DNS is to translate domain names into IP addresses, to make the Web a friendlier place. The resolver configuration file, or /etc/resolv.conf, contains information that is read by the resolver routines the first time they are invoked by a process.<br />
<br />
*''If you are using DHCP, you may safely ignore this file, as by default, it will be dynamically created and destroyed by the dhcpcd daemon. You may change this default behavior if you wish. (See [[Network]]).''<br />
<br />
If you use a static IP, set your DNS servers in /etc/resolv.conf (nameserver <ip-address>). You may have as many as you wish, e.g.:<br />
nameserver 4.2.2.1<br />
nameserver 4.2.2.2<br />
<br />
If you are using a router, you will probably want to specify your DNS servers in the router itself, and merely point to it from your '''/etc/resolv.conf''', using your router's IP (which is also your gateway from '''/etc/rc.conf'''), e.g.:<br />
nameserver 192.168.1.1<br />
<br />
If using '''DHCP''', you may also specify your DNS servers in the router, or allow automatic assignment from your ISP, if your ISP is so equipped.<br />
<br />
=====/etc/hosts=====<br />
<br />
This file associates IP addresses with hostnames and aliases, one line per IP address. For each host a single line should be present with the following information:<br />
<IP-address> <hostname> [aliases...]<br />
Add your ''hostname'', coinciding with the one specified in /etc/rc.conf, as an alias, so that it looks like this:<br />
127.0.0.1 localhost.localdomain localhost '''''yourhostname'''''<br />
{{Box Note |''This format, '''including the 'localhost' and your actual host name''', is required for program compatibility! Errors in this entry may cause poor network performance and/or certain programs to open very slowly, or not work at all. This is a very common error for beginners.''}}<br />
<br />
If you use a static IP, add another line using the syntax: <static-IP> <hostname.domainname.org> <hostname> e.g.:<br />
192.168.1.100 '''''yourhostname'''''.domain.org '''''yourhostname'''''<br />
<br />
*'''TIP''': For convenience, you may also use /etc/hosts aliases for hosts on your network, and/or on the Web, e.g.:<br />
64.233.169.103 www.google.com g<br />
192.168.1.90 media<br />
192.168.1.88 data<br />
The above example would allow you to access google simply by typing 'g' into your browser, and access to a media and data server on your network by name and without the need for typing out their respective IP addresses.<br />
<br />
=====/etc/hosts.deny and /etc/hosts.allow=====<br />
Modify these configurations according to your needs if you plan on using the [[SSH|ssh]] daemon. The default configuration will reject all incoming connections, not only ssh connections. Edit your '''/etc/hosts.allow '''file and add: <br />
sshd:all <br />
This will allow all incoming ssh connections.<br />
<br />
If you do not plan on using the [[SSH|ssh]] daemon, leave this file at the default, (empty), for added security.<br />
<br />
=====/etc/locale.gen=====<br />
<br />
The '''locale-gen''' command reads from '''/etc/locale.gen''' to generate specific locales. They can then be used by '''glibc''' and any other locale-aware program or library for rendering "peculiar" text, correctly displaying regional monetary values, time and date formats, alphabetic idiosyncrasies, and other locale-specific standards. The ability to setup a default locale is a great built-in privilege of using a <code>UNIX</code>-like operating system.<br />
<br />
By default /etc/locale.gen is an empty file with commented documentation. Once edited, the file won't get touched again. '''locale-gen''' runs on every '''glibc''' upgrade, generating all the locales specified in /etc/locale.gen.<br />
<br />
Choose the locale(s) you need (remove the # in front of the lines you want), e.g.:<br />
en_US ISO-8859-1<br />
en_US.UTF-8 <br />
<br />
The installer will now run the locale-gen script, which will generate the locales you specified. You may change your locale in the future by editing /etc/locale.gen and subsequently running 'locale-gen' as root.<br />
<br />
{{Box Note |'''''If you fail to choose your locale, this will lead to a "The current locale is invalid..." error. This is perhaps the most common mistake by new Arch users, and also leads to the most commonly asked questions on the forum.'''''}}<br />
<br />
=====Root password=====<br />
Finally, set a root password and make sure that you remember it later. Return to the main menu and continue with installing bootloader.<br />
<br />
=====Pacman-Mirror=====<br />
Choose a mirror repository for '''pacman'''. <br />
*''archlinux.org is throttled, limiting downloads to 50KB/s'' <br />
<br />
Return to the main menu.<br />
<br />
===Install Bootloader===<br />
Because we have no secondary operating system in our example, we will need a bootloader. [http://www.gnu.org/software/grub/ GNU GRUB] is the recommended bootloader. Alternatively, you may choose [http://lilo.go.dyndns.org/ LILO]. <br />
===GRUB===<br />
The provided '''GRUB''' configuration ('''/boot/grub/menu.lst''') should be sufficient. The only thing you may want to alter is the resolution of the console. Add<br />
a vga=<number> to the first kernel line. (A table of resolutions and the corresponding numbers is printed in the menu.lst.)<br />
<br />
Example: <br />
title Arch Linux (Main)<br />
root (hd0,0)<br />
kernel /boot/vmlinuz26 root=/dev/disk/by-uuid/0ec1-9339.. ro vga=773<br />
initrd /boot/kernel26.img<br />
Explanation:<br />
<br />
Line 1: '''title''': A printed menu selection. "Arch Linux (Main)" will be printed on the screen as a menu selection.<br />
<br />
Line 2: '''root''': GRUB's root; the drive and partition where the kernel (/boot) resides. '''NOT necesarily the root''' (/) file system, as they can reside on separate partitions. GRUB's numbering scheme starts at 0, and uses an hd''x,x'' format regardless of IDE or SATA, enclosed within parentheses. <br />
<br />
The example indicates that /boot is on the first partition of the first drive, or, (hd0,0).<br />
<br />
Line 3: '''kernel''': This line specifies:<br />
<br />
* The path and filename of the kernel '''''relative to GRUB's root''''' (within the partition containing the kernel). <br />
<br />
In the example, /boot is merely a directory residing on the same partition as / and '''vmlinuz26''' is the kernel filename; '''/boot/vmlinuz26'''. ''If /boot were on a separate partition, the path and filename would be simply '''/vmlinuz26''', being relative to '''GRUB''''s root.'' <br />
<br />
* The root= argument to the kernel statement specifies the partition containing the root (/) directory in the booted system, (more accurately, the partition containing '''/sbin/init'''), ''according to the UUID numbering scheme'' as of 2008-04rc, which uses the /dev/disk/by-uuid/xxxx-xxxx-xxxx format. <br />
<br />
* Kernel options. <br />
<br />
In our example, '''ro''' mounts the filesystem as read only during startup, and the '''"vga=773"''' argument will give a 1024x768 framebuffer with 256 color depth.<br />
<br />
Line 4: '''initrd''': (For Initial RAM disk) The path and filename of the initial RAM filesystem '''relative to GRUB''''s root (within the partition containing the kernel). Again, in the example, /boot is merely a directory residing on the same partition as / and '''kernel26.img''' is the initrd filename; '''/boot/kernel26.img'''. ''If /boot were on a separate partition, the path and filename would be simply '''/kernel26.img''', being relative to '''GRUB''''s root.'' <br />
<br />
Install the '''GRUB''' bootloader to the master boot record, (sda in our example).<br />
<br />
That's it; You have configured and installed your Arch Linux base system. Exit the install, eject the installer CD, and type the magic word:<br />
<br />
reboot<br />
<br />
Your new Arch Linux system will boot up and finish with a login prompt (you may want to change the boot order in your '''BIOS''' back to booting from hard disk).<br />
<br />
'''Congratulations, and welcome to your shiny, new Arch Linux base system!'''<br />
<br />
==The Base System ==<br />
Your new Arch Linux base system is now a functional GNU/Linux environment ready for customization. From here, you may build this elegant set of tools into whatever you wish or require for your purposes. <br />
<br />
Let's begin.<br />
<br />
Login with your root account. We will configure pacman and update the system as root, then add a normal user. <br />
{{Box Note |Virtual consoles 1-6 are available, as is the '''links''' command line web browser.}}<br />
<br />
===Configuring the network (if necessary)===<br />
*''This section will assist you in configuring most types of networks, if your network configuration is not working for you.''<br />
<br />
If you properly configured your system, you should have a working network. Try to ping www.google.com to verify this.<br />
ping -c 3 www.google.com<br />
<br />
''If you have successfully established a network connection, continue with '''[[#Update, Sync and Upgrade the system with pacman|Update, Sync and Upgrade the system with pacman]]'''.''<br />
<br />
If, after trying to ping www.google.com, you get an "unknown host" error, you may conclude that your network is not properly configured. You may choose to double-check the following files for integrity and proper settings:<br />
<br />
'''/etc/rc.conf''' # Specifically, check your HOSTNAME= and NETWORKING section for typos and errors.<br />
<br />
'''/etc/hosts''' # Double-check your format. (See above.)<br />
<br />
'''/etc/resolv.conf''' # If you are using a static IP. If you are using DHCP, this file will be dynamically created and destroyed by default, but can be changed to your preference. (See [[Network]].)<br />
<br />
Advanced instructions for configuring the network can be found in the [[Network]] article.<br />
<br />
====Wired LAN====<br />
<br />
Check your Ethernet with<br />
ifconfig -a<br />
All interfaces will be listed. You should see an entry for eth0, or perhaps eth1. If required, you can set a new static IP with<br />
ifconfig eth0 <ip address> netmask <netmask> up <br />
and the default gateway with<br />
route add default gw <ip address of the gateway><br />
Check to see if /etc/resolv.conf contains your DNS server and add it if it is missing. <br />
Check your network again with ping www.google.de. If everything is working now, adjust /etc/rc.conf as described above for static IP. If you have a DHCP server/router in your network try<br />
dhcpcd eth0<br />
If this is working, adjust /etc/rc.conf as described above, for dynamic IP.<br />
<br />
====Wireless LAN====<br />
Detailed setup guide: [[Wireless Setup]]<br />
<br />
====Analog Modem====<br />
To be able to use a Hayes-compatible, external, analog modem, you need to at least have the ppp package installed. Modify the file /etc/ppp/options to suit your needs and according to man pppd. You will need to define a chat script to supply your username and password to the ISP after the initial connection has been established. The manpages for pppd and chat have examples in them that should suffice to get a connection up and running if you're either experienced or stubborn enough. With udev, your serial ports usually are /dev/tts/0 and /dev/tts/1.<br />
Tip: Read [[Dialup without a dialer HOWTO]].<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt to install wvdial or a similar tool to ease the setup process considerably. In case you're using a so-called WinModem, which is basically a PCI plugin card working as an internal analog modem, you should indulge in the vast information found on the [http://www.linmodems.org/ LinModem] homepage.<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, meaning that you won't need to recompile your kernel unless you're about to use rather odd ISDN hardware. After physically installing your ISDN card in your machine or plugging in your USB ISDN-Box, you can try loading the modules with modprobe. Nearly all passive ISDN PCI cards are handled by the hisax module, which needs two parameters: type and protocol. You must set protocol to '1' if your country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3' if you're hooked to a so-called leased-line without D-channel, and '4' for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the kernel documentation, more specifically in the isdn subdirectory, and available online. The type parameter depends on your card; a list of all possible types can be found in the README.HiSax kernel documentation. Choose your card and load the module with the appropriate options like this:<br />
<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my ELSA Quickstep 1000PCI, being used in Germany with the EDSS1 protocol. You should find helpful debugging output in your /var/log/everything.log file, in which you should see your card being prepared for action. Please note that you will probably need to load some USB modules before you can work with an external USB ISDN Adapter.<br />
<br />
Once you have confirmed that your card works with certain settings, you can add the module options to your /etc/modprobe.conf:<br />
<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively, you can add only the options line here, and add hisax to your MODULES array in the rc.conf. It's your choice, really, but this example has the advantage that the module will not be loaded until it's really needed.<br />
<br />
That being done, you should have working, supported hardware. Now you need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl; it'll get you started. Further down in the manpage you will find explanations on how to create a configuration file that can be parsed by isdnctrl, as well as some helpful setup examples. Please note that you have to add your SPID to your MSN setting separated by a colon if you use US NI1.<br />
<br />
After you have configured your ISDN card with the isdnctrl utility, you should be able to dial into the machine you specified with the PHONE_OUT parameter, but fail the username and password authentication. To make this work add your username and password to /etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were configuring a normal analogous PPP link, depending on which protocol your ISP uses for authentication. If in doubt, put your data into both files.<br />
<br />
If you set up everything correctly, you should now be able to establish a dial-up connection with<br />
isdnctrl dial ippp0<br />
as root. If you have any problems, remember to check the logfiles!<br />
<br />
====DSL (PPPoE)====<br />
<br />
These instructions are relevant to you only if your PC itself is supposed to manage the connection to your ISP. You do not need to do anything but define a correct default gateway if you are using a separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to physically install the network card that is supposed to be connected to the DSL-Modem into your computer. After adding your newly installed network card to the modules.conf/modprobe.conf or the MODULES array, you should install the rp-pppoe package and run the pppoe-setup script to configure your connection. After you have entered all the data, you can connect and disconnect your line with<br />
<br />
/etc/rc.d/adsl start<br />
<br />
and<br />
<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward, but feel free to read the manpages for hints. If you want to automatically dial in on boot-up, add adsl to your DAEMONS array.<br />
<br />
==Update, Sync and Upgrade the system with [[pacman]]==<br />
Now we will update the system using [[pacman]]. <br />
<br />
=====What is pacman ?=====<br />
[[Pacman]] is the '''pac'''kage '''man'''ager of Arch Linux. Pacman is written in C and is fast, simple, and extremely powerful. It manages your entire package system and handles installation, removal, package downgrade (through cache), custom compiled package handling, automatic dependency resolution, remote and local searches and much more. Arch uses the .tar.gz package format, which further enhances pacman's speed; Gzipped tarballs, though slightly larger, are decompressed much faster than their Bzipped counterparts, and are therefore generally installed more expediently. <br />
<br />
We will use pacman to download software packages from remote repositories and install them onto your system.<br />
<br />
Pacman is the most important tool in your Arch Linux toolbox for building the base system into whatsoever you please.<br />
<br />
===Configuring pacman===<br />
<br />
=====Package Repositories and /etc/pacman.conf=====<br />
Arch currently offers the following repositories readily accessible through pacman:<br />
<br />
'''[core]'''<br />
<br />
The simple principle behind [core] is to provide only one of each necessary tool for a base Arch Linux system; The GNU toolchain, the Linux kernel, one editor, one command line browser, etc. (There are a few exceptions to this. For instance, both vi and nano are provided, allowing the user to choose one or both.) Developer maintained.<br />
<br />
*''The Core installation cd simply contains an installer script, and a snapshot of the core repository.''<br />
<br />
'''[extra]'''<br />
<br />
The [extra] repository contains all Arch packages that are not themselves necessary for a base Arch system, but contribute to a more full-featured environment. '''X''', KDE and GNOME, for instance, can be found here. Developer maintained.<br />
<br />
'''[unstable]'''<br />
<br />
The [unstable] repository contains experimental and unstable software, especially if the development version of a package has become popular for some reason. For example, perhaps the upstream stable version is hopelessly out of date, or the unstable version has some groundbreaking changes that a lot of users seem interested in, like experimental kernel drivers or -svn package versions. Developer maintained.<br />
<br />
{{Box Note |'''Contrary to popular belief, it is perfectly safe to enable the unstable repository, as there are no name collisions with [core], [community] or [extra]. Packages from [unstable] are only installed if you explicitly do so. If there is a conflict between an [Unstable] package and an installed package, pacman will warn you and resolve the conflict, if prompted, by removing the installed package.'''}}<br />
<br />
The [unstable] repository is currently not maintained for ''x86_64''.<br />
<br />
'''[testing]'''<br />
<br />
The [testing] repository contains packages that are candidates for the [core], [extra] or [unstable] repositories. New packages go into [testing] if:<br />
* they are expected to break something on update and need to be tested first<br />
* they require other packages to be rebuilt. In this case, all packages that need to be rebuilt are put into [testing] first and when all rebuilds are done, they are moved back to the other repositories. Developer maintained.<br />
<br />
[testing] is the only repository that can have name collisions with any of the other official repositories. If enabled, it has to be the first repo listed in your ''pacman.conf'' file.<br />
<br />
{{Box Note|'''''Be careful when enabling [testing]. Your system may break after you update with [testing] enabled. Only experienced users should use it.'''''}}<br />
<br />
'''[community]'''<br />
<br />
The [community] repository is maintained by the ''Trusted Users (TUs)'' and is part of the ''Arch User Repository ([[AUR]])''. It contains binary packages from the ''AUR'' that have enough votes and were adopted by a ''TU''. Like all repos listed above, [community] may be readily accessed by pacman.<br />
<br />
The '''[[AUR]]''' also contains the '''unsupported''' branch, which cannot be accessed directly by pacman*. [unsupported] contains more than 8 thousand PKGBUILD scripts for building packages from source, that may be unavailable through the other repos. <br />
<br />
<nowiki>*</nowiki>''The '''''[[#Install Yaourt| yaourt]]''''' tool, an extremely popular, community contributed wrapper for pacman, can seamlessly access the '''AUR'''.''<br />
<br />
'''/etc/pacman.conf'''<br />
<br />
pacman will attempt to read /etc/pacman.conf each time it is invoked. This configuration file is divided into sections, or repositories. Each section defines a package [[Official Repositories|repository]] that pacman can use when searching for packages. The exception to this is the options section, which defines global options.<br />
nano /etc/pacman.conf<br />
Example:<br />
[core]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[extra]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
#[unstable]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[community]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
Enable all desired repositories (remove the # in front of the 'Include =' and '[repository]' lines).<br />
<br />
<br />
*'''''When choosing repos, be sure to uncomment both the repository header lines in [brackets] as well as the 'Include =' lines. Failure to do so will result in the selected repository being omitted! This is a very common error.'' '''<br />
<br />
====/etc/pacman.d/mirrorlist====<br />
Faster mirrors will dramatically improve pacman performance, and your overall Arch Linux experience.<br />
<br />
Edit /etc/pacman.d/mirrorlist:<br />
nano /etc/pacman.d/mirrorlist<br />
Remove all mirrors which are not on your continent, or are extremely distant. (Using nano, you may use CTRL-K to cut each unneeded line.) <br />
<br />
Edit /etc/pacman.d/mirrorlist by placing the best mirror at the top of the list. (Recall that archlinux.org is throttled to 50KB/s). If using nano, you can cut a line with CTRL-K and paste with CTRL-U. <br />
<br />
After changing mirrors, issue the following command:<br />
pacman -Syy<br />
This will force pacman to resynchronize with the new repo. Issuing pacman -Syy ''whenever a mirror is changed'', is good practice and will avoid possible headaches.<br />
=====Ignoring packages=====<br />
When you execute the command "pacman -Syu", your entire system will be updated. It is possible that you want to prevent a package from being upgraded. An example could be the kernel (kernel26) or a package for which an upgrade may prove problematic for your system. In this case, you have two options; indicate the packages you want to skip in the pacman command line using the --ignore switch (do pacman -S --help for details) or permanently indicate the packages you want to skip in your /etc.pacman.conf file:<br />
<br />
IgnorePkg = kernel26<br />
The typical way to use Arch is to use pacman to install all packages unless there is no package available, in which case you can build your own package using [[ABS]]. Many user-contributed packages are available in the Arch User Repository. You are expected to keep your system up to date with pacman -Syu, rather than selectively upgrading packages. Use of '''IgnorePkg''' in /etc/pacman.conf is therefore discouraged, and should be used sparingly, if you know what you are doing.<br />
<br />
You may diverge from this typical usage as you wish; just be warned that there is a greater chance that things will not work as intended and that it could break your system. The majority of complaints happen when selective upgrading or unusual compilation is performed.<br />
<br />
=====Ignoring Configuration Files=====<br />
In the same vein, you can also "protect" your configuration/system files from being overwritten during "pacman -Su" using the following option in your /etc/pacman.conf<br />
<br />
NoUpgrade = etc/lilo.conf boot/grub/menu.lst<br />
<br />
==Update System==<br />
Update, sync, and '''upgrade''' your entire new system with:<br />
pacman -Syu<br />
pacman will now fetch the latest information about available packages and perform all available upgrades. (You may be prompted to upgrade pacman itself at this point. If so, say yes, and then reissue the pacman -Syu command when finished.) <br />
Reboot if a kernel upgrade has occurred. <br />
{{Box Note|'''''Occasionally, configuration changes may take place requiring user action during an update; read pacman's output for any pertinent information.'''''}}<br />
<br />
=====The beauty of the Arch rolling release model=====<br />
Keep in mind that Arch is a '''rolling release''' distribution. This means there is never a reason to reinstall or perform elaborate system rebuilds to upgrade to the newest version. Simply issuing '''pacman -Syu''' periodically keeps your entire system up-to-date and on the bleeding edge. At the end of this upgrade, your system is completely current. <br />
Reboot if a kernel upgrade has occurred.<br />
<br />
=====Get familiar with pacman=====<br />
Pacman is the Arch user's best friend. It is highly recommended to study and learn how to use the pacman tool. Try:<br />
man pacman<br />
Check out the bottom of this article, and look up the [[pacman]] wiki entries at your leisure.<br />
<br />
<br />
<br />
===Add a user and setup groups===<br />
You should not do your everyday work using the root account. It is more than poor practice; it is dangerous. Root is for administrative tasks. Instead, add a normal user account using:<br />
adduser<br />
While most default options are safe to use, you may want to add storage, audio, video, optical, and wheel to your additional groups- especially if you are planning on having a full-featured desktop environment. <br />
<br />
Groups and users thereof are defined in /etc/group. <br />
<br />
They include:<br />
<br />
*'''audio''' - for tasks involving sound card and related software<br />
<br />
*'''wheel''' - for using sudo<br />
<br />
*'''storage''' - for managing storage devices<br />
<br />
*'''video''' - for video tasks and 3d acceleration<br />
<br />
*'''optical''' - for managing tasks pertaining to the optical drive(s)<br />
<br />
*'''floppy''' - for access to a floppy if applicable<br />
<br />
*'''lp''' - for managing printing tasks<br />
<br />
See the [[Groups]] article to understand what groups you need to be a member of. <br />
<br />
Check the man pages for usermod and gpasswd for more information.<br />
=====Install and setup Sudo=====<br />
<br />
See [[Sudo]]<br />
<br />
==Part II: Install X and configure ALSA==<br />
<br />
<br />
===Configure the audio card with alsamixer===<br />
The Advanced Linux Sound Architecture (known by the acronym '''ALSA''') is a Linux kernel component intended to replace the original Open Sound System (OSS) for providing device drivers for sound cards. Besides the sound device drivers, '''ALSA''' also bundles a user space library for application developers who want to use driver features with a higher level API than direct interaction with the kernel drivers. <br />
-----<br />
{{Box Note|udev will automatically probe your hardware on boot-up, loading the corresponding module for your audio card. Your sound should already be working, but you can't hear anything because it is muted by default.}} <br />
The alsa-utils package contains alsamixer, which will allow us to configure the sound device from the console. (You may also run alsamixer from an '''X''' environment later.)<br />
<br />
Install the alsa-utils package:<br />
pacman -S alsa-utils<br />
Did you add your normal user to the audio group? If not, now would be a good time. As root do:<br />
gpasswd -a yourusername audio<br />
Log your normal user out and back in to ensure the audio group is loaded.<br />
<br />
As '''''normal, non-root''''' user, do: <br />
'''$''' alsamixer<br />
Unmute the Master and PCM channels by scrolling to them with cursor left/right and pressing '''M'''. Increase the volume levels with the cursor-up key. (70-90 Should be a safe range.) Leave alsamixer by pressing ESC. <br />
==== Sound Test ====<br />
Test your sound configuration as normal user using aplay:<br />
aplay /usr/share/sounds/alsa/Front_Center.wav<br />
You should hear a very eloquent woman say, "Front, center."<br />
<br />
Then run alsactl as root:<br />
alsactl store<br />
This will create '/etc/asound.state', saving the alsamixer settings. <br />
<br />
Also, add the alsa ''daemon'' to your DAEMONS section in /etc/rc.conf to automatically restore the mixer settings on boot-up.<br />
nano /etc/rc.conf<br />
DAEMONS=(syslog-ng network crond '''alsa''')<br />
''Note that the alsa daemon merely restores your volume mixer levels on boot up by reading /etc/asound.state. It is separate from the alsa audio library (and kernel level API).''<br />
<br />
Expanded information available in the [[ALSA]] wiki entry.<br />
<br />
===Installing and configuring X===<br />
The '''X''' Window System (commonly '''X11''', or just simply '''X''') is a networking and display protocol which provides windowing on bitmap displays. It provides the standard toolkit and protocol to build graphical user interfaces (GUIs) on <code>UNIX</code>-like operating systems.<br />
<br />
'''X''' provides the basic framework, or primitives, for building GUI environments: drawing and moving windows on the screen and interacting with a mouse and/or keyboard. '''X''' does not mandate the user interface — individual client programs handle this. <br />
<br />
'''X''' is so named because it was preceded by the '''W''' Window System, originally developed at Stanford University. <br />
-----<br />
<br />
{{Box Note| If you plan on using an '''open-source''' video driver, and need 3d acceleration, it is recommended to install the libgl library before installing Xorg:}}<br />
pacman -S libgl<br />
''(Proprietary video drivers provide their own gl library implementations.)''<br />
----- <br />
Now we will install the base Xorg packages using pacman. This is the first step in building a GUI.<br />
<br />
pacman -S xorg<br />
3d utilities such as glxgears are included in the '''mesa''' package:<br />
pacman -S mesa<br />
<br />
Now we have the base packages we need for running the '''X''' Server. You should add the driver for your graphics card now (e.g. xf86-video-<name>). The easiest way to configure X.org is by installing the correct driver packages first, and then generating /etc/X11/xorg.conf using an autoconfiguration script, like Xorg -configure.<br />
<br />
If you need a list of all '''open-source''' video drivers, do: <br />
pacman -Ss xf86-video | less<br />
You will need knowledge of which video chipset your machine has. If you don't know, do:<br />
lspci | grep VGA<br />
Here is a list of '''open source''' drivers, and corresponding video chipsets.<br />
*'''xf86-video-apm''' Alliance ProMotion video driver<br />
*'''xf86-video-ark''' ark video driver<br />
*'''xf86-video-ati''' ati video driver<br />
*'''xf86-video-chips''' Chips and Technologies video driver<br />
*'''xf86-video-cirrus''' Cirrus Logic video driver<br />
*'''xf86-video-dummy''' dummy video driver<br />
*'''xf86-video-fbdev''' framebuffer video driver<br />
*'''xf86-video-glint''' GLINT/Permedia video driver<br />
*'''xf86-video-i128''' Number 0 i128 video driver<br />
*'''xf86-video-i740''' Intel i740 video driver<br />
*'''xf86-video-i810''' Intel i810/i830/i9xx video drivers (deprecated - use -intel)<br />
*'''xf86-video-intel''' Newer Version of Intel i810/i830/i9xx video drivers<br />
*'''xf86-video-imstt''' Integrated Micro Solutions Twin Turbo vidoe driver<br />
*'''xf86-video-mga''' mga video driver (Matrox Graphics Adapter)<br />
*'''xf86-video-neomagic''' neomagic video driver<br />
*'''xf86-video-nv''' nvidia nv video driver<br />
*'''xf86-video-rendition''' Rendition video driver<br />
*'''xf86-video-s3''' S3 video driver<br />
*'''xf86-video-s3virge''' S3 Virge video driver<br />
*'''xf86-video-savage''' savage video driver<br />
*'''xf86-video-siliconmotion''' siliconmotion video driver<br />
*'''xf86-video-sis''' SiS video driver<br />
*'''xf86-video-sisusb''' SiS USB video driver<br />
*'''xf86-video-tdfx''' tdfx video driver<br />
*'''xf86-video-trident''' Trident video driver<br />
*'''xf86-video-tseng''' tseng video driver<br />
*'''xf86-video-unichrome''' Unichrome video drivers<br />
*'''xf86-video-v4l''' v4l video driver<br />
*'''xf86-video-vesa''' vesa video driver<br />
*'''xf86-video-vga''' VGA 16 color video driver<br />
*'''xf86-video-via''' via video driver<br />
*'''xf86-video-vmware ''' vmware video driver<br />
*'''xf86-video-voodoo ''' voodoo video driver<br />
<br />
* Note that the '''vesa''' driver is the most generic, and should work with almost any modern video chipset. If you cannot find a suitable driver for your video chipset, vesa '''should''' work.<br />
<br />
*If you have an NVIDIA or ATI video adapter, you may wish to install the proprietary NVIDIA or ATI drivers. '''Installing proprietary video drivers is covered [[#Using proprietary Graphics Driver (NVIDIA, ATI)|below]].'''<br />
<br />
Use pacman to install the appropriate video driver for your video card/onboard video. e.g.:<br />
pacman -S xf86-video-savage<br />
(for the Savage driver.)<br />
<br />
==Create /etc/X11/xorg.conf==<br />
=====What is /etc/X11/xorg.conf?=====<br />
/etc/X11/xorg.conf is the main configuration file for your '''X''' Window System, the foundation of your '''G'''raphical '''U'''ser '''I'''nterface. It is a plain text file ordered into sections and subsections. Important sections are ''Files, InputDevice, Module, Monitor, Modes, Screen, Device, and ServerLayout''. Sections can appear in any order and there may be more than one section of each kind, for example, if you have more than one monitor, or if your laptop has a trackpoint as well as a mouse. <br />
------<br />
By default, you will not have an Xorg config file, and with the newest versions of Xorg, you don't need one ''if'' the autodetection ''works satisfactorily'' and you don't need to turn on features such as aiglx and so on. <br />
<br />
''Most people will still find that they need to generate a config file, however.''<br />
<br />
<br />
Advanced users may wish to manually create their own xorg.conf file. You may also use the Xorg -configure script to make a basic config file. As root, do:<br />
Xorg -configure<br />
This will create a config file at /root/xorg.conf.new <br />
<br />
To test the server, run:<br />
X -config /root/xorg.conf.new<br />
'''X''' should start with the white hollow vector '''X''' in the center of the screen, which should respond to mouse, trackpoint or touchpad movement. Use CTRL-Alt-Backspace to exit '''X'''.<br />
<br />
Inspect your config file in case of errors:<br />
<br />
nano /root/xorg.conf.new<br />
<br />
Ensure the Xorg -configure script has correctly specified your video driver. e.g.:<br />
Section "Device"<br />
<br />
...<br />
<br />
Driver "savage"<br />
<br />
...<br />
<br />
EndSection<br />
<br />
Ensure there are horizontal sync and vertical refresh specs under section "Monitor". If not, add them:<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
VendorName "Monitor Vendor"<br />
ModelName "Monitor Model"<br />
HorizSync 30.0 - 130.0 # Safe for LCD's<br />
VertRefresh 50.0 - 100.0 # Safe for LCD's and most CRT's.<br />
EndSection<br />
(If you do not know these specs, consult your monitor's documentation.)<br />
<br />
Specify your default color depth under section "Screen":<br />
Section "Screen"<br />
Identifier "Screen0"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
(Typically, this will be set to 24 for true color.)<br />
<br />
Also add your desired Modes to your "Display" subsection, at least under the Depth 24 header, e.g.:<br />
SubSection "Display"<br />
Viewport 0 0<br />
Depth 24<br />
Modes "1024x768" "800x600" "640x480"<br />
Add the following section, if you wish to enable eye candy which requires the composite extension: <br />
Section "Extensions"<br />
Option "Composite" "Enable"<br />
EndSection<br />
Try your config again, after modifying:<br />
X -config /root/xorg.conf.new<br />
Ensure an '''X''' session opens, without errors, and move the generated config file to /etc/X11/:<br />
mv /root/xorg.conf.new /etc/X11/xorg.conf<br />
Detailed instructions in the [[Xorg]] article.<br />
<br />
====Alternative xorg.conf generation====<br />
If Xorg -configure is not generating a usable xorg.conf, you may alternatively use the hwd tool. Install with:<br />
pacman -S hwd<br />
And run with<br />
hwd -xa <br />
Lastly, you may choose xorgconfig, which will interactively prompt you for hardware information to create a basic xorg.conf:<br />
xorgconfig<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
===Using proprietary Graphics Driver (NVIDIA, ATI)===<br />
You may choose to use the proprietary video drivers from NVIDIA or ATI. <br />
====NVIDIA Graphic Cards====<br />
The NVIDIA proprietary drivers are generally considered to be of good quality, and offer 3D performance, whereas the open source '''nv''' driver offers only 2d support at this time. <br />
<br />
Before you configure your Graphics Card you will need to know which driver fits. Arch currently has 3 different driver packages that each match a certain subset of Cards: <br />
<br />
'''1. nvidia-71xx''' ''for very old Cards like TNT and TNT2''<br />
<br />
'''2. nvidia-96xx''' ''slightly newer cards up to the GF 4''<br />
<br />
'''3. nvidia''' ''newest GPUs after the GF 4''<br />
<br />
Consult the NVIDIA-Homepage to see which one is for you. The difference is only for the installation; Configuration works the same with every driver.<br />
<br />
Select and install the appropriate NVIDIA driver ''for your card'', e.g.: <br />
pacman -S nvidia-96xx<br />
<br />
The NVIDIA package has a utility for updating your existing /etc/X11/xorg.conf for use with the NVIDIA driver:<br />
nvidia-xconfig<br />
<br />
It also has several options which will further specify the contents and options of the xorg.conf file.<br />
For example,<br />
nvidia-xconfig --composite --add-argb-glx-visuals<br />
<br />
For more detailed information, see nvidia-xconfig(1).<br />
<br />
Some useful tweaking options in the device section are (beware that these may not work on your system):<br />
Option "RenderAccel" "true"<br />
Option "NoLogo" "true"<br />
Option "AGPFastWrite" "true"<br />
Option "EnablePageFlip" "true"<br />
Make sure all instances of DRI are commented out:<br />
# Load "dri"<br />
Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
Update kernel module dependencies:<br />
depmod -a<br />
<br />
Advanced instructions for nvidia configuration can be found in the [[NVIDIA]] article.<br />
<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
====ATI Graphic Cards====<br />
ATI owners have two options for drivers. If you are unsure which driver to use, please try the open-source one first. The open-source driver will suit most needs along with being generally less problematic.<br />
<br />
Install the '''proprietary''' ATI Driver with<br />
pacman -S catalyst<br />
Use the aticonfig tool to modify the xorg.conf.<br />
<br />
Install the '''open-source''' ATI Driver with<br />
pacman -S xf86-video-ati<br />
Currently, the performance of the open-source driver is not on par with that of the proprietary one. It also lacks TV-out, dual-link DVI support, and possibly other features. On the other hand, it supports Aiglx and has better dual-head support.<br />
{{Box Note| The latest proprietary driver does support [[AIGLX]] now. To use [[Compiz]] or [[Beryl]] add Option "AIGLX" "True" to Section ServerFlags and Option "Composite" "True" to Section Extensions.}}<br />
Advanced instructions for ATI configuration can be found in the [[ATI | ATI wiki]].<br />
<br />
===Simple baseline X test===<br />
<br />
At this point, you should have xorg installed, with a suitable video driver and an /etc/X11/xorg.conf configuration file. If you want to test your configuration quickly, to ensure your ability to start '''X''' from the command line before installing a complete desktop environment, you can do so by invoking '''xterm'''. Xterm is a very simple terminal emulator which runs in the '''X '''Server environment; it is installed as part of the base xorg packages.<br />
<br />
Prepare for the test by configuring a ~/.xinitrc:<br />
<br />
===== ~/.xinitrc =====<br />
This file dictates what '''X''' Window client is invoked with the '''startx''' and/or '''xinit''' command ''on a per-user basis''. (The '''startx''' script is merely a front end to the more versatile '''xinit''' command.) <br />
<br />
To determine the client to run, '''startx/xinit''' will first look for a .xinitrc file in the user's home directory. In the absence of file ~/.xinitrc, it defaults to the global xinitrc in the xinit library directory; /etc/X11/xinit/xinitrc, which defaults to using the TWM window manager. (Hence, if you invoke startx without a ~/.xinitrc file, a TWM session will start.)<br />
<br />
Switch to your '''''normal, non-root''''' user:<br />
su yourusername<br />
* /etc/skel/ contains files and directories to provide sane defaults for newly created user accounts. The name '''skel''' is derived from the word '''skeleton''', because the files it contains form the basic structure for users' home directories.<br />
Copy the sample xinitrc file from /etc/skel/ to your home directory: <br />
<br />
cp /etc/skel/.xinitrc ~/<br />
Edit the file: <br />
nano ~/.xinitrc<br />
and add:<br />
<br />
exec xterm<br />
<br />
So that it looks like this:<br />
<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
#<br />
exec xterm<br />
# exec wmaker<br />
# exec startkde<br />
# exec icewm<br />
# exec blackbox<br />
# exec fluxbox<br />
<br />
''Be sure to have only one uncommented '''exec''' line in your ~/.xinitrc at this time''. Below, we shall edit this file again to specify the appropriate desktop environment/window manager of your choice.<br />
<br />
Start '''X''' Server as '''normal, non-root''' user, with:<br />
<br />
startx<br />
or<br />
xinit<br />
You should have an '''xterm''' session open up. You can exit the '''X''' Server with Ctrl+Alt+Backspace, or by typing "exit". If you have problems starting '''X''', you can look for errors in the /var/log/Xorg.0.log file and on the console output of the console you started '''X''' from.<br />
<br />
If you prove a properly configured /etc/X11/xorg.conf by successfully running the test, you can be assured that your DE/WM of choice will work smoothly.<br />
<br />
Advanced instructions for Xorg configuration can be found in the [[Xorg]] article.<br />
<br />
==Part III: Installing and configuring a Desktop Environment ==<br />
While The '''X''' Window System provides the basic framework for building a ''graphical user interface'' (GUI), a '''Desktop Environment''' (DE), works atop and in conjunction with '''X''', to provide a completely functional and dynamic GUI. A DE typically provides icons, applets, windows, toolbars, folders, wallpapers, applications and abilities like drag and drop. The particular functionalities and designs of each DE will uniquely affect your overall environment and experience. Therefore, choosing a DE is a very subjective and personal decision. Choose the best environment for ''your'' needs.<br />
<br />
* If you want something full-featured and similar to Windows and Mac OSX, '''[[#KDE|KDE]]''' is a good choice<br />
* If you want something slightly more minimalist, which follows the K.I.S.S. principle more closely, '''[[#GNOME|GNOME]]''' is a good choice<br />
* '''[[#Xfce|Xfce]]''' is generally perceived as similar to GNOME, but lighter and less demanding on system resources, yet still visually pleasing and providing a very complete environment.<br />
<br />
If you have an older machine, or desire a lighter, less demanding GUI, you may choose to simply install a '''Window Manager''', or WM. A WM controls the placement and appearance of application windows in conjunction with the X Window System but does NOT provide such additions as panels, applets, icons, applications, etc.<br />
* Lightweight WM's include: '''Openbox, Fluxbox, fvwm2''', '''Windowmaker, Awesome and TWM'''.<br />
* If you need something completely different, try '''ion, wmii, dwm, or xmonad'''.<br />
<br />
===Install Fonts===<br />
At this point, you may want to install some good-looking fonts, '''before''' installing a desktop environment/window manager, (so you don't have to stare at ugly bitmap fonts in X). Dejavu and bitstream-vera are nice font sets. For websites, you may want to have the Microsoft fonts too. Install with:<br />
pacman -S ttf-ms-fonts ttf-dejavu ttf-bitstream-vera<br />
<br />
===~/.xinitrc (again)===<br />
<br />
As '''non-root user''', edit your /home/username/.xinitrc to utilize the DE you wish to use. This will allow you to use '''startx/xinit''' from the shell to open your DE/WM of choice:<br />
<br />
nano ~/.xinitrc<br />
<br />
Uncomment or add the ''''exec''' ..' line of the appropriate desktop environment/window manager. Some examples are below.<br />
<br />
For the Xfce4 desktop environment:<br />
exec startxfce4 <br />
<br />
For the KDE desktop environment:<br />
exec startkde<br />
A '''startkde''' or '''startxfce4''' command starts the KDE or Xfce4 desktop environment. This command does not finish until you logout of the DE. Normally the shell would wait for KDE to finish, then run the next command. The "exec" prefix to this command tells the shell that this is the last command, so the shell does not need to wait to run a subsequent command.<br />
<br />
Remember to have only one uncommented '''exec''' line in your ~/.xinitrc for now. <br />
<br />
Continue below, installing the DE/WM of your choice.<br />
<br />
===GNOME===<br />
====О проекте GNOME====<br />
'''G'''NU '''N'''etwork '''O'''bject '''M'''odel '''E'''nvironment. Проект GNOME сочетает в себе две вещи: интуитивно-понятное и приятное окружение рабочего стола, а также платформу для разработки, позволяющую создавать полностью интегрированные между собой и остальным окружением приложения.<br />
<br />
<br />
====Установка====<br />
Установить базовый набор пакетов GNOME можно следующей командой:<br />
pacman -S gnome<br />
<br />
Дополнительные пакеты (эмулятор терминала, текстовый редактор и т.д.) находятся в группе gnome-extra:<br />
pacman -S gnome-extra<br />
<br />
=====Полезные демоны для GNOME=====<br />
Демон - это исполняемая в фоне программа, которая дожидается определенных событий и обрабатывает их. Демон '''hal''', кроме всего прочего, автоматизирует монтирование жестких дисков, оптических приводов и флэш-накопителей. Демон '''fam''' обрабатывает изменения в структуре данных файловой системы, позволяя в реальном времени отслеживать изменения в файлах или директориях. Оба этих демона позволяют сильно упростить работу с окружением. Они устанавливаются при установке GNOME, но должны быть запущены для начала работы:<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
<br />
В качестве менеджера сессий хорошим выбором будет '''gdm'''.<br />
<br />
Установка:<br />
pacman -S gdm<br />
<br />
Для запуска этих демонов при загрузке, следует добавить их в секцию DAEMONS конфигурационного файла /etc/rc.conf :<br />
nano /etc/rc.conf<br />
<br />
DAEMONS=(syslog-ng network crond alsa '''hal fam gdm''')<br />
<br />
Чтобы запустить графическое окружение выполните:<br />
startx<br />
Если файл ~/.xinitrc не настроен для запуска GNOME, то окружение можно запустить командой xinit:<br />
xinit /usr/bin/gnome-session<br />
<br />
Дополнительные инструкции по установке и настройке могут быть найдены в статье [[GNOME_(Русский)|GNOME]].<br />
<br />
Поздравляем! Добро пожаловать в среду GNOME на вашей свежеустановленной системе Arch Linux! Также вы можете захотеть узнать о '''[[#Tweaks/Finishing touches|дополнительных настройках]]'''. Рекомендуется прочитать [[Post Installation Tips|советы]] после окончания установки и настройки.<br />
<br />
====Украшения====<br />
Вы можете захотеть поменять стандартную тему графического окружения. В данном случае, хорошим выбором будет тема "murrine".<br />
Установить можно следующей командой:<br />
pacman -S gtk-engine-murrine<br />
А затем выбрать данную тему в меню Система->Параметры->Внешний вид. Найти больше разнообразных тем оформления, наборов значков, фоновых изображений и т.п., вы можете на сайте [http://www.gnome-look.org Gnome Look].<br />
<br />
===KDE===<br />
====О KDE====<br />
'''K''' '''D'''esktop '''E'''nvironment. KDE - это мощное свободное окружение рабочего стола для рабочих станций GNU/Linux и <code>UNIX</code>. KDE сочетает лёгкость в использовании, современную функциональность и выдающийся графический дизайн с технологическим превосходством UNIX-подобных операционных систем.<br />
<br />
====Установка====<br />
Arch предлагает несколько вариантов kde: '''kde, kdebase, и KDEmod'''. Выберите '''один''' из представленных ниже, и продолжите дальше с '''[[#Useful KDE DAEMONS|Useful KDE DAEMONS]]''': <br />
<br />
'''1.)''' Пакет '''kde''' это полный, стандартнй KDE, ~300MB.<br />
pacman -S kde<br />
'''2.)''' Пакет '''kdebase''' это урезанная версия с меньшим количеством приложений, ~80MB.<br />
pacman -S kdebase<br />
'''3.)''' Наконец, '''KDEmod''' - это эксклюзив для Arch Linux, созданный по инициативе сообщества, которое модифицировало KDE для максимальной производительности и модульности. Веб-сайт проекта KDEmod может быть найден на [http://kdemod.ath.cx/ http://kdemod.ath.cx/]. KDEmod очень быстрый, легкий и гибкий, с приятной, собственной темой оформления<br />
<br />
====Useful KDE DAEMONS====<br />
<br />
KDE will require the '''hal''' ('''H'''ardware '''A'''bstraction '''L'''ayer) and '''fam''' ('''F'''ile '''A'''lteration '''M'''onitor) daemons. The '''kdm''' daemon is the '''K''' '''D'''isplay '''M'''anager, which provides a '''graphical login''', if desired.<br />
<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system.. Both '''hal''' and '''fam''' make life easier for the KDE user. The hal, fam and kdm packages are installed when you install KDE, but must be invoked to become useful.<br />
-----<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup. If you prefer a graphical login, add '''kdm''' as well: <br />
DAEMONS=(syslog-ng network crond alsa '''hal fam kdm''')<br />
*This method will start the system at runlevel 3, (/etc/inittab default, multiuser mode), and then start KDM as a daemon. <br />
<br />
*Some users prefer an alternative method of starting a display manager like KDM on bootup by utilizing the /etc/inittab method and starting the system at runlevel 5. See [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]] for more.<br />
<br />
*If you prefer to log into the '''console''' at runlevel 3, and manually start X in the 'Slackware tradition', leave out kdm, or comment it out with an exclamation. ( ! )<br />
<br />
Now try starting your X Server as normal user:<br />
startx<br />
Advanced instructions for installing and configuring KDE can be found in the [[KDE]] article.<br />
<br />
Congratulations! Welcome to your KDE desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===Xfce===<br />
====About Xfce====<br />
The cholesterol-free '''X''' environment. Xfce, like GNOME or KDE, is a desktop environment, but aims to be fast and lightweight while remaining visually appealing and easy to use. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit (like GNOME) and contains its own development environment (libraries, daemons, etc) similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and extremely fast. Xfce is great for older hardware, and will fly with especially great speed on newer machines as well.<br />
<br />
====Installation====<br />
Install Xfce: <br />
pacman -S xfce4 <br />
You may also wish to install themes and extras:<br />
pacman -S xfce4-goodies gtk2-themes-collection<br />
If you want to admire 'Tips and Tricks' on login, you must install the '''fortune-mod''' package:<br />
pacman -S fortune-mod <br />
====Useful DAEMONS====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. The hal and fam packages are installed when you install Xfce, but must be invoked to become useful.<br />
<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup.<br />
<br />
Advanced instructions for installing and configuring Xfce can be found in the [[Xfce]] article.<br />
<br />
If you wish to install one, see [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]]<br />
<br />
Congratulations! Welcome to your Xfce desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===*box===<br />
====Fluxbox====<br />
Fluxbox © is yet another windowmanager for X.<br />
It's based on the Blackbox 0.61.1 code. Fluxbox looks like blackbox and handles styles, colors, window placement and similar things exactly like blackbox (100% theme/style compability).<br />
<br />
Install Fluxbox using <br />
pacman -S fluxbox fluxconf<br />
<br />
If you use gdm/kdm a new fluxbox session will be automatically added. Otherwise, you should modify your user's .xinitrc and add this to it:<br />
exec startfluxbox <br />
<br />
More information is available in the [[Fluxbox]] article.<br />
<br />
====Openbox====<br />
Openbox is a standards compliant, fast, light-weight, extensible window manager.<br />
<br />
Openbox works with your applications, and makes your desktop easier to manage. This is because the approach to its development was the opposite of what seems to be the general case for window managers. Openbox was written first to comply with standards and to work properly. Only when that was in place did the team turn to the visual interface.<br />
<br />
Openbox is fully functional as a stand-alone working environment, or can be used as a drop-in replacement for the default window manager in the GNOME or KDE desktop environments. <br />
<br />
Install openbox using<br />
pacman -S openbox obconf obmenu<br />
<br />
Once openbox is installed you will get a message to move menu.xml & rc.xml to ~/.config/openbox/ in your home directory:<br />
<br />
mkdir -p ~/.config/openbox/<br />
cp /etc/xdg/openbox/rc.xml ~/.config/openbox/<br />
cp /etc/xdg/openbox/menu.xml ~/.config/openbox/<br />
<br />
In the file "rc.xml" you can change various settings for Openbox (or you can use OBconf). In "menu.xml" you can change your right-click menu.<br />
<br />
To be able to log into openbox you can either go via graphical login using KDM/GDM or startx, in which case you will need to edit your ~/.xinitrc (as user) and add the following:<br />
<br />
exec openbox<br />
You may also start openbox from the shell using '''xinit''':<br />
xinit /usr/bin/openbox-session<br />
* Openbox may also be used as the window manager for GNOME, KDE, and Xfce.<br />
For KDM there is nothing left to do; openbox is listed in the sessions menu in KDM.<br />
<br />
Useful programs for openbox are:<br />
* PyPanel or LXpanel if you want a panel<br />
* feh if you want to set the background<br />
* ROX if you want a simple file manager and desktop icons<br />
<br />
More information is available in the [[Openbox]] article.<br />
<br />
===fvwm2===<br />
FVWM is an extremely powerful ICCCM-compliant multiple virtual desktop window manager for the X Window system. Development is active, and support is excellent. <br />
<br />
Install fvwm2 with<br />
pacman -S fvwm <br />
<br />
fvwm will automatically be listed in kdm/gdm in the sessions menu. Otherwise, add <br />
exec fvwm <br />
<br />
to your user's .xinitrc.<br />
<br />
Note that this stable version of fvwm is a few years old. If you want a more recent version of fvwm, there is a fvwm-devel package in the unstable repo.<br />
<br />
=APPENDIX=<br />
==Tweaks/Finishing touches==<br />
===Install [http://archlinux.fr/yaourt-en# Yaourt]===<br />
'''Y'''et '''A'''n'''O'''ther '''U'''ser '''R'''epository '''T'''ool. Yaourt is a community-contributed wrapper for pacman which adds seamless access to the [[AUR]], allowing and automating package compilation and installation from your choice of the 8000+ PKGBUILDs in the [[AUR]], in addition to the many thousands of available Arch binary packages. Yaourt uses the same exact syntax as pacman, which saves you from relearning an entirely new method of system maintenance, but also adds new options. Yaourt expands the power and simplicity of pacman by adding even more useful features and provides pleasing, colorized output, interactive search mode, and much more. You will almost certainly want this. <br />
<br />
The easiest way to install Yaourt is to add the yaourt repository to your /etc/pacman.conf:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/i686<br />
for i686 or:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/x86_64<br />
for x86-64.<br />
<br />
Sync and install:<br />
pacman -Sy yaourt<br />
<br />
If you wish, you may then create your own command aliases in ~/.bashrc to save typing: <br />
nano ~/.bashrc<br />
<br />
alias p="pacman"<br />
alias y="yaourt" <br />
Save and then source:<br />
source ~/.bashrc<br />
See the [http://archlinux.fr/yaourt-en# yaourt] man page for more.<br />
<br />
===HAL===<br />
Since you have now installed a desktop environment, and if you did not do so earlier, now would be a good time to also install HAL. HAL allows plug-and-play for your mobile phone, your iPod, your external HD's, etc. It will mount the device and make a nice visual icon on your desktop and/or in 'My Computer', allowing you to access the device after you have plugged it in instead of having to manually configure the /etc/fstab file or udev rules for each and every new device.<br />
<br />
KDE, GNOME and XFCE all use HAL.<br />
<br />
The installation procedure is described in the [[HAL]] article. Some information can also be found at [http://en.wikipedia.org/wiki/HAL_(software) Wikipedia].<br />
<br />
===Backgrounding DAEMONS on startup===<br />
<br />
To speed up system start up procedure, background selected DAEMONS in /etc/rc.conf by prefixing them with a '@' e.g.:<br />
<br />
DAEMONS=(syslog-ng @network crond @alsa @hal @fam @kdm)<br />
This will enable daemons to load in the background, without waiting for the preceding daemon to load first.<br />
<br />
Prefix any daemons which you do not need with a bang (!) e.g.:<br />
<br />
DAEMONS=(syslog-ng @network !netfs !crond @alsa @hal @fam @kdm)<br />
<br />
Alternatively, you may also simply remove unneeded daemons.<br />
<br />
===Beautifying Fonts for LCD's===<br />
See [[Fonts]]<br />
<br />
===Adjusting Mouse for scroll wheel===<br />
While your mouse should be working out of the box, you may want to use your scroll wheel. Add this to your Input Section (mouse0):<br />
Option "ZAxisMapping" "4 5 6 7"<br />
<br />
===Get All Mouse Buttons Working===<br />
See [[Get All Mouse Buttons Working]]<br />
<br />
===Configuring Touchpad for Laptops===<br />
See [[Touchpad Synaptics]]<br />
<br />
===Adjusting Keyboard Layout===<br />
You may want to change your keyboard layout. To do this edit your /etc/X11/xorg.conf and add these lines in the InputDevice Section (Keyboard0) (the example shows a German keyboard layout with no dead keys; alter this to fit your needs).<br />
Option "XkbLayout" "de"<br />
Option "XkbVariant" "nodeadkeys"<br />
<br />
===Additional tweaks for laptops===<br />
ACPI support is needed if you want to use some special functions on your notebook (e.g. sleep, sleep when lid is closed, special keys...). Install <tt>acpid</tt> using<br />
pacman -S acpid<br />
and add it to the daemons in /etc/rc.conf. <tt>acpid</tt> should be started before <tt>hal</tt> and <tt>dbus</tt>, so take care to place it before any calls to hal and dbus. Manually, it can be started by<br />
/etc/rc.d/acpid start<br />
<br />
More-specific information about Arch Linux on various Laptops can be found at [[:Category:Laptops (English)]]<br />
<br />
===Configuring CPU frequency scaling===<br />
Modern processors can decrease their frequency and voltage to reduce heat and power consumption. Less heat leads to a quieter system; Laptop users will definitely want this, but even a desktop system will benefit from it. Install cpufrequtils with<br />
pacman -S cpufrequtils<br />
Edit the config file /etc/conf.d/cpufreq and change <br />
governor="ondemand"<br />
which dynamically increases the CPU frequency if needed (which is a safe choice on desktop systems too). Alter min_freq and max_freq to match your system's CPU spec. If you don't know the frequencies, run ''cpufreq-info'' after loading one of the frequency scaling modules. You can also comment out or delete the min_freq and max_freq lines: things will work automatically. Add the frequency scaling modules to your /etc/rc.conf modules line. Most modern notebooks and desktops can simply use the ''acpi-cpufreq'' driver, however other options include the ''p4-clockmod, powernow-k6, powernow-k7, powernow-k8, and speedstep-centrino'' drivers. Load the module with<br />
modprobe <modulname> <br />
and start cpufreq with<br />
/etc/rc.d/cpufreq start<br />
For more details, see [[Cpufrequtils]]<br />
<br />
===Pm-Utils===<br />
The pm-utils package will allow you to suspend-to-RAM and hibernate: <br />
pacman -S pm-utils<br />
[[Pm-utils]] wiki page.<br />
<br />
===Laptop-Mode===<br />
The laptop-mode-tools package is sort of a one-stop configuration for all laptop power management utilities. It works in conjunction with other installed tools to fully configure everything from hard disk spin-down to X display DPMS standby times, if desired.<br />
pacman -S laptop-mode-tools<br />
Add laptop-mode to your DAEMONS= line in /etc/rc.conf and configure /etc/laptop-mode/laptop-mode.conf.<br />
<br />
==File and directory explanation==<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, (as dictated by BIOS) just like the sda, sdb, etc.<br />
names in /dev. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 corresponding to the first entity. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding. <br />
<br />
{{ Box Note | The first appearance of 'root (hdx,x)' may be misleading. The '''root''' command is specifying '''''GRUB''''''s root, which corresponds to ''where the kernel resides, i.e. '''/boot'''''. Ensure that the drive and partition are correct, since '''''/boot''', does not necessarily share the same partition as the root filesystem, or /''.}}<br />
<br />
Once you have grasped the concept of device naming, choose a title for your boot section(s), create a kernel line that includes the partition and path to where the kernel resides, and supply the correct root filesystem device and partition as a parameter to the kernel root option to have it mounted as / on bootup, 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 to the initramfs on the initrd line will be the same as<br />
the path to vmlinuz26 that you provide on the kernel line, since both reside under /boot. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines.<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 />
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 also globally defines PS1, $PATH, bash aliases, etc. It is kept quite simple under Arch Linux, as most things are. You may wish 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 runlevels. 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 mounting filesystems, running udev, activating swap, loading modules, setting localization parameters, etc. You will most likely never need 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 started in single-user mode, for example with the kernel parameter 1 before booting or during normal multi-user operation with the command init 1, this script makes sure no daemons are running except for the bare minimum; syslog-ng and udev. The single-user mode is useful if you need to make any changes to the system while making sure that no remote user can do anything that might cause data loss or damage. <br />
For desktop users, this mode is usually quite useless. You should most likely have no need to edit this script.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the DAEMONS array (set in /etc/rc.conf) after which it calls /etc/rc.local. You shouldn't feel a pressing need to edit this file. <br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any last-minute commands you want the system to run at the very end of the bootup process. This is finally the one and only script you should modify if needed, and you have total freedom on what to add to this script. Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place where they belong. To avoid confusion, you should make sure that whatever you intend to add to your rc.local isn't feeling just as home in /etc/profile.d/ or any other already existant config location instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems, deactivates the swap, etc. <br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any commands you want to run right before the common rc.shutdown is executed. Please note that this file does not exist by default, and 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 rc.conf's DAEMONS= array. In addition to being called on bootup, you can use these scripts when the system is running to manage the services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. This directory is not in the $PATH by default, but may be added for convenience. Obviously a corresponding daemon script only exists when the appropriate package has been installed (in this case postfix). With a base system install, you don't have many scripts in here, but rest assured that all relevant daemon scripts end up here. If you wish, you can, of course, create your own scripts and place them here, to be called by the DAEMONS= array in /etc/rc.conf on system startup. <br />
<br />
This directory is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/ directories of other distributions, but without all the symlink hassle. The lack of symlink requirement is a defining difference of a *BSD-style init framework, vs a sysvinit.<br />
<br />
==Useful Applications==<br />
This section will never be complete. It just shows some good applications for the everyday user. <br />
<br />
'''KDE users NOTE''': Since KDE resides in /opt, you will most likely have to log out and in after initial installation to update your PATH before these programs can be used.<br />
===Internet===<br />
<br />
=====Firefox=====<br />
The ever-popular Firefox web browser is available through pacman, although it doesnt have its official branding, so the program appears when opened as Bon Echo. Install with:<br />
<br />
pacman -S firefox<br />
Be sure and install 'flashplugin', 'mplayer', 'mplayer-plugin', and the 'codecs' packages for a complete web experience:<br />
pacman -S flashplugin mplayer mplayer-plugin codecs<br />
(The codecs package contains codecs for Quicktime and Realplayer content.)<br />
<br />
Thunderbird is useful for managing your emails. If you are using GNOME you may want to take a look at Epiphany and Evolution; if you are using KDE Konqueror and KMail could be your choice. If you want something completely different you can still use Opera. Finally, if you are working on the system console - or in a terminal session - you could use various text-based browsers like ELinks, Links and Lynx, and manage your emails with [[Mutt]]. Pidgin (previously known as Gaim) and Kopete are good instant messengers for GNOME and KDE, respectively. PSI and Gajim are perfect if you are using only Jabber or Google Talk.<br />
<br />
===Office===<br />
OpenOffice is a complete office suite (similar to Microsoft Office). Abiword is a good, small alternative word processor, and Gnumeric an Excel replacement for the GNOME desktop. KOffice is a complete office suite for the KDE Desktop. GIMP (or GIMPShop) is a pixel-based graphics program (similar to Adobe Photoshop), while Inkscape is a vector-based graphics program (like Adobe Illustrator). And, of course, Arch comes with a full set of LaTeX Programs: tetex has been popular for many years and still works, and its successor [[Texlive]] is available from the [[AUR]] repository.<br />
<br />
==Multimedia ==<br />
<br />
<br />
===Video Player===<br />
====VLC====<br />
VLC Player is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S vlc<br />
<br />
(TODO) Instructions for VLC mozilla plug-in<br />
<br />
====Mplayer====<br />
MPlayer is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S mplayer<br />
<br />
It also has a Mozilla plug-in for videos and streams embedded in web pages. To install it, simply type the code below.<br />
<br />
pacman -S mplayer-plugin<br />
<br />
If you use KDE, KMplayer is a better choice. It comes with a plug-in for videos and streams embedded in web pages, which works with Konqueror. To install it, simply type the code below.<br />
<br />
pacman -S kmplayer<br />
<br />
(TODO) GMPlayer instructions<br />
<br />
====Xine====<br />
<br />
Xine is an excellent player, especially for DVDs.<br />
<br />
pacman -S xine-ui<br />
The libdvdcss library provides DVD decoding for encrypted DVDs. ''Ensure the legality of using libdvdcss in your country before installing!''<br />
pacman -S libdvdcss<br />
<br />
====GNOME====<br />
=====Totem=====<br />
[http://www.gnome.org/projects/totem/ Totem] is the official movie player of the GNOME desktop environment based on xine-lib or GStreamer (gstreamer is the default which installs with the arch totem package). It features a playlist, a full-screen mode, seek and volume controls, as well as keyboard navigation.<br />
It comes with added functionality such as:<br />
<br />
* Video thumbnailer for the file manager<br />
* Nautilus properties tab<br />
* Epiphany / Mozilla (Firefox) plugin to view movies inside your browser <br />
* Webcam utility (in development)<br />
<br />
Totem-xine is still the better choice if you want to watch DVDs.<br />
<br />
Totem is part of the gnome-extra group; the Totem webbrowser plugin isn't.<br />
<br />
To install separately:<br />
pacman -S totem<br />
<br />
To install the Totem webbrowser plugin:<br />
pacman -S totem-plugin<br />
<br />
====KDE====<br />
=====Kaffeine=====<br />
Kaffeine is a good option for KDE users. To install it, simply type the code below.<br />
<br />
pacman -S kaffeine<br />
<br />
===Audio Player===<br />
====Gnome/Xfce====<br />
=====Exaile=====<br />
[[Exaile]] is a music player written in Python that makes use of the GTK+ toolkit. It tries to be close to the popular Amarok, but in GTK. It is in [community], so install with:<br />
pacman -S exaile<br />
<br />
=====Rhythmbox=====<br />
[http://www.gnome.org/projects/rhythmbox/ Rhythmbox] is an integrated music management application, originally inspired by Apple's iTunes. It is free software, designed to work well under the GNOME Desktop, and based on the powerful GStreamer media framework.<br />
<br />
Rhythmbox has a number of features, including:<br />
<br />
* Easy-to-use music browser<br />
* Searching and sorting<br />
* Comprehensive audio format support through GStreamer<br />
* Internet radio support<br />
* Playlists<br />
<br />
To install rhythmbox:<br />
pacman -S rhythmbox<br />
<br />
=====Quod Libet=====<br />
[http://www.sacredchao.net/quodlibet Quod Libet] is a music manager that uses the GStreamer media framework to play audio files. This allows it to play all the file-types that Rhythmbox (which uses GStreamer too) can play. Quod Libet is more suited to non-Gnome desktops since it has a smaller footprint and fewer dependencies than Rhythmbox (Rhythmbox depends on nautilus, which requires a lot of GNOME to be installed).<br />
<br />
In addition to the music player/manager, Quod Libet also includes Ex Falso, a tag editor.<br />
<br />
Quod Libet's features include:<br />
<br />
* Easy-to-use music browser<br />
* Searching<br />
* Comprehensive audio format support through GStreamer<br />
* Easy Playlist management<br />
<br />
To install Quod Libet:<br />
pacman -S quodlibet<br />
<br />
Other good audio players are Banshee and Listen. See [http://gnomefiles.org/ Gnomefiles] to compare them.<br />
<br />
====KDE====<br />
=====Amarok=====<br />
[http://amarok.kde.org/ Amarok] is one of the best audio players and music library systems available for KDE. To install it, simply type the code below.<br />
<br />
pacman -S amarok-base<br />
<br />
====Console====<br />
[http://moc.daper.net/ Moc] is a ncurses-based audio player for the console; another good choice is [http://musicpd.org/ mpd].<br />
<br />
Another excellent choice is [http://freshmeat.net/projects/cmus/ cmus].<br />
<br />
====Other X-based====<br />
(TODO) Xmms, audacious, bmpx.<br />
<br />
===Codecs and other multimedia content types (i686 only) ===<br />
====DVD====<br />
You can use xine-ui, totem-xine, mplayer or kaffeine (just to name three of the big ones) to watch DVDs. The only thing you may miss is libdvdcss. Beware that using it may be illegal in some countries.<br />
<br />
====Flash====<br />
Install the flash plugin using<br />
pacman -S flashplugin<br />
to enable Macromedia (now Adobe) Flash in your browser, if you run KDE you should see this after installing flash. http://wiki.archlinux.org/index.php/Flash_and_Adobe_Acrobat_browser_plugins#Fixing_Flash_in_Konqueror<br />
<br />
====Quicktime====<br />
Quicktime codecs are contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them.<br />
====Realplayer====<br />
The codec for Realplayer 9 is contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them. Realplayer 10 is available as a binary package for Linux. You can get it from AUR [http://aur.archlinux.org/packages.php?do_Details=1&ID=1590&O=0&L=0&C=0&K=realplay&SB=&SO=&PP=25&do_MyPackages=0&do_Orphans=0&SeB=nd here].<br />
<br />
===CD and DVD Burning===<br />
====GNOME====<br />
=====Brasero=====<br />
[http://www.gnome.org/projects/brasero/ Brasero] is an application that burns CDs/DVDs for the GNOME Desktop. It is designed to be as simple as possible and has some unique features to enable users to create their discs easily and quickly.<br />
<br />
To install:<br />
pacman -S brasero<br />
<br />
====KDE====<br />
=====K3b=====<br />
K3b (from '''K'''DE '''B'''urn '''B'''aby '''B'''urn) is a free software CD and DVD authoring application for GNU/Linux and other <code>UNIX</code>-like operating systems designed for KDE. As is the case with most KDE applications, K3b is written in the C++ programming language and uses the Qt GUI toolkit. K3b provides a graphical user interface to perform most CD/DVD burning tasks like creating an Audio CD from a set of audio files or copying a CD/DVD, as well as more advanced tasks such as burning eMoviX CD/DVDs. It can also perform direct disc-to-disc copies. The program has many default settings which can be customized by more experienced users. The actual disc recording in K3b is done by the command line utilities cdrecord or wodim, cdrdao, and growisofs. As of version 1.0, K3b features a built-in DVD ripper.- licensed under the GPL.<br />
<br />
K3b was voted LinuxQuestions.org's Multimedia Utility of the Year (2006) by the majority (70%) of voters. <br />
-----<br />
To install:<br />
pacman -S k3b<br />
<br />
=====(Todo) cdrecord, graveman...=====<br />
<br />
<br />
<br />
<br />
Most CD burners are wrappers for cdrecord:<br />
<br />
pacman -S cdrkit<br />
<br />
If you install packages for CD/DVD burning applications like Brasero or K3B it also installs the CD/DVD burning library for it, like libburn or cdrkit.<br />
<br />
A good command-line DVD-burning tool is growisofs:<br />
<br />
pacman -S dvd+rw-tools<br />
<br />
===TV-Cards===<br />
<br />
There are several things to do if you want to watch TV under (Arch) Linux. The most important task is to find out which chip your tuner is using. However, quite a lot are supported. Be sure to check at a Hardware Database to be sure (see [http://en.opensuse.org/HCL/TV_Cards this list], for example). Once you know your Model, there are just a few steps ahead to get you going.<br />
<br />
In most cases, you will need to use the bttv-drivers (other drivers exist, like [http://linux.bytesex.org/v4l2/drivers.html V4L]) together with the I2C-modules. Configuring those is the hardest task. If you are lucky, a<br />
modprobe bttv<br />
will autodetect the card (check dmesg for results). In that case, you need only to install an application to watch TV. We will look at that later, though.<br />
If the autodetection did not work, you will need to check the file CARDLIST, which is included in the tarball of [http://dl.bytesex.org/releases/video4linux/ bttv] to find out the right parameters for your card. A PV951 without radio support would need this line:<br />
modprobe bttv card=42 radio=0<br />
Some cards need the following line to produce sound:<br />
modprobe tvaudio<br />
However, that varies. So just try it out. Some other cards demand the following line:<br />
modprobe tuner<br />
This is subject to trial-and-error, too.<br />
<br />
TODO: clarify the installation-procedure<br />
<br />
To actually watch TV, install the xawtv-package with<br />
pacman -S xawtv <br />
and read its manpage.<br />
<br />
TODO: clarify some possible problems and procedures. Introduction to XAWTV on another page?<br />
<br />
===Digital Cameras===<br />
Most newer digital cameras are supported as USB mass storage devices, which means that you can simply plug it in and copy the images. Older cameras may use the PTP (Picture Transfer Protocol) which requires a "special driver". gPhoto2 provides this driver and allows a shell-based transfer of the images; digikam (for KDE) and gthumb (for GNOME, gtkam would be another choice) use this driver and offer a nice GUI.<br />
<br />
===USB Memory Sticks / Hard Disks===<br />
USB Memory Sticks and hard disks are supported out of the box with the USB mass storage device driver and will appear as a new SCSI device (/dev/sdX). If you are using KDE or GNOME you should use dbus and hal (add them to your daemons in /etc/rc.conf), and they will be automatically mounted. If you use a different Desktop Environment you may have a look at ivman.<br />
<br />
==Maintaining the system==<br />
===Pacman===<br />
[[Pacman]] is both a binary and source package manager which is able to download, install, and upgrade packages from both remote and local repositories with full dependency handling, and has easy-to-understand tools for crafting your own packages too.<br />
<br />
A more-detailed description of Pacman can be found in [[Pacman|its article]].<br />
<br />
====Useful commands====<br />
To view the options available for a particular operational command, say '''-Q''', just append it with '''-h''':<br />
pacman -Qh<br />
<br />
To synchronize and update the local packages database with the remote repositories (it is a good idea to do this before installing and upgrading packages):<br />
pacman -Sy<br />
<br />
To '''upgrade''' all packages on the system:<br />
pacman -Su<br />
<br />
To sync, update, and '''upgrade''' all the packages on the system with one command:<br />
pacman -Syu<br />
<br />
To install or upgrade a single package or list of packages (including dependencies):<br />
pacman -S packageA packageB<br />
<br />
You can also sync, update the package database, and install packages in one command:<br />
pacman -Sy packageA packageB<br />
<br />
To remove a single package, leaving all of its dependencies installed:<br />
pacman -R package<br />
<br />
To remove a package and all of the package's dependencies which aren't used by any other installed package:<br />
pacman -Rs package<br />
('''-Rs''' is typically preferred vs '''R''' to remove any package as it will clean up all unused dependencies)<br />
<br />
To remove all of the package's now unneeded dependencies and also instruct pacman to ignore file backup designations. (Normally, when a file is removed from the system the database is checked to see if the file should be renamed with a ".pacsave" extension.):<br />
pacman -Rsn package<br />
<br />
To search the remote (repo) package database for a list of packages matching a given keyword:<br />
pacman -Ss keyword<br />
<br />
To list all packages on your system<br />
pacman -Q<br />
<br />
To list all packages on your system without the version strings, we add the '''-q''' option:<br />
pacman -Qq<br />
<br />
To search (query) the local (your machine) package database for a given package:<br />
pacman -Q package <br />
<br />
To search (query) the local (your machine) package database for a given package and list all pertinent information:<br />
pacman -Qi package<br />
<br />
To list all files installed by a given ''package'':<br />
<tt>pacman -Ql ''package''</tt><br />
Conversely, to find the package that owns a given file (in this example, the ''ls'' executable):<br />
<tt>pacman -Qo /bin/ls</tt><br />
To find all unused packages (orphans):<br />
pacman -Qdt<br />
Missing libraries: Suppose you receive an error message like this:<br />
<tt>mplayer: error while loading shared libraries: ''libgssapi.so.2'': cannot open shared object file: No such file or directory</tt><br />
This may be an indication that a package you have previously installed is now corrupt (some or all of its files are missing). You should try to find the package name that provides the missing shared library. In this example, you could type:<br />
<tt>pacman -Ql | grep ''libgssapi.so.2''</tt><br />
The first column in the output is the package name:<br />
<tt>heimdal /usr/lib/libgssapi.so.2<br />
heimdal /usr/lib/libgssapi.so.2.0.0<br />
</tt><br />
Then, you can just re-install it:<br />
<tt>pacman -Sy heimdal</tt><br />
<br />
To defragment pacman's cache database and optimize for speed:<br />
pacman-optimize<br />
<br />
To count how many packages are currently on your system:<br />
pacman -Q | wc -l<br />
<br />
To install a package compiled from source using ABS and makepkg:<br />
pacman -U packagename.pkg.tar.gz<br />
<br />
Note: There are countless additional pacman functions and commands. Try man pacman and consult the [[pacman]] wiki entries.<br />
<br />
====Files====<br />
There are a number of files left and created by pacman and other programs to facilitate maintenance and to conform to a safe computing practice. When pacman is installing something, the package contains information on whether to back up a particular file. Such files will have the '''.pacsave''' extension. When you force a "NoUpgrade" on a file via [http://www.archlinux.org/pacman/pacman.conf.5.html pacman.conf], it will not be replaced during an upgrade and the new file will come with the '''.pacnew''' extension. For example, you have edited a configuration file thoroughly and you do not want an upgrade of the respective package to replace the file with a new one, we must have the following line in '''/etc/pacman.conf''':<br />
NoUpgrade = /path/to/config/file<br />
To view the differences of the old and new versions of these files, we can either edit them manually or use a '''diff''' utility to take note of the differences. There is an automated tool to find and view such files available from the '''community''' repository:<br />
pacman -S pacman-contrib<br />
cd ~/<br />
pacdiff # as root<br />
There is a bug in the above tool where if you navigate to '''/etc''' and run it from there, the paths will be messed up. We remain on the safer side by being at "home". You may want to run it as user first in case you happen to be a careless person (you may just overwrite or remove files because you ''think'' that is the right way).<br><br />
<br />
There are other types of leftovers depending on the programs available on your system. Some will create backups with a '''.bak''' extension, while others with something like "'''~'''" or "'''-'''". Unfortunately, there is currently no way to "automatically" find and review them. Fear not, as we have no need for automated tools to deal with such trivial tasks. Simply use '''locate''' to search for them:<br />
locate -e *.~ *.- *.bak<br />
And we can use something useful like '''vimdiff''' to look at the differences manually:<br />
pacman -S vim<br />
vimdiff file1 file2<br />
<br />
==Polishing & Further information==<br />
For further information and support you can go to the [http://www.archlinux.org/ homepage], [[Special:Search|search the wiki]], the [http://bbs.archlinux.org/ forums], the [[ArchChannel|IRC channel]], and the [http://www.archlinux.org/mailman/listinfo/ mailing lists].<br />
=====FAQs=====<br />
See [[Arch FAQs for newbies]]<br />
<br />
There is also an [http://bbs.archlinux.org/viewforum.php?id=23 Arch Subforum] devoted to beginners.<br />
<br />
=====Terminology=====<br />
For more information on the jargon used in Arch, look at [[Arch Terminology/Jargon for newbies|this article]].<br />
<br />
=====Where to go from here?=====<br />
<br />
You may also be interested in:<br />
<br />
[[Post Installation Tips]]<br />
<br />
[[ArchLinux User-community Repository (AUR)]]<br />
<br />
[[Get All Mouse Buttons Working]]<br />
<br />
[[Improve Pacman Performance]]<br />
<br />
[[Kernel Compilation]]<br />
<br />
[[Pm-utils]]<br />
<br />
[[Cpufrequtils]]<br />
<br />
[[:Category:Eye candy (English)| Eye Candy]]<br />
<br />
==External links==<br />
* [http://archux.com/page/installation-guide/ Arch Linux installation guide with images and videos]<br />
{{translateme}}</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Newcomers_Guide&diff=53077
Newcomers Guide
2008-11-10T14:13:07Z
<p>Cucullus: /* Obtain the latest Installation media */ tpowa iso url fix</p>
<hr />
<div>[[Category:Getting and installing Arch (English)]]<br />
[[Category:About Arch (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{Article summary start}}<br />
{{Article summary text|Provides a highly detailed, explanatory guide to installing, configuring and using a full-featured Arch Linux system.}}<br />
{{Article summary heading|Available Languages}}<br />
{{i18n_entry|Česky|Průvodce začátečníka (Česky)}}<br />
{{i18n_entry|Dansk|Dansk_Begynderguide}}<br />
{{i18n_entry|简体中文|Beginners Guide 新手指南}}<br />
{{i18n_entry|正體中文|Beginner's Guide 新手指南}}<br />
{{i18n_entry|Deutsch|Beginners Guide (Deutsch)}}<br />
{{i18n_entry|English|Beginners Guide}}<br />
{{i18n_entry|Español|Guía para Principiantes (Español)}}<br />
{{i18n_entry|Français|Manuel_du_Débutant_(Français)}}<br />
{{i18n_entry|Italiano|Beginners Guide (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Pradedančiųjų gidas (Lietuviškai)}}<br />
{{i18n_entry|Português Brasil|Guia do Iniciante(Português do Brasil)}}<br />
{{i18n_entry|Português|Guia para Principiantes(Português)}}<br />
{{i18n_entry|Русский|Руководство_для_новичков}}<br />
{{i18n_entry|Türkçe|Başlangıç Rehberi (Türkçe)}}<br />
{{Article summary heading|Related articles}}<br />
{{Article summary wiki|Official Arch Linux Install Guide}} (provides a more general approach)<br />
{{Article summary end}}<br />
==Preface==<br />
<br />
=====Everything you ever wanted to know about Arch, but were afraid to ask=====<br />
Welcome. This self-contained document will guide you through the process of installing, configuring and using [[Arch Linux]]; a simple, agile and lightweight GNU/Linux distribution, <code>UNIX</code>-like operating system. Arch Linux requires a certain level of intimate knowledge of its configuration and of <code>UNIX</code>-like system methodology and for this reason, extra explanatory information is included. This guide is aimed at new Arch users, but strives to serve as a strong reference and informative base for all. After reading it entirely, the reader will be well equipped to begin using Arch.<br />
<br />
'''Arch Linux distribution highlights:'''<br />
* '''[[The Arch Way | Simple]]''' design and philosophy<br />
* Community distro targeted at competent GNU/Linux users<br />
* System assembled by the user from the ground up<br />
* All packages compiled for '''i686/x86-64'''<br />
* '''[[The Arch boot process | BSD-style init]]''' scripts, featuring one centralized configuration file; /etc/rc.conf<br />
* '''Rolling Release''' model<br />
* '''[[Pacman]]''' package manager is fast, written in '''C''', lightweight and agile, with a very modest memory footprint<br />
* '''[[ABS]]''': The '''A'''rch '''B'''uild '''S'''ystem, a ports-like package building system<br />
* '''[[AUR]]''': The Arch User Repository, offering many thousands of build scripts for user-provided software packages<br />
<br />
Since GNU/Linux Distributions are fundamentally 'modular' by design, the guide is logically divided into 3 main components of a desktop <code>UNIX</code>-like operating system:<br />
<br />
'''[[#Part I: Install the Base System|Part I: Installing the Base system]]'''<br />
<br />
'''[[#Part II: Install X and configure ALSA|Part II: Installing X and configuring ALSA]]'''<br />
<br />
'''[[#Part III: Installing and configuring a Desktop Environment|Part III: Installing a Desktop Environment]]'''<br />
<br />
=====DON'T PANIC!=====<br />
The Arch Linux system is assembled by the ''user'', from the shell, using basic command line tools. This is '''[[The Arch Way]].''' Unlike the more rigid structures of other distributions and installers, there are no default environments nor configurations chosen for you. From the command line, ''you'' will add packages from the Arch repositories using the [[pacman]] tool via your internet connection and manually configure your installation until your system is customized to your requirements. This method allows for maximum flexibility, choice, and system resource control ''from the base up''.<br />
<br />
Arch Linux is aimed at competent GNU/Linux users who desire minimal 'code separation' from their machine.<br />
<br />
=====License=====<br />
<br />
Arch Linux, pacman, documentation, and scripts are copyright<br />
©2002-2007 by Judd Vinet, ©2007-2008 by Aaron Griffin and are licensed under the GNU General Public License Version 2.<br />
=====[[The Arch Way]]=====<br />
<br />
'''''The design principles behind Arch are aimed at keeping it [[The Arch Way|simple]].'' '''<br />
<br />
'Simple', in this context, shall mean 'without unnecessary additions, modifications, or complications'. In short; an elegant, minimalist approach.<br />
<br />
'''Some thoughts to keep in mind:'''<br />
<br />
*''" 'Simple' is defined from a technical standpoint, not a usability standpoint. It is better to be technically elegant with a higher learning curve, than to be easy to use and technically [inferior]." -Aaron Griffin''<br />
<br />
*''Entia non sunt multiplicanda praeter necessitatem'' or "Entities should not be multiplied unnecessarily." -Occam's razor. The term ''razor'' refers to the act of shaving away unnecessary complications to arrive at the simplest explanation, method or theory.<br />
<br />
*''"The extraordinary part of [my method] lies in its simplicity..I always believe that the simple way is the right way."'' - Bruce Lee<br />
<br />
{{Box Note |'''Following this guide closely is essential in order to successfully install a properly configured Arch Linux system, so ''please'' read it thoroughly. It is strongly recommended you read each section completely before carrying out the tasks contained.'''}}<br />
* You may wish to make a print out of this guide which will serve as a useful Arch Linux user reference. Simply click on the 'Printable Version' tab in the toolbox on the top-left.<br />
*''If you would like to add to this wiki, please include the "Why" as well as the "How", where appropriate. The best documentation teaches us how, as well as why!''<br />
* The Arch wiki is an excellent resource and should be consulted for issues [http://wiki.archlinux.org/index.php/Main_Page first]; IRC (freenode #archlinux), and the [http://bbs.archlinux.org/ forums] are also available if the answer cannot be found.<br />
<br />
<br />
Welcome to Arch! Now, let's get started.<br />
<br />
==Part I: Install the Base System==<br />
<br />
===Obtain the latest Installation media ===<br />
<br />
You can obtain Arch's official archiso media from [http://archlinux.org/download/ here]. The latest version is 2008.06<br />
<br />
You can obtain Tobias Powalowski's 2008.10 archboot media from [http://downloads.archlinux.de/iso/archboot/2008.10/ here]. <br />
<br />
*Both the Core installer and the FTP/HTTP-downloads provide only the necessary packages to create an '''Arch Linux base system'''. ''Note that the Base System does not include a GUI. It is mainly comprised of the GNU toolchain, (compiler, assembler, linker, libraries, shell, and a few useful utilities) the Linux kernel, and a few extra libraries and modules.'' <br />
*Expanding your Arch Linux system beyond the base system, to include extra software, a Graphical User Interface, etc., is achieved from the command line, ''by the user'', via the pacman package manager to grab i686/x86-64 binary packages. The process is covered in detail below.<br />
====CD installer====<br />
Burn the .iso to a CD with your favorite burner, and continue with [[#Boot Arch Linux Installer | Boot Arch Linux Installer]]<br />
{{Box Note| CD media quality varies greatly, but generally, using a slow burn speed is recommended for reliable burns; Some users recommend speeds '''''as low as 4x or 2x!''''' If you are experiencing unexpected behavior from the CD, try burning at the minimum speed supported by your system. }}<br />
<br />
====USB stick====<br />
<font color="red">'''WARNING''': This will destroy all data on your USB stick.</font><br />
<br />
Insert an empty or expendable USB stick, determine its path, and dump the .img to the USB stick with the <code>/bin/dd</code> program:<br />
dd if=archlinux-2008.06-[core_or_ftp]-i686.img of=/dev/sd''x''<br />
where ''if='' is the path to the img file and ''of='' is your USB device. Make sure to use /dev/sd''x'' and not /dev/sd''x1''.<br />
<br />
'''Check md5sum (optional):'''<br />
<br />
Make a note of the number of records (blocks) read in and written out, then perform the following check:<br />
dd if=/dev/sd''x'' count=''number_of_records'' status=noxfer | md5sum<br />
The md5sum returned should match the md5sum of the downloaded archlinux image file; they both should match the md5sum of the image as listed in the md5sums file in the mirror distribution site.<br />
<br />
Continue with [[#Boot Arch Linux Installer | Boot Arch Linux Installer]]<br />
<br />
===Boot Arch Linux Installer===<br />
Insert the CD or USB stick and boot from it. You may have to <br />
change the boot order in your computer BIOS or press a key (usually DEL, F1, F2, F11 or F12) during the BIOS POST phase.<br />
<br />
Memory requirements:<br />
<br />
* CORE : 160 MB RAM x86_64/i686 (all packages selected, with swap partition)<br />
* FTP : 160 MB RAM x86_64/i686 (all packages selected, with swap partition)<br />
<br />
Choose Boot Archlive or Boot Archlive [legacy IDE] if you have trouble with libata/PATA. <br />
<br />
To change boot options press '''e''' for editing the boot lines. Many users may wish to change the resolution of the framebuffer, for more readable console output. Append:<br />
vga=773<br />
to the kernel line, followed by <ENTER>, for a 1024x768 framebuffer. Hit '''b''' to boot.<br />
<br />
The system will now boot and present a login prompt.<br />
<br />
===Login and Changing the keymap===<br />
Login as 'root'.<br />
<br />
If you have a non-US keyboard layout do:<br />
# km<br />
at the prompt, and choose your keymap/console font.<br />
<br />
That's right, the ever-popular '''km''' program is back as of 2008-06!<br />
<br />
===Documentation===<br />
The guide you are now reading is available on the live system. Change to vc/2 with <ALT>+F2 and do:<br />
# less /arch/beginnersguide.txt<br />
'''Less''' will allow you to page through the document. Change back to vc/1 with <ALT>+F1. <br />
<br />
Change back to vc/2 if you need to reference the Beginners' Guide at any time.<br />
<br />
===Start the Installation===<br />
As root, run the installer script from vc/1:<br />
# /arch/setup <br />
<br />
====Select an installation source====<br />
After a welcome screen, you will be prompted for an installation source. Choose the appropriate source for the installer you are using. <br />
* If you chose the CORE installer, continue below with [[#Prepare Hard Drive|Prepare Hard Drive]].<br />
* FTP/HTTP only: You shall be prompted to load ethernet drivers manually, if desired. Udev is quite effective at loading the required modules, so you may assume it has already done so. You may verify this by invoking ifconfig -a from vc/3. (Select OK to continue.)<br />
<br />
===Configure Network (FTP/HTTP)===<br />
Available Interfaces will be presented. If an interface and HWaddr is listed, then your module has already been loaded. If your interface is not listed, you may probe it from the installer, or manually do so from another virtual console.<br />
<br />
The following screen will prompt you to ''Select the interface, Probe,'' or ''Cancel''. Choose the appropriate interface and continue.<br />
<br />
The installer will then ask if you wish to use DHCP. Choosing Yes will run '''dhcpcd''' to discover an available gateway and request an IP address; Choosing No will prompt you for your static IP, netmask, broadcast, gateway DNS IP, HTTP proxy, and FTP proxy. Lastly, you will be presented with an overview to ensure your entries are correct.<br />
<br />
====Wireless Quickstart (If you need wireless connectivity during the installation process)====<br />
<br />
The wireless drivers and utilities are now available to you in the live environment of the installation media. <br />
<br />
If you need wireless functionality from the initial installation (live installer environment) onwards, the basic procedure will be:<br />
* Switch to a free virtual console, e.g.: <ALT>+F3<br />
* Identify your wireless card and appropriate module with <code>/sbin/hwdetect</code>:<br />
# hwdetect --show-net<br />
* Ensure udev has loaded the module with <code>/bin/lsmod</code>:<br />
# lsmod | grep <name_of_module><br />
* If not, probe it using <code>/sbin/modprobe</code>:<br />
# modprobe <name_of_module><br />
{{Box Note | '''''In addition to the wireless module, some wireless chipsets also require corresponding firmware installation. The firmware packages are pre-installed in the live environment, but must be explicitly installed to your actual system to provide wireless functionality after you reboot into your installed system. Package selection and installation is covered below. Ensure installation of both your wireless module and firmware during the package selection step! See [[Wireless Setup]] if you are unsure about the requirement of corresponding firmware installation for your particular chipset. This is a very common error.'''''}}<br />
<br />
* Ensure the driver has created a usable wireless kernel interface with <code>/usr/sbin/iwconfig</code>:<br />
# iwconfig<br />
(Output should show an available wireless interface)<br />
* Bring the interface up with <code>/sbin/ifconfig <interface> up</code>. <br />
<br />
An example, using an atheros card and madwifi driver:<br />
# ifconfig ath0 up<br />
(Remember, your interface may be named something else, depending on your module (driver) and chipset: wlan0, eth1, etc.)<br />
* Specify the id of the wireless network with iwconfig <interface> essid <youressid> key <yourwepkey>, e.g.:<br />
# iwconfig ath0 essid linksys key 0241baf34c<br />
* Acquire an IP address with <code>/sbin/dhcpcd <interface> </code>. e.g.:<br />
# dhcpcd ath0<br />
* Ensure you can route using <code>/bin/ping</code>:<br />
# ping -c 3 www.google.com<br />
Done.<br />
<br />
After the initial Arch installation is complete, you may wish to refer to [[Wireless Setup]] to ensure a permanent configuration solution for your system.<br />
<br />
<br />
Return to vc/1 with <ALT>+F1. Continue with [[#Prepare Hard Drive|Prepare Hard Drive]]<br />
<br />
===Prepare Hard Drive===<br />
<br />
<font color="red"> '''WARNING:''' '''''Partitioning hard drives can destroy data. You are strongly cautioned and advised to backup your critical data if applicable.'''''</font><br />
<br />
Verify your current disk identities and layout by invoking <code>/sbin/fdisk.</code><br />
<br />
Open another virtual console (<ALT>+F3) and enter:<br />
# fdisk -l<br />
Take note of the disk(s)/partition(s) you wish to utilize for your Arch installation.<br />
<br />
Switch back to the installation script with <ALT>+F1<br />
<br />
Select the first menu entry "Prepare Hard Drive". <br />
* Option 1: Auto Prepare<br />
Auto-Prepare divides your disk into the following configuration:<br />
<br />
* ext2 /boot partition, default size 32MB. ''You will be prompted to modify the size to you requirement.''<br />
* swap partition, default size 256MB. ''You will be prompted to modify the size to you requirement.'' <br />
* A Separate / and /home partition, (sizes can also be specified). You may choose from ext2, ext3, reiserfs, xfs and jfs, but note that ''both / and /home must share the same fs type'' if choosing the Auto Prepare option.<br />
<br />
Be warned that Auto-prepare will completely erase the chosen hard drive. Read the <font color="red">warning</font> presented by the installer very carefully, and make sure the correct device is about to be partitioned.<br />
<br />
* Option 2: '''(Recommended)''' Partition Hard Drives (with cfdisk)<br />
<br />
This option will allow for the most robust and customized partitioning solution for your personal needs. <br />
<br />
''At this point, more advanced GNU/Linux users who are familiar and comfortable with manually partitioning may wish to skip down to '''[[#Select Packages|Select Packages]]''' below.''<br />
<br />
====Partition Hard Drives====<br />
<br />
=====Partition Info=====<br />
<br />
Partitioning a hard disk drive defines specific areas (the partitions) within the disk, that will each appear and behave as a separate disk and upon which a filesystem may be created (formatted). <br />
*There exist 3 types of disk partitions: <br />
#Primary<br />
#Extended<br />
#Logical<br />
'''Primary''' partitions can be bootable, and are limited to 4. If a partitioning scheme requires more than 4 partitions, we are forced to use an '''extended''' partition which will contain '''logical''' partitions.<br />
<br />
Extended partitions are not usable by themselves; they are merely a "container" for logical partitions. If required, a hard disk shall contain only one extended partition; which shall then be sub-divided into logical partitions. <br />
<br />
When partitioning a disk, one can observe this numbering scheme by creating primary partitions sda1-3 followed by creating an extended partition, sda4, and subsequently creating logical partition(s) within the extended partition; sda5, sda6, and so on.<br />
<br />
=====Swap Partition=====<br />
A swap partition is a place on your hard drive where virtual ram resides, allowing the kernel to easily use disk storage for data that does not fit into physical RAM. <br />
<br />
Historically, the general rule for swap partition size was 2x the amount of physical RAM. Over time, as computers have gained ever larger memory capacities, this rule has become increasingly deprecated. Generally, on machines with up to 512MB RAM, the 2x rule is usually quite sufficient. On machines with 1GB RAM, generally a 1x rule is adequate. If you have gratuitous amounts of RAM (more than 1024 MB) it may be possible to completely forgo a swap partition altogether, though this is not recommended. We will create a 1 GB swap partition in this example.<br />
{{Box Note|If you plan on using suspend-to-disk, (hibernate) you must have a swap partition at least '''equal''' in size to the amount of physical RAM, and some Arch users even recommend oversizing it beyond the amount of physical RAM by 10-15%, to allow for possible bad sectors.}}<br />
<br />
=====Partition Scheme=====<br />
A disk partitioning scheme is a very personalized preference. Each user's choices will be unique to their own computing habits and requirements. <br />
<br />
Filesystem candidates for separate partitions include:<br />
<br />
'''/''' (root) ''The root filesystem is the primary filesystem from which all other filesystems stem; the top of the hierarchy. All files and directories appear under the root directory "/", even if they are stored on different physical devices. The contents of the root filesystem must be adequate to boot, restore, recover, and/or repair the system.'' <br />
<br />
'''/boot''' ''This directory contains the kernel and ramdisk images as well as the bootloader configuration file, and bootloader stages. /boot also stores data that is used before the kernel begins executing userspace programs. This may include saved master boot sectors and sector map files.''<br />
<br />
'''/home''' ''User data and user specific configuration files for applications are stored in each user's home directory in a file that starts with the '.' character (a "dot file").''<br />
<br />
'''/usr''' ''While root is the primary filesystem, /usr is the secondary hierarchy, for user data, containing the majority of (multi-)user utilities and applications. /usr is shareable, read-only data. This means that /usr shall be shareable between various hosts and must not be written to, except in the case of system update/upgrade. Any information that is host-specific or varies with time is stored elsewhere.''<br />
<br />
'''/tmp''' ''directory for programs that require temporary files''<br />
<br />
'''/var''' ''contains variable data; spool directories and files, administrative and logging data, pacman's cache, the ABS tree, etc.''<br />
{{Box Note | Besides /boot, directories essential for booting are: '/bin', '/dev', '/etc', '/lib', '/proc' and '/sbin'. Therefore, they must not reside on a separate partition from /.}}<br />
There are several advantages for using discrete filesystems, rather than combining all into one partition:<br />
<br />
* Security: Each filesystem may be configured in /etc/fstab as 'nosuid', 'nodev', 'noexec', 'readonly', etc.<br />
* Stability: A user, or malfunctioning program can completely fill a filesystem with garbage if they have write permissions for it. Critical programs, which reside on a different filesystem remain unaffected.<br />
* Speed: A filesystem which gets written to frequently may become somewhat fragmented. (An effective method of avoiding fragmentation is to ensure that each filesystem is never in danger of filling up completely.) Separate filesystems remain unaffected, and each can be defragmented separately as well.<br />
* Integrity: If one filesystem becomes corrupted, separate filesystems remain unaffected.<br />
* Versatility: Sharing data across several systems becomes more expedient when independent filesystems are used. Separate filesystem types may also be chosen based upon the nature of data and usage. <br />
In this example, we shall use separate partitions for /, /var, /home, and a swap partition. <br />
<br />
{{Box Note | /var contains many small files. You may wish to take this into consideration when choosing a filesystem type for it.}}<br />
<br />
=====How big should my partitions be?=====<br />
This question is best answered based upon individual needs. If you have little or no experience with partitioning, you may wish to simply create one partition for root, and one partition for swap. Or, follow the example closely, and consider these guidelines to provide a frame of reference:<br />
* The root filesystem (/) in the example will contain the /usr directory, which can become moderately large, depending upon how much software is installed.<br />
<br />
* The /var filesystem will contain, among other data, the [[ABS]] tree and the pacman cache. Keeping cached packages is useful and versatile; it provides the ability to downgrade packages if needed. /var tends to grow in size; the pacman cache can grow large over long periods of time, but can be safely cleared if needed. 6-8 Gigs on a desktop system should therefore be sufficient for /var. Servers tend to have extremely large /var filesystems.<br />
* The /home filesystem is typically where user data, downloads, and multimedia reside. On a desktop system, /home is typically the largest filesystem on the drive by a large margin. <br />
* An extra 25% of space added to each filesystem will provide a cushion for unforeseen occurrence, expansion, and serve as a preventive against fragmentation.<br />
'''''From the guidelines above, the example system shall contain a ~15GB root (/) partition, ~6GB /var, 1GB swap, and a /home containing the remaining disk space.'''''<br />
<br />
=====cfdisk=====<br />
Start by creating the primary partition that will contain the '''root''', (/) filesystem. <br />
<br />
Choose '''N'''ew -> Primary and enter the desired size for root (/). Put the partition at the beginning of the disk. <br />
<br />
Also choose the '''T'''ype by designating it as '83 Linux'. The created / partition shall appear as sda1 in our example.<br />
<br />
Now create a primary partition for /var, designating it as '''T'''ype 83 Linux. The created /var partition shall appear as sda2 <br />
<br />
Next, create a partition for swap. Select an appropriate size and specify the '''T'''ype as 82 (Linux swap / Solaris). The created swap partition shall appear as sda3.<br />
<br />
Lastly, create a partition for your /home directory. Choose another primary partition and set the desired size.<br />
<br />
Likewise, select the '''T'''ype as 83 Linux. The created /home partition shall appear as sda4.<br />
<br />
Example:<br />
<br />
Name Flags Part Type FS Type [Label] Size (MB)<br />
-------------------------------------------------------------------------<br />
sda1 Primary Linux 15440 #root<br />
sda2 Primary Linux 6256 #/var<br />
sda3 Primary Linux swap / Solaris 1024 #swap<br />
sda4 Primary Linux 140480 #/home<br />
<br />
Choose '''W'''rite and type ''''yes''''. Beware that this operation may destroy data on your disk. Choose '''Q'''uit to leave the partitioner. <br />
Choose Done to leave this menu and continue with "Set Filesystem Mountpoints".<br />
<br />
{{Box Note | Since the latest developments of the Linux kernel which include the libata and PATA modules, all IDE, SATA and SCSI drives have adopted the sd''x'' naming scheme. This is perfectly normal and should not be a concern.}}<br />
<br />
====Set Filesystem Mountpoints====<br />
First you will be asked for your swap partition. Choose the appropriate partition (sda3 in this example). You will be asked if you want to create a swap filesystem; select yes. Next, choose where to mount the / (root) directory (sda1 in the example). At this time, you will be asked to specify the filesystem type.<br />
<br />
=====Filesystem Types=====<br />
<br />
Again, a filesystem type is a very subjective matter which comes down to personal preference. Each has its own advantages, disadvantages, and unique idiosyncrasies. Here is a very brief overview of supported filesystems:<br />
<br />
1. '''ext2''' ''Second Extended Filesystem''- Old, reliable GNU/Linux filesystem. Very stable, but ''without journaling support''. May be inconvenient for root (/) and /home, due to very long fsck's. ''An ext2 filesystem can easily be converted to ext3.'' Generally regarded as a good choice for /boot/.<br />
<br />
2. '''ext3''' ''Third Extended Filesystem''- Essentially the ext2 system, but with journaling support. ext3 is completely compatible with ext2. ''Extremely'' stable, mature, and by far the most widely used, supported and developed GNU/Linux FS.<br />
<br />
'''High Performance Filesystems:'''<br />
<br />
3. '''ReiserFS''' - Hans Reiser's high-performance journaling FS uses a very interesting method of data throughput based on an unconventional and creative algorithm. ReiserFS is touted as very fast, especially when dealing with many small files. ReiserFS is fast at formatting, yet comparatively slow at mounting. Quite mature and stable. ReiserFS is not actively developed at this time (Reiser4 is the new Reiser filesystem). Generally regarded as a good choice for /var/.<br />
<br />
4. '''JFS''' - IBM's '''J'''ournaled '''F'''ile'''S'''ystem- The first filesystem to offer journaling. JFS had many years of use in the IBM AIX® OS before being ported to Linux. JFS currently uses the least CPU resources of any GNU/Linux filesystem. Very fast at formatting, mounting and fsck's, and very good all-around performance, especially in conjunction with the deadline I/O scheduler. (See [[JFS]].) Not as widely supported as ext or ReiserFS, but very mature and stable.<br />
<br />
5. '''XFS''' - Another early journaling filesystem originally developed by Silicon Graphics for the IRIX OS and ported to Linux. XFS offers very fast throughput on large files and large filesystems. Very fast at formatting and mounting. Generally benchmarked as slower with many small files, in comparison to other filesystems. XFS is very mature and is currently the only available stable Linux FS with online defragmentation ability.<br />
<br />
===== A note on Journaling=====<br />
All above filesystems, except ext2, use [http://en.wikipedia.org/wiki/Journaling_file_system journaling]. Journaling file systems are fault-resilient file systems that use a journal to log changes before they're committed to the file system to avoid metadata corruption in the event of a crash. Note that not all journaling techniques are alike; specifically, only ext3 offers ''data-mode journaling'', (though, not by default), which journals ''both'' data ''and'' meta-data (but with significant speed penalty). The others only offer ''ordered-mode journaling'', which journals meta-data only. While all will return your filesystem to a valid state after recovering from a crash, ''data-mode journaling'' offers the greatest protection against file system corruption and data loss but can suffer from performance degradation, as all data is written twice (first to the journal, then to the disk). Depending on how important your data are, this may be a consideration in choosing your filesystem type.<br />
<br />
'''''Moving on...'''''<br />
<br />
Choose and create the filesystem (format the partition) for / by selecting '''yes'''. You will now be prompted to add any additional partitions. In our example, sda2 and sda4 remain. For sda2, choose a filesystem type and mount it as /var. Finally, choose the filesystem type for sda4, and mount it as /home. Return to main menu.<br />
<br />
===Select Packages===<br />
<br />
Now we shall select packages to install in our system.<br />
*Core ISO: Choose CD as source and select the appropriate CD drive if you have more than one. <br />
*FTP ISO: Select an FTP/HTTP mirror. ''Note that archlinux.org is throttled to 50KB/s''.<br />
* 2008.06 installation media: Package category BASE is now installed by default. <br />
<br />
Package selection is split into two stages. First, you will select the base package category, then you will be presented will the full lists of packages, allowing you to fine-tune your selections. Use the space bar to select and unselect.<br />
Choose OK to continue and then choose 'yes' for 'Select all packages by default', for now.<br />
<br />
The next screen will present you with the selected packages within your selected categories.<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 />
Next, choose 'Install Packages'. You will be asked if you wish to keep the packages in the pacman cache. If you choose 'yes', you will have the flexibility to [[Downgrade packages|downgrade]] to previous package versions in the future, so this is recommended (you can always clear the cache in the future). The installer script will now install the selected packages, as well as the default Arch 2.6 kernel, to your system. <br />
*FTP ISO: The [[Pacman]] package manager will now download and install your selected packages. (See vc/5 for output, vc/1 to return to the installer)<br />
*CORE ISO: The packages will be installed from the CD.<br />
<br />
Note: For Arch 2007.08 FTP installation: after 'Install Packages' you have to upgrade pacman (<ALT>+F3, pacman -Sy pacman) and again 'Install Packages'.<br />
<br />
===Configure the System===<br />
''Closely following and understanding these steps is of key importance to ensure a properly configured system.'' <br />
<br />
At this stage of the installation, you will configure the primary configuration files of your Arch Linux base system.<br />
<br />
The installer will ask if you want to choose [[Hwdetect|hwdetect]] to gather information for your configuration. Beginners should choose 'yes'. <br />
<br />
Advanced users who are thoroughly familiar with their hardware, required modules, and who are able and willing to manually configure /etc/rc.conf, /etc/mkinitcpio, /etc/fstab, and other system-critical configuration files from scratch may wish to choose 'no'. (Needless to say, this option is very involved, beyond the scope of this guide, and therefore is not covered.)<br />
<br />
Next, you will be asked if you need support for booting from USB devices, FireWire devices, PCMCIA devices, NFS shares, software RAID arrays, LVM2 volumes, encrypted volumes, and DSDT support. Choose yes if you need it; in our example nothing is needed. <br />
<br />
Now you will be asked which text editor you want to use; choose [http://en.wikipedia.org/wiki/Nano_%28text_editor%29 nano] or, if you are familiar with it, [http://en.wikipedia.org/wiki/Vim_%28text_editor%29 vim]. You will be presented with a menu including the main configuration files for your system. <br />
<br />
{{Box Note | ''It is very important at this point to edit, or at the very least, to verify by opening, every configuration file.'' The installer script relies on your input to create these files on your installation. A common error is to skip over these critical steps of configuration.}}<br />
<br />
=====Can the installer handle this more automatically?=====<br />
Hiding the process of system configuration is in direct opposition to [[The Arch Way]]. While it is true that recent versions of the kernel and hardware probing tools offer excellent hardware support and auto-configuration, Arch presents the user all pertinent configuration files during installation for the purposes of ''transparency and system resource control''. By the time you have finished modifying these files to your specifications, you will have learned the simple method of manual Arch Linux system configuration and become more familiar with the base structure, leaving you better prepared to use and maintain your new installation productively.<br />
<br />
====='''/etc/rc.conf'''=====<br />
Arch Linux follows in the '''*BSD''' tradition of utilizing '''/etc/rc.conf''' as the principal location for system configuration. This one file contains a wide range of configuration information, principally used at system startup. As its name directly implies, it also contains settings for and invokes the /etc/rc* files, and is, of course, sourced ''by'' these files. /etc/rc.conf offers a simple, elegant method of streamlining system resource configuration by encompassing a wide range of control, readily accessible for the Arch user. <br />
* '''LOCALIZATION''' section<br />
** '''LOCALE'''=: This sets your system locale, which will be used by all i18n-aware applications and utilities. You can get a list of the available locales by running 'locale -a' from the command line. This setting's default is fine for US English users. <br />
** '''HARDWARECLOCK'''=: Specifies whether the hardware clock, which is synchronized on boot and on shutdown, stores '''UTC''' time, or the '''localtime'''. UTC makes sense because it greatly simplifies changing timezones and daylight savings time. localtime is necessary if you dual boot with an operating system such as Windows, that only stores localtime to the hardware clock.<br />
** '''USEDIRECTISA''': Use direct I/O request instead of /dev/rtc for hwclock<br />
** '''TIMEZONE'''=: Specify your TIMEZONE. (All available zones are under /usr/share/zoneinfo/).<br />
** '''KEYMAP'''=: The available keymaps are in /usr/share/kbd/keymaps. Please note that this setting is only valid for your TTYs, not any graphical window managers or '''X'''.<br />
** '''CONSOLEFONT'''=: Available console fonts reside under /usr/share/kbd/consolefonts/ if you must change. The default (blank) is safe.<br />
** '''CONSOLEMAP'''=: Defines the console map to load with the setfont program at boot. Possible maps are found in /usr/share/kbd/consoletrans, if needed. The default (blank) is safe. <br />
** '''USECOLOR'''=: Select "yes" if you have a color monitor and wish to have colors in your consoles.<br />
<br />
LOCALE="en_US.utf8"<br />
HARDWARECLOCK="localtime"<br />
USEDIRECTISA="no"<br />
TIMEZONE="US/Eastern"<br />
KEYMAP="us"<br />
CONSOLEFONT=<br />
CONSOLEMAP=<br />
USECOLOR="yes"<br />
<br />
* '''HARDWARE''' section<br />
** '''MOD_AUTOLOAD'''=: Setting this to "yes" will use '''udev''' to automatically probe hardware and load the appropriate modules during boot-up, (convenient with the default modular kernel). Setting this to "no" will rely on the user's ability to specify this information manually, or compile their own custom kernel and modules, etc.<br />
** '''MOD_BLACKLIST'''=: This has become deprecated in favor of adding blacklisted modules directly to the '''MODULES=''' line below. <br />
** '''MODULES'''=: Specify additional MODULES if you know that an important module is missing, ('''hwdetect''' should have filled in the most important modules). Also specify any blacklisted modules by prefixing them with a bang (!). Udev will be forced NOT to load blacklisted modules. In the example, the IPv6 module as well as the annoying pcspeaker are blacklisted. <br />
# Scan hardware and load required modules at boot<br />
MOD_AUTOLOAD="yes"<br />
# Module Blacklist - Deprecated<br />
MOD_BLACKLIST=()<br />
#<br />
MODULES=(e100 eepro100 mii slhc snd-ac97-codec snd-intel8x0 soundcore !net-pf-10 !pcspkr)<br />
<br />
* '''NETWORKING''' section<br />
** '''HOSTNAME'''=:Set your HOSTNAME to your liking.<br />
** '''eth0'''=: 'Ethernet, card 0'. Adjust the interface IP address, netmask and broadcast address ''if'' you are using '''static IP'''. Set eth0="dhcp" if you want to use '''DHCP'''<br />
** '''INTERFACES'''=: Specify any/all interfaces here. If you do not use DHCP to configure a device, just keep in mind that the value of the variable (whose name must be equal to the name of the device which is supposed to be configured) equals the line which would be appended to the ifconfig command if you were to configure the device manually in the shell.<br />
** '''gateway'''=: If you are using '''static IP''', set the gateway address. If using '''DHCP''', you can usually ignore this variable, though some users have reported the need to define it.<br />
** '''ROUTES'''=: If you are using static '''IP''', remove the '''!''' in front of 'gateway'. If using '''DHCP''', you can usually leave this variable commented out with the bang (!), but again, some users require the gateway and ROUTES defined. If you experience networking issues with pacman, for instance, you may want to return to these variables. <br />
<br />
Example, using '''DHCP''':<br />
HOSTNAME="arch"<br />
#eth0="eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255" <br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
gateway="default gw 192.168.0.1"<br />
ROUTES=(!gateway)<br />
{{Box Note | Arch uses the '''dhcpcd''' DHCP client. Alternatively, '''dhclient''' is available from the [extra] repository via pacman.}}<br />
<br />
* '''DAEMONS''' section<br />
<br />
This array simply lists the names of those scripts contained in /etc/rc.d/ which are to be started during the boot process, and the order in which they start. <br />
DAEMONS=(@network syslog-ng netfs crond)<br />
*If a script name is prefixed with a bang (!), it is not executed. <br />
*If a script is prefixed with an "at" symbol (@), then it will be executed in the background; the startup sequence will not wait for successful completion of each daemon before continuing to the next. (Useful for speeding up system boot).<br />
*Edit this array whenever new system services are installed, if starting them automatically during boot is desired. <br />
<br />
This 'BSD-style' init, is the Arch way of handling what others handle with various symlinks to an /etc/init.d directory.<br />
<br />
=====About DAEMONS=====<br />
You do not have to change the [[daemons]] line at this time, but it is useful to explain what daemons are, because we need them later in this guide. <br />
A ''daemon'' is a program that runs in the background, waiting for events to occur and offering services. A good example is a webserver that waits for a request to deliver a page or an SSH server waiting for someone trying to log in. While these are full-featured applications, there are daemons whose work is not that visible. Examples are a daemon which writes messages into a log file (e.g. syslog, metalog), a daemon which lowers your CPU's frequency if your system has nothing to do (e.g.:cpufreq), and a daemon which offers you a graphical login (e.g.: gdm, kdm). All these programs can be added to the daemons line and will be started when the system boots. Useful daemons will be presented during this guide.<br />
<br />
Historically, the term ''daemon'' was coined by the programmers of MIT's Project MAC. They took the name from ''Maxwell's demon'', an imaginary being from a famous thought experiment that constantly works in the background, sorting molecules. <code>UNIX</code> systems inherited this terminology and created the backronym '''d'''isk '''a'''nd '''e'''xecution '''mon'''itor. <br />
<br />
*<font color="blue">'''Tip:</font> All Arch daemons reside under /etc/rc.d/'''<br />
<br />
=====/etc/fstab=====<br />
The '''fstab''' (for '''f'''ile '''s'''ystems '''tab'''le) is part of the system configuration listing all available disks and disk partitions, and indicating how they are to be initialized or otherwise integrated into the overall system's filesystem. The '''/etc/fstab''' file is most commonly used by the '''mount''' command. The mount command takes a filesystem on a device, and adds it to the main system heirarchy that you see when you use your system. '''mount -a''' is called from /etc/rc.sysinit, about 3/4 of the way through the boot process, and reads /etc/fstab to determine which options should be used when mounting the specified devices therein. If '''noauto''' is appended to a filesystem in /etc/fstab, '''mount -a''' will not mount it at boot.<br />
<br />
An example '''/etc/fstab''':<br />
# <file system> <dir> <type> <options> <dump> <pass><br />
none /dev/pts devpts defaults 0 0<br />
none /dev/shm tmpfs defaults 0 0<br />
#/dev/cdrom /media/cdrom auto ro,user,noauto,unhide 0 0<br />
#/dev/dvd /media/dvd auto ro,user,noauto,unhide 0 0<br />
#/dev/fd0 /media/fl auto user,noauto 0 0<br />
/dev/disk/by-uuid/0ec-933.. / jfs defaults,noatime,nodiratime 0 1<br />
/dev/disk/by-uuid/7ef-223.. /home jfs defaults,noatime,nodiratime 0 2<br />
/dev/disk/by-uuid/530-1e-.. swap swap defaults 0 0<br />
/dev/disk/by-uuid/4fe-110.. /var reiserfs defaults,noatime,notail 0 2 <br />
{{Box Note | '''''The 'noatime' and 'nodiratime' options may safely be appended to / and /home regardless of your specified filesystem type for increased speed, performance, and power efficiency, for laptops as well as desktops. 'notail' disables the ReiserFS tailpacking feature, for added performance at the cost of slightly less efficient disk usage.'''''}}<br />
<br />
* The first field, '''<file system>''', describes the block device or remote filesystem to be mounted. For regular mounts, this field will contain a link to a block device node (as created by mknod which is called by udev at boot) for the device to be mounted; for instance, '/dev/cdrom' or '/dev/sda1'. Instead of giving the device explicitly, the Arch installer indicates the filesystem that is to be mounted by its UUID by default.<br />
{{Box Note | As of 2008-04rc, Arch is now utilizing the UUID, or Universally Unique Identifier naming convention, for consistent device mapping. This is due to active developments in the kernel and also udev, which may randomly change the ordering in which drivers for storage controllers are loaded, yielding an unbootable system/kernel panic. Nearly every motherboard has several controllers (onboard SATA, onboard IDE), and due to the aforementioned development updates, /dev/sda may become /dev/sdb on the next reboot- hence the persistent device naming convention of UUID has been adopted for reliability. ''If you do not need nor wish to use UUID, simply change your fstab to use whatever naming convention desired.'' (See [[Persistent block device naming| this wiki article]] for more information on persistent block device naming. )}}<br />
ls -lF /dev/disk/by-uuid/<br />
Will list all partitions by uuid.<br />
<br />
* The second field, '''<dir>''', describes the mount point for the filesystem. For swap partitions, this field should be specified as 'swap'; (Swap partitions are not actually mounted.)<br />
<br />
* The third field, '''<type>''', describes the type of the filesystem. The Linux kernel supports many filesystem types. (For the filesystems currently supported by the running kernel, see /proc/filesystems). An entry 'swap' denotes a file or partition to be used for swapping. An entry 'ignore' causes the line to be ignored. This is useful to show disk partitions which are currently unused. <br />
<br />
* The fourth field, '''<options>''', describes the mount options associated with the filesystem. It is formatted as a comma separated list of options. It contains at least the type of mount plus any additional options appropriate to the filesystem type. For documentation on the available options for non-nfs file systems, see mount(8).<br />
<br />
* The fifth field, '''<dump>''', is used for these filesystems by the dump(8) command to determine which filesystems need to be dumped. dump is a backup utility. If the fifth field is not present, a value of zero is returned and dump will assume that the filesystem does not need to be backed up. ''Note that dump is not installed by default.''<br />
<br />
* The sixth field, '''<pass>''', is used by the fsck(8) program to determine the order in which filesystem checks are done at boot time. The root filesystem should be specified with a <pass> of 1, and other filesystems should have a <pass> of 2 or 0. Filesystems within a drive will be checked sequentially, but filesystems on different drives will be checked at the same time to use parallelism available in the hardware. If the sixth field is not present or zero, a value of zero is returned and fsck will assume that the filesystem does not need to be checked. <br />
<br />
*If you plan on using '''hal''' to automount media such as DVDs, you may wish to comment out the cdrom and dvd entries in preparation for '''hal''', which will be installed later in this guide.<br />
<br />
<br />
<br />
Expanded information available in the [[Fstab]] wiki entry.<br />
<br />
====='''[[Configuring mkinitcpio | /etc/mkinitcpio]].conf'''=====<br />
Editing this configuration is unnecessary at this point; this information is provided for explanation. <br />
<br />
This file allows you to fine-tune the initial ram filesystem (also commonly referred to as the initial ramdisk or "initrd") for your system. The initrd is a gzipped image that is read by the kernel during boot. The purpose of the initrd is to bootstrap the system to the point where it can access the root filesystem. This means it has to load any modules that are required for devices like IDE, SCSI, or SATA drives (or USB/FW, if you are booting off a USB/FW drive). Once the initrd loads the proper modules, either manually or through udev, it passes control to the Arch system and your boot continues. For this reason, the initrd only needs to contain the modules necessary to access the root filesystem. It does not need to contain every module you would ever want to use. The majority of your everyday modules will be loaded later on by udev, during the init process.<br />
<br />
'''mkinitcpio''' is the next generation of '''initramfs creation'''. It has many advantages over the old '''mkinitrd''' and '''mkinitramfs''' scripts.<br />
<br />
* It uses '''klibc''' and '''kinit''' which are developed by Linux kernel devs to provide a small and lightweight base for early userspace.<br />
* It can use '''udev''' for hardware autodetection at runtime, thus prevents you from having tons of unnecessary modules loaded.<br />
* Its hook-based init script is easily extendable with custom hooks, which can easily be included in pacman packages without having to modifiy mkinitcpio itself.<br />
* It already supports '''lvm2''', '''dm-crypt''' for both legacy and luks volumes, '''raid''', '''swsusp''' and '''suspend2''' resuming and booting from '''usb mass storage''' devices.<br />
* Many features can be configured from the kernel command line without having to rebuild the image.<br />
* The '''mkinitcpio''' script makes it possible to include the image in a kernel, thus making a self-contained kernel image is possible.<br />
* Its flexibility makes recompiling a kernel unnecessary in many cases. <br />
'''mkinitcpio''' was developed by Aaron Griffin and Tobias Powalowski with some help from the community.<br />
<br />
===== /etc/modprobe.conf=====<br />
It is unnecessary to configure this file at this time.<br />
<br />
* '''modprobe.conf''' can be used to set special configuration options for the kernel modules<br />
<br />
=====/etc/resolv.conf (for Static IP)=====<br />
The ''resolver'' is a set of routines in the C library that provide access to the Internet Domain Name System (DNS). One of the main functions of DNS is to translate domain names into IP addresses, to make the Web a friendlier place. The resolver configuration file, or /etc/resolv.conf, contains information that is read by the resolver routines the first time they are invoked by a process.<br />
<br />
*''If you are using DHCP, you may safely ignore this file, as by default, it will be dynamically created and destroyed by the dhcpcd daemon. You may change this default behavior if you wish. (See [http://wiki.archlinux.org/index.php/Network#For_DHCP_IP Network]]).''<br />
<br />
If you use a static IP, set your DNS servers in /etc/resolv.conf (nameserver <ip-address>). You may have as many as you wish.<br />
An example, using OpenDNS:<br />
nameserver 208.67.222.222<br />
nameserver 208.67.220.220<br />
<br />
If you are using a router, you will probably want to specify your DNS servers in the router itself, and merely point to it from your '''/etc/resolv.conf''', using your router's IP (which is also your gateway from '''/etc/rc.conf'''), e.g.:<br />
nameserver 192.168.1.1<br />
<br />
If using '''DHCP''', you may also specify your DNS servers in the router, or allow automatic assignment from your ISP, if your ISP is so equipped.<br />
<br />
=====/etc/hosts=====<br />
<br />
This file associates IP addresses with hostnames and aliases, one line per IP address. For each host a single line should be present with the following information:<br />
<IP-address> <hostname> [aliases...]<br />
Add your ''hostname'', coinciding with the one specified in /etc/rc.conf, as an alias, so that it looks like this:<br />
127.0.0.1 localhost.localdomain localhost '''''yourhostname'''''<br />
{{Box Note |''This format, '''including the 'localhost' and your actual host name''', is required for program compatibility! Errors in this entry may cause poor network performance and/or certain programs to open very slowly, or not work at all. This is a very common error for beginners.''}}<br />
<br />
If you use a static IP, add another line using the syntax: <static-IP> <hostname.domainname.org> <hostname> e.g.:<br />
192.168.1.100 '''''yourhostname'''''.domain.org '''''yourhostname'''''<br />
<br />
*<font color="blue">'''TIP''':</font> For convenience, you may also use /etc/hosts aliases for hosts on your network, and/or on the Web, e.g.:<br />
64.233.169.103 www.google.com g<br />
192.168.1.90 media<br />
192.168.1.88 data<br />
The above example would allow you to access google simply by typing 'g' into your browser, and access to a media and data server on your network by name and without the need for typing out their respective IP addresses.<br />
<br />
=====/etc/hosts.deny and /etc/hosts.allow=====<br />
Modify these configurations according to your needs if you plan on using the [[SSH|ssh]] daemon. The default configuration will reject all incoming connections, not only ssh connections. Edit your '''/etc/hosts.allow '''file and add the appropriate parameters: <br />
<br />
* let everyone connect to you<br />
sshd: ALL<br />
<br />
* restrict it to a certain ip<br />
sshd: 192.168.0.1<br />
<br />
* OR restrict for an IP range<br />
sshd: 10.0.0.0/255.255.255.0<br />
<br />
If you do not plan on using the [[SSH|ssh]] daemon, leave this file at the default, (empty), for added security.<br />
<br />
=====/etc/locale.gen=====<br />
<br />
The '''/usr/sbin/locale-gen''' command reads from '''/etc/locale.gen''' to generate specific locales. They can then be used by '''glibc''' and any other locale-aware program or library for rendering "peculiar" text, correctly displaying regional monetary values, time and date formats, alphabetic idiosyncrasies, and other locale-specific standards. The ability to setup a default locale is a great built-in privilege of using a <code>UNIX</code>-like operating system.<br />
<br />
By default /etc/locale.gen is an empty file with commented documentation. Once edited, the file remains untouched. '''locale-gen''' runs on every '''glibc''' upgrade, generating all the locales specified in /etc/locale.gen.<br />
<br />
Choose the locale(s) you need (remove the # in front of the lines you want), e.g.:<br />
en_US ISO-8859-1<br />
en_US.UTF-8 <br />
<br />
The installer will now run the locale-gen script, which will generate the locales you specified. You may change your locale in the future by editing /etc/locale.gen and subsequently running 'locale-gen' as root.<br />
<br />
{{Box Note |'''''If you fail to choose your locale, this will lead to a "The current locale is invalid..." error. This is perhaps the most common mistake by new Arch users, and also leads to the most commonly asked questions on the forum.'''''}}<br />
<br />
=====Root password=====<br />
Finally, set a root password and make sure that you remember it later. Return to the main menu and continue with installing bootloader.<br />
<br />
=====Pacman-Mirror=====<br />
Choose a mirror repository for '''pacman'''. <br />
*''archlinux.org is throttled, limiting downloads to 50KB/s'' <br />
<br />
Return to the main menu.<br />
<br />
===Install Bootloader===<br />
Because we have no secondary operating system in our example, we will need a bootloader. [http://www.gnu.org/software/grub/ GNU GRUB] is the recommended bootloader. Alternatively, you may choose [http://lilo.go.dyndns.org/ LILO]. <br />
====GRUB====<br />
The provided '''GRUB''' configuration ('''/boot/grub/menu.lst''') should be sufficient, but verify its contents to ensure accuracy. You may want to alter the resolution of the console by adding a vga=<number> kernel argument corresponding to your desired virtual console resolution. (A table of resolutions and the corresponding numbers is printed in the menu.lst.)<br />
<br />
Example: <br />
title Arch Linux (Main)<br />
root (hd0,0) <br />
kernel /boot/vmlinuz26 root=/dev/disk/by-uuid/0ec1-9339.. ro vga=773<br />
initrd /boot/kernel26.img<br />
{{Box Note | ''The linux kernel, 'vmlinuz', is so named because it incorporated '''v'''irtual '''m'''emory capability early in its development. The '''z''' denotes a zipped (compressed) image.''}}<br />
<br />
Explanation:<br />
<br />
Line 1: '''title''': A printed menu selection. "Arch Linux (Main)" will be printed on the screen as a menu selection.<br />
<br />
Line 2: '''root''': '''GRUB''''s root; the drive and partition where the kernel (/boot) resides, according to system BIOS. (More accurately, where GRUB's stage2 file resides). '''NOT necessarily the root''' (/) file system, as they can reside on separate partitions. GRUB's numbering scheme starts at 0, and uses an hd''x,x'' format regardless of IDE or SATA, and enclosed within parentheses. <br />
<br />
The example indicates that /boot is on the first partition of the first drive, according to BIOS, or, (hd0,0).<br />
<br />
Line 3: '''kernel''': This line specifies:<br />
<br />
* The path and filename of the kernel '''''relative to GRUB's root'''''.<br />
In the example, /boot is merely a directory residing on the same partition as / and '''vmlinuz26''' is the kernel filename; '''/boot/vmlinuz26'''. ''If /boot were on a separate partition, the path and filename would be simply '''/vmlinuz26''', being relative to '''GRUB''''s root.'' <br />
<br />
* The root= argument to the kernel statement specifies the partition containing the root (/) directory in the booted system, (more accurately, the partition containing '''/sbin/init'''), ''according to the UUID numbering scheme'' as of 2008-04rc, which uses the /dev/disk/by-uuid/xxxx-xxxx-xxxx format. <br />
<br />
*An easy way to distinguish the 2 appearances of 'root' in /boot/grub/menu.lst is to remember that the first root statement ''informs GRUB where the kernel resides'', whereas the second root= kernel argument ''tells the kernel where the root filesystem (/) resides''.<br />
<br />
* Kernel options. <br />
<br />
In our example, '''ro''' mounts the filesystem as read only during startup, and the '''"vga=773"''' argument will give a 1024x768 framebuffer with 256 color depth.<br />
<br />
Line 4: '''initrd''': (For Initial RAM disk) The path and filename of the initial RAM filesystem '''relative to GRUB''''s root. Again, in the example, /boot is merely a directory residing on the same partition as / and '''kernel26.img''' is the initrd filename; '''/boot/kernel26.img'''. ''If /boot were on a separate partition, the path and filename would be simply '''/kernel26.img''', being relative to '''GRUB''''s root.'' <br />
<br />
Install the '''GRUB''' bootloader to the master boot record, (sda in our example).<br />
<br />
===Reboot===<br />
<br />
That's it; You have configured and installed your Arch Linux base system. Exit the install, and reboot:<br />
<br />
# reboot<br />
(Be sure to remove the installer CD)<br />
<br />
Your new Arch Linux system will boot up and finish with a login prompt (you may want to change the boot order in your '''BIOS''' back to booting from hard disk).<br />
<br />
'''Congratulations, and welcome to your shiny, new Arch Linux base system!'''<br />
<br />
Your new Arch Linux base system is now a functional GNU/Linux environment ready for customization. From here, you may build this elegant set of tools into whatever you wish or require for your purposes. <br />
<br />
Login with the root account. We will configure pacman and update the system as root, then add a normal user. <br />
{{Box Note |Virtual consoles 1-6 are available.}}<br />
<br />
===Configuring the network (if necessary)===<br />
*''This section will assist you in configuring most types of networks, if your network configuration is not working for you.''<br />
<br />
If you properly configured your system, you should have a working network. Try to ping www.google.com to verify this.<br />
# ping -c 3 www.google.com<br />
<br />
''If you have successfully established a network connection, continue with '''[[#Update, Sync and Upgrade the system with pacman|Update, Sync and Upgrade the system with pacman]]'''.''<br />
<br />
If, after trying to ping www.google.com, you get an "unknown host" error, you may conclude that your network is not properly configured. You may choose to double-check the following files for integrity and proper settings:<br />
<br />
'''/etc/rc.conf''' # Specifically, check your HOSTNAME= and NETWORKING section for typos and errors.<br />
<br />
'''/etc/hosts''' # Double-check your format. (See above.)<br />
<br />
'''/etc/resolv.conf''' # If you are using a static IP. If you are using DHCP, this file will be dynamically created and destroyed by default, but can be changed to your preference. (See [[Network]].)<br />
<br />
Advanced instructions for configuring the network can be found in the [[Network]] article.<br />
<br />
====Wired LAN====<br />
<br />
Check your Ethernet with<br />
# ifconfig -a<br />
All interfaces will be listed. You should see an entry for eth0, or perhaps eth1. <br />
*'''Static IP'''<br />
<br />
If required, you can set a new static IP with:<br />
# ifconfig eth0 <ip address> netmask <netmask> up <br />
and the default gateway with<br />
# route add default gw <ip address of the gateway><br />
Verify that /etc/resolv.conf contains your DNS server and add it if it is missing. <br />
Check your network again with ping www.google.com. If everything is working now, adjust /etc/rc.conf as described above for static IP. <br />
*'''DHCP'''<br />
If you have a DHCP server/router in your network try:<br />
# dhcpcd eth0<br />
If this is working, adjust /etc/rc.conf as described above, for dynamic IP.<br />
<br />
====Wireless LAN====<br />
* Ensure the driver has created a usable interface:<br />
# iwconfig<br />
* Bring the interface up with <code>ifconfig <interface> up</code>. e.g.:<br />
# ifconfig ath0 up<br />
* (Optional) Scan for available access points:<br />
# iwlist ath0 scan | less<br />
* Specify the id of the wireless network with <code>iwconfig <interface> essid <youressid></code>. Or, if using WEP; <code>iwconfig <interface> essid <youressid> key <yourwepkey></code>, e.g.:<br />
# iwconfig ath0 essid linksys key 0241baf34c<br />
* Request an IP address with <code>dhcpcd <interface></code>. e.g.:<br />
# dhcpcd ath0<br />
* Ensure you can route:<br />
$ ping -c 3 www.google.com<br />
Done.<br />
<br />
Detailed setup guide: [[Wireless Setup]]<br />
<br />
====Analog Modem====<br />
To be able to use a Hayes-compatible, external, analog modem, you need to at least have the ppp package installed. Modify the file /etc/ppp/options to suit your needs and according to man pppd. You will need to define a chat script to supply your username and password to the ISP after the initial connection has been established. The manpages for pppd and chat have examples in them that should suffice to get a connection up and running if you're either experienced or stubborn enough. With udev, your serial ports usually are /dev/tts/0 and /dev/tts/1.<br />
Tip: Read [[Dialup without a dialer HOWTO]].<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt to install wvdial or a similar tool to ease the setup process considerably. In case you're using a so-called WinModem, which is basically a PCI plugin card working as an internal analog modem, you should indulge in the vast information found on the [http://www.linmodems.org/ LinModem] homepage.<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, meaning that you will not need to recompile your kernel unless you're about to use rather odd ISDN hardware. After physically installing your ISDN card in your machine or plugging in your USB ISDN-Box, you can try loading the modules with modprobe. Nearly all passive ISDN PCI cards are handled by the hisax module, which needs two parameters: type and protocol. You must set protocol to '1' if your country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3' if you're hooked to a so-called leased-line without D-channel, and '4' for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the kernel documentation, more specifically in the isdn subdirectory, and available online. The type parameter depends on your card; a list of all possible types can be found in the README.HiSax kernel documentation. Choose your card and load the module with the appropriate options like this:<br />
<br />
# modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my ELSA Quickstep 1000PCI, being used in Germany with the EDSS1 protocol. You should find helpful debugging output in your /var/log/everything.log file, in which you should see your card being prepared for action. Please note that you will probably need to load some USB modules before you can work with an external USB ISDN Adapter.<br />
<br />
Once you have confirmed that your card works with certain settings, you can add the module options to your /etc/modprobe.conf:<br />
<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively, you can add only the options line here, and add hisax to your MODULES array in the rc.conf. It's your choice, really, but this example has the advantage that the module will not be loaded until it's really needed.<br />
<br />
That being done, you should have working, supported hardware. Now you need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl; it'll get you started. Further down in the manpage you will find explanations on how to create a configuration file that can be parsed by isdnctrl, as well as some helpful setup examples. Please note that you have to add your SPID to your MSN setting separated by a colon if you use US NI1.<br />
<br />
After you have configured your ISDN card with the isdnctrl utility, you should be able to dial into the machine you specified with the PHONE_OUT parameter, but fail the username and password authentication. To make this work add your username and password to /etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were configuring a normal analogous PPP link, depending on which protocol your ISP uses for authentication. If in doubt, put your data into both files.<br />
<br />
If you set up everything correctly, you should now be able to establish a dial-up connection with<br />
# isdnctrl dial ippp0<br />
as root. If you have any problems, remember to check the logfiles!<br />
<br />
====DSL (PPPoE)====<br />
<br />
These instructions are relevant to you only if your PC itself is supposed to manage the connection to your ISP. You do not need to do anything but define a correct default gateway if you are using a separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to physically install the network card that is supposed to be connected to the DSL-Modem into your computer. After adding your newly installed network card to the modules.conf/modprobe.conf or the MODULES array, you should install the rp-pppoe package and run the pppoe-setup script to configure your connection. After you have entered all the data, you can connect and disconnect your line with<br />
<br />
# /etc/rc.d/adsl start<br />
<br />
and<br />
<br />
# /etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward, but feel free to read the manpages for hints. If you want to automatically 'dial in' on boot-up, add adsl to your DAEMONS array.<br />
<br />
===Update, Sync and Upgrade the system with [[pacman]]===<br />
Now we will update the system using [[pacman]]. <br />
<br />
====What is pacman ?====<br />
[[Pacman]] is the '''pac'''kage '''man'''ager of Arch Linux. Pacman is written in ''C'' and is designed from the ground up to be lightweight with a very modest memory footprint, fast, simple, and versatile. It manages your entire package system and handles installation, removal, package downgrade (through cache), custom compiled package handling, automatic dependency resolution, remote and local searches and much more. Arch uses the .tar.gz package format, which further enhances pacman's speed; Gzipped tarballs, though slightly larger, are decompressed many times faster than their Bzipped counterparts, and are therefore installed much more expediently. <br />
<br />
We will use pacman to download software packages from remote repositories and install them onto your system.<br />
<br />
Pacman is the most important tool in your Arch Linux toolbox for building the base system into whatsoever you please.<br />
<br />
====Configuring pacman====<br />
<br />
=====Package Repositories and /etc/pacman.conf=====<br />
Arch currently offers the following 4 repositories readily accessible through pacman:<br />
<br />
'''[core]'''<br />
<br />
The simple principle behind [core] is to provide only one of each necessary tool for a base Arch Linux system; The GNU toolchain, the Linux kernel, one editor, one command line browser, etc. (There are a few exceptions to this. For instance, both vi and nano are provided, allowing the user to choose one or both.) It contains all the packages that MUST be in perfect working order to make sure your system continues to run. These are the absolute system-critical packages. Developer maintained.<br />
<br />
*''The Core installation media simply contains an installer script, and a snapshot of the core repository at the time of release.''<br />
<br />
'''[extra]'''<br />
<br />
The [extra] repository contains all Arch packages that are not themselves necessary for a base Arch system, but contribute to a more full-featured environment. '''X''', KDE, and Apache, for instance, can be found here. Developer maintained.<br />
<br />
'''[testing]'''<br />
<br />
The [testing] repository contains packages that are candidates for the [core] or [extra] repositories. New packages go into [testing] if:<br />
* they are expected to break something on update and need to be tested first<br />
* they require other packages to be rebuilt. In this case, all packages that need to be rebuilt are put into [testing] first and when all rebuilds are done, they are moved back to the other repositories. Developer maintained.<br />
<br />
[testing] is the only repository that can have name collisions with any of the other official repositories. <br />
<br />
<font color="blue">*If enabled, [testing] must be the first repo listed in your ''pacman.conf'' file.</font><br />
<br />
<font color="red">'''WARNING''': '''''Your system may break after you update with [testing] enabled. Only experienced users should use it.'''''</font><br />
<br />
'''[community]'''<br />
<br />
The [community] repository is maintained by the ''Trusted Users (TUs)'' and is part of the ''Arch User Repository ([[AUR]])''. It contains binary packages from the ''AUR'' that have enough votes and were adopted by a ''TU''. Like all repos listed above, [community] may be readily accessed by pacman.<br />
<br />
The '''[[AUR]]''' also contains the '''unsupported''' branch, which cannot be accessed directly by pacman*. [unsupported] contains more than eight thousand PKGBUILD scripts for building packages from source, that may be unavailable through the other repos. <br />
<br />
<nowiki>*</nowiki> '''''[[AUR Helpers]]''''' can help you seamlessly access AUR.<br />
<br />
'''/etc/pacman.conf'''<br />
<br />
pacman will attempt to read /etc/pacman.conf each time it is invoked. This configuration file is divided into sections, or repositories. Each section defines a package [[Official Repositories|repository]] that pacman can use when searching for packages. The exception to this is the options section, which defines global options.<br />
# nano /etc/pacman.conf<br />
Example:<br />
#<br />
# /etc/pacman.conf<br />
#<br />
# See the pacman.conf(5) manpage for option and repository directives<br />
<br />
#<br />
# GENERAL OPTIONS<br />
#<br />
[options]<br />
# The following paths are commented out with their default values listed.<br />
# If you wish to use different paths, uncomment and update the paths.<br />
#RootDir = /<br />
#DBPath = /var/lib/pacman/<br />
#CacheDir = /var/cache/pacman/pkg/<br />
#LogFile = /var/log/pacman.log<br />
HoldPkg = pacman glibc<br />
# If upgrades are available for these packages they will be asked for first<br />
SyncFirst = pacman<br />
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u<br />
#XferCommand = /usr/bin/curl %u > %o<br />
<br />
# Pacman won't upgrade packages listed in IgnorePkg and members of IgnoreGroup<br />
#IgnorePkg =<br />
#IgnoreGroup =<br />
<br />
#NoUpgrade =<br />
#NoExtract =<br />
<br />
# Misc options (all disabled by default)<br />
#NoPassiveFtp<br />
#UseSyslog<br />
#ShowSize<br />
#UseDelta<br />
#TotalDownload<br />
ILoveCandy<br />
#<br />
# REPOSITORIES<br />
# - can be defined here or included from another file<br />
# - pacman will search repositories in the order defined here<br />
# - local/custom mirrors can be added here or in separate files<br />
# - repositories listed first will take precedence when packages<br />
# have identical names, regardless of version number<br />
# - URLs will have $repo replaced by the name of the current repo<br />
#<br />
# Repository entries are of the format:<br />
# [repo-name]<br />
# Server = ServerName<br />
# Include = IncludePath<br />
#<br />
# The header [repo-name] is crucial - it must be present and<br />
# uncommented to enable the repo.<br />
# <br />
<br />
# Testing is disabled by default. To enable, uncomment the following<br />
# two lines. You can add preferred servers immediately after the header,<br />
# and they will be used before the default mirrors.<br />
#[testing]<br />
#Include = /etc/pacman.d/mirrorlist<br />
<br />
[core]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
<br />
[extra]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist <br />
<br />
[community]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
<br />
# An example of a custom package repository. See the pacman manpage for<br />
# tips on creating your own repositories.<br />
#[custom]<br />
#Server = file:///home/custompkgs<br />
<br />
Enable all desired repositories (remove the # in front of the 'Include =' and '[repository]' lines).<br />
<br />
<br />
*'''''When choosing repos, be sure to uncomment both the repository header lines in [brackets] as well as the 'Include =' lines. Failure to do so will result in the selected repository being omitted! This is a very common error.'' '''<br />
<br />
=====/etc/pacman.d/mirrorlist=====<br />
Faster mirrors will dramatically improve pacman performance, and your overall Arch Linux experience.<br />
<br />
Edit /etc/pacman.d/mirrorlist:<br />
# nano /etc/pacman.d/mirrorlist<br />
Remove all mirrors which are not on your continent, or are extremely distant. (Using nano, you may use CTRL-K to cut each unneeded line.) <br />
<br />
Edit /etc/pacman.d/mirrorlist by placing the best mirror at the top of the list. (Recall that archlinux.org is throttled to 50KB/s). If using nano, you can cut a line with CTRL-K and paste with CTRL-U. <br />
<br />
After changing mirrors, issue the following command:<br />
# pacman -Syy<br />
Passing two --refresh or -y flags forces a refresh of all package lists even if they are considered by pacman to be up to date. Issuing pacman -Syy ''whenever a mirror is changed'', is good practice and will avoid possible headaches.<br />
<br />
=====Ignoring packages=====<br />
When you execute the command "pacman -Syu", your entire system will be updated. It is possible that you want to prevent a package from being upgraded. An example could be the kernel (kernel26) or a package for which an upgrade may prove problematic for your system. In this case, you have two options; indicate the packages you want to skip in the pacman command line using the --ignore switch (do pacman -S --help for details) or permanently indicate the packages you want to skip in your /etc/pacman.conf file:<br />
<br />
IgnorePkg = kernel26<br />
The typical way to use Arch is to use pacman to install all packages unless there is no package available, in which case you can build your own package using [[ABS]]. Many user-contributed package build scripts are also available in the [[AUR]]. <br />
<br />
You are expected to keep your system up to date with pacman -Syu, rather than selectively upgrading packages. You may diverge from this typical usage as you wish; just be warned that there is a greater chance that things will not work as intended and that it could break your system. The majority of complaints happen when selective upgrading, unusual compilation or improper software installation is performed. Use of '''IgnorePkg''' in /etc/pacman.conf is therefore discouraged, and should only be used sparingly, if you know what you are doing.<br />
<br />
=====Ignoring Configuration Files=====<br />
In the same vein, you can also "protect" your configuration/system files from being overwritten during "pacman -Su" using the following option in your /etc/pacman.conf<br />
<br />
NoUpgrade = etc/lilo.conf boot/grub/menu.lst<br />
<br />
===Update System===<br />
You are now ready to upgrade your entire system. Before you do, read through the [http://www.archlinux.org/news/ news] (and optionally the [http://archlinux.org/pipermail/arch-announce/ announce mailing list]). Often the developers will provide important information about fixes for known issues. Consulting these pages before any upgrade is good practice. <br />
<br />
Sync, refresh, and '''upgrade''' your entire new system with:<br />
# pacman -Syu<br />
you may also use:<br />
# pacman --sync --refresh --sysupgrade<br />
<br />
pacman will now download a fresh copy of the master package list from the server(s) defined in pacman.conf(5) and perform all available upgrades. (You may be prompted to upgrade pacman itself at this point. If so, say yes, and then reissue the pacman -Syu command when finished.) <br />
Reboot if a kernel upgrade has occurred. <br />
{{Box Note|'''''Occasionally, configuration changes may take place requiring user action during an update; read pacman's output for any pertinent information.'''''}}<br />
If the messages go by too fast to read, you can look at them later at /var/log/pacman.log.<br />
<br />
=====The beauty of the Arch rolling release model=====<br />
Keep in mind that Arch is a '''rolling release''' distribution. This means there is never a reason to reinstall or perform elaborate system rebuilds to upgrade to the newest version. Simply issuing '''pacman -Syu''' periodically keeps your entire system up-to-date and on the bleeding edge. At the end of this upgrade, your system is completely current. <br />
Reboot if a kernel upgrade has occurred.<br />
<br />
====Get familiar with pacman====<br />
Pacman is the Arch user's best friend. It is highly recommended to study and learn how to use the pacman(8) tool. Try:<br />
man pacman<br />
Check out the bottom of this article, and look up the [[pacman]] wiki entries at your leisure.<br />
<br />
===Add a user and setup groups===<br />
<code>UNIX</code> is a multi-user environment. You should not do your everyday work using the root account. It is more than poor practice; it is dangerous. Root is for administrative tasks. Instead, add a normal, non-root user account using the <code>/usr/sbin/useradd</code> program:<br />
# useradd -m -G [groups] -s [login_shell] [username] <br />
* '''-m''' Creates user home directory as /home/'''username'''. Within their home directory, a user can write files, delete them, install programs, etc. Users' home directories shall contain their data and personal configuration files, the so-called 'dot files' (their name is preceded by a dot), which are 'hidden'. (To view dotfiles, enable the appropriate option in your file manager or run ls with the -a switch.) If there is a conflict between ''user'' (under /home/username) and ''global'' configuration files, (usually under /etc/) the settings in the ''user'' file will prevail. Dotfiles likely to be altered by the end user include .xinitrc and .bashrc files. The configuration files for xinit and Bash respectively. They allow the user the ability to change the window manager to be started upon login and also aliases, user-specified commands and environment variables respectively. When a user is created, their dotfiles shall be taken from the /etc/skel directory where system sample files reside.<br />
* '''-G''' A list of supplementary groups which the user is also a member of. ''Each group is separated from the next by a comma, with no intervening spaces''. The default is for the user to belong only to the initial group (users). <br />
* '''-s''' The name of the user´s login shell. Leaving this field blank will cause the system to select the default login shell.<br />
Useful groups for your non-root user include:<br />
*'''audio''' - for tasks involving sound card and related software<br />
*'''floppy''' - for access to a floppy if applicable<br />
*'''lp''' - for managing printing tasks<br />
*'''optical''' - for managing tasks pertaining to the optical drive(s)<br />
*'''storage''' - for managing storage devices<br />
*'''video''' - for video tasks and 3d acceleration<br />
*'''wheel''' - for using sudo/su<br />
*'''power''' - used w/ power options (ie. shutdown w/ off button) <br />
A typical example, adding a user named "archie" specifying bash as the login shell:<br />
# useradd -m -G users,audio,lp,optical,storage,video,wheel,power -s /bin/bash archie<br />
Next, add a password for your new user using <code>/usr/bin/passwd</code>.<br />
<br />
An example for our user, 'archie':<br />
# passwd archie<br />
(You will be prompted to provide the new <code>UNIX</code> password.)<br />
<br />
Your new non-root user has now been created, complete with a home directory and a login password.<br />
<br />
'''Alternative method, using <code>/usr/sbin/adduser</code>:'''<br />
<br />
Alternatively, you may use <code>adduser</code>, an interactive user adding program which will prompt you for the above data:<br />
# adduser<br />
<br />
See the [[Groups]] article and check the man pages for <code>usermod(8)</code> and <code>gpasswd(8)</code> for further information.<br />
<br />
In the event of error, or if you wish to delete this user account in favor of a different name or for any other reason, use <code>/usr/sbin/userdel</code>:<br />
# userdel -r [username]<br />
* '''-r ''' Files in the user´s home directory will be removed along with the home directory itself and the user´s mail spool.<br />
<br />
===Install and setup Sudo (Optional)===<br />
To install Sudo:<br />
# pacman -S sudo<br />
To add a user as a sudo user (a "sudoer"), the visudo command must be run as root. If you do not know how to use vi, you may set the EDITOR environment variable to the editor of your choice before running visudo. e.g.:<br />
# EDITOR=nano visudo<br />
If you are comfortable using vi, issue the visudo command without the EDITOR=nano variable:<br />
# visudo<br />
This will open the file /etc/sudoers in a special session of vi. visudo copies the file to be edited to a temporary file, edits it with an editor, (vi by default), and subsequently runs a sanity check. If it passes, the temporary file overwrites the original with the correct permissions. <br />
<br />
<font color="red">'''WARNING: Do not edit /etc/sudoers directly with an editor; Errors in syntax can cause annoyances (like rendering the root account unusable). You must use the ''visudo'' command to edit /etc/sudoers.'''</font><br />
<br />
To give the user full root privileges when he/she precedes a command with "sudo", add the following line:<br />
USER_NAME ALL=(ALL) ALL<br />
where USER_NAME is the username of the individual.<br />
<br />
For more information, such as sudoer <TAB> completion, see [[Sudo]]<br />
<br />
==Part II: Install X and configure ALSA==<br />
<br />
<br />
===Configure the audio card with alsamixer===<br />
The Advanced Linux Sound Architecture (known by the acronym '''ALSA''') is a Linux kernel component intended to replace the original Open Sound System (OSS) for providing device drivers for sound cards. Besides the sound device drivers, '''ALSA''' also bundles a user space library for application developers who want to use driver features with a higher level API than direct interaction with the kernel drivers. <br />
-----<br />
{{Box Note| Alsa is included in the Arch mainline kernel and udev will automatically probe your hardware on boot-up, loading the corresponding kernel module for your audio card. Therefore, your sound should already be working, but is muted by default.}} <br />
The alsa-utils package contains the alsamixer userspace tool, which will allow us to configure the sound device from the console. (You may also run alsamixer from an '''X''' environment later.)<br />
<br />
Install the alsa-utils package:<br />
# pacman -S alsa-utils<br />
Did you add your normal user to the audio group? If not, use <code>/usr/bin/gpasswd</code>. As root do:<br />
# gpasswd -a ''yourusername'' audio<br />
As '''''normal, non-root''''' user, invoke <code>/usr/bin/alsamixer</code>:<br />
# su - ''yourusername'' <br />
'''$''' alsamixer<br />
Unmute the Master and PCM channels by scrolling to them with cursor left/right and pressing '''M'''. Increase the volume levels with the cursor-up key. (70-90 Should be a safe range.) Some machines, (like the Thinkpad T61), have a '''Speaker''' channel which must be unmuted and adjusted as well. Leave alsamixer by pressing ESC. <br />
==== Sound Test ====<br />
Ensure your speakers are properly connected, and test your sound configuration as normal user using <code>/usr/bin/aplay</code>:<br />
$ aplay /usr/share/sounds/alsa/Front_Center.wav<br />
You should hear a very eloquent woman say, "Front, center."<br />
<br />
Then run <code>/usr/bin/alsactl</code> as root:<br />
$ su -<br />
# alsactl store<br />
This will create '/etc/asound.state', saving the alsamixer settings. <br />
<br />
Also, add the alsa ''daemon'' to your DAEMONS section in /etc/rc.conf to automatically restore the mixer settings on boot-up.<br />
# nano /etc/rc.conf<br />
DAEMONS=(syslog-ng network crond '''alsa''')<br />
''Note that the alsa daemon merely restores your volume mixer levels on boot up by reading /etc/asound.state. It is separate from the alsa audio library (and kernel level API).''<br />
<br />
Expanded information available in the [[ALSA]] wiki entry.<br />
<br />
===Installing and configuring X===<br />
The '''X''' Window System (commonly '''X11''', or just simply '''X''') is a networking and display protocol which provides windowing on bitmap displays. It provides the standard toolkit and protocol to build graphical user interfaces (GUIs) on <code>UNIX</code>-like operating systems.<br />
<br />
'''X''' provides the basic framework, or primitives, for building GUI environments: drawing and moving windows on the screen and interacting with a mouse and/or keyboard. '''X''' does not mandate the user interface — individual client programs handle this. <br />
<br />
'''X''' is so named because it was preceded by the '''W''' Window System, originally developed at Stanford University. <br />
-----<br />
<br />
{{Box Note| If you plan on using an '''open-source''' video driver, and need 3d acceleration, it is recommended to install the libgl library before installing Xorg:}}<br />
# pacman -S libgl<br />
''(Proprietary video drivers provide their own gl library implementations.)''<br />
----- <br />
Now we will install the base Xorg packages using pacman. This is the first step in building a GUI.<br />
<br />
# pacman -S xorg<br />
3d utilities such as glxgears are included in the '''mesa''' package:<br />
# pacman -S mesa<br />
<br />
Now we have the base packages we need for running the '''X''' Server. You should add the driver for your graphics card now (e.g. xf86-video-<name>). The easiest way to configure X.org is by installing the correct driver packages first, and then generating /etc/X11/xorg.conf using an autoconfiguration script, like Xorg -configure.<br />
<br />
You will need knowledge of which video chipset your machine has. If you do not know, use the <code>/usr/sbin/lspci</code> program:<br />
# lspci | grep VGA<br />
<br />
If you need a list of all '''open-source''' video drivers, do: <br />
# pacman -Ss xf86-video | less<br />
Here is a list of '''open source''' drivers, and the corresponding video chipsets.<br />
*'''xf86-video-apm''' Alliance ProMotion video driver<br />
*'''xf86-video-ark''' ark video driver<br />
*'''xf86-video-ati''' ATI(AMD) video driver<br />
*'''xf86-video-chips''' Chips and Technologies video driver<br />
*'''xf86-video-cirrus''' Cirrus Logic video driver<br />
*'''xf86-video-dummy''' dummy video driver<br />
*'''xf86-video-fbdev''' framebuffer video driver<br />
*'''xf86-video-glint''' GLINT/Permedia video driver<br />
*'''xf86-video-i128''' Number 0 i128 video driver<br />
*'''xf86-video-i740''' Intel i740 video driver<br />
*'''xf86-video-i810''' Intel i810/i830/i9xx video drivers (deprecated - use -intel)<br />
*'''xf86-video-intel''' Newer Version of Intel i810/i830/i9xx video drivers<br />
*'''xf86-video-imstt''' Integrated Micro Solutions Twin Turbo vidoe driver<br />
*'''xf86-video-mga''' mga video driver (Matrox Graphics Adapter)<br />
*'''xf86-video-neomagic''' neomagic video driver<br />
*'''xf86-video-nv''' Nvidia nv video driver<br />
*'''xf86-video-rendition''' Rendition video driver<br />
*'''xf86-video-s3''' S3 video driver<br />
*'''xf86-video-s3virge''' S3 Virge video driver<br />
*'''xf86-video-savage''' savage video driver<br />
*'''xf86-video-siliconmotion''' siliconmotion video driver<br />
*'''xf86-video-sis''' SiS video driver<br />
*'''xf86-video-sisusb''' SiS USB video driver<br />
*'''xf86-video-tdfx''' tdfx video driver<br />
*'''xf86-video-trident''' Trident video driver<br />
*'''xf86-video-tseng''' tseng video driver<br />
*'''xf86-video-unichrome''' VIA S3 Unichrome video drivers<br />
*'''xf86-video-v4l''' v4l video driver<br />
*'''xf86-video-vesa''' vesa video driver<br />
*'''xf86-video-openchrome (testing)''' via video driver (currently in testing, try openchrome in the meantime)<br />
*'''xf86-video-vga''' VGA 16 color video driver<br />
*'''xf86-video-vmware ''' vmware video driver<br />
*'''xf86-video-voodoo ''' voodoo video driver<br />
<br />
* Note that the '''vesa''' driver is the most generic, and should work with almost any modern video chipset. If you cannot find a suitable driver for your video chipset, vesa '''should''' work.<br />
<br />
*If you have an NVIDIA or ATI video adapter, you may wish to install the proprietary NVIDIA or ATI drivers. '''Installing proprietary video drivers is covered [[#Using proprietary Graphics Driver (NVIDIA, ATI)|below]].'''<br />
<br />
Use pacman to install the appropriate video driver for your video card/onboard video. e.g.:<br />
# pacman -S xf86-video-savage<br />
(for the Savage driver.)<br />
<br />
===Create /etc/X11/xorg.conf===<br />
=====What is /etc/X11/xorg.conf?=====<br />
/etc/X11/xorg.conf is the main configuration file for your '''X''' Window System, the foundation of your '''G'''raphical '''U'''ser '''I'''nterface. It is a plain text file ordered into sections and subsections. Important sections are ''Files, InputDevice, Module, Monitor, Modes, Screen, Device, and ServerLayout''. Sections can appear in any order and there may be more than one section of each kind, for example, if you have more than one monitor, or if your laptop has a trackpoint as well as a mouse. <br />
------<br />
By default, you will not have an Xorg config file, as the newest versions of Xorg feature autodetection. ''If'' the autodetection ''works satisfactorily'' and you do not need to specify special features such as aiglx, compositing and so forth, you may forgo creating an xorg.conf file. <br />
<br />
''Most people will still find that they need to generate a config file, however.''<br />
<br />
Advanced users may wish to manually create their own xorg.conf file. You may also use the <code>/usr/bin/Xorg</code> program with the -configure option to generate a basic config file; As root, do:<br />
# Xorg -configure<br />
This will create a config file at /root/xorg.conf.new <br />
<br />
To test the server, run:<br />
# X -config /root/xorg.conf.new<br />
'''X''' should start with the white hollow vector '''X''' in the center of the screen, which should respond to mouse, trackpoint or touchpad movement. Use CTRL-Alt-Backspace to exit '''X'''.<br />
<br />
Inspect your config file in case of errors:<br />
<br />
# nano /root/xorg.conf.new<br />
<br />
Ensure the Xorg -configure script has correctly specified your video driver. e.g.:<br />
Section "Device"<br />
<br />
...<br />
<br />
Driver "savage"<br />
<br />
...<br />
<br />
EndSection<br />
<br />
Ensure there are horizontal sync and vertical refresh specs under section "Monitor". If not, add them:<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
VendorName "Monitor Vendor"<br />
ModelName "Monitor Model"<br />
HorizSync 30.0 - 130.0 # Safe for LCD's<br />
VertRefresh 50.0 - 100.0 # Safe for LCD's and most CRT's.<br />
EndSection<br />
(If you do not know these specs, consult your monitor's documentation.)<br />
<br />
Specify your default color depth under section "Screen":<br />
Section "Screen"<br />
Identifier "Screen0"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
(Typically, this will be set to 24 for true color.)<br />
<br />
Also add your desired Modes to your "Display" subsection, at least under the Depth 24 header, e.g.:<br />
SubSection "Display"<br />
Viewport 0 0<br />
Depth 24<br />
Modes "1024x768" "800x600" "640x480"<br />
Add the following section, if you wish to enable eye candy which requires the composite extension: <br />
Section "Extensions"<br />
Option "Composite" "Enable"<br />
EndSection<br />
Try your config again, after modifying:<br />
# X -config /root/xorg.conf.new<br />
Ensure an '''X''' session opens, without errors, and copy or move the generated config file to /etc/X11/:<br />
# cp /root/xorg.conf.new /etc/X11/xorg.conf<br />
Detailed instructions in the [[Xorg]] article.<br />
<br />
====Alternative xorg.conf generation====<br />
* Note that if your machine has a successfully configured xorg.conf under another distribution, you may easily copy it over to your current Arch system.<br />
* If Xorg -configure is not generating a usable xorg.conf, you may alternatively use the <code>/usr/bin/hwd</code> tool. Install with:<br />
# pacman -S hwd<br />
And run with<br />
# hwd -xa<br />
* You may also try the <code>/usr/bin/xorgcfg</code> script:<br />
# xorgcfg <br />
* Lastly, you may choose <code>/usr/bin/xorgconfig</code>, which will interactively prompt you for hardware information to create a basic xorg.conf:<br />
# xorgconfig<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
===Using proprietary Graphics Driver (NVIDIA, ATI)===<br />
You may choose to use the proprietary video drivers from NVIDIA or ATI. <br />
====NVIDIA Graphic Cards====<br />
The NVIDIA proprietary drivers are generally considered to be of good quality, and offer 3D performance, whereas the open source '''nv''' driver offers only 2d support at this time. <br />
<br />
Before you configure your Graphics Card you will need to know which driver fits. Arch currently has several different driver packages that each match a certain subset of Cards: <br />
<br />
'''1. nvidia-71xx''' ''for very old Cards like TNT and TNT2''<br />
<br />
'''2. nvidia-96xx''' ''slightly newer cards up to the GF 4''<br />
<br />
'''3. nvidia-173xx''' ''Geforce FX series cards''<br />
<br />
'''4. nvidia''' ''newest GPUs after the GF FX''<br />
<br />
Consult the NVIDIA-Homepage to see which one is for you. The difference is only for the installation; Configuration works the same with every driver.<br />
<br />
Select and install the appropriate NVIDIA driver ''for your card'', e.g.: <br />
# pacman -S nvidia-96xx<br />
<br />
The NVIDIA package has a utility for updating your existing /etc/X11/xorg.conf for use with the NVIDIA driver:<br />
# nvidia-xconfig<br />
<br />
It also has several options which will further specify the contents and options of the xorg.conf file.<br />
For example,<br />
# nvidia-xconfig --composite --add-argb-glx-visuals<br />
<br />
For more detailed information, see nvidia-xconfig(1).<br />
<br />
Some useful tweaking options in the device section are (beware that these may not work on your system):<br />
Option "RenderAccel" "true"<br />
Option "NoLogo" "true"<br />
Option "AGPFastWrite" "true"<br />
Option "EnablePageFlip" "true"<br />
Make sure all instances of DRI are commented out:<br />
# Load "dri"<br />
Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
Update kernel module dependencies using <code>/sbin/depmod</code>:<br />
# depmod -a<br />
(A reboot may be necessary.)<br />
Advanced instructions for nvidia configuration can be found in the [[NVIDIA]] article.<br />
<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
====ATI Graphic Cards====<br />
ATI owners have two options for drivers. If you are unsure which driver to use, please try the open-source one first. The open-source driver will suit most needs along with being generally less problematic.<br />
<br />
Install the '''proprietary''' ATI Driver with<br />
# pacman -S catalyst<br />
Use the aticonfig tool to modify the xorg.conf.<br />
<br />
Install the '''open-source''' ATI Driver with<br />
# pacman -S xf86-video-ati<br />
Currently, the performance of the open-source driver is not on par with that of the proprietary one. It also lacks TV-out, dual-link DVI support, and possibly other features. On the other hand, it supports Aiglx and has better dual-head support.<br />
{{Box Note| The latest proprietary driver does support [[AIGLX]] now. To use [[Compiz]] or [[Beryl]] add Option "AIGLX" "True" to Section ServerFlags and Option "Composite" "True" to Section Extensions.}}<br />
Advanced instructions for ATI configuration can be found in the [[ATI | ATI wiki]].<br />
<br />
===Simple baseline X test===<br />
<br />
At this point, you should have xorg installed, with a suitable video driver and an /etc/X11/xorg.conf configuration file. If you want to test your configuration quickly, to ensure your ability to successfully start '''X''' from the command line before installing a complete desktop environment, you can do so by invoking '''xterm'''. Xterm is a very simple terminal emulator which runs in the '''X '''Server environment; it is installed as part of the base xorg packages. More advanced users who are comfortable with '''X''' configuration may choose to skip this optional step.<br />
<br />
Prepare for the test by configuring a ~/.xinitrc:<br />
<br />
===== ~/[[.xinitrc]] =====<br />
One of the main functions of this file is to dictate what '''X''' Window client is invoked with the '''/usr/bin/startx''' and/or '''/usr/bin/xinit''' program ''on a per-user basis''. (The '''startx''' script is merely a front end to the more versatile '''xinit''' command.) There are vast amounts of additional configurable specifications and commands that may also be added to ~/[[.xinitrc]] as you further customize your system. <br />
{{Box Note | '''[[.xinitrc]]''' is a so-called 'dot' (.) file. Files in a UNIX filesystem which are preceded with a dot (.) are 'hidden', and will not show up with a regular 'ls' command, usually for the sake of keeping directories tidy. Dot files may be seen by issuing '''ls -a'''. The 'rc' denotes ''Run Commands'' and simply indicates that it is a configuration file. Since it controls how a program runs, it is (although historically incorrect) also said to stand for "Run Control".}}<br />
<br />
'''startx/xinit''' will start the '''X''' server and clients. To determine the client to run, '''startx/xinit''' will first look to parse a [[.xinitrc]] file in the user's home directory. In the absence of file ~/[[.xinitrc]], it defaults to the global xinitrc in the xinit library directory; /etc/X11/xinit/xinitrc, which defaults to using the TWM window manager. (Hence, if you invoke startx without a ~/[[.xinitrc]] file, a TWM session will start.) Further details in the [[.xinitrc]] wiki entry.<br />
<br />
Switch to your '''''normal, non-root''''' user:<br />
# su - ''yourusername''<br />
* /etc/skel/ contains files and directories to provide sane defaults for newly created user accounts. The name '''skel''' is derived from the word '''skeleton''', because the files it contains form the basic structure for users' home directories.<br />
Copy the sample xinitrc file from /etc/skel/ to your home directory: <br />
<br />
$ cp /etc/skel/[[.xinitrc]] ~/<br />
Edit the file: <br />
$ nano ~/.xinitrc<br />
and add:<br />
<br />
exec xterm<br />
<br />
So that it looks like this:<br />
<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
#<br />
exec xterm<br />
# exec wmaker<br />
# exec startkde<br />
# exec icewm<br />
# exec blackbox<br />
# exec fluxbox<br />
<br />
''Be sure to have only one uncommented '''exec''' line in your ~/.xinitrc''. Below, we shall edit this file again to specify the appropriate desktop environment/window manager of your choice.<br />
<br />
Finally, test your configurations by starting '''X''' as '''normal, non-root''' user, with:<br />
<br />
$ startx<br />
or<br />
$ xinit<br />
You should have an '''xterm''' session open up. You can test your keyboard and its layout in it. You may need to add option lines in the "InputDevice" section of the /etc/X11/xorg.conf file specifying the keyboard layout and variant:<br />
<br />
<pre><br />
Option "XkbLayout" "be"<br />
Option "XkbVariant" ""<br />
</pre><br />
<br />
You can exit the '''X''' Server with Ctrl+Alt+Backspace, or by typing "exit". If you have problems starting '''X''', you can look for errors in the /var/log/Xorg.0.log file and on the console output of the console you started '''X''' from.<br />
<br />
If you prove a properly configured /etc/X11/xorg.conf by successfully running the test, you can be assured that your DE/WM of choice will work smoothly.<br />
<br />
Advanced instructions for Xorg configuration can be found in the [[Xorg]] article.<br />
<br />
==Part III: Installing and configuring a Desktop Environment ==<br />
While The '''X''' Window System provides the basic framework for building a ''graphical user interface'' (GUI), a '''Desktop Environment''' (DE), works atop and in conjunction with '''X''', to provide a completely functional and dynamic GUI. A DE typically provides a window manager, icons, applets, windows, toolbars, folders, wallpapers, a suite of applications and abilities like drag and drop. The particular functionalities and designs of each DE will uniquely affect your overall environment and experience. Therefore, choosing a DE is a very subjective and personal decision. Choose the best environment for ''your'' needs.<br />
<br />
* If you want something full-featured and similar to Windows and Mac OSX, '''[[#KDE|KDE]]''' is a good choice<br />
* If you want something slightly more minimalist, which follows the K.I.S.S. principle more closely, '''[[#GNOME|GNOME]]''' is a good choice<br />
* '''[[#Xfce|Xfce]]''' is generally perceived as similar to GNOME, but lighter and less demanding on system resources, yet still visually pleasing and providing a very complete environment.<br />
* '''[[#LXDE|LXDE]]''' is a minimal DE based on the Openbox window manager. It provides most things you need for a modern desktop while keeping relatively low system resource usage. LXDE is a good choice for those who want a quick way of setting up a pre-configured Openbox system.<br />
<br />
If you desire a lighter, less demanding GUI to configure manually, you may choose to simply install a '''Window Manager''', or WM. A WM controls the placement and appearance of application windows in conjunction with the X Window System but does NOT include such features as panels, applets, icons, applications, etc., by default.<br />
* Lightweight floating WM's include: [[#Openbox|'''Openbox''']], [[#Fluxbox|'''Fluxbox''']], [[#fvwm2|'''fvwm2''']], '''Windowmaker, Pekwm, and TWM'''.<br />
* If you need something completely different, try '''Awesome, ion, wmii, dwm, or xmonad'''.<br />
<br />
===Install Fonts===<br />
At this point, you may wish to save time by installing visually pleasing, true type fonts, before installing a desktop environment/window manager. Dejavu and bitstream-vera are good, general-purpose font sets. You may also want to have the Microsoft font sets, which are especially popular on websites. <br />
<br />
Install with:<br />
# pacman -S ttf-ms-fonts ttf-dejavu ttf-bitstream-vera<br />
<br />
===~/.xinitrc (again)===<br />
<br />
As '''non-root user''', edit your /home/username/.xinitrc to specify the DE you wish to use. This will allow you to use '''startx/xinit''' from the shell, in the future, to open your DE/WM of choice:<br />
<br />
$ nano ~/.xinitrc<br />
<br />
Uncomment or add the ''''exec''' ..' line of the appropriate desktop environment/window manager. Some examples are below:<br />
<br />
For the Xfce4 desktop environment:<br />
exec startxfce4 <br />
<br />
For the KDE desktop environment:<br />
exec startkde<br />
A '''startkde''' or '''startxfce4''' command starts the KDE or Xfce4 desktop environment. This command does not finish until you logout of the DE. Normally the shell would wait for KDE to finish, then run the next command. The "exec" prefix to this command tells the shell that this is the last command, so the shell does not need to wait to run a subsequent command.<br />
<br />
Remember to have only one uncommented '''exec''' line in your ~/.xinitrc. <br />
<br />
Continue below, installing the DE/WM of your choice.<br />
<br />
* [[#GNOME|'''GNOME''']]<br />
* [[#KDE|'''KDE''']]<br />
* [[#Xfce|'''Xfce''']]<br />
* [[#LXDE|'''LXDE''']]<br />
* [[#Openbox|'''Openbox''']]<br />
* [[#Fluxbox|'''Fluxbox''']]<br />
* [[#fvwm2|'''fvwm2''']]<br />
<br />
===GNOME===<br />
====About GNOME====<br />
The '''G'''NU '''N'''etwork '''O'''bject '''M'''odel '''E'''nvironment. The GNOME project provides two things: The GNOME desktop environment, an intuitive and attractive desktop for end-users, and the GNOME development platform, an extensive framework for building applications that integrate into the rest of the desktop.<br />
<br />
====Installation====<br />
Install the base GNOME environment with:<br />
# pacman -S gnome<br />
<br />
Additionally, you can install the extras:<br />
# pacman -S gnome-extra<br />
<br />
It's safe to choose all packages shown in the extra package. <br />
<br />
====Useful DAEMONS for GNOME====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The '''hal''' daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The '''fam''' daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. Both '''hal''' and '''fam''' make life easier for the GNOME user. The hal and fam packages are installed when you install GNOME, but must be invoked to become useful.<br />
<br />
You may want to install a graphical login manager. For GNOME, the '''gdm''' daemon is a good choice. <br />
<br />
As root:<br />
# pacman -S gdm<br />
You will almost certainly want the '''hal''' and '''fam''' daemons.<br />
<br />
Start hal and fam:<br />
# /etc/rc.d/hal start<br />
<br />
# /etc/rc.d/fam start<br />
<br />
Add them to your /etc/rc.conf DAEMONS section, so they will be invoked at boot:<br />
# nano /etc/rc.conf<br />
<br />
DAEMONS=(syslog-ng network crond alsa '''hal fam gdm''')<br />
(If you prefer to log into the console and manually start X, leave out gdm.)<br />
<br />
<br />
As normal user, start X:<br />
$ startx<br />
or<br />
$ xinit<br />
If ~/.xinitrc is not configured for GNOME, you may always start it with '''xinit''', followed by the path to GNOME:<br />
$ xinit /usr/bin/gnome-session<br />
<br />
Advanced instructions for installing and configuring GNOME can be found in the [[Gnome]] article.<br />
<br />
Congratulations! Welcome to your GNOME desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
====Eye Candy====<br />
By default, GNOME does not come with many themes and icons. You may wish to install some more attractive artwork for GNOME:<br />
<br />
A nice gtk (gui widget) theme engine (includes themes) is the murrine engine. Install with:<br />
# pacman -S gtk-engine-murrine<br />
<br />
Once it has been installed, select it with System -> Preferences -> Appearance -> Theme tab.<br />
<br />
The Arch Linux repositories also have a few more nice themes and engines. Install the following to see for yourself:<br />
<br />
# pacman -S gtk-engines gtk2-themes-collection gtk-aurora-engine gtk-candido-engine gtk-rezlooks-engine<br />
<br />
You can find many more themes, icons, and wallpapers at [http://www.gnome-look.org Gnome Look].<br />
<br />
===KDE===<br />
====About KDE====<br />
The '''K''' '''D'''esktop '''E'''nvironment. KDE is a powerful Free Software graphical desktop environment for GNU/Linux and <code>UNIX</code> workstations. It combines ease of use, contemporary functionality, and outstanding graphical design with the technological superiority of <code>UNIX</code>-like operating systems.<br />
<br />
====Installation====<br />
Choose one of the following, and continue below with '''[[#Useful KDE DAEMONS|Useful KDE DAEMONS]]''': <br />
<br />
1. Package '''kde''' is the complete, vanilla KDE 4.1 residing under the Arch [extra] repo.<br />
<br />
Install this before: <br />
# pacman -S zlib shared-mime-info<br />
Install with pacman: <br />
# pacman -S kde<br />
<br />
2. '''KDEmod''' is an Arch Linux exclusive community-driven system designed for modularity and also offers a choice between KDE 3.5.10 or 4.1. KDEmod can be installed with pacman, after adding the proper repository to /etc/pacman.conf. The project website, including complete instructions can be found at [http://kdemod.ath.cx/ http://kdemod.ath.cx/].<br />
<br />
{{Box Note|A dependency of the full kdemod3/kdemod-legacy was removed from the Arch official repositories. KDEmod is not part of said repositories, and no standard Arch programs used this package. If you wish to install kdemod3-complete without potentially problematic workarounds [kdemod3-base shouldn't have this issue btw], you should install the package libopensync from AUR manually (See: [http://wiki.archlinux.org/index.php/AUR_User_Guidelines#Using_Packages_from_UNSUPPORTED]) or via yaourt until the package is in the KDEMod3 repositories. If you have trouble, try libopensync-stable (or libopensync-unstable if you're desperate).}}<br />
<br />
====Useful KDE DAEMONS====<br />
<br />
KDE will require the '''hal''' ('''H'''ardware '''A'''bstraction '''L'''ayer) and '''fam''' ('''F'''ile '''A'''lteration '''M'''onitor) daemons. The '''kdm''' daemon is the '''K''' '''D'''isplay '''M'''anager, which provides a '''graphical login''', if desired.<br />
<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system.. Both '''hal''' and '''fam''' make life easier for the KDE user. The hal, fam and kdm packages are installed when you install KDE, but must be invoked to become useful.<br />
-----<br />
Start hal and fam:<br />
<br />
# /etc/rc.d/hal start<br />
<br />
# /etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS array in /etc/rc.conf:<br />
# nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS array, to invoke them on boot. If you prefer a graphical login, add '''kdm''' as well: <br />
DAEMONS=(syslog-ng network crond alsa '''hal fam kdm''')<br />
{{Box Note|If you installed KDEmod3 instead of normal KDE, use kdm3 instead of kdm.}}<br />
<br />
*This method will start the system at runlevel 3, (/etc/inittab default, multiuser mode), and then start KDM as a daemon. <br />
<br />
*Some users prefer an alternative method of starting a display manager like KDM on boot by utilizing the /etc/inittab method and starting the system at runlevel 5. See [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]] for more.<br />
<br />
*If you prefer to log into the '''console''' at runlevel 3, and manually start X, leave out kdm, or comment it out with a bang, ( ! ).<br />
<br />
Now try starting your X Server as normal user:<br />
$ startx<br />
or<br />
$ xinit<br />
Advanced instructions for installing and configuring KDE can be found in the [[KDE]] article.<br />
<br />
Congratulations! Welcome to your KDE desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===Xfce===<br />
====About Xfce====<br />
The cholesterol-free '''X''' environment. Xfce, like GNOME or KDE, is a desktop environment, but aims to be fast and lightweight while remaining visually appealing and easy to use. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit (like GNOME) and contains its own development environment (libraries, daemons, etc) similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and fast. Xfce is great for older hardware, and will perform excellently on newer machines as well.<br />
<br />
====Installation====<br />
Install Xfce: <br />
# pacman -S xfce4 <br />
You may also wish to install themes and extras:<br />
# pacman -S xfce4-goodies gtk2-themes-collection<br />
Note: '''xfce4-xfapplet-plugin''' (a plugin that allows the use of GNOME applets in the Xfce4 panel) is part of the '''xfce4-goodies''' group and depends on '''gnome-panel''', which in turn depends on '''gnome-desktop'''. You may wish to take this into consideration before installing, since it represents a significant number of extra dependencies.<br />
<br />
If you wish to admire 'Tips and Tricks' on login, install the '''fortune-mod''' package:<br />
# pacman -S fortune-mod<br />
<br />
====Useful DAEMONS====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. The hal and fam packages are installed when you install Xfce, but must be invoked to become useful.<br />
<br />
Start hal and fam:<br />
<br />
# /etc/rc.d/hal start<br />
<br />
# /etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS array in /etc/rc.conf:<br />
# nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS array, to invoke them at boot.<br />
<br />
Advanced instructions for installing and configuring Xfce can be found in the [[Xfce]] article.<br />
<br />
If you wish to install one, see [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]]. Otherwise you can login in via the console and run:<br />
<br />
$ startxfce4<br />
<br />
Congratulations! Welcome to your Xfce desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===LXDE===<br />
====About LXDE====<br />
LXDE, (for ''L''ightweight ''X''11 ''D''esktop ''E''nvironment), is a new project focused on providing a modern desktop environment which aims to be lightweight, fast, intuitive and functional while keeping system resource usage low. LXDE is quite different from other desktop environments, since each component of LXDE is a discrete and independent application, and each can be easily substituted by other programs. This modular design eliminates all unnecessary dependencies and provides more flexibility. Details and screenshots available at: http://lxde.org/ <br />
<br />
LXDE provides:<br />
# The OpenBox windowmanager<br />
# PCManFM File manager<br />
# LXpanel system panel<br />
# LXSession session manager<br />
# LXAppearance GTK+ theme switcher<br />
# GPicView image viewer<br />
# Leafpad simple text editor<br />
# XArchiver: Lightweight, fast, and desktop-independent gtk+-based file archiver<br />
# LXNM (still under development): Lightweight network manager for LXDE supporting wireless connections<br />
These lightweight and versatile tools combine for quick setup, modularity and simplicity.<br />
<br />
Install LXDE with: <br />
# pacman -S lxde<br />
Add:<br />
exec startlxde<br />
to your ~/.xinitrc and start with ''startx'' or ''xinit''<br />
<br />
Further information available at the [[LXDE]] wiki article.<br />
<br />
===*box===<br />
====Fluxbox====<br />
Fluxbox © is yet another windowmanager for X.<br />
It's based on the Blackbox 0.61.1 code. Fluxbox looks like blackbox and handles styles, colors, window placement and similar things exactly like blackbox (100% theme/style compability).<br />
<br />
Install Fluxbox using <br />
# pacman -S fluxbox fluxconf<br />
<br />
If you use gdm/kdm a new fluxbox session will be automatically added. Otherwise, you should modify your user's .xinitrc and add this to it:<br />
exec startfluxbox <br />
<br />
More information is available in the [[Fluxbox]] article.<br />
<br />
====Openbox====<br />
Openbox is a standards compliant, fast, light-weight, extensible window manager.<br />
<br />
Openbox works with your applications, and makes your desktop easier to manage. This is because the approach to its development was the opposite of what seems to be the general case for window managers. Openbox was written first to comply with standards and to work properly. Only when that was in place did the team turn to the visual interface.<br />
<br />
Openbox is fully functional as a stand-alone working environment, or can be used as a drop-in replacement for the default window manager in the GNOME or KDE desktop environments. <br />
<br />
Install openbox using<br />
# pacman -S openbox<br />
Additional configuration tools are also available, if desired:<br />
# pacman -S obconf obmenu<br />
<br />
Once openbox is installed you will get a message to move menu.xml & rc.xml to ~/.config/openbox/ in your home directory:<br />
# su - ''yourusername''<br />
$ mkdir -p ~/.config/openbox/<br />
$ cp /etc/xdg/openbox/rc.xml ~/.config/openbox/<br />
$ cp /etc/xdg/openbox/menu.xml ~/.config/openbox/<br />
<br />
'''rc.xml''' is the main configuration file for OpenBox. It may be manually edited, (or you can use OBconf). '''menu.xml''' configures the right-click menu.<br />
<br />
You may log into OpenBox via graphical login using KDM/GDM, or from the shell using '''startx''', in which case you will need to edit your ~/.xinitrc (as non-root user) and add the following:<br />
<br />
exec openbox-session<br />
You may also start OpenBox from the shell using '''xinit''':<br />
$ xinit /usr/bin/openbox-session<br />
* Openbox may also be used as the window manager for GNOME, KDE, and Xfce.<br />
For KDM there is nothing left to do; openbox is listed in the sessions menu in KDM.<br />
<br />
Some useful, lightweight programs for OpenBox are:<br />
* PyPanel or LXpanel if you want a panel<br />
* feh if you want to set the background<br />
* ROX if you want a simple file manager (also provides simple icons)<br />
* PcmanFM a lightweight but versatile file manager (also provides desktop icon functionality)<br />
* iDesk (available in [[AUR]]) for providing desktop icons<br />
<br />
More information is available in the [[Openbox]] article.<br />
<br />
===fvwm2===<br />
FVWM is an extremely powerful ICCCM-compliant multiple virtual desktop window manager for the X Window system. Development is active, and support is excellent. <br />
<br />
Install fvwm2 with<br />
# pacman -S fvwm <br />
<br />
fvwm will automatically be listed in kdm/gdm in the sessions menu. Otherwise, add <br />
exec fvwm <br />
<br />
to your user's .xinitrc.<br />
<br />
==Browser, Codecs, Video Player & Useful Applications==<br />
===Web Browser===<br />
The ever-popular Firefox web browser is available through pacman, although it does not have its official branding. Therefore, the program appears as its development codename, ''Gran Paradiso'', when opened.<br />
<br />
Install with:<br />
<br />
pacman -S firefox<br />
Be sure and install 'flashplugin', 'mplayer', 'mplayer-plugin', and the 'codecs' packages for a complete web experience:<br />
pacman -S flashplugin mplayer mplayer-plugin codecs<br />
<br />
''For newbies: if you install the x86_64 version of Arch Linux don`t use the option flashplugin in pacman, like above, or you will get an error. Unfortunately Adobe does not offer a 64 bit version of flash plugin. Please see [http://wiki.archlinux.org/index.php/Install_Flash_on_Arch64 this wiki] entry to workaround the problem'' <br />
<br />
(The codecs package contains most codecs, including those for Win32, Quicktime and Realplayer9 content.)<br />
===VLC===<br />
VLC Player is a versatile multimedia player which can handle many different formats, from a disc or file. It also provides the ability to stream multimedia over a lan. Install with:<br />
pacman -S vlc<br />
The libdvdcss library provides DVD decoding for encrypted DVDs. Ensure the legality of using libdvdcss in your country before installing!<br />
pacman -S libdvdcss<br />
<br />
===Useful Applications===<br />
For more apps, see [[Useful Applications]].<br />
=APPENDIX=<br />
See [[Beginners' Guide Appendix]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Microsoft_fonts&diff=52706
Microsoft fonts
2008-11-05T19:06:50Z
<p>Cucullus: typo fix</p>
<hr />
<div>[[Category:Fonts (English)]]<br />
[[Category:Graphics and DTP (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{Article summary start}}<br />
{{Article summary text|This HOWTO shows how to install ''TrueType core fonts for the Web'' package.}}<br />
{{Article summary heading|Available in languages}}<br />
{{I18n entry|English|MS Fonts}}<br />
{{Article summary heading|Legal}}<br />
{{Article summary text|According to [http://web.archive.org/web/20020227054122/www.microsoft.com/typography/fontpack/eula.htm original Microsoft's End User License Agreement], there are ''some'' legal limitations when using the font.}}<br />
{{Article summary heading|Related articles}}<br />
{{Article summary wiki|Fonts}}<br />
{{Article summary wiki|Fonts FAQ}}<br />
{{Article summary end}}<br />
<br />
== About ==<br />
<br />
:''The msfonts package adds fonts that were created by Microsoft.''<br />
:''You might want to use these when editing old MS word docs in openoffice.''<br />
<br />
== Microsoft's EULA (excerpt)[http://web.archive.org/web/20020227054122/www.microsoft.com/typography/fontpack/eula.htm] ==<br />
<br />
1. GRANT OF LICENSE. This EULA grants you the following rights:<br />
<br />
* Installation and Use. You may install and use an unlimited number of copies of the SOFTWARE PRODUCT.<br />
* Reproduction and Distribution. You may reproduce and distribute an unlimited number of copies of the SOFTWARE PRODUCT; provided that each copy shall be a true and complete copy, including all copyright and trademark notices, and shall be accompanied by a copy of this EULA. Copies of the SOFTWARE PRODUCT may not be distributed for profit either on a standalone basis or included as part of your own product. <br />
<br />
<br />
2. DESCRIPTION OF OTHER RIGHTS AND LIMITATIONS.<br />
<br />
* Limitations on Reverse Engineering, Decompilation, and Disassembly. You may not reverse engineer, decompile, or disassemble the SOFTWARE PRODUCT, except and only to the extent that such activity is expressly permitted by applicable law notwithstanding this limitation.<br />
* Restrictions on Alteration. You may not rename, edit or create any derivative works from the SOFTWARE PRODUCT, other than subsetting when embedding them in documents.<br />
* Software Transfer. You may permanently transfer all of your rights under this EULA, provided the recipient agrees to the terms of this EULA.<br />
* Termination. Without prejudice to any other rights, Microsoft may terminate this EULA if you fail to comply with the terms and conditions of this EULA. In such event, you must destroy all copies of the SOFTWARE PRODUCT and all of its component parts.<br />
<br />
== Included fonts ==<br />
<br />
Fonts included are: Andale Mono, Arial, Arial Black, Comic, Courier New, Georgia, Impact, Lucida Sans, Lucida Console, Microsoft Sans Serif, Symbol, Tahoma, Times New Roman, Trebuchet, Verdana, Webdings and Wingdings.<br />
<br />
== Instructions ==<br />
<br />
Currently, the preferred way of installing these fonts is through Arch ''extra'' repository. The old manual methods are still listed below for those interested.<br />
<br />
=== Install from extra repository ===<br />
<br />
The package for these fonts is available in the ''extra'' repository. Run the following command to install them:<br />
<br />
# pacman -S ttf-ms-fonts<br />
<br />
=== Manual install from avi.alkalay.net ===<br />
<br />
Download: http://avi.alkalay.net/software/msfonts/download/<br />
Mirror: http://webperf.org/msfonts/<br />
<br />
To install (manually):<br />
# tar zxvf msfonts-1.2.1.tar.gz<br />
# cp -a msfonts-1.2.1/main /usr/X11R6/lib/X11/fonts/ms<br />
# cd /usr/X11R6/lib/X11/fonts/ms<br />
# ttmkfdir >fonts.scale<br />
# mkfontdir<br />
# fc-cache -v<br />
<br />
=== Manual install from freshmeat.net ===<br />
<br />
new repository from freshmeat.net:<br />
http://freshmeat.net/projects/msfonts/<br />
<br />
To install (manually):<br />
# tar xvfz webcore-fonts-1.3.tar.gz<br />
# cp -a webcore-fonts/fonts /usr/share/fonts/ms <br />
# cd /usr/share/fonts/ms<br />
# ttmkfdir >fonts.scale<br />
# mkfontdir<br />
# fc-cache -v<br />
<br />
== Tweaks ==<br />
A complete guide on how to make the MS Fonts look as in Windows XP is found at http://www.sharpfonts.com/. In short, download the fonts as described above and use the authors tweaked xml files.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Newcomers_Guide&diff=51261
Newcomers Guide
2008-10-16T16:39:10Z
<p>Cucullus: russian trans link</p>
<hr />
<div>[[Category:Getting and installing Arch (English)]]<br />
[[Category:About Arch (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{Article summary start}}<br />
{{Article summary text|Provides a highly detailed, explanatory guide to installing, configuring and using a full-featured Arch Linux system.}}<br />
{{Article summary heading|Available Languages}}<br />
{{i18n_entry|Česky|Průvodce začátečníka (Česky)}}<br />
{{i18n_entry|Dansk|Dansk_Begynderguide}}<br />
{{i18n_entry|简体中文|Beginners Guide 新手指南}}<br />
{{i18n_entry|正體中文|Beginner's Guide 新手指南}}<br />
{{i18n_entry|Deutsch|Beginners Guide (Deutsch)}}<br />
{{i18n_entry|English|Beginners Guide}}<br />
{{i18n_entry|Español|Guía para Principiantes (Español)}}<br />
{{i18n_entry|Français|Manuel_du_Débutant_(Français)}}<br />
{{i18n_entry|Italiano|Beginners Guide (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Pradedančiųjų gidas (Lietuviškai)}}<br />
{{i18n_entry|Português Brasil|Guia do Iniciante(Português do Brasil)}}<br />
{{i18n_entry|Русский|Руководство_для_новичков}}<br />
{{i18n_entry|Türkçe|Başlangıç Rehberi (Türkçe)}}<br />
{{Article summary heading|Related articles}}<br />
{{Article summary wiki|Official Arch Linux Install Guide}} (provides a more general approach)<br />
{{Article summary end}}<br />
==Preface==<br />
<br />
=====Everything you ever wanted to know about Arch, but were afraid to ask=====<br />
Welcome. This self-contained document will guide you through the process of installing, configuring and using [[ArchLinux|Arch Linux]]; a simple, agile and lightweight GNU/Linux distribution, <code>UNIX</code>-like operating system. Arch Linux requires a certain level of intimate knowledge of its configuration and of <code>UNIX</code>-like system methodology and for this reason, extra explanatory information is included. This guide is aimed at new Arch users, but strives to serve as a strong reference and informative base for all. After reading it entirely, the reader will be well equipped to begin using Arch.<br />
<br />
'''Arch Linux distribution highlights:'''<br />
* '''[[The Arch Way | Simple]]''' design and philosophy<br />
* System assembled by the user from the ground up<br />
* All packages compiled for '''i686/x86-64'''<br />
* '''[[The Arch boot process | BSD-style init]]''' scripts, including one centralized configuration file<br />
* '''Rolling Release''' model<br />
* '''[[Pacman]]''' package manager is written in '''C''', lightweight and agile, with a very modest memory footprint<br />
* '''[[ABS]]''': The '''A'''rch '''B'''uild '''S'''ystem, a ports-like packaging system<br />
* '''[[AUR]]''': The Arch User Repository, offering many thousands of build scripts for user-provided software packages<br />
<br />
Since GNU/Linux Distributions are fundamentally 'modular' by design, the guide is logically divided into 3 main components of a desktop <code>UNIX</code>-like operating system:<br />
<br />
'''[[#Part I: Install the Base System|Part I: Installing the Base system]]'''<br />
<br />
'''[[#Part II: Install X and configure ALSA|Part II: Installing X and configuring ALSA]]'''<br />
<br />
'''[[#Part III: Installing and configuring a Desktop Environment|Part III: Installing a Desktop Environment]]'''<br />
<br />
=====DON'T PANIC!=====<br />
The Arch Linux system is assembled by the ''user'', from the shell, using basic command line tools. This is '''[[The Arch Way]].''' Unlike the more rigid structures of other distributions and installers, there are no default environments nor configurations chosen for you. From the command line, ''you'' will add packages from the Arch repositories using the [[pacman]] tool via your internet connection and manually configure your installation until your system is customized to your requirements. This method allows for maximum flexibility, choice, and system resource control ''from the base up''.<br />
<br />
Arch Linux is aimed at GNU/Linux users who desire minimal 'code separation' from their machine.<br />
<br />
=====[[The Arch Way]]=====<br />
<br />
'''''The design principles behind Arch are aimed at keeping it [[The Arch Way|simple]].'' '''<br />
<br />
'Simple', in this context, shall mean 'without unnecessary additions, modifications, or complications'. In short; an elegant, minimalist approach.<br />
<br />
'''Some thoughts to keep in mind:'''<br />
<br />
*''" 'Simple' is defined from a technical standpoint, not a usability standpoint. It is better to be technically elegant with a higher learning curve, than to be easy to use and technically [inferior]." -Aaron Griffin''<br />
<br />
*''Entia non sunt multiplicanda praeter necessitatem'' or "Entities should not be multiplied unnecessarily." -Occam's razor. The term ''razor'' refers to the act of shaving away unnecessary complications to arrive at the simplest explanation, method or theory.<br />
<br />
*''"The extraordinary part of [my method] lies in its simplicity..I always believe that the simple way is the right way."'' - Bruce Lee<br />
<br />
{{Box Note |'''Following this guide closely is essential in order to successfully install a properly configured Arch Linux system, so ''please'' read it thoroughly. It is strongly recommended you read each section completely before carrying out the tasks contained.'''}}<br />
* You may wish to make a print out of this guide which will serve as a useful Arch Linux user reference. Simply click on the 'Printable Version' tab in the toolbox on the top-left.<br />
*''If you would like to add to this wiki, please include the "Why" as well as the "How", where appropriate. The best documentation teaches us how, as well as why!''<br />
* The Arch wiki is an excellent resource and should be consulted for issues [http://wiki.archlinux.org/index.php/Main_Page first]; IRC (freenode #archlinux), and the [http://bbs.archlinux.org/ forums] are also available if the answer cannot be found.<br />
----<br />
Welcome to Arch! Now, let's get started.<br />
<br />
==Part I: Install the Base System==<br />
<br />
===Obtain the latest Installation media ===<br />
<br />
You can obtain Arch's official archiso media from [http://archlinux.org/download/ here]. The latest version is 2008.06<br />
<br />
You can obtain Tobias Powalowski's 2008.10 archboot media from [http://downloads.archlinux.de/iso/2008.10-archboot/ here]. <br />
<br />
*Both the Core installer and the FTP/HTTP-downloads provide only the necessary packages to create an '''Arch Linux base system'''. ''Note that the Base System does not include a GUI. It is mainly comprised of the GNU toolchain, (compiler, assembler, linker, libraries, shell, and a few useful utilities) the Linux kernel, and a few extra libraries and modules.'' <br />
*Expanding your Arch Linux system beyond the base system, to include extra software, a Graphical User Interface, etc., is achieved from the command line, ''by the user'', via the pacman package manager to grab i686/x86-64 binary packages. The process is covered in detail below.<br />
====CD installer====<br />
Burn the .iso to a CD with your favorite burner, and continue with [[#Boot Arch Linux Installer | Boot Arch Linux Installer]]<br />
{{Box Note| CD media quality varies greatly, but generally, using a slow burn speed is recommended for reliable burns; Some users recommend speeds '''''as low as 4x or 2x!''''' If you are experiencing unexpected behavior from the CD, try burning at the minimum speed supported by your system. }}<br />
<br />
====USB stick====<br />
<font color="red">'''WARNING''': This will destroy all data on your USB stick.</font><br />
<br />
Insert an empty or expendable USB stick, determine its path, and dump the .img to the USB stick with the <code>/bin/dd</code> program:<br />
dd if=archlinux-2008.06-[core_or_ftp]-i686.img of=/dev/sd''x''<br />
where ''if='' is the path to the img file and ''of='' is your USB device. Make sure to use /dev/sd''x'' and not /dev/sd''x1''.<br />
<br />
'''Check md5sum (optional):'''<br />
<br />
Make a note of the number of records (blocks) read in and written out, then perform the following check:<br />
dd if=/dev/sd''x'' count=''number_of_records'' status=noxfer | md5sum<br />
The md5sum returned should match the md5sum of the downloaded archlinux image file; they both should match the md5sum of the image as listed in the md5sums file in the mirror distribution site.<br />
<br />
Continue with [[#Boot Arch Linux Installer | Boot Arch Linux Installer]]<br />
<br />
===Boot Arch Linux Installer===<br />
Insert the CD or USB stick and boot from it. You may have to <br />
change the boot order in your computer BIOS or press a key (usually DEL, F1, F2, F11 or F12) during the BIOS POST phase.<br />
<br />
Memory requirements:<br />
<br />
* CORE : 160 MB RAM x86_64/i686 (all packages selected, with swap partition)<br />
* FTP : 160 MB RAM x86_64/i686 (all packages selected, with swap partition)<br />
<br />
Choose Boot Archlive or Boot Archlive [legacy IDE] if you have trouble with libata/PATA. <br />
<br />
To change boot options press '''e''' for editing the boot lines. Many users may wish to change the resolution of the framebuffer, for more readable console output. Append:<br />
vga=773<br />
to the kernel line, followed by <ENTER>, for a 1024x768 framebuffer. Hit '''b''' to boot.<br />
<br />
The system will now boot and present a login prompt.<br />
<br />
===Login and Changing the keymap===<br />
Login as 'root'.<br />
<br />
If you have a non-US keyboard layout do:<br />
# km<br />
at the prompt, and choose your keymap/console font.<br />
<br />
That's right, the ever-popular '''km''' program is back as of 2008-06!<br />
<br />
===Documentation===<br />
The guide you are now reading is available on the live system. Change to vc/2 with <ALT>+F2 and do:<br />
# less /arch/beginnersguide.txt<br />
'''Less''' will allow you to page through the document. Change back to vc/1 with <ALT>+F1. <br />
<br />
Change back to vc/2 if you need to reference the Beginners' Guide at any time.<br />
<br />
===Start the Installation===<br />
As root, run the installer script from vc/1:<br />
# /arch/setup <br />
<br />
====Select an installation source====<br />
After a welcome screen, you will be prompted for an installation source. Choose the appropriate source for the installer you are using. <br />
* If you chose the CORE installer, continue below with [[#Prepare Hard Drive|Prepare Hard Drive]].<br />
* FTP/HTTP only: You shall be prompted to load ethernet drivers manually, if desired. Udev is quite effective at loading the required modules, so you may assume it has already done so. You may verify this by invoking ifconfig -a from vc/3. (Select OK to continue.)<br />
<br />
===Configure Network (FTP/HTTP)===<br />
Available Interfaces will be presented. If an interface and HWaddr is listed, then your module has already been loaded. If your interface is not listed, you may probe it from the installer, or manually do so from another virtual console.<br />
<br />
The following screen will prompt you to ''Select the interface, Probe,'' or ''Cancel''. Choose the appropriate interface and continue.<br />
<br />
The installer will then ask if you wish to use DHCP. Choosing Yes will run '''dhcpcd''' to discover an available gateway and request an IP address; Choosing No will prompt you for your static IP, netmask, broadcast, gateway DNS IP, HTTP proxy, and FTP proxy. Lastly, you will be presented with an overview to ensure your entries are correct.<br />
<br />
====Wireless Quickstart (If you need wireless connectivity during the installation process)====<br />
<br />
The wireless drivers and utilities are now available to you in the live environment of the installation media. <br />
<br />
If you need wireless functionality from the initial installation (live installer environment) onwards, the basic procedure will be:<br />
* Switch to a free virtual console, e.g.: <ALT>+F3<br />
* Identify your wireless card and appropriate module with <code>/sbin/hwdetect</code>:<br />
# hwdetect --show-net<br />
* Ensure udev has loaded the module with <code>/bin/lsmod</code>:<br />
# lsmod | grep <name_of_module><br />
* If not, probe it using <code>/sbin/modprobe</code>:<br />
# modprobe <name_of_module><br />
{{Box Note | '''''In addition to the wireless module, some wireless chipsets also require corresponding firmware installation. The firmware packages are pre-installed in the live environment, but must be explicitly installed to your actual system to provide wireless functionality after you reboot into your installed system. Package selection and installation is covered below. Ensure installation of both your wireless module and firmware during the package selection step! See [[Wireless Setup]] if you are unsure about the requirement of corresponding firmware installation for your particular chipset. This is a very common error.'''''}}<br />
<br />
* Ensure the driver has created a usable wireless kernel interface with <code>/usr/sbin/iwconfig</code>:<br />
# iwconfig<br />
(Output should show an available wireless interface)<br />
* Bring the interface up with <code>/sbin/ifconfig <interface> up</code>. <br />
<br />
An example, using an atheros card and madwifi driver:<br />
# ifconfig ath0 up<br />
(Remember, your interface may be named something else, depending on your module (driver) and chipset: wlan0, eth1, etc.)<br />
* Specify the id of the wireless network with iwconfig <interface> essid <youressid> key <yourwepkey>, e.g.:<br />
# iwconfig ath0 essid linksys key 0241baf34c<br />
* Acquire an IP address with <code>/sbin/dhcpcd <interface> </code>. e.g.:<br />
# dhcpcd ath0<br />
* Ensure you can route using <code>/bin/ping</code>:<br />
# ping -c 3 www.google.com<br />
Done.<br />
<br />
After the initial Arch installation is complete, you may wish to refer to [[Wireless Setup]] to ensure a permanent configuration solution for your system.<br />
<br />
<br />
Return to vc/1 with <ALT>+F1. Continue with [[#Prepare Hard Drive|Prepare Hard Drive]]<br />
<br />
===Prepare Hard Drive===<br />
<font color="red"> '''WARNING:''' '''''Partitioning hard drives can destroy data. You are strongly cautioned and advised to backup your critical data if applicable.'''''</font><br />
<br />
Select the first menu entry "Prepare Hard Drive". <br />
* Option 1: Auto Prepare<br />
Auto-Prepare divides your disk into the following configuration:<br />
<br />
* ext2 /boot partition, default size 32MB. ''You will be prompted to modify the size to you requirement.''<br />
* swap partition, default size 256MB. ''You will be prompted to modify the size to you requirement.'' <br />
* A Separate / and /home partition, (sizes can also be specified). You may choose from ext2, ext3, reiserfs, xfs and jfs, but note that ''both / and /home must share the same fs type'' if choosing the Auto Prepare option.<br />
<br />
Be warned that Auto-prepare will completely erase the chosen hard drive. Read the <font color="red">warning</font> presented by the installer very carefully, and make sure the correct device is about to be partitioned.<br />
<br />
* Option 2: '''(Recommended)''' Partition Hard Drives (with cfdisk)<br />
<br />
This option will allow for the most robust and customized partitioning solution for your personal needs. <br />
<br />
''At this point, more advanced GNU/Linux users who are familiar and comfortable with manually partitioning may wish to skip down to '''[[#Select Packages|Select Packages]]''' below.''<br />
<br />
====Partition Hard Drives====<br />
<br />
=====Partition Info=====<br />
<br />
Partitioning a hard disk drive defines specific areas (the partitions) within the disk, that will each appear and behave as a separate disk and upon which a filesystem may be created (formatted). There exist 3 types of disk partitions: <br />
#Primary<br />
#Extended<br />
#Logical<br />
'''Primary''' partitions can be bootable, and are limited to 4. If a partitioning scheme requires more than 4 partitions, we are forced to use an '''extended''' partition which will contain '''logical''' partitions.<br />
<br />
Extended partitions are not usable by themselves; they are merely a "container" for logical partitions. If required, a hard disk shall contain only one extended partition; which shall then be sub-divided into logical partitions. <br />
<br />
When partitioning a disk, one can observe this numbering scheme by creating primary partitions sda1-3 followed by creating an extended partition, sda4, and subsequently creating logical partition(s) within the extended partition; sda5, sda6, and so on.<br />
<br />
=====Swap Partition=====<br />
A swap partition is a place on your hard drive where virtual ram resides, allowing the kernel to easily use disk storage for data that does not fit into physical RAM. <br />
<br />
Historically, the general rule for swap partition size was 2x the amount of physical RAM. Over time, as computers have gained ever larger memory capacities, this rule has become increasingly deprecated. Generally, on machines with up to 512MB RAM, the 2x rule is usually quite sufficient. On machines with 1GB RAM, generally a 1x rule is adequate. If you have gratuitous amounts of RAM (more than 1024 MB) it may be possible to completely forgo a swap partition altogether, though this is not recommended. We will create a 1 GB swap partition in this example.<br />
{{Box Note|If you plan on using suspend-to-disk, (hibernate) you must have a swap partition at least '''equal''' in size to the amount of physical RAM, and some Arch users even recommend oversizing it beyond the amount of physical RAM by 10-15%, to allow for possible bad sectors.}}<br />
<br />
=====Partition Scheme=====<br />
A disk partitioning scheme is a very personalized preference. Each user's choices will be unique to their own computing habits and requirements. <br />
<br />
Filesystem candidates for separate partitions include:<br />
<br />
'''/''' (root) ''The root filesystem is the primary filesystem from which all other filesystems stem; the top of the hierarchy. All files and directories appear under the root directory "/", even if they are stored on different physical devices. The contents of the root filesystem must be adequate to boot, restore, recover, and/or repair the system.'' <br />
<br />
'''/boot''' ''This directory contains the kernel and ramdisk images as well as the bootloader configuration file, and bootloader stages. /boot also stores data that is used before the kernel begins executing userspace programs. This may include saved master boot sectors and sector map files.''<br />
<br />
'''/home''' ''User data and user specific configuration files for applications are stored in each user's home directory in a file that starts with the '.' character (a "dot file").''<br />
<br />
'''/usr''' ''While root is the primary filesystem, /usr is the secondary hierarchy, for user data, containing the majority of (multi-)user utilities and applications. /usr is shareable, read-only data. This means that /usr shall be shareable between various hosts and must not be written to, except in the case of system update/upgrade. Any information that is host-specific or varies with time is stored elsewhere.''<br />
<br />
'''/tmp''' ''directory for programs that require temporary files''<br />
<br />
'''/var''' ''contains variable data; spool directories and files, administrative and logging data, pacman's cache, the ABS tree, etc.''<br />
{{Box Note | Besides /boot, directories essential for booting are: '/bin', '/dev', '/etc', '/lib', '/proc' and '/sbin'. Therefore, they must not reside on a separate partition from /.}}<br />
There are several advantages for using discrete filesystems, rather than combining all into one partition:<br />
<br />
* Security: Each filesystem may be configured as 'nosuid', 'nodev', 'noexec', 'readonly', etc. (This is specified in /etc/fstab).<br />
* Stability: A user, or malfunctioning program can completely fill a filesystem with garbage if they have write permissions for it. Critical programs, which reside on a different filesystem remain unaffected.<br />
* Speed: A filesystem which gets written to frequently may become somewhat fragmented. (An effective method of avoiding fragmentation is to ensure that each filesystem is never in danger of filling up completely.) Separate filesystems remain unaffected, and each can be defragmented separately as well.<br />
* Integrity: If one filesystem becomes corrupted, separate filesystems remain unaffected.<br />
* Versatility: Sharing data across several systems becomes more expedient when independent filesystems are used. Separate filesystem types may also be chosen based upon the nature of data and usage. <br />
In this example, we shall use separate partitions for /, /var, /home, and a swap partition. <br />
<br />
{{Box Note | /var contains many small files. You may wish to take this into consideration when choosing a filesystem type for it.}}<br />
<br />
=====How big should my partitions be?=====<br />
This question is best answered based upon individual needs. If you have little or no experience with partitioning, you may wish to simply create one partition for root, and one partition for swap. Or, follow the example closely, and consider these guidelines to provide a frame of reference:<br />
* The root filesystem (/) in the example will contain the /usr directory, which can become moderately large, depending upon how much software is installed.<br />
<br />
* The /var filesystem will contain, among other data, the [[ABS]] tree and the pacman cache. Keeping cached packages is useful and versatile; it provides the ability to downgrade packages if needed. /var tends to grow in size; the pacman cache can grow large over long periods of time, but can be safely cleared if needed. 6-8 Gigs on a desktop system should therefore be sufficient for /var. Servers tend to have extremely large /var filesystems.<br />
* The /home filesystem is typically where user data, downloads, and multimedia reside. On a desktop system, /home is typically the largest filesystem on the drive by a large margin. <br />
* An extra 25% of space added to each filesystem will provide a cushion for unforeseen occurrence, expansion, and serve as a preventive against fragmentation.<br />
From the guidelines above, the example system shall contain a ~15GB root (/) partition, ~6GB /var, 1GB swap, and a /home containing the remaining disk space.<br />
<br />
=====cfdisk=====<br />
Start by creating the primary partition that will contain the '''root''', (/) filesystem. <br />
<br />
Choose '''N'''ew -> Primary and enter the desired size for root (/). Put the partition at the beginning of the disk. <br />
<br />
Also choose the '''T'''ype by designating it as '83 Linux'. The created / partition shall appear as sda1 in our example.<br />
<br />
Now create a primary partition for /var, designating it as '''T'''ype 83 Linux. The created /var partition shall appear as sda2 <br />
<br />
Next, create a partition for swap. Select an appropriate size and specify the '''T'''ype as 82 (Linux swap / Solaris). The created swap partition shall appear as sda3.<br />
<br />
Lastly, create a partition for your /home directory. Choose another primary partition and set the desired size.<br />
<br />
Likewise, select the '''T'''ype as 83 Linux. The created /home partition shall appear as sda4.<br />
<br />
Example:<br />
<br />
Name Flags Part Type FS Type [Label] Size (MB)<br />
-------------------------------------------------------------------------<br />
sda1 Primary Linux 15440 #root<br />
sda2 Primary Linux 6256 #/var<br />
sda3 Primary Linux swap / Solaris 1024 #swap<br />
sda4 Primary Linux 140480 #/home<br />
<br />
Choose '''W'''rite and type ''''yes''''. Beware that this operation may destroy data on your disk. Choose '''Q'''uit to leave the partitioner. <br />
Choose Done to leave this menu and continue with "Set Filesystem Mountpoints".<br />
<br />
{{Box Note | Since the latest developments of the Linux kernel which include the libata and PATA modules, all IDE, SATA and SCSI drives have adopted the sd''x'' naming scheme. This is perfectly normal and should not be a concern.}}<br />
<br />
====Set Filesystem Mountpoints====<br />
First you will be asked for your swap partition. Choose the appropriate partition (sda3 in this example). You will be asked if you want to create a swap filesystem; select yes. Next, choose where to mount the / (root) directory (sda1 in the example). At this time, you will be asked to specify the filesystem type.<br />
<br />
=====Filesystem Types=====<br />
<br />
Again, a filesystem type is a very subjective matter which comes down to personal preference. Each has its own advantages, disadvantages, and unique idiosyncrasies. Here is a very brief overview of supported filesystems:<br />
<br />
1. '''ext2''' ''Second Extended Filesystem''- Old, reliable GNU/Linux filesystem. Very stable, but ''without journaling support''. May be inconvenient for root (/) and /home, due to very long fsck's. ''An ext2 filesystem can easily be converted to ext3.'' Generally regarded as a good choice for /boot/.<br />
<br />
2. '''ext3''' ''Third Extended Filesystem''- Essentially the ext2 system, but with journaling support. ext3 is completely compatible with ext2. ''Extremely'' stable, mature, and by far the most widely used, supported and developed GNU/Linux FS.<br />
<br />
'''High Performance Filesystems:'''<br />
<br />
3. '''ReiserFS''' - Hans Reiser's high-performance journaling FS uses a very interesting method of data throughput based on an unconventional and creative algorithm. ReiserFS is touted as very fast, especially when dealing with many small files. ReiserFS is fast at formatting, yet comparatively slow at mounting. Quite mature and stable. ReiserFS is not actively developed at this time (Reiser4 is the new Reiser filesystem). Generally regarded as a good choice for /var/.<br />
<br />
4. '''JFS''' - IBM's '''J'''ournaled '''F'''ile'''S'''ystem- The first filesystem to offer journaling. JFS had many years of use in the IBM AIX® OS before being ported to Linux. JFS currently uses the least CPU resources of any GNU/Linux filesystem. Very fast at formatting, mounting and fsck's, and very good all-around performance, especially in conjunction with the deadline I/O scheduler. (See [[JFS]].) Not as widely supported as ext or ReiserFS, but very mature and stable.<br />
<br />
5. '''XFS''' - Another early journaling filesystem originally developed by Silicon Graphics for the IRIX OS and ported to Linux. XFS offers very fast throughput on large files and large filesystems. Very fast at formatting and mounting. Generally benchmarked as slower with many small files, in comparison to other filesystems. XFS is very mature and is currently the only available stable Linux FS with online defragmentation ability.<br />
<br />
===== A note on Journaling=====<br />
All above filesystems, except ext2, use [http://en.wikipedia.org/wiki/Journaling_file_system journaling]. Journaling file systems are fault-resilient file systems that use a journal to log changes before they're committed to the file system to avoid metadata corruption in the event of a crash. Note that not all journaling techniques are alike; specifically, only ext3 offers ''data-mode journaling'', (though, not by default), which journals ''both'' data ''and'' meta-data (but with significant speed penalty). The others only offer ''ordered-mode journaling'', which journals meta-data only. While all will return your filesystem to a valid state after recovering from a crash, ''data-mode journaling'' offers the greatest protection against file system corruption and data loss but can suffer from performance degradation, as all data is written twice (first to the journal, then to the disk). Depending on how important your data are, this may be a consideration in choosing your filesystem type.<br />
<br />
'''''Moving on...'''''<br />
<br />
Choose and create the filesystem (format the partition) for / by selecting '''yes'''. You will now be prompted to add any additional partitions. In our example, sda2 and sda4 remain. For sda2, choose a filesystem type and mount it as /var. Finally, choose the filesystem type for sda4, and mount it as /home. Return to main menu.<br />
<br />
===Select Packages===<br />
<br />
*Core ISO: Choose CD as source and select the appropriate CD drive if you have more than one.<br />
*FTP ISO: Select an FTP/HTTP mirror. ''Note that archlinux.org is throttled to 50KB/s''.<br />
* 2008.06 installation media: Package category BASE is now installed by default.<br />
<br />
Package selection is split into two stages. First, you will select the base package category, then you will be presented will the full lists of packages, allowing you to fine-tune your selections. Use the space bar to select and unselect.<br />
<br />
Choose OK to continue and then choose 'yes' for 'Select all packages by default', for now.<br />
<br />
The next screen will present you with the selected packages within your selected categories. Leaving all selected is a safe choice for beginners, while more experienced users will wish to trim a few unnecessary packages. (For instance, an unneeded filesystem type utility, unneeded drivers, etc.)<br />
<br />
===Install Packages===<br />
Next, choose 'Install Packages'. You will be asked if you wish to keep the packages in the pacman cache. If you choose 'yes', you will have the flexibility to [[Downgrade packages|downgrade]] to previous package versions in the future, so this is recommended (you can always clear the cache in the future). The installer script will now install the selected packages, as well as the default Arch 2.6 kernel, to your system. <br />
*FTP ISO: The [[Pacman]] package manager will now download and install your selected packages. (See vc/5 for output, vc/1 to return to the installer)<br />
*CORE ISO: The packages will be installed from the CD.<br />
<br />
Note: For Arch 2007.08 FTP installation: after 'Install Packages' you have to upgrade pacman (<ALT>+F3, pacman -Sy pacman) and again 'Install Packages'.<br />
<br />
===Configure the System===<br />
''Closely following and understanding these steps is of key importance to ensure a properly configured system.'' <br />
<br />
At this stage of the installation, you will configure the primary configuration files of your Arch Linux base system.<br />
<br />
The installer will ask if you want to choose [[Hwdetect|hwdetect]] to gather information for your configuration. Beginners should choose 'yes'. <br />
<br />
Advanced users who are thoroughly familiar with their hardware, required modules, and who are able and willing to manually configure /etc/rc.conf, /etc/mkinitcpio, /etc/fstab, and other system-critical configuration files from scratch may wish to choose 'no'. (Needless to say, this option is very involved, beyond the scope of this guide, and therefore is not covered.)<br />
<br />
Next, you will be asked if you need support for booting from USB devices, FireWire devices, PCMCIA devices, NFS shares, software RAID arrays, LVM2 volumes, encrypted volumes, and DSDT support. Choose yes if you need it; in our example nothing is needed. <br />
<br />
Now you will be asked which text editor you want to use; choose [http://en.wikipedia.org/wiki/Nano_%28text_editor%29 nano] or, if you are familiar with it, [http://en.wikipedia.org/wiki/Vim_%28text_editor%29 vim]. You will be presented with a menu including the main configuration files for your system. <br />
<br />
{{Box Note | ''It is very important at this point to edit, or at the very least, to verify by opening, every configuration file.'' The installer script relies on your input to create these files on your installation. A common error is to skip over these critical steps of configuration.}}<br />
<br />
=====Can the installer handle this more automatically?=====<br />
Hiding the process of system configuration is in direct opposition to [[The Arch Way]]. While it is true that recent versions of the kernel and hardware probing tools offer excellent hardware support and auto-configuration, Arch presents the user all pertinent configuration files during installation for the purposes of ''transparency and system resource control''. By the time you have finished modifying these files to your specifications, you will have learned the simple method of manual Arch Linux system configuration and become more familiar with the base structure, leaving you better prepared to use and maintain your new installation productively.<br />
<br />
====='''/etc/rc.conf'''=====<br />
Arch Linux follows in the '''*BSD''' tradition of utilizing '''/etc/rc.conf''' as the principal location for system configuration. This one file contains a wide range of configuration information, principally used at system startup. As its name directly implies, it also contains settings for and invokes the /etc/rc* files, and is, of course, sourced ''by'' these files. /etc/rc.conf offers a simple, elegant method of streamlining system resource configuration by encompassing a wide range of control, readily accessible for the Arch user. <br />
* '''LOCALIZATION''' section<br />
** '''LOCALE'''=: This sets your system locale, which will be used by all i18n-aware applications and utilities. You can get a list of the available locales by running 'locale -a' from the command line. This setting's default is fine for US English users. <br />
** '''HARDWARECLOCK'''=: Specifies whether the hardware clock, which is synchronized on boot and on shutdown, stores '''UTC''' time, or the '''localtime'''. UTC makes sense because it greatly simplifies changing timezones and daylight savings time. localtime is necessary if you dual boot with an operating system such as Windows, that only stores localtime to the hardware clock.<br />
** '''TIMEZONE'''=: Specify your TIMEZONE. (All available zones are under /usr/share/zoneinfo/).<br />
** '''KEYMAP'''=: The available keymaps are in /usr/share/kbd/keymaps. Please note that this setting is only valid for your TTYs, not any graphical window managers or '''X'''.<br />
** '''CONSOLEFONT'''=: Available console fonts reside under /usr/share/kbd/consolefonts/ if you must change. The default (blank) is safe.<br />
** '''CONSOLEMAP'''=: Defines the console map to load with the setfont program at boot. Possible maps are found in /usr/share/kbd/consoletrans, if needed. The default (blank) is safe. <br />
** '''USECOLOR'''=: Select "yes" if you have a color monitor and wish to have colors in your consoles.<br />
<br />
LOCALE="en_US.utf8"<br />
HARDWARECLOCK="localtime"<br />
TIMEZONE="US/Eastern"<br />
KEYMAP="us"<br />
CONSOLEFONT=<br />
CONSOLEMAP=<br />
USECOLOR="yes"<br />
<br />
* '''HARDWARE''' section<br />
** '''MOD_AUTOLOAD'''=: Setting this to "yes" will use '''udev''' to automatically probe hardware and load the appropriate modules during boot-up, (convenient with the default modular kernel). Setting this to "no" will rely on the user's ability to specify this information manually, or compile their own custom kernel and modules, etc.<br />
** '''MOD_BLACKLIST'''=: This has become deprecated in favor of adding blacklisted modules directly to the '''MODULES=''' line below. <br />
** '''MODULES'''=: Specify additional MODULES if you know that an important module is missing, ('''hwdetect''' should have filled in the most important modules). Also specify any blacklisted modules by prefixing them with a bang (!). Udev will be forced NOT to load blacklisted modules. In the example, the IPv6 module as well as the annoying pcspeaker are blacklisted. <br />
# Scan hardware and load required modules at boot<br />
MOD_AUTOLOAD="yes"<br />
# Module Blacklist - Deprecated<br />
MOD_BLACKLIST=()<br />
#<br />
MODULES=(e100 eepro100 mii slhc snd-ac97-codec snd-intel8x0 soundcore !net-pf-10 !pcspkr)<br />
<br />
* '''NETWORKING''' section<br />
** '''HOSTNAME'''=:Set your HOSTNAME to your liking.<br />
** '''eth0'''=: 'Ethernet, card 0'. Adjust the interface IP address, netmask and broadcast address ''if'' you are using '''static IP'''. Set eth0="dhcp" if you want to use '''DHCP'''<br />
** '''INTERFACES'''=: Specify any/all interfaces here. If you do not use DHCP to configure a device, just keep in mind that the value of the variable (whose name must be equal to the name of the device which is supposed to be configured) equals the line which would be appended to the ifconfig command if you were to configure the device manually in the shell.<br />
** '''gateway'''=: If you are using '''static IP''', set the gateway address. If using '''DHCP''', you can usually ignore this variable, though some users have reported the need to define it.<br />
** '''ROUTES'''=: If you are using static '''IP''', remove the '''!''' in front of 'gateway'. If using '''DHCP''', you can usually leave this variable commented out with the bang (!), but again, some users require the gateway and ROUTES defined. If you experience networking issues with pacman, for instance, you may want to return to these variables. <br />
<br />
Example, using '''DHCP''':<br />
HOSTNAME="arch"<br />
#eth0="eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255" <br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
gateway="default gw 192.168.0.1"<br />
ROUTES=(!gateway)<br />
{{Box Note | Arch uses the '''dhcpcd''' DHCP client. Alternatively, '''dhclient''' is available from the [extra] repository via pacman.}}<br />
<br />
* '''DAEMONS''' section<br />
<br />
This array simply lists the names of those scripts contained in /etc/rc.d/ which are to be started during the boot process, and the order in which they start. <br />
DAEMONS=(@network syslog-ng netfs crond)<br />
*If a script name is prefixed with a bang (!), it is not executed. <br />
*If a script is prefixed with an "at" symbol (@), then it will be executed in the background; the startup sequence will not wait for successful completion of each daemon before continuing to the next. (Useful for speeding up system boot).<br />
*Edit this array whenever new system services are installed, if starting them automatically during boot is desired. <br />
<br />
This 'BSD-style' init, is the Arch way of handling what others handle with various symlinks to an /etc/init.d directory.<br />
<br />
=====About DAEMONS=====<br />
You do not have to change the [[daemons]] line at this time, but it is useful to explain what daemons are, because we need them later in this guide. <br />
A ''daemon'' is a program that runs in the background, waiting for events to occur and offering services. A good example is a webserver that waits for a request to deliver a page or an SSH server waiting for someone trying to log in. While these are full-featured applications, there are daemons whose work is not that visible. Examples are a daemon which writes messages into a log file (e.g. syslog, metalog), a daemon which lowers your CPU's frequency if your system has nothing to do (e.g.:cpufreq), and a daemon which offers you a graphical login (e.g.: gdm, kdm). All these programs can be added to the daemons line and will be started when the system boots. Useful daemons will be presented during this guide.<br />
<br />
Historically, the term ''daemon'' was coined by the programmers of MIT's Project MAC. They took the name from ''Maxwell's demon'', an imaginary being from a famous thought experiment that constantly works in the background, sorting molecules. <code>UNIX</code> systems inherited this terminology and created the backronym '''d'''isk '''a'''nd '''e'''xecution '''mon'''itor. <br />
<br />
*<font color="blue">'''Tip:</font> All Arch daemons reside under /etc/rc.d/'''<br />
<br />
=====/etc/fstab=====<br />
The '''fstab''' (for '''f'''ile '''s'''ystems '''tab'''le) is part of the system configuration listing all available disks and disk partitions, and indicating how they are to be initialized or otherwise integrated into the overall system's filesystem. The '''/etc/fstab''' file is most commonly used by the '''mount''' command. The mount command takes a filesystem on a device, and adds it to the main system heirarchy that you see when you use your system. '''mount -a''' is called from /etc/rc.sysinit, about 3/4 of the way through the boot process, and reads /etc/fstab to determine which options should be used when mounting the specified devices therein. If '''noauto''' is appended to a filesystem in /etc/fstab, '''mount -a''' will not mount it at boot.<br />
<br />
An example '''/etc/fstab''':<br />
# <file system> <dir> <type> <options> <dump> <pass><br />
none /dev/pts devpts defaults 0 0<br />
none /dev/shm tmpfs defaults 0 0<br />
#/dev/cdrom /media/cdrom auto ro,user,noauto,unhide 0 0<br />
#/dev/dvd /media/dvd auto ro,user,noauto,unhide 0 0<br />
#/dev/fd0 /media/fl auto user,noauto 0 0<br />
/dev/disk/by-uuid/0ec-933.. / jfs defaults,noatime,nodiratime 0 1<br />
/dev/disk/by-uuid/7ef-223.. /home jfs defaults,noatime,nodiratime 0 2<br />
/dev/disk/by-uuid/530-1e-.. swap swap defaults 0 0<br />
/dev/disk/by-uuid/4fe-110.. /var reiserfs defaults,noatime,notail 0 2 <br />
{{Box Note | '''''The 'noatime' and 'nodiratime' options may safely be appended to / and /home regardless of your specified filesystem type for increased speed, performance, and power efficiency, for laptops as well as desktops. 'notail' disables the ReiserFS tailpacking feature, for added performance at the cost of slightly less efficient disk usage.'''''}}<br />
<br />
* The first field, '''<file system>''', describes the block device or remote filesystem to be mounted. For regular mounts, this field will contain a link to a block device node (as created by mknod which is called by udev at boot) for the device to be mounted; for instance, '/dev/cdrom' or '/dev/sda1'. Instead of giving the device explicitly, the Arch installer indicates the filesystem that is to be mounted by its UUID by default.<br />
{{Box Note | As of 2008-04rc, Arch is now utilizing the UUID, or Universally Unique Identifier naming convention, for consistent device mapping. This is due to active developments in the kernel and also udev, which may randomly change the ordering in which drivers for storage controllers are loaded, yielding an unbootable system/kernel panic. Nearly every motherboard has several controllers (onboard SATA, onboard IDE), and due to the aforementioned development updates, /dev/sda may become /dev/sdb on the next reboot- hence the persistent device naming convention of UUID has been adopted for reliability. ''If you do not need nor wish to use UUID, simply change your fstab to use whatever naming convention desired.'' (See [[Persistent block device naming| this wiki article]] for more information on persistent block device naming. )}}<br />
ls -lF /dev/disk/by-uuid/<br />
Will list all partitions by uuid.<br />
<br />
* The second field, '''<dir>''', describes the mount point for the filesystem. For swap partitions, this field should be specified as 'swap'; (Swap partitions are not actually mounted.)<br />
<br />
* The third field, '''<type>''', describes the type of the filesystem. The Linux kernel supports many filesystem types. (For the filesystems currently supported by the running kernel, see /proc/filesystems). An entry 'swap' denotes a file or partition to be used for swapping. An entry 'ignore' causes the line to be ignored. This is useful to show disk partitions which are currently unused. <br />
<br />
* The fourth field, '''<options>''', describes the mount options associated with the filesystem. It is formatted as a comma separated list of options. It contains at least the type of mount plus any additional options appropriate to the filesystem type. For documentation on the available options for non-nfs file systems, see mount(8).<br />
<br />
* The fifth field, '''<dump>''', is used for these filesystems by the dump(8) command to determine which filesystems need to be dumped. dump is a backup utility. If the fifth field is not present, a value of zero is returned and dump will assume that the filesystem does not need to be backed up. ''Note that dump is not installed by default.''<br />
<br />
* The sixth field, '''<pass>''', is used by the fsck(8) program to determine the order in which filesystem checks are done at boot time. The root filesystem should be specified with a <pass> of 1, and other filesystems should have a <pass> of 2 or 0. Filesystems within a drive will be checked sequentially, but filesystems on different drives will be checked at the same time to use parallelism available in the hardware. If the sixth field is not present or zero, a value of zero is returned and fsck will assume that the filesystem does not need to be checked. <br />
<br />
*If you plan on using '''hal''' to automount media such as DVDs, you may wish to comment out the cdrom and dvd entries in preparation for '''hal''', which will be installed later in this guide.<br />
<br />
<br />
<br />
Expanded information available in the [[Fstab]] wiki entry.<br />
<br />
====='''[[Configuring mkinitcpio | /etc/mkinitcpio]].conf'''=====<br />
Editing this configuration is unnecessary at this point; this information is provided for explanation. <br />
<br />
This file allows you to fine-tune the initial ram filesystem (also commonly referred to as the initial ramdisk or "initrd") for your system. The initrd is a gzipped image that is read by the kernel during boot. The purpose of the initrd is to bootstrap the system to the point where it can access the root filesystem. This means it has to load any modules that are required for devices like IDE, SCSI, or SATA drives (or USB/FW, if you are booting off a USB/FW drive). Once the initrd loads the proper modules, either manually or through udev, it passes control to the Arch system and your boot continues. For this reason, the initrd only needs to contain the modules necessary to access the root filesystem. It does not need to contain every module you would ever want to use. The majority of your everyday modules will be loaded later on by udev, during the init process.<br />
<br />
'''mkinitcpio''' is the next generation of '''initramfs creation'''. It has many advantages over the old '''mkinitrd''' and '''mkinitramfs''' scripts.<br />
<br />
* It uses '''klibc''' and '''kinit''' which are developed by Linux kernel devs to provide a small and lightweight base for early userspace.<br />
* It can use '''udev''' for hardware autodetection at runtime, thus prevents you from having tons of unnecessary modules loaded.<br />
* Its hook-based init script is easily extendable with custom hooks, which can easily be included in pacman packages without having to modifiy mkinitcpio itself.<br />
* It already supports '''lvm2''', '''dm-crypt''' for both legacy and luks volumes, '''raid''', '''swsusp''' and '''suspend2''' resuming and booting from '''usb mass storage''' devices.<br />
* Many features can be configured from the kernel command line without having to rebuild the image.<br />
* The '''mkinitcpio''' script makes it possible to include the image in a kernel, thus making a self-contained kernel image is possible.<br />
* Its flexibility makes recompiling a kernel unnecessary in many cases. <br />
'''mkinitcpio''' was developed by Aaron Griffin and Tobias Powalowski with some help from the community.<br />
<br />
===== /etc/modprobe.conf=====<br />
It is unnecessary to configure this file at this time.<br />
<br />
* '''modprobe.conf''' can be used to set special configuration options for the kernel modules<br />
<br />
=====/etc/resolv.conf (for Static IP)=====<br />
The ''resolver'' is a set of routines in the C library that provide access to the Internet Domain Name System (DNS). One of the main functions of DNS is to translate domain names into IP addresses, to make the Web a friendlier place. The resolver configuration file, or /etc/resolv.conf, contains information that is read by the resolver routines the first time they are invoked by a process.<br />
<br />
*''If you are using DHCP, you may safely ignore this file, as by default, it will be dynamically created and destroyed by the dhcpcd daemon. You may change this default behavior if you wish. (See [http://wiki.archlinux.org/index.php/Network#For_DHCP_IP Network]]).''<br />
<br />
If you use a static IP, set your DNS servers in /etc/resolv.conf (nameserver <ip-address>). You may have as many as you wish.<br />
An example, using OpenDNS:<br />
nameserver 208.67.222.222<br />
nameserver 208.67.220.220<br />
<br />
If you are using a router, you will probably want to specify your DNS servers in the router itself, and merely point to it from your '''/etc/resolv.conf''', using your router's IP (which is also your gateway from '''/etc/rc.conf'''), e.g.:<br />
nameserver 192.168.1.1<br />
<br />
If using '''DHCP''', you may also specify your DNS servers in the router, or allow automatic assignment from your ISP, if your ISP is so equipped.<br />
<br />
=====/etc/hosts=====<br />
<br />
This file associates IP addresses with hostnames and aliases, one line per IP address. For each host a single line should be present with the following information:<br />
<IP-address> <hostname> [aliases...]<br />
Add your ''hostname'', coinciding with the one specified in /etc/rc.conf, as an alias, so that it looks like this:<br />
127.0.0.1 localhost.localdomain localhost '''''yourhostname'''''<br />
{{Box Note |''This format, '''including the 'localhost' and your actual host name''', is required for program compatibility! Errors in this entry may cause poor network performance and/or certain programs to open very slowly, or not work at all. This is a very common error for beginners.''}}<br />
<br />
If you use a static IP, add another line using the syntax: <static-IP> <hostname.domainname.org> <hostname> e.g.:<br />
192.168.1.100 '''''yourhostname'''''.domain.org '''''yourhostname'''''<br />
<br />
*<font color="blue">'''TIP''':</font> For convenience, you may also use /etc/hosts aliases for hosts on your network, and/or on the Web, e.g.:<br />
64.233.169.103 www.google.com g<br />
192.168.1.90 media<br />
192.168.1.88 data<br />
The above example would allow you to access google simply by typing 'g' into your browser, and access to a media and data server on your network by name and without the need for typing out their respective IP addresses.<br />
<br />
=====/etc/hosts.deny and /etc/hosts.allow=====<br />
Modify these configurations according to your needs if you plan on using the [[SSH|ssh]] daemon. The default configuration will reject all incoming connections, not only ssh connections. Edit your '''/etc/hosts.allow '''file and add the appropriate parameters: <br />
<br />
* let everyone connect to you<br />
sshd: ALL<br />
<br />
* restrict it to a certain ip<br />
sshd: 192.168.0.1<br />
<br />
* OR restrict for an IP range<br />
sshd: 10.0.0.0/255.255.255.0<br />
<br />
If you do not plan on using the [[SSH|ssh]] daemon, leave this file at the default, (empty), for added security.<br />
<br />
=====/etc/locale.gen=====<br />
<br />
The '''/usr/sbin/locale-gen''' command reads from '''/etc/locale.gen''' to generate specific locales. They can then be used by '''glibc''' and any other locale-aware program or library for rendering "peculiar" text, correctly displaying regional monetary values, time and date formats, alphabetic idiosyncrasies, and other locale-specific standards. The ability to setup a default locale is a great built-in privilege of using a <code>UNIX</code>-like operating system.<br />
<br />
By default /etc/locale.gen is an empty file with commented documentation. Once edited, the file remains untouched. '''locale-gen''' runs on every '''glibc''' upgrade, generating all the locales specified in /etc/locale.gen.<br />
<br />
Choose the locale(s) you need (remove the # in front of the lines you want), e.g.:<br />
en_US ISO-8859-1<br />
en_US.UTF-8 <br />
<br />
The installer will now run the locale-gen script, which will generate the locales you specified. You may change your locale in the future by editing /etc/locale.gen and subsequently running 'locale-gen' as root.<br />
<br />
{{Box Note |'''''If you fail to choose your locale, this will lead to a "The current locale is invalid..." error. This is perhaps the most common mistake by new Arch users, and also leads to the most commonly asked questions on the forum.'''''}}<br />
<br />
=====Root password=====<br />
Finally, set a root password and make sure that you remember it later. Return to the main menu and continue with installing bootloader.<br />
<br />
=====Pacman-Mirror=====<br />
Choose a mirror repository for '''pacman'''. <br />
*''archlinux.org is throttled, limiting downloads to 50KB/s'' <br />
<br />
Return to the main menu.<br />
<br />
===Install Bootloader===<br />
Because we have no secondary operating system in our example, we will need a bootloader. [http://www.gnu.org/software/grub/ GNU GRUB] is the recommended bootloader. Alternatively, you may choose [http://lilo.go.dyndns.org/ LILO]. <br />
====GRUB====<br />
The provided '''GRUB''' configuration ('''/boot/grub/menu.lst''') should be sufficient, but verify its contents to ensure accuracy. You may want to alter the resolution of the console by adding a vga=<number> kernel argument corresponding to your desired virtual console resolution. (A table of resolutions and the corresponding numbers is printed in the menu.lst.)<br />
<br />
Example: <br />
title Arch Linux (Main)<br />
root (hd0,0) <br />
kernel /boot/vmlinuz26 root=/dev/disk/by-uuid/0ec1-9339.. ro vga=773<br />
initrd /boot/kernel26.img<br />
{{Box Note | ''The linux kernel, 'vmlinuz', is so named because it incorporated '''v'''irtual '''m'''emory capability early in its development. The '''z''' denotes a zipped (compressed) image.''}}<br />
<br />
Explanation:<br />
<br />
Line 1: '''title''': A printed menu selection. "Arch Linux (Main)" will be printed on the screen as a menu selection.<br />
<br />
Line 2: '''root''': '''GRUB''''s root; the drive and partition where the kernel (/boot) resides, according to system BIOS. (More accurately, where GRUB's stage2 file resides). '''NOT necessarily the root''' (/) file system, as they can reside on separate partitions. GRUB's numbering scheme starts at 0, and uses an hd''x,x'' format regardless of IDE or SATA, and enclosed within parentheses. <br />
<br />
The example indicates that /boot is on the first partition of the first drive, according to BIOS, or, (hd0,0).<br />
<br />
Line 3: '''kernel''': This line specifies:<br />
<br />
* The path and filename of the kernel '''''relative to GRUB's root'''''.<br />
In the example, /boot is merely a directory residing on the same partition as / and '''vmlinuz26''' is the kernel filename; '''/boot/vmlinuz26'''. ''If /boot were on a separate partition, the path and filename would be simply '''/vmlinuz26''', being relative to '''GRUB''''s root.'' <br />
<br />
* The root= argument to the kernel statement specifies the partition containing the root (/) directory in the booted system, (more accurately, the partition containing '''/sbin/init'''), ''according to the UUID numbering scheme'' as of 2008-04rc, which uses the /dev/disk/by-uuid/xxxx-xxxx-xxxx format. <br />
<br />
*An easy way to distinguish the 2 appearances of 'root' in /boot/grub/menu.lst is to remember that the first root statement ''informs GRUB where the kernel resides'', whereas the second root= kernel argument ''tells the kernel where the root filesystem (/) resides''.<br />
<br />
* Kernel options. <br />
<br />
In our example, '''ro''' mounts the filesystem as read only during startup, and the '''"vga=773"''' argument will give a 1024x768 framebuffer with 256 color depth.<br />
<br />
Line 4: '''initrd''': (For Initial RAM disk) The path and filename of the initial RAM filesystem '''relative to GRUB''''s root. Again, in the example, /boot is merely a directory residing on the same partition as / and '''kernel26.img''' is the initrd filename; '''/boot/kernel26.img'''. ''If /boot were on a separate partition, the path and filename would be simply '''/kernel26.img''', being relative to '''GRUB''''s root.'' <br />
<br />
Install the '''GRUB''' bootloader to the master boot record, (sda in our example).<br />
<br />
===Reboot===<br />
<br />
That's it; You have configured and installed your Arch Linux base system. Exit the install, and reboot:<br />
<br />
# reboot<br />
(Be sure to remove the installer CD)<br />
<br />
Your new Arch Linux system will boot up and finish with a login prompt (you may want to change the boot order in your '''BIOS''' back to booting from hard disk).<br />
<br />
'''Congratulations, and welcome to your shiny, new Arch Linux base system!'''<br />
<br />
Your new Arch Linux base system is now a functional GNU/Linux environment ready for customization. From here, you may build this elegant set of tools into whatever you wish or require for your purposes. <br />
<br />
Login with the root account. We will configure pacman and update the system as root, then add a normal user. <br />
{{Box Note |Virtual consoles 1-6 are available.}}<br />
<br />
===Configuring the network (if necessary)===<br />
*''This section will assist you in configuring most types of networks, if your network configuration is not working for you.''<br />
<br />
If you properly configured your system, you should have a working network. Try to ping www.google.com to verify this.<br />
# ping -c 3 www.google.com<br />
<br />
''If you have successfully established a network connection, continue with '''[[#Update, Sync and Upgrade the system with pacman|Update, Sync and Upgrade the system with pacman]]'''.''<br />
<br />
If, after trying to ping www.google.com, you get an "unknown host" error, you may conclude that your network is not properly configured. You may choose to double-check the following files for integrity and proper settings:<br />
<br />
'''/etc/rc.conf''' # Specifically, check your HOSTNAME= and NETWORKING section for typos and errors.<br />
<br />
'''/etc/hosts''' # Double-check your format. (See above.)<br />
<br />
'''/etc/resolv.conf''' # If you are using a static IP. If you are using DHCP, this file will be dynamically created and destroyed by default, but can be changed to your preference. (See [[Network]].)<br />
<br />
Advanced instructions for configuring the network can be found in the [[Network]] article.<br />
<br />
====Wired LAN====<br />
<br />
Check your Ethernet with<br />
# ifconfig -a<br />
All interfaces will be listed. You should see an entry for eth0, or perhaps eth1. <br />
*'''Static IP'''<br />
<br />
If required, you can set a new static IP with:<br />
# ifconfig eth0 <ip address> netmask <netmask> up <br />
and the default gateway with<br />
# route add default gw <ip address of the gateway><br />
Verify that /etc/resolv.conf contains your DNS server and add it if it is missing. <br />
Check your network again with ping www.google.com. If everything is working now, adjust /etc/rc.conf as described above for static IP. <br />
*'''DHCP'''<br />
If you have a DHCP server/router in your network try:<br />
# dhcpcd eth0<br />
If this is working, adjust /etc/rc.conf as described above, for dynamic IP.<br />
<br />
====Wireless LAN====<br />
* Ensure the driver has created a usable interface:<br />
# iwconfig<br />
* Bring the interface up with <code>ifconfig <interface> up</code>. e.g.:<br />
# ifconfig ath0 up<br />
* (Optional) Scan for available access points:<br />
# iwlist ath0 scan | less<br />
* Specify the id of the wireless network with <code>iwconfig <interface> essid <youressid></code>. Or, if using WEP; <code>iwconfig <interface> essid <youressid> key <yourwepkey></code>, e.g.:<br />
# iwconfig ath0 essid linksys key 0241baf34c<br />
* Request an IP address with <code>dhcpcd <interface></code>. e.g.:<br />
# dhcpcd ath0<br />
* Ensure you can route:<br />
$ ping -c 3 www.google.com<br />
Done.<br />
<br />
Detailed setup guide: [[Wireless Setup]]<br />
<br />
====Analog Modem====<br />
To be able to use a Hayes-compatible, external, analog modem, you need to at least have the ppp package installed. Modify the file /etc/ppp/options to suit your needs and according to man pppd. You will need to define a chat script to supply your username and password to the ISP after the initial connection has been established. The manpages for pppd and chat have examples in them that should suffice to get a connection up and running if you're either experienced or stubborn enough. With udev, your serial ports usually are /dev/tts/0 and /dev/tts/1.<br />
Tip: Read [[Dialup without a dialer HOWTO]].<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt to install wvdial or a similar tool to ease the setup process considerably. In case you're using a so-called WinModem, which is basically a PCI plugin card working as an internal analog modem, you should indulge in the vast information found on the [http://www.linmodems.org/ LinModem] homepage.<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, meaning that you will not need to recompile your kernel unless you're about to use rather odd ISDN hardware. After physically installing your ISDN card in your machine or plugging in your USB ISDN-Box, you can try loading the modules with modprobe. Nearly all passive ISDN PCI cards are handled by the hisax module, which needs two parameters: type and protocol. You must set protocol to '1' if your country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3' if you're hooked to a so-called leased-line without D-channel, and '4' for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the kernel documentation, more specifically in the isdn subdirectory, and available online. The type parameter depends on your card; a list of all possible types can be found in the README.HiSax kernel documentation. Choose your card and load the module with the appropriate options like this:<br />
<br />
# modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my ELSA Quickstep 1000PCI, being used in Germany with the EDSS1 protocol. You should find helpful debugging output in your /var/log/everything.log file, in which you should see your card being prepared for action. Please note that you will probably need to load some USB modules before you can work with an external USB ISDN Adapter.<br />
<br />
Once you have confirmed that your card works with certain settings, you can add the module options to your /etc/modprobe.conf:<br />
<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively, you can add only the options line here, and add hisax to your MODULES array in the rc.conf. It's your choice, really, but this example has the advantage that the module will not be loaded until it's really needed.<br />
<br />
That being done, you should have working, supported hardware. Now you need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl; it'll get you started. Further down in the manpage you will find explanations on how to create a configuration file that can be parsed by isdnctrl, as well as some helpful setup examples. Please note that you have to add your SPID to your MSN setting separated by a colon if you use US NI1.<br />
<br />
After you have configured your ISDN card with the isdnctrl utility, you should be able to dial into the machine you specified with the PHONE_OUT parameter, but fail the username and password authentication. To make this work add your username and password to /etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were configuring a normal analogous PPP link, depending on which protocol your ISP uses for authentication. If in doubt, put your data into both files.<br />
<br />
If you set up everything correctly, you should now be able to establish a dial-up connection with<br />
# isdnctrl dial ippp0<br />
as root. If you have any problems, remember to check the logfiles!<br />
<br />
====DSL (PPPoE)====<br />
<br />
These instructions are relevant to you only if your PC itself is supposed to manage the connection to your ISP. You do not need to do anything but define a correct default gateway if you are using a separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to physically install the network card that is supposed to be connected to the DSL-Modem into your computer. After adding your newly installed network card to the modules.conf/modprobe.conf or the MODULES array, you should install the rp-pppoe package and run the pppoe-setup script to configure your connection. After you have entered all the data, you can connect and disconnect your line with<br />
<br />
# /etc/rc.d/adsl start<br />
<br />
and<br />
<br />
# /etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward, but feel free to read the manpages for hints. If you want to automatically 'dial in' on boot-up, add adsl to your DAEMONS array.<br />
<br />
===Update, Sync and Upgrade the system with [[pacman]]===<br />
Now we will update the system using [[pacman]]. <br />
<br />
====What is pacman ?====<br />
[[Pacman]] is the '''pac'''kage '''man'''ager of Arch Linux. Pacman is written in ''C'' and is designed from the ground up to be lightweight with a very modest memory footprint, fast, simple, and versatile. It manages your entire package system and handles installation, removal, package downgrade (through cache), custom compiled package handling, automatic dependency resolution, remote and local searches and much more. Arch uses the .tar.gz package format, which further enhances pacman's speed; Gzipped tarballs, though slightly larger, are decompressed many times faster than their Bzipped counterparts, and are therefore installed much more expediently. <br />
<br />
We will use pacman to download software packages from remote repositories and install them onto your system.<br />
<br />
Pacman is the most important tool in your Arch Linux toolbox for building the base system into whatsoever you please.<br />
<br />
====Configuring pacman====<br />
<br />
=====Package Repositories and /etc/pacman.conf=====<br />
Arch currently offers the following 4 repositories readily accessible through pacman:<br />
<br />
'''[core]'''<br />
<br />
The simple principle behind [core] is to provide only one of each necessary tool for a base Arch Linux system; The GNU toolchain, the Linux kernel, one editor, one command line browser, etc. (There are a few exceptions to this. For instance, both vi and nano are provided, allowing the user to choose one or both.) It contains all the packages that MUST be in perfect working order to make sure your system continues to run. These are the absolute system-critical packages. Developer maintained.<br />
<br />
*''The Core installation media simply contains an installer script, and a snapshot of the core repository at the time of release.''<br />
<br />
'''[extra]'''<br />
<br />
The [extra] repository contains all Arch packages that are not themselves necessary for a base Arch system, but contribute to a more full-featured environment. '''X''', KDE, and Apache, for instance, can be found here. Developer maintained.<br />
<br />
'''[testing]'''<br />
<br />
The [testing] repository contains packages that are candidates for the [core] or [extra] repositories. New packages go into [testing] if:<br />
* they are expected to break something on update and need to be tested first<br />
* they require other packages to be rebuilt. In this case, all packages that need to be rebuilt are put into [testing] first and when all rebuilds are done, they are moved back to the other repositories. Developer maintained.<br />
<br />
[testing] is the only repository that can have name collisions with any of the other official repositories. If enabled, [testing] must be the first repo listed in your ''pacman.conf'' file.<br />
<br />
<font color="red">'''WARNING''': '''''Your system may break after you update with [testing] enabled. Only experienced users should use it.'''''</font><br />
<br />
'''[community]'''<br />
<br />
The [community] repository is maintained by the ''Trusted Users (TUs)'' and is part of the ''Arch User Repository ([[AUR]])''. It contains binary packages from the ''AUR'' that have enough votes and were adopted by a ''TU''. Like all repos listed above, [community] may be readily accessed by pacman.<br />
<br />
The '''[[AUR]]''' also contains the '''unsupported''' branch, which cannot be accessed directly by pacman*. [unsupported] contains more than eight thousand PKGBUILD scripts for building packages from source, that may be unavailable through the other repos. <br />
<br />
<nowiki>*</nowiki> '''''[[AUR Helpers]]''''' can help you seamlessly access AUR.<br />
<br />
'''/etc/pacman.conf'''<br />
<br />
pacman will attempt to read /etc/pacman.conf each time it is invoked. This configuration file is divided into sections, or repositories. Each section defines a package [[Official Repositories|repository]] that pacman can use when searching for packages. The exception to this is the options section, which defines global options.<br />
# nano /etc/pacman.conf<br />
Example:<br />
#<br />
# /etc/pacman.conf<br />
#<br />
# See the pacman.conf(5) manpage for option and repository directives<br />
<br />
#<br />
# GENERAL OPTIONS<br />
#<br />
[options]<br />
# The following paths are commented out with their default values listed.<br />
# If you wish to use different paths, uncomment and update the paths.<br />
#RootDir = /<br />
#DBPath = /var/lib/pacman/<br />
#CacheDir = /var/cache/pacman/pkg/<br />
#LogFile = /var/log/pacman.log<br />
HoldPkg = pacman glibc<br />
# If upgrades are available for these packages they will be asked for first<br />
SyncFirst = pacman<br />
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u<br />
#XferCommand = /usr/bin/curl %u > %o<br />
<br />
# Pacman won't upgrade packages listed in IgnorePkg and members of IgnoreGroup<br />
#IgnorePkg =<br />
#IgnoreGroup =<br />
<br />
#NoUpgrade =<br />
#NoExtract =<br />
<br />
# Misc options (all disabled by default)<br />
#NoPassiveFtp<br />
#UseSyslog<br />
#ShowSize<br />
#UseDelta<br />
#TotalDownload<br />
<br />
#<br />
# REPOSITORIES<br />
# - can be defined here or included from another file<br />
# - pacman will search repositories in the order defined here<br />
# - local/custom mirrors can be added here or in separate files<br />
# - repositories listed first will take precedence when packages<br />
# have identical names, regardless of version number<br />
# - URLs will have $repo replaced by the name of the current repo<br />
#<br />
# Repository entries are of the format:<br />
# [repo-name]<br />
# Server = ServerName<br />
# Include = IncludePath<br />
#<br />
# The header [repo-name] is crucial - it must be present and<br />
# uncommented to enable the repo.<br />
# <br />
<br />
# Testing is disabled by default. To enable, uncomment the following<br />
# two lines. You can add preferred servers immediately after the header,<br />
# and they will be used before the default mirrors.<br />
#[testing]<br />
#Include = /etc/pacman.d/mirrorlist<br />
<br />
[core]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
<br />
[extra]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist <br />
<br />
[community]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
<br />
# An example of a custom package repository. See the pacman manpage for<br />
# tips on creating your own repositories.<br />
#[custom]<br />
#Server = file:///home/custompkgs<br />
<br />
Enable all desired repositories (remove the # in front of the 'Include =' and '[repository]' lines).<br />
<br />
<br />
*'''''When choosing repos, be sure to uncomment both the repository header lines in [brackets] as well as the 'Include =' lines. Failure to do so will result in the selected repository being omitted! This is a very common error.'' '''<br />
<br />
=====/etc/pacman.d/mirrorlist=====<br />
Faster mirrors will dramatically improve pacman performance, and your overall Arch Linux experience.<br />
<br />
Edit /etc/pacman.d/mirrorlist:<br />
# nano /etc/pacman.d/mirrorlist<br />
Remove all mirrors which are not on your continent, or are extremely distant. (Using nano, you may use CTRL-K to cut each unneeded line.) <br />
<br />
Edit /etc/pacman.d/mirrorlist by placing the best mirror at the top of the list. (Recall that archlinux.org is throttled to 50KB/s). If using nano, you can cut a line with CTRL-K and paste with CTRL-U. <br />
<br />
After changing mirrors, issue the following command:<br />
# pacman -Syy<br />
Passing two --refresh or -y flags forces a refresh of all package lists even if they are considered by pacman to be up to date. Issuing pacman -Syy ''whenever a mirror is changed'', is good practice and will avoid possible headaches.<br />
<br />
=====Ignoring packages=====<br />
When you execute the command "pacman -Syu", your entire system will be updated. It is possible that you want to prevent a package from being upgraded. An example could be the kernel (kernel26) or a package for which an upgrade may prove problematic for your system. In this case, you have two options; indicate the packages you want to skip in the pacman command line using the --ignore switch (do pacman -S --help for details) or permanently indicate the packages you want to skip in your /etc/pacman.conf file:<br />
<br />
IgnorePkg = kernel26<br />
The typical way to use Arch is to use pacman to install all packages unless there is no package available, in which case you can build your own package using [[ABS]]. Many user-contributed package build scripts are also available in the [[AUR]]. <br />
<br />
You are expected to keep your system up to date with pacman -Syu, rather than selectively upgrading packages. You may diverge from this typical usage as you wish; just be warned that there is a greater chance that things will not work as intended and that it could break your system. The majority of complaints happen when selective upgrading, unusual compilation or improper software installation is performed. Use of '''IgnorePkg''' in /etc/pacman.conf is therefore discouraged, and should only be used sparingly, if you know what you are doing.<br />
<br />
=====Ignoring Configuration Files=====<br />
In the same vein, you can also "protect" your configuration/system files from being overwritten during "pacman -Su" using the following option in your /etc/pacman.conf<br />
<br />
NoUpgrade = etc/lilo.conf boot/grub/menu.lst<br />
<br />
===Update System===<br />
Sync, refresh, and '''upgrade''' your entire new system with:<br />
# pacman -Syu<br />
pacman will now download a fresh copy of the master package list from the server(s) defined in pacman.conf(5) and perform all available upgrades. (You may be prompted to upgrade pacman itself at this point. If so, say yes, and then reissue the pacman -Syu command when finished.) <br />
Reboot if a kernel upgrade has occurred. <br />
{{Box Note|'''''Occasionally, configuration changes may take place requiring user action during an update; read pacman's output for any pertinent information.'''''}}<br />
If the messages go by too fast to read, you can look at them later at /var/log/pacman.log.<br />
<br />
=====The beauty of the Arch rolling release model=====<br />
Keep in mind that Arch is a '''rolling release''' distribution. This means there is never a reason to reinstall or perform elaborate system rebuilds to upgrade to the newest version. Simply issuing '''pacman -Syu''' periodically keeps your entire system up-to-date and on the bleeding edge. At the end of this upgrade, your system is completely current. <br />
Reboot if a kernel upgrade has occurred.<br />
<br />
====Get familiar with pacman====<br />
Pacman is the Arch user's best friend. It is highly recommended to study and learn how to use the pacman(8) tool. Try:<br />
man pacman<br />
Check out the bottom of this article, and look up the [[pacman]] wiki entries at your leisure.<br />
<br />
===Add a user and setup groups===<br />
<code>UNIX</code> is a multi-user environment. You should not do your everyday work using the root account. It is more than poor practice; it is dangerous. Root is for administrative tasks. Instead, add a normal, non-root user account using the <code>/usr/sbin/useradd</code> program:<br />
# useradd -m -G [groups] -s [login_shell] [username] <br />
* '''-m''' Creates user home directory as /home/'''username'''. Within their home directory, a user can write files, delete them, install programs, etc. Users' home directories shall contain their data and personal configuration files, the so-called 'dot files' (their name is preceded by a dot), which are 'hidden'. (To view dotfiles, enable the appropriate option in your file manager or run ls with the -a switch.) If there is a conflict between ''user'' (under /home/username) and ''global'' configuration files, (usually under /etc/) the settings in the ''user'' file will prevail. Dotfiles likely to be altered by the end user include .xinitrc and .bashrc files. The configuration files for xinit and Bash respectively. They allow the user the ability to change the window manager to be started upon login and also aliases, user-specified commands and environment variables respectively. When a user is created, their dotfiles shall be taken from the /etc/skel directory where system sample files reside.<br />
* '''-G''' A list of supplementary groups which the user is also a member of. ''Each group is separated from the next by a comma, with no intervening spaces''. The default is for the user to belong only to the initial group (users). <br />
* '''-s''' The name of the user´s login shell. Leaving this field blank will cause the system to select the default login shell.<br />
Useful groups for your non-root user include:<br />
*'''audio''' - for tasks involving sound card and related software<br />
*'''floppy''' - for access to a floppy if applicable<br />
*'''lp''' - for managing printing tasks<br />
*'''optical''' - for managing tasks pertaining to the optical drive(s)<br />
*'''storage''' - for managing storage devices<br />
*'''video''' - for video tasks and 3d acceleration<br />
*'''wheel''' - for using sudo/su<br />
A typical example, adding a user named "archie" specifying bash as the login shell:<br />
# useradd -m -G users,audio,lp,optical,storage,video,wheel -s /bin/bash archie<br />
Next, add a password for your new user using <code>/usr/bin/passwd</code>.<br />
<br />
An example for our user, 'archie':<br />
# passwd archie<br />
(You will be prompted to provide the new <code>UNIX</code> password.)<br />
<br />
Your new non-root user has now been created, complete with a home directory and a login password.<br />
<br />
'''Alternative method, using <code>/usr/sbin/adduser</code>:'''<br />
<br />
Alternatively, you may use <code>adduser</code>, an interactive user adding program which will prompt you for the above data:<br />
# adduser<br />
<br />
See the [[Groups]] article and check the man pages for <code>usermod(8)</code> and <code>gpasswd(8)</code> for further information.<br />
<br />
In the event of error, or if you wish to delete this user account in favor of a different name or for any other reason, use <code>/usr/sbin/userdel</code>:<br />
# userdel -r [username]<br />
* '''-r ''' Files in the user´s home directory will be removed along with the home directory itself and the user´s mail spool.<br />
<br />
===Install and setup Sudo (Optional)===<br />
To install Sudo:<br />
# pacman -S sudo<br />
To add a user as a sudo user (a "sudoer"), the visudo command must be run as root. <br />
# visudo<br />
This will open the file /etc/sudoers in a special session of vi. visudo copies the file to be edited to a temporary file, edits it with an editor, (vi by default), and subsequently runs a sanity check. If it passes, the temporary file overwrites the original with the correct permissions. <br />
<br />
Alternatively, or if you do not know how to use vi, you may set the EDITOR environment variable to the editor of your choice before running visudo. e.g.:<br />
# EDITOR=nano visudo<br />
<font color="red">'''WARNING: Do not edit /etc/sudoers directly with an editor; Errors in syntax can cause annoyances (like rendering the root account unusable). You must use the ''visudo'' command to edit /etc/sudoers.'''</font><br />
<br />
To give the user full root privileges when he/she precedes a command with "sudo", add the following line:<br />
USER_NAME ALL=(ALL) ALL<br />
where USER_NAME is the username of the individual.<br />
<br />
For more information, such as sudoer <TAB> completion, see [[Sudo]]<br />
<br />
==Part II: Install X and configure ALSA==<br />
<br />
<br />
===Configure the audio card with alsamixer===<br />
The Advanced Linux Sound Architecture (known by the acronym '''ALSA''') is a Linux kernel component intended to replace the original Open Sound System (OSS) for providing device drivers for sound cards. Besides the sound device drivers, '''ALSA''' also bundles a user space library for application developers who want to use driver features with a higher level API than direct interaction with the kernel drivers. <br />
-----<br />
{{Box Note| Alsa is included in the Arch mainline kernel and udev will automatically probe your hardware on boot-up, loading the corresponding kernel module for your audio card. Therefore, your sound should already be working, but is muted by default.}} <br />
The alsa-utils package contains the alsamixer userspace tool, which will allow us to configure the sound device from the console. (You may also run alsamixer from an '''X''' environment later.)<br />
<br />
Install the alsa-utils package:<br />
# pacman -S alsa-utils<br />
Did you add your normal user to the audio group? If not, use <code>/usr/bin/gpasswd</code>. As root do:<br />
# gpasswd -a ''yourusername'' audio<br />
As '''''normal, non-root''''' user, invoke <code>/usr/bin/alsamixer</code>:<br />
# su - ''yourusername'' <br />
'''$''' alsamixer<br />
Unmute the Master and PCM channels by scrolling to them with cursor left/right and pressing '''M'''. Increase the volume levels with the cursor-up key. (70-90 Should be a safe range.) Some machines, (like the Thinkpad T61), have a '''Speaker''' channel which must be unmuted and adjusted as well. Leave alsamixer by pressing ESC. <br />
==== Sound Test ====<br />
Ensure your speakers are properly connected, and test your sound configuration as normal user using <code>/usr/bin/aplay</code>:<br />
$ aplay /usr/share/sounds/alsa/Front_Center.wav<br />
You should hear a very eloquent woman say, "Front, center."<br />
<br />
Then run <code>/usr/bin/alsactl</code> as root:<br />
$ su -<br />
# alsactl store<br />
This will create '/etc/asound.state', saving the alsamixer settings. <br />
<br />
Also, add the alsa ''daemon'' to your DAEMONS section in /etc/rc.conf to automatically restore the mixer settings on boot-up.<br />
# nano /etc/rc.conf<br />
DAEMONS=(syslog-ng network crond '''alsa''')<br />
''Note that the alsa daemon merely restores your volume mixer levels on boot up by reading /etc/asound.state. It is separate from the alsa audio library (and kernel level API).''<br />
<br />
Expanded information available in the [[ALSA]] wiki entry.<br />
<br />
===Installing and configuring X===<br />
The '''X''' Window System (commonly '''X11''', or just simply '''X''') is a networking and display protocol which provides windowing on bitmap displays. It provides the standard toolkit and protocol to build graphical user interfaces (GUIs) on <code>UNIX</code>-like operating systems.<br />
<br />
'''X''' provides the basic framework, or primitives, for building GUI environments: drawing and moving windows on the screen and interacting with a mouse and/or keyboard. '''X''' does not mandate the user interface — individual client programs handle this. <br />
<br />
'''X''' is so named because it was preceded by the '''W''' Window System, originally developed at Stanford University. <br />
-----<br />
<br />
{{Box Note| If you plan on using an '''open-source''' video driver, and need 3d acceleration, it is recommended to install the libgl library before installing Xorg:}}<br />
# pacman -S libgl<br />
''(Proprietary video drivers provide their own gl library implementations.)''<br />
----- <br />
Now we will install the base Xorg packages using pacman. This is the first step in building a GUI.<br />
<br />
# pacman -S xorg<br />
3d utilities such as glxgears are included in the '''mesa''' package:<br />
# pacman -S mesa<br />
<br />
Now we have the base packages we need for running the '''X''' Server. You should add the driver for your graphics card now (e.g. xf86-video-<name>). The easiest way to configure X.org is by installing the correct driver packages first, and then generating /etc/X11/xorg.conf using an autoconfiguration script, like Xorg -configure.<br />
<br />
You will need knowledge of which video chipset your machine has. If you do not know, use the <code>/usr/sbin/lspci</code> program:<br />
# lspci | grep VGA<br />
<br />
If you need a list of all '''open-source''' video drivers, do: <br />
# pacman -Ss xf86-video | less<br />
Here is a list of '''open source''' drivers, and the corresponding video chipsets.<br />
*'''xf86-video-apm''' Alliance ProMotion video driver<br />
*'''xf86-video-ark''' ark video driver<br />
*'''xf86-video-ati''' ATI(AMD) video driver<br />
*'''xf86-video-chips''' Chips and Technologies video driver<br />
*'''xf86-video-cirrus''' Cirrus Logic video driver<br />
*'''xf86-video-dummy''' dummy video driver<br />
*'''xf86-video-fbdev''' framebuffer video driver<br />
*'''xf86-video-glint''' GLINT/Permedia video driver<br />
*'''xf86-video-i128''' Number 0 i128 video driver<br />
*'''xf86-video-i740''' Intel i740 video driver<br />
*'''xf86-video-i810''' Intel i810/i830/i9xx video drivers (deprecated - use -intel)<br />
*'''xf86-video-intel''' Newer Version of Intel i810/i830/i9xx video drivers<br />
*'''xf86-video-imstt''' Integrated Micro Solutions Twin Turbo vidoe driver<br />
*'''xf86-video-mga''' mga video driver (Matrox Graphics Adapter)<br />
*'''xf86-video-neomagic''' neomagic video driver<br />
*'''xf86-video-nv''' Nvidia nv video driver<br />
*'''xf86-video-rendition''' Rendition video driver<br />
*'''xf86-video-s3''' S3 video driver<br />
*'''xf86-video-s3virge''' S3 Virge video driver<br />
*'''xf86-video-savage''' savage video driver<br />
*'''xf86-video-siliconmotion''' siliconmotion video driver<br />
*'''xf86-video-sis''' SiS video driver<br />
*'''xf86-video-sisusb''' SiS USB video driver<br />
*'''xf86-video-tdfx''' tdfx video driver<br />
*'''xf86-video-trident''' Trident video driver<br />
*'''xf86-video-tseng''' tseng video driver<br />
*'''xf86-video-unichrome''' VIA S3 Unichrome video drivers<br />
*'''xf86-video-v4l''' v4l video driver<br />
*'''xf86-video-vesa''' vesa video driver<br />
*'''xf86-video-vga''' VGA 16 color video driver<br />
*'''xf86-video-via''' via video driver<br />
*'''xf86-video-vmware ''' vmware video driver<br />
*'''xf86-video-voodoo ''' voodoo video driver<br />
<br />
* Note that the '''vesa''' driver is the most generic, and should work with almost any modern video chipset. If you cannot find a suitable driver for your video chipset, vesa '''should''' work.<br />
<br />
*If you have an NVIDIA or ATI video adapter, you may wish to install the proprietary NVIDIA or ATI drivers. '''Installing proprietary video drivers is covered [[#Using proprietary Graphics Driver (NVIDIA, ATI)|below]].'''<br />
<br />
Use pacman to install the appropriate video driver for your video card/onboard video. e.g.:<br />
# pacman -S xf86-video-savage<br />
(for the Savage driver.)<br />
<br />
===Create /etc/X11/xorg.conf===<br />
=====What is /etc/X11/xorg.conf?=====<br />
/etc/X11/xorg.conf is the main configuration file for your '''X''' Window System, the foundation of your '''G'''raphical '''U'''ser '''I'''nterface. It is a plain text file ordered into sections and subsections. Important sections are ''Files, InputDevice, Module, Monitor, Modes, Screen, Device, and ServerLayout''. Sections can appear in any order and there may be more than one section of each kind, for example, if you have more than one monitor, or if your laptop has a trackpoint as well as a mouse. <br />
------<br />
By default, you will not have an Xorg config file, as the newest versions of Xorg feature autodetection. ''If'' the autodetection ''works satisfactorily'' and you do not need to specify special features such as aiglx, compositing and so forth, you may forgo creating an xorg.conf file. <br />
<br />
''Most people will still find that they need to generate a config file, however.''<br />
<br />
Advanced users may wish to manually create their own xorg.conf file. You may also use the <code>/usr/bin/Xorg</code> program with the -configure option to generate a basic config file; As root, do:<br />
# Xorg -configure<br />
This will create a config file at /root/xorg.conf.new <br />
<br />
To test the server, run:<br />
# X -config /root/xorg.conf.new<br />
'''X''' should start with the white hollow vector '''X''' in the center of the screen, which should respond to mouse, trackpoint or touchpad movement. Use CTRL-Alt-Backspace to exit '''X'''.<br />
<br />
Inspect your config file in case of errors:<br />
<br />
# nano /root/xorg.conf.new<br />
<br />
Ensure the Xorg -configure script has correctly specified your video driver. e.g.:<br />
Section "Device"<br />
<br />
...<br />
<br />
Driver "savage"<br />
<br />
...<br />
<br />
EndSection<br />
<br />
Ensure there are horizontal sync and vertical refresh specs under section "Monitor". If not, add them:<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
VendorName "Monitor Vendor"<br />
ModelName "Monitor Model"<br />
HorizSync 30.0 - 130.0 # Safe for LCD's<br />
VertRefresh 50.0 - 100.0 # Safe for LCD's and most CRT's.<br />
EndSection<br />
(If you do not know these specs, consult your monitor's documentation.)<br />
<br />
Specify your default color depth under section "Screen":<br />
Section "Screen"<br />
Identifier "Screen0"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
(Typically, this will be set to 24 for true color.)<br />
<br />
Also add your desired Modes to your "Display" subsection, at least under the Depth 24 header, e.g.:<br />
SubSection "Display"<br />
Viewport 0 0<br />
Depth 24<br />
Modes "1024x768" "800x600" "640x480"<br />
Add the following section, if you wish to enable eye candy which requires the composite extension: <br />
Section "Extensions"<br />
Option "Composite" "Enable"<br />
EndSection<br />
Try your config again, after modifying:<br />
# X -config /root/xorg.conf.new<br />
Ensure an '''X''' session opens, without errors, and copy or move the generated config file to /etc/X11/:<br />
# cp /root/xorg.conf.new /etc/X11/xorg.conf<br />
Detailed instructions in the [[Xorg]] article.<br />
<br />
====Alternative xorg.conf generation====<br />
* Note that if your machine has a successfully configured xorg.conf under another distribution, you may easily copy it over to your current Arch system.<br />
* If Xorg -configure is not generating a usable xorg.conf, you may alternatively use the <code>/usr/bin/hwd</code> tool. Install with:<br />
# pacman -S hwd<br />
And run with<br />
# hwd -xa<br />
* You may also try the <code>/usr/bin/xorgcfg</code> script:<br />
# xorgcfg <br />
* Lastly, you may choose <code>/usr/bin/xorgconfig</code>, which will interactively prompt you for hardware information to create a basic xorg.conf:<br />
# xorgconfig<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
===Using proprietary Graphics Driver (NVIDIA, ATI)===<br />
You may choose to use the proprietary video drivers from NVIDIA or ATI. <br />
====NVIDIA Graphic Cards====<br />
The NVIDIA proprietary drivers are generally considered to be of good quality, and offer 3D performance, whereas the open source '''nv''' driver offers only 2d support at this time. <br />
<br />
Before you configure your Graphics Card you will need to know which driver fits. Arch currently has 3 different driver packages that each match a certain subset of Cards: <br />
<br />
'''1. nvidia-71xx''' ''for very old Cards like TNT and TNT2''<br />
<br />
'''2. nvidia-96xx''' ''slightly newer cards up to the GF 4''<br />
<br />
'''3. nvidia''' ''newest GPUs after the GF 4''<br />
<br />
Consult the NVIDIA-Homepage to see which one is for you. The difference is only for the installation; Configuration works the same with every driver.<br />
<br />
Select and install the appropriate NVIDIA driver ''for your card'', e.g.: <br />
# pacman -S nvidia-96xx<br />
<br />
The NVIDIA package has a utility for updating your existing /etc/X11/xorg.conf for use with the NVIDIA driver:<br />
# nvidia-xconfig<br />
<br />
It also has several options which will further specify the contents and options of the xorg.conf file.<br />
For example,<br />
# nvidia-xconfig --composite --add-argb-glx-visuals<br />
<br />
For more detailed information, see nvidia-xconfig(1).<br />
<br />
Some useful tweaking options in the device section are (beware that these may not work on your system):<br />
Option "RenderAccel" "true"<br />
Option "NoLogo" "true"<br />
Option "AGPFastWrite" "true"<br />
Option "EnablePageFlip" "true"<br />
Make sure all instances of DRI are commented out:<br />
# Load "dri"<br />
Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
Update kernel module dependencies using <code>/sbin/depmod</code>:<br />
# depmod -a<br />
(A reboot may be necessary.)<br />
Advanced instructions for nvidia configuration can be found in the [[NVIDIA]] article.<br />
<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
====ATI Graphic Cards====<br />
ATI owners have two options for drivers. If you are unsure which driver to use, please try the open-source one first. The open-source driver will suit most needs along with being generally less problematic.<br />
<br />
Install the '''proprietary''' ATI Driver with<br />
# pacman -S catalyst<br />
Use the aticonfig tool to modify the xorg.conf.<br />
<br />
Install the '''open-source''' ATI Driver with<br />
# pacman -S xf86-video-ati<br />
Currently, the performance of the open-source driver is not on par with that of the proprietary one. It also lacks TV-out, dual-link DVI support, and possibly other features. On the other hand, it supports Aiglx and has better dual-head support.<br />
{{Box Note| The latest proprietary driver does support [[AIGLX]] now. To use [[Compiz]] or [[Beryl]] add Option "AIGLX" "True" to Section ServerFlags and Option "Composite" "True" to Section Extensions.}}<br />
Advanced instructions for ATI configuration can be found in the [[ATI | ATI wiki]].<br />
<br />
===Simple baseline X test===<br />
<br />
At this point, you should have xorg installed, with a suitable video driver and an /etc/X11/xorg.conf configuration file. If you want to test your configuration quickly, to ensure your ability to successfully start '''X''' from the command line before installing a complete desktop environment, you can do so by invoking '''xterm'''. Xterm is a very simple terminal emulator which runs in the '''X '''Server environment; it is installed as part of the base xorg packages. More advanced users who are comfortable with '''X''' configuration may choose to skip this optional step.<br />
<br />
Prepare for the test by configuring a ~/.xinitrc:<br />
<br />
===== ~/[[.xinitrc]] =====<br />
One of the main functions of this file is to dictate what '''X''' Window client is invoked with the '''/usr/bin/startx''' and/or '''/usr/bin/xinit''' program ''on a per-user basis''. (The '''startx''' script is merely a front end to the more versatile '''xinit''' command.) There are vast amounts of additional configurable specifications and commands that may also be added to ~/[[.xinitrc]] as you further customize your system. <br />
{{Box Note | '''[[.xinitrc]]''' is a so-called 'dot' (.) file. Files in a UNIX filesystem which are preceded with a dot (.) are 'hidden', and will not show up with a regular 'ls' command, usually for the sake of keeping directories tidy. Dot files may be seen by issuing '''ls -a'''. The 'rc' denotes ''Run Commands'' and simply indicates that it is a configuration file. Since it controls how a program runs, it is (although historically incorrect) also said to stand for "Run Control".}}<br />
<br />
'''startx/xinit''' will start the '''X''' server and clients. To determine the client to run, '''startx/xinit''' will first look to parse a [[.xinitrc]] file in the user's home directory. In the absence of file ~/[[.xinitrc]], it defaults to the global xinitrc in the xinit library directory; /etc/X11/xinit/xinitrc, which defaults to using the TWM window manager. (Hence, if you invoke startx without a ~/[[.xinitrc]] file, a TWM session will start.) Further details in the [[.xinitrc]] wiki entry.<br />
<br />
Switch to your '''''normal, non-root''''' user:<br />
# su - ''yourusername''<br />
* /etc/skel/ contains files and directories to provide sane defaults for newly created user accounts. The name '''skel''' is derived from the word '''skeleton''', because the files it contains form the basic structure for users' home directories.<br />
Copy the sample xinitrc file from /etc/skel/ to your home directory: <br />
<br />
$ cp /etc/skel/[[.xinitrc]] ~/<br />
Edit the file: <br />
$ nano ~/.xinitrc<br />
and add:<br />
<br />
exec xterm<br />
<br />
So that it looks like this:<br />
<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
#<br />
exec xterm<br />
# exec wmaker<br />
# exec startkde<br />
# exec icewm<br />
# exec blackbox<br />
# exec fluxbox<br />
<br />
''Be sure to have only one uncommented '''exec''' line in your ~/.xinitrc''. Below, we shall edit this file again to specify the appropriate desktop environment/window manager of your choice.<br />
<br />
Finally, test your configurations by starting '''X''' as '''normal, non-root''' user, with:<br />
<br />
$ startx<br />
or<br />
$ xinit<br />
You should have an '''xterm''' session open up. You can test your keyboard and its layout in it. You may need to add option lines in the "InputDevice" section of the /etc/X11/xorg.conf file specifying the keyboard layout and variant:<br />
<br />
<pre><br />
Option "XkbLayout" "be"<br />
Option "XkbVariant" ""<br />
</pre><br />
<br />
You can exit the '''X''' Server with Ctrl+Alt+Backspace, or by typing "exit". If you have problems starting '''X''', you can look for errors in the /var/log/Xorg.0.log file and on the console output of the console you started '''X''' from.<br />
<br />
If you prove a properly configured /etc/X11/xorg.conf by successfully running the test, you can be assured that your DE/WM of choice will work smoothly.<br />
<br />
Advanced instructions for Xorg configuration can be found in the [[Xorg]] article.<br />
<br />
==Part III: Installing and configuring a Desktop Environment ==<br />
While The '''X''' Window System provides the basic framework for building a ''graphical user interface'' (GUI), a '''Desktop Environment''' (DE), works atop and in conjunction with '''X''', to provide a completely functional and dynamic GUI. A DE typically provides icons, applets, windows, toolbars, folders, wallpapers, applications and abilities like drag and drop. The particular functionalities and designs of each DE will uniquely affect your overall environment and experience. Therefore, choosing a DE is a very subjective and personal decision. Choose the best environment for ''your'' needs.<br />
<br />
* If you want something full-featured and similar to Windows and Mac OSX, '''[[#KDE|KDE]]''' is a good choice<br />
* If you want something slightly more minimalist, which follows the K.I.S.S. principle more closely, '''[[#GNOME|GNOME]]''' is a good choice<br />
* '''[[#Xfce|Xfce]]''' is generally perceived as similar to GNOME, but lighter and less demanding on system resources, yet still visually pleasing and providing a very complete environment.<br />
* '''[[#LXDE|LXDE]]''' is a minimal DE based on the Openbox window manager. It provides most things you need for a modern desktop while keeping relatively low system resource usage. LXDE is a good choice for those who want a quick way of setting up a pre-configured Openbox system.<br />
<br />
If you desire a lighter, less demanding GUI to configure manually, you may choose to simply install a '''Window Manager''', or WM. A WM controls the placement and appearance of application windows in conjunction with the X Window System but does NOT include such features as panels, applets, icons, applications, etc., by default.<br />
* Lightweight floating WM's include: [[#Openbox|'''Openbox''']], [[#Fluxbox|'''Fluxbox''']], [[#fvwm2|'''fvwm2''']], '''Windowmaker, Pekwm, and TWM'''.<br />
* If you need something completely different, try '''Awesome, ion, wmii, dwm, or xmonad'''.<br />
<br />
===Install Fonts===<br />
At this point, you may wish to save time by installing visually pleasing, true type fonts, before installing a desktop environment/window manager. Dejavu and bitstream-vera are good, general-purpose font sets. You may also want to have the Microsoft font sets, which are especially popular on websites. <br />
<br />
Install with:<br />
# pacman -S ttf-ms-fonts ttf-dejavu ttf-bitstream-vera<br />
<br />
===~/.xinitrc (again)===<br />
<br />
As '''non-root user''', edit your /home/username/.xinitrc to specify the DE you wish to use. This will allow you to use '''startx/xinit''' from the shell, in the future, to open your DE/WM of choice:<br />
<br />
$ nano ~/.xinitrc<br />
<br />
Uncomment or add the ''''exec''' ..' line of the appropriate desktop environment/window manager. Some examples are below:<br />
<br />
For the Xfce4 desktop environment:<br />
exec startxfce4 <br />
<br />
For the KDE desktop environment:<br />
exec startkde<br />
A '''startkde''' or '''startxfce4''' command starts the KDE or Xfce4 desktop environment. This command does not finish until you logout of the DE. Normally the shell would wait for KDE to finish, then run the next command. The "exec" prefix to this command tells the shell that this is the last command, so the shell does not need to wait to run a subsequent command.<br />
<br />
Remember to have only one uncommented '''exec''' line in your ~/.xinitrc. <br />
<br />
Continue below, installing the DE/WM of your choice.<br />
<br />
* [[#GNOME|'''GNOME''']]<br />
* [[#KDE|'''KDE''']]<br />
* [[#Xfce|'''Xfce''']]<br />
* [[#LXDE|'''LXDE''']]<br />
* [[#Openbox|'''Openbox''']]<br />
* [[#Fluxbox|'''Fluxbox''']]<br />
* [[#fvwm2|'''fvwm2''']]<br />
<br />
===GNOME===<br />
====About GNOME====<br />
The '''G'''NU '''N'''etwork '''O'''bject '''M'''odel '''E'''nvironment. The GNOME project provides two things: The GNOME desktop environment, an intuitive and attractive desktop for end-users, and the GNOME development platform, an extensive framework for building applications that integrate into the rest of the desktop.<br />
<br />
====Installation====<br />
Install the base GNOME environment with:<br />
# pacman -S gnome<br />
<br />
Additionally, you can install the extras:<br />
# pacman -S gnome-extra<br />
<br />
It's safe to choose all packages shown in the extra package. <br />
<br />
====Useful DAEMONS for GNOME====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The '''hal''' daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The '''fam''' daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. Both '''hal''' and '''fam''' make life easier for the GNOME user. The hal and fam packages are installed when you install GNOME, but must be invoked to become useful.<br />
<br />
You may want to install a graphical login manager. For GNOME, the '''gdm''' daemon is a good choice. <br />
<br />
As root:<br />
# pacman -S gdm<br />
You will almost certainly want the '''hal''' and '''fam''' daemons.<br />
<br />
Start hal and fam:<br />
# /etc/rc.d/hal start<br />
<br />
# /etc/rc.d/fam start<br />
<br />
Add them to your /etc/rc.conf DAEMONS section, so they will be invoked at boot:<br />
# nano /etc/rc.conf<br />
<br />
DAEMONS=(syslog-ng network crond alsa '''hal fam gdm''')<br />
(If you prefer to log into the console and manually start X, leave out gdm.)<br />
<br />
<br />
As normal user, start X:<br />
$ startx<br />
or<br />
$ xinit<br />
If ~/.xinitrc is not configured for GNOME, you may always start it with '''xinit''', followed by the path to GNOME:<br />
$ xinit /usr/bin/gnome-session<br />
<br />
Advanced instructions for installing and configuring GNOME can be found in the [[Gnome]] article.<br />
<br />
Congratulations! Welcome to your GNOME desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
====Eye Candy====<br />
You may find the default GNOME theme and icons not very attractive. A nice gtk theme is murrine. Install it with<br />
# pacman -S gtk-engine-murrine<br />
and select it with System->Preferences->Appearance->Theme tab. You can find more themes, icons, and wallpaper at [http://www.gnome-look.org Gnome Look].<br />
<br />
===KDE===<br />
====About KDE====<br />
The '''K''' '''D'''esktop '''E'''nvironment. KDE is a powerful Free Software graphical desktop environment for GNU/Linux and <code>UNIX</code> workstations. It combines ease of use, contemporary functionality, and outstanding graphical design with the technological superiority of <code>UNIX</code>-like operating systems.<br />
<br />
====Installation====<br />
Choose one of the following, and continue below with '''[[#Useful KDE DAEMONS|Useful KDE DAEMONS]]''': <br />
<br />
1. Package '''kde''' is the complete, vanilla KDE 4.1<br />
<br />
Install this before: <br />
# pacman -S zlib shared-mime-info<br />
Install with pacman: <br />
# pacman -S kde<br />
<br />
2. '''KDEmod''' is an Arch Linux exclusive community-driven system designed for modularity and also offers a choice between KDE 3.5 or 4.1. KDEmod can be installed with pacman, after adding the proper repository to /etc/pacman.conf. The project website, including complete instructions can be found at [http://kdemod.ath.cx/ http://kdemod.ath.cx/].<br />
<br />
{{Box Note|A dependency of the full kdemod3/kdemod-legacy was removed from the Arch official repositories. KDEmod is not part of said repositories, and no standard Arch programs used this package. If you wish to install kdemod3-complete without potentially problematic workarounds [kdemod3-base shouldn't have this issue btw], you should install the package libopensync from AUR manually (See: [http://wiki.archlinux.org/index.php/AUR_User_Guidelines#Using_Packages_from_UNSUPPORTED]) or via yaourt until the package is in the KDEMod3 repositories. If you have trouble, try libopensync-stable (or libopensync-unstable if you're desperate).}}<br />
<br />
====Useful KDE DAEMONS====<br />
<br />
KDE will require the '''hal''' ('''H'''ardware '''A'''bstraction '''L'''ayer) and '''fam''' ('''F'''ile '''A'''lteration '''M'''onitor) daemons. The '''kdm''' daemon is the '''K''' '''D'''isplay '''M'''anager, which provides a '''graphical login''', if desired.<br />
<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system.. Both '''hal''' and '''fam''' make life easier for the KDE user. The hal, fam and kdm packages are installed when you install KDE, but must be invoked to become useful.<br />
-----<br />
Start hal and fam:<br />
<br />
# /etc/rc.d/hal start<br />
<br />
# /etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
# nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on boot. If you prefer a graphical login, add '''kdm''' as well: <br />
DAEMONS=(syslog-ng network crond alsa '''hal fam kdm''')<br />
{{Box Note|If you installed KDEmod3 instead of normal KDE, use kdm3 instead of kdm.}}<br />
<br />
*This method will start the system at runlevel 3, (/etc/inittab default, multiuser mode), and then start KDM as a daemon. <br />
<br />
*Some users prefer an alternative method of starting a display manager like KDM on boot by utilizing the /etc/inittab method and starting the system at runlevel 5. See [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]] for more.<br />
<br />
*If you prefer to log into the '''console''' at runlevel 3, and manually start X, leave out kdm, or comment it out with an exclamation. ( ! )<br />
<br />
Now try starting your X Server as normal user:<br />
$ startx<br />
Advanced instructions for installing and configuring KDE can be found in the [[KDE]] article.<br />
<br />
Congratulations! Welcome to your KDE desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===Xfce===<br />
====About Xfce====<br />
The cholesterol-free '''X''' environment. Xfce, like GNOME or KDE, is a desktop environment, but aims to be fast and lightweight while remaining visually appealing and easy to use. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit (like GNOME) and contains its own development environment (libraries, daemons, etc) similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and extremely fast. Xfce is great for older hardware, and will fly with especially great speed on newer machines as well.<br />
<br />
====Installation====<br />
Install Xfce: <br />
# pacman -S xfce4 <br />
You may also wish to install themes and extras:<br />
# pacman -S xfce4-goodies gtk2-themes-collection<br />
Note: '''xfce4-xfapplet-plugin''' (a plugin that allows the use of GNOME applets in the Xfce4 panel) is part of the '''xfce4-goodies''' group and depends on '''gnome-panel''', which in turn depends on '''gnome-desktop'''. You may wish to take this into consideration before installing, since it represents a significant number of extra dependencies.<br />
<br />
If you wish to admire 'Tips and Tricks' on login, install the '''fortune-mod''' package:<br />
# pacman -S fortune-mod<br />
<br />
====Useful DAEMONS====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. The hal and fam packages are installed when you install Xfce, but must be invoked to become useful.<br />
<br />
Start hal and fam:<br />
<br />
# /etc/rc.d/hal start<br />
<br />
# /etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
# nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them at boot.<br />
<br />
Advanced instructions for installing and configuring Xfce can be found in the [[Xfce]] article.<br />
<br />
If you wish to install one, see [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]]. Otherwise you can login in via the console and run:<br />
<br />
$ startxfce4<br />
<br />
Congratulations! Welcome to your Xfce desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===LXDE===<br />
====About LXDE====<br />
LXDE, (for ''L''ightweight ''X''11 ''D''esktop ''E''nvironment), is a new project focused on providing a modern desktop environment which aims to be lightweight, fast, intuitive and functional while keeping system resource usage low. LXDE is quite different from other desktop environments, since each component of LXDE is a discrete and independent application, and each can be easily substituted by other programs. This modular design eliminates all unnecessary dependencies and provides more flexibility. Details and screenshots available at: http://lxde.org/ <br />
<br />
LXDE provides:<br />
# The OpenBox windowmanager<br />
# PCManFM File manager<br />
# LXpanel system panel<br />
# LXSession session manager<br />
# LXAppearance GTK+ theme switcher<br />
# GPicView image viewer<br />
# Leafpad simple text editor<br />
# XArchiver: Lightweight, fast, and desktop-independent gtk+-based file archiver<br />
# LXNM (still under development): Lightweight network manager for LXDE supporting wireless connections<br />
These lightweight and versatile tools combine for quick setup, modularity and simplicity.<br />
<br />
Install LXDE with: <br />
# pacman -S lxde<br />
Add:<br />
exec startlxde<br />
to your ~/.xinitrc and start with ''startx'' or ''xinit''<br />
<br />
Further information available at the [[LXDE]] wiki article.<br />
<br />
===*box===<br />
====Fluxbox====<br />
Fluxbox © is yet another windowmanager for X.<br />
It's based on the Blackbox 0.61.1 code. Fluxbox looks like blackbox and handles styles, colors, window placement and similar things exactly like blackbox (100% theme/style compability).<br />
<br />
Install Fluxbox using <br />
# pacman -S fluxbox fluxconf<br />
<br />
If you use gdm/kdm a new fluxbox session will be automatically added. Otherwise, you should modify your user's .xinitrc and add this to it:<br />
exec startfluxbox <br />
<br />
More information is available in the [[Fluxbox]] article.<br />
<br />
====Openbox====<br />
Openbox is a standards compliant, fast, light-weight, extensible window manager.<br />
<br />
Openbox works with your applications, and makes your desktop easier to manage. This is because the approach to its development was the opposite of what seems to be the general case for window managers. Openbox was written first to comply with standards and to work properly. Only when that was in place did the team turn to the visual interface.<br />
<br />
Openbox is fully functional as a stand-alone working environment, or can be used as a drop-in replacement for the default window manager in the GNOME or KDE desktop environments. <br />
<br />
Install openbox using<br />
# pacman -S openbox<br />
Additional configuration tools are also available, if desired:<br />
# pacman -S obconf obmenu<br />
<br />
Once openbox is installed you will get a message to move menu.xml & rc.xml to ~/.config/openbox/ in your home directory:<br />
# su - ''yourusername''<br />
$ mkdir -p ~/.config/openbox/<br />
$ cp /etc/xdg/openbox/rc.xml ~/.config/openbox/<br />
$ cp /etc/xdg/openbox/menu.xml ~/.config/openbox/<br />
<br />
'''rc.xml''' is the main configuration file for OpenBox. It may be manually edited, (or you can use OBconf). '''menu.xml''' configures the right-click menu.<br />
<br />
You may log into OpenBox via graphical login using KDM/GDM, or from the shell using '''startx''', in which case you will need to edit your ~/.xinitrc (as non-root user) and add the following:<br />
<br />
exec openbox-session<br />
You may also start OpenBox from the shell using '''xinit''':<br />
$ xinit /usr/bin/openbox-session<br />
* Openbox may also be used as the window manager for GNOME, KDE, and Xfce.<br />
For KDM there is nothing left to do; openbox is listed in the sessions menu in KDM.<br />
<br />
Some useful, lightweight programs for OpenBox are:<br />
* PyPanel or LXpanel if you want a panel<br />
* feh if you want to set the background<br />
* ROX if you want a simple file manager (also provides simple icons)<br />
* PcmanFM a lightweight but versatile file manager (also provides desktop icon functionality)<br />
* iDesk (available in [[AUR]]) for providing desktop icons<br />
<br />
More information is available in the [[Openbox]] article.<br />
<br />
===fvwm2===<br />
FVWM is an extremely powerful ICCCM-compliant multiple virtual desktop window manager for the X Window system. Development is active, and support is excellent. <br />
<br />
Install fvwm2 with<br />
# pacman -S fvwm <br />
<br />
fvwm will automatically be listed in kdm/gdm in the sessions menu. Otherwise, add <br />
exec fvwm <br />
<br />
to your user's .xinitrc.<br />
<br />
==Browser and Video Player==<br />
===Web Browser===<br />
The ever-popular Firefox web browser is available through pacman, although it does not have its official branding. Therefore, the program appears as its development codename, ''Gran Paradiso'', when opened.<br />
<br />
Install with:<br />
<br />
pacman -S firefox<br />
Be sure and install 'flashplugin', 'mplayer', 'mplayer-plugin', and the 'codecs' packages for a complete web experience:<br />
pacman -S flashplugin mplayer mplayer-plugin codecs<br />
<br />
''For newbies: if you install the x86_64 version of Archlinux don`t use the option flashplugin in pacman, like above, or you will get an error. Unfortunately Adobe does not offer a 64 bit version of flash plugin. Please see [http://wiki.archlinux.org/index.php/Install_Flash_on_Arch64 this wiki] entry to workaround the problem'' <br />
<br />
(The codecs package contains most codecs, including those for Win32, Quicktime and Realplayer9 content.)<br />
===VLC===<br />
VLC Player is a versatile multimedia player which can handle many different formats, from a disc or file. It also provides the ability to stream multimedia over a lan. Install with:<br />
pacman -S vlc<br />
The libdvdcss library provides DVD decoding for encrypted DVDs. Ensure the legality of using libdvdcss in your country before installing!<br />
pacman -S libdvdcss<br />
For more, see [[Useful Applications]].<br />
<br />
=APPENDIX=<br />
<br />
==An Introduction to [[ABS]]==<br />
<br />
[[ABS]] is the Arch Linux Build System. It is a ports-like system for compiling sources into installable packages. <br />
<br />
'Ports' is a system used by *BSD, which uses simple build scripts residing in a directory tree on the local machine. Each port is simply a directory, named for the installable 3rd party software, and containing a build script. Typically, a *BSD user who wanted to build and install ''firefox'', would cd into the corresponding firefox port residing under /usr/ports and do <code>make install clean</code>. The ''firefox'' sourcecode would then be downloaded from a 3rd party source. According to the port build script, the sources would then be compiled, patched (if directed), and finally, installed to the system.<br />
<br />
[[ABS]] offers the same functionality by providing build scripts called [[#ABS PKGBUILD Explained | PKGBUILD]]s, which contain all information for a given piece of software; The md5sums, source URL, version, license and compilation instructions. In addition, [[ABS]] provides the advantage of compiling the sources ''into an installable package'' with the extension ''.pkg.tar.gz''. Obviously, it is a simple g-zipped tarball, but it is cleanly installable/removable/trackable via pacman.<br />
<br />
Install the abs package:<br />
# pacman -Sy abs<br />
<br />
After installing the ''abs'' package with pacman, run the <code>/usr/bin/abs</code> script as root:<br />
# abs <br />
The ''ABS tree'' is then extracted under /var/abs, organized according to the installable software. <br />
<br />
To build a package from source, create a build directory and copy the abs directory for a given application to the build directory:<br />
$ mkdir ~/abs<br />
$ cp -r /var/abs/extra/x11/slim ~/abs<br />
This will move the slim subdir and PKGBUILD script for slim to the build directory.<br />
{{Box Note | In addition to PKGBUILDs, some software requires an additional *.install file. See the '''[[ABS]]''' and '''[[makepkg]]''' wiki entries for more information}}<br />
navigate to the slim build directory and, after modifying the PKGBUILD if desired or necessary, invoke the abs <code>/usr/bin/makepkg</code> tool<br />
$ [[makepkg]] -cs<br />
* -'''c''' Cleans up any leftover files from the source compilation<br />
* -'''s''' Downloads and installs any missing dependencies by invoking pacman<br />
Install with pacman's -U (upgrade) switch:<br />
# pacman -U slim<version>.pkg.tar.gz<br />
Done. Slim sources are downloaded, compiled, compressed into a package and finally, installed.<br />
{{Box Note | You may build, clean, install any needed dependencies and finally install the package with one command: '''makepkg -csi'''. The above example used pacman -U to install as a separate step for informational purposes. See the '''makepkg(8)''' man page.}} <br />
Q: Why would I need [[ABS]] to compile and create an installable package from source, when I have access to all of the same software via pacman and the binary repos?<br />
<br />
A: A few reasons:<br />
*For installing newer, unstable, custom, or development versions of an application.<br />
PKGBUILDs are transparent and simple. Edit the software version and the md5sums of the desired versions within the PKGBUILD, and build and install your custom packages.<br />
*For [[Patching in ABS | patching]].<br />
Copy the corresponding PKGBUILD to a build directory along with your patch, edit the PKGBUILD, and build/install with <code>/usr/bin/makepkg</code>.<br />
*For [[The Arch package making HOW-TO - with guidelines | creating your own packages]] for yourself, or to share with the community on the [[AUR]].<br />
You are not limited to the PKGBUILDs under /var/abs. Create your own to build from 3rd party sourcecode. They are simple, open and transparent. Explore the prototpe PKGBUILD provided at /usr/share/pacman/PKGBUILD.proto<br />
*ABS provides an expedient method for recompiling, if necessary. <br />
For example, to recompile your video or wireless drivers.<br />
* To build an installable package with custom configurations<br />
Enable or disable options in any package by modifying the PKGBUILD<br />
* To build an installable package, further optimized for your machine's architecture, <br />
Specify your [[#makepkg.conf | CFLAGS]] in /etc/[[makepkg]].conf.<br />
* To rebuild your entire system, BSD-style, further optimized for your machine's architecure.<br />
Use the makeworld script, or the community-contributed [http://bbs.archlinux.org/viewtopic.php?id=48957 pacbuilder]<br />
<br />
==An Introduction to The [[AUR]]==<br />
The '''A'''rch '''U'''ser '''R'''epository<br />
<br />
The [[ABS]] tree provides the ability to build all Arch software available in the [core], [extra], [community], and [testing] repositories by providing build scripts on the local machine. In contrast, the [[AUR]] does not provide a tree on the local machine, but rather, an unsupported repository of build scripts, sporting a handsome web interface at http://aur.archlinux.org/index.php Also, there is an AUR link tab at the top right of every page on the Arch site.<br />
<br />
Once you have navigated to the AUR web page, click on the '''Packages''' button on the top right. You will be brought to the packages search page. <br />
<br />
The general procedure will be:<br />
# Enter the search criteria into the '''keywords''' field and click on '''go'''. The next screen will present all related results.<br />
# Take note of the '''Location''' on the package listing. If the package location is in '''community''', you have not done your homework, and should simply use pacman or ABS to install. If the location is '''unsupported''', continue. <br />
# Click on the name of the package on the package listing. You will be brought to the Package Details page.<br />
An example for the '''yaourt''' package:<br />
yaourt 0.9-2<br />
http://www.archlinux.fr/yaourt-en/<br />
A Pacman frontend with more features and AUR support<br />
unsupported :: system<br />
Maintainer: wain<br />
Votes: 943<br />
License: GPL<br />
Last Updated: Sat, 15 Mar 2008 17:15:20 +0000<br />
First Submitted: Tue, 04 Jul 2006 20:37:58 +0000<br />
Tarball :: Files :: PKGBUILD<br />
Click on the '''Tarball''' link in the last line of the details, and save to a build directory.<br />
<br />
Navigate to, and extract the tarball:<br />
$ tar -xvf yaourt.tar.gz<br />
Enter the build directory and invoke makepkg, which will download the sources, compile, and compress the installation into an installable .pkg.tar.gz package:<br />
$ makepkg -cs<br />
* -'''c''' Cleans up any leftover files from the source compilation<br />
* -'''s''' Downloads and installs any missing dependencies by invoking pacman <br />
Install with pacman's '''-U''' (upgrade) switch:<br />
# pacman -U yaourt<version>.pkg.tar.gz<br />
Done.<br />
<br />
See the [[AUR]] wiki entry for more information.<br />
===Install an AUR Helper===<br />
[[AUR Helpers]] add seamless access to the [[AUR]]. They vary in their features, but can ease in searching, fetching, building, and installing from over 9000 PKGBUILDs found in AUR.<br />
<br />
==File and directory explanation==<br />
<br />
"Shareable" files are defined as those that can be stored on one host and<br />
used on others. "Unshareable" files are those that are not shareable. For<br />
example, the files in user home directories are shareable whereas device<br />
lock files are not. "Static" files include binaries, libraries,<br />
documentation files and other files that do not change without system<br />
administrator intervention. "Variable" files are defined as files that<br />
are not static.<br />
<br />
'''/''' (root) The root filesystem is the primary filesystem from which all other filesystems stem; the top of the hierarchy. All files and directories appear under the root directory "/", even if they are stored on different physical devices. The contents of the root filesystem must be adequate to boot, restore, recover, and/or repair the system.<br />
<br />
'''/bin/''' Essential command binaries that must be available in single user mode; for all users (e.g., cat, ls, cp). /bin/ provides programs that must be available even if only the partition containing / is mounted. This situation may arise should one need to repair other partitions but have no access to shared directories (i.e. you are in single user mode and therefore have no network access). Unlike /sbin, the /bin directory contains several useful commands that are of use to both the root user as well as non-root users.<br />
<br />
'''/boot/''' Unshareable, static directory containing the kernel and ramdisk images as well as the bootloader configuration file, and bootloader stages. /boot also stores data that is used before the kernel begins executing userspace programs. This may include saved master boot sectors and sector map files.<br />
<br />
'''/dev/''' Essential device nodes created by udev during the boot process and as machine hardware is discovered by events. This directory highlights one important aspect of the <code>UNIX</code> filesystem - everything is a file or a directory. Exploring this directory will reveal many files, each representing a hardware component of the system. The majority of devices are either block or character devices; however other types of devices exist and can be created. In general, 'block devices' are devices that store or hold data, whereas 'character devices' can be thought of as devices that transmit or transfer data. For example, hard disk drives and optical drives are categorized as block devices while serial ports, mice and USB ports are all character devices.<br />
<br />
'''/etc/''' Host-specific, unshareable global configuration files shall be placed in the /etc directory. If more than one configuration file is required for an application, it is customary to use a subdirectory in order to keep the /etc/ area as clean as possible. It is considered good practice to make frequent backups of this directory as it contains all system related configuration files. <br />
:'''/etc/conf.d/''' Some daemon scripts will have a matching configuration file in this directory that contains some useful default values. When a daemon is started, it will first source the settings from its config file within this directory, and then source /etc/rc.conf. Arch's simple, transparent scripting approach means you can easily centralize all your daemon configuration options in your /etc/rc.conf simply by setting an appropriate variable value, or, split up your configuration over multiple files if you prefer a decentralized approach to this issue. <br />
:'''/etc/rc.d/''' All Arch daemons reside here. Custom scripts may also be placed here and invoked from the DAEMONS= array in /etc/rc.conf<br />
:'''/etc/X11/''' Configuration files for the X Window System<br />
:::'''/etc/X11/xinit/''' xinit configuration files. 'xinit' is a configuration method of starting up an X session that is designed to be used as part of a script. <br />
:::'''/etc/X11/xinit/xinitrc''' Global xinitrc file, used by all X sessions started by xinit (startx). Its usage is of course overridden by a .xinitrc file located in the home directory of a user.<br />
<br />
'''/home/''' <code>UNIX</code> is a multi-user environment. Therefore, each user is also assigned a specific directory that is accessible only to them and to the root user. These are the user home directories, which can be found under '/home/$USER' (~/). Within their home directory, a user can write files, delete them, install programs, etc. Users' home directories contain their data and personal configuration files, the so-called 'dot files' (their name is preceded by a dot), which are 'hidden'. To view dotfiles, enable the appropriate option in your file manager or run ls with the -a switch. If there is a conflict between personal and system wide configuration files, the settings in the personal file will prevail. Dotfiles most likely to be altered by the end user include .xinitrc and .bashrc files. The configuration files for xinit and Bash respectively. They allow the user the ability to change the window manager to be started upon login and also aliases, user-specified commands and environment variables respectively. When a user is created, their dotfiles shall be taken from the /etc/skel directory where system sample files reside. <br />
'''/home''' can become quite large as it is typically used for storing downloads, compiling, installing and running programs, mail, collections of multimedia files etc.<br />
<br />
'''/lib/''' Contains kernel modules and essential shared library images (the C programming code library) needed to boot the system and run the commands under /bin/ and /sbin/. Libraries are collections of frequently used program routines and are readily identifiable through their filename extension of *.so. They are essential for basic system functionality. Kernel modules (drivers) are in the subdirectory /lib/modules/<kernel-version>.<br />
<br />
'''/lost+found''' <code>UNIX</code>-like operating systems must execute a proper shutdown sequence. At times, a system might crash or a power failure might take the machine down. Either way, at the next boot, a filesystem check using the ''fsck'' program shall be performed. ''Fsck'' will go through the system and try to recover any corrupt files that it finds. The result of this recovery operation will be placed in this directory. The files recovered are not likely to be complete or make much sense but there always is a chance that something worthwhile is recovered.<br />
<br />
'''/media/''' Mount points for removable media. CDROMs, DVD's, and USB sticks shall have an appropriate mount point under /media/. The motivation for the creation of this directory has been that historically there have been a number of other different places used to mount removeable media such as /cdrom, /mnt or /mnt/cdrom. Placing the mount points for all removeable media directly in the root directory would potentially result in a large number of extra directories in /. Although the use of subdirectories in /mnt as a mount point has recently been common, it conflicts with a much older tradition of using /mnt directly as a temporary mount point. Therefore, Arch allocates /media as the mountpoint for removable media. On systems where more than one device exists for mounting a certain type of media, mount directories shall be created by appending a digit to the name of those available above starting with '0', but the unqualified name must also exist.<br />
* hal mounts removable media to /media as /media/<name_of_removable_filesystem><br />
<br />
'''/mnt/''' This is a generic mount point for temporary filesystems or devices. Mounting is the process of making a filesystem available to the system. After mounting, files will be accessible under the mount-point. Additional mount-points (subdirectories) may be created under /mnt/. There is no limitation to creating a mount-point anywhere on the system, but by convention and for practicality, littering a file system with mount-points should be avoided.<br />
<br />
'''/proc/''' /proc is very special in that it is also a virtual filesystem. It is sometimes referred to as the ''process information pseudo-file system''. It doesn't contain 'real' files, but rather, runtime system information (e.g. system memory, devices mounted, hardware configuration, etc). For this reason it can be regarded as a control and information center for the kernel. In fact, quite a lot of system utilities are simply calls to files in this directory. For example, 'lsmod' is the same as 'cat /proc/modules' while 'lspci' is a synonym for 'cat /proc/pci'. By altering files located in this directory, kernel parameters may be read/changed (sysctl) while the system is running.<br />
<br />
The most distinctive facet about files in this directory is the fact that all of them have a file size of 0, with the exception of '''kcore, mounts''' and '''self'''. <br />
<br />
'''/root/''' Home directory of the System Administrator, 'root'. This may be somewhat confusing, ('/root under root') but historically, '/' was root's home directory (hence the name of the Administrator account). To keep things tidier, 'root' eventually got his own home directory. Why not in '/home'? Because '/home' is often located on a different partition or even on another system and would thus be inaccessible to 'root' when - for some reason - only '/' is mounted. <br />
<br />
'''/sbin/''' <code>UNIX</code> discriminates between 'normal' executables and those used for system maintenance and/or administrative tasks. The latter reside either here or - the less important ones - in /usr/sbin. Programs executed after /usr is known to be mounted (when there are no problems) are generally placed into /usr/sbin. This directory contains binaries that are essential to the working of the system. These include system administration as well as maintenance and hardware configuration programs. grub (the command), fdisk, init, route, ifconfig, etc., all reside here. <br />
<br />
'''/srv/''' Site-specific data which is served by the system. The main purpose of specifying this is so that users may find the location of the data files for a particular service, and so that services which require a single tree for readonly data, writable data and scripts (such as cgi scripts) can be reasonably placed. Data of interest to a specific user shall be placed in that user's home directory.<br />
<br />
'''/tmp''' This directory contains files that are required temporarily. Many programs use this to create lock files and for temporary storage of data. Do not remove files from this directory unless you know exactly what you are doing! Many of these files are important for currently running programs and deleting them may result in a system crash. On most systems, this directory is cleared out at boot or at shutdown by the local system. The basis for this was historical precedent and common practice.<br />
<br />
'''/usr/''' While root is the primary filesystem, /usr is the secondary hierarchy, for user data, containing the majority of (multi-)user utilities and applications. /usr is shareable, read-only data. This means that /usr shall be shareable between various hosts and must not be written to, except in the case of system administrator intervention (installation, update, upgrade). Any information that is host-specific or varies with time is stored elsewhere. <br />
<br />
Aside from /home/, /usr/ usually contains by far the largest share of data on a system. Hence, this is one of the most important directories in the system as it contains all the user binaries, their documentation, libraries, header files, etc. X and its supporting libraries can be found here. User programs like telnet, ftp, etc., are also placed here. In the original <code>UNIX</code> implementations, /usr/ (for ''user''), was where the home directories of the system's users were placed (that is to say, /usr/''someone'' was then the directory now known as /home/''someone''). Over time, /usr/ has become where userspace programs and data (as opposed to 'kernelspace' programs and data) reside. The name has not changed, but its meaning has narrowed and lengthened from ''everything user related'' to ''user usable programs and data''. As such, the backronym ''''U'''ser '''S'''ystem '''R'''esources' was created. <br />
::'''/usr/bin/''' Non-essential command binaries (not needed in single user mode); for all users. This directory contains the vast majority of binaries (applications) on your system. Executables in this directory vary widely. For instance vi, gcc, and gnome-session reside here.<br />
::'''/usr/include/''' Header files needed for compiling userspace source code..<br />
::'''/usr/lib/''' Libraries for the binaries in /usr/bin/ and /usr/sbin/.<br />
::'''/usr/sbin/''' Non-essential system binaries of use to the system administrator. This is where the network daemons for the system reside, along with other binaries that (generally) only the system administrator has access to, but which are not required for system maintenance and repair. Normally, these directories are never part of normal user's $PATHs, only of root's (PATH is an environment variable that controls the sequence of locations that the system will attempt to look in for commands).<br />
::'''/usr/share/''' This directory contains 'shareable', architecture-independent files (docs, icons, fonts etc). Note, however, that '/usr/share' is generally not intended to be shared by different operating systems or by different releases of the same operating system. Any program or package which contains or requires data that don't need to be modified should store these data in '/usr/share/' (or '/usr/local/share/', if manually installed - see below). It is recommended that a subdirectory be used in /usr/share for this purpose.<br />
::'''/usr/src/''' The 'linux' sub-directory holds the Linux kernel sources, and header-files.<br />
::'''/usr/local/''' Optional tertiary hierarchy for local data. The original idea behind '/usr/local' was to have a separate ('local') '/usr/' directory on every machine besides '/usr/', which might be mounted read-only from somewhere else. It copies the structure of '/usr/'. These days, '/usr/local/' is widely regarded as a good place in which to keep self-compiled or third-party programs. This directory is empty by default in Arch Linux. It may be used for manually compiled software installations if desired. Pacman installs to /usr/, therefore, manually compiled/installed software installed to /usr/local/ may peacefully co-exist with pacman-tracked system software. <br />
<br />
'''/var/''' Variable files, such as logs, spool files, and temporary e-mail files. On Arch, the [[ABS]] tree and pacman cache also reside here. Why not put the variable and transient data into /usr/? Because there might be circumstances when /usr/ is mounted as read-only, e.g. if it is on a CD or on another computer. '/var/' contains variable data, i.e. files and directories the system must be able to write to during operation, whereas /usr/ shall only contain static data. Some directories can be put onto separate partitions or systems, e.g. for easier backups, due to network topology or security concerns. Other directories have to be on the root partition, because they are vital for the boot process. 'Mountable' directories are: '/home', '/mnt', '/tmp', '/usr' and '/var'. Essential for booting are: '/bin', '/boot', '/dev', '/etc', '/lib', '/proc' and '/sbin'. <br />
::'''/var/abs/''' The [[ABS]] tree. A ports-like package build system hierarchy containing build scripts within subdirectories corresponding to all installable Arch software.<br />
::'''/var/cache/pacman/pkg/''' The pacman package cache. <br />
::'''/var/lib/''' State information. Persistent data modified by programs as they run (e.g. databases, packaging system metadata etc.).<br />
::'''/var/lock/''' Unsharable Lock files data. Files keeping track of resources currently in use.<br />
::'''/var/log/''' Log files. <br />
::'''/var/mail/''' Shareable directory for users' mailboxes.<br />
::'''/var/run/''' Unshareable data about the running system since last boot (e.g. currently logged-in users and running daemons).<br />
::'''/var/spool/''' Spool for tasks waiting to be processed (e.g. print queues and unread mail).<br />
::'''/var/spool/mail/''' Deprecated location for users' mailboxes.<br />
::'''/var/tmp/''' Temporary files to be preserved between reboots.<br />
'''/opt/''' Packages and large static files that do not fit cleanly into the above GNU filesystem layout can be placed in /opt. A package placing files in the /opt/ directory creates a directory bearing the same name as the package. This directory in turn holds files that otherwise would be scattered throughout the file system.<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 GNU filesystem layout, so Arch places all the<br />
files in a subdirectory of /opt.<br />
<br />
==Arch Boot Process==<br />
<br />
After the initial POST, the BIOS directs the computer to load a boot sector from the hard drive. Actually, a small program called GRUB stage1 is within this sector. This is a tiny program. Its only function is to load GRUB stage1.5 or stage2 (depending on filesystem type). <br />
<br />
GRUB stage1.5/stage2 will present a boot menu with various (customizable) choices of operating systems to boot. The path to the device, partition and filename of the kernel and initial ram filesystem is contained for GRUB in /boot/grub/menu.lst.<br />
<br />
After choosing an Arch Linux entry, GRUB loads the Linux kernel. The kernel is the core of an operating system. It functions on a low level (''kernelspace'') interacting between the hardware of the machine, and the programs which use the hardware to run. To make efficient use of the cpu, the kernel uses a scheduler to arbitrate which tasks take priority at any given moment, creating the illusion (to human perception) of many tasks being executed simultaneously. <br />
<br />
After the kernel is loaded, it reads from the initramfs. The purpose of the initramfs is to bootstrap the system to the point where it can access the root filesystem. This means it has to load any modules that are required for devices like IDE, SCSI, or SATA drives (or USB/FW, if you are booting off a USB/FW drive). Once the initramfs loads the proper modules, either manually or through udev, it passes control to the kernel and the boot process continues. For this reason, the initrd only needs to contain the modules necessary to access the root filesystem. It does not need to contain every module you would ever want to use. The majority of your everyday modules will be loaded later on by udev, during the init process. <br />
<br />
The kernel then looks for the program <code>init</code> which resides at <code>/sbin/init</code>. <code>init</code> relies on <code>glibc</code>, the GNU C library. Libraries are collections of frequently used program routines and are readily identifiable through their filename extension of *.so. They are essential for basic system functionality. This part of the boot process is called ''early userspace''.<br />
<br />
The purpose of <code>init</code> is to bring (and keep) the system up into a usable state. It uses the boot scripts to do so. As you may be aware, Arch uses BSD-style boot scripts. <code>init</code> reads the file <code>/etc/inittab</code>, which tells it what to do. Looking over the <code>inittab</code> script, you will find that the first uncommented line defines the default system runlevel, or, 3. The next thing it is told to do is to run an initialization script. The program that executes (or interprets) this script is bash, the same program that gives you a command prompt. In Arch Linux, the main initialization script is <code>/etc/rc.sysinit</code>. <code>/etc/inittab</code> also defines your virtual consoles, which are 'respawned' by <code>/sbin/init</code> if terminated. Lastly, <code>inittab</code> defines a login manager, if starting the system at runlevel 5 is desired. By default the login manager is also respawned by <code>/sbin/init</code> if terminated.<br />
<br />
<code>/etc/inittab</code> directs <code>init</code> to call the first boot script, <code>/etc/rc.sysinit</code>, after which <code>/etc/rc.multi</code> will be called (in a normal boot). The last script to run will be <code>/etc/rc.local</code>, which is empty by default. <br />
<br />
When started in runlevel 1, the single user mode, the script <code>/etc/rc.single</code> is run instead of <code>/etc/rc.multi</code>. You will not find an endless symlink collection in the /etc/rc?.d/ directories to define the boot sequence for all possible runlevels. 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 <code>/etc/rc.conf</code> file and also a set of general functions defined in the <code>/etc/rc.d/functions</code> script. If you plan to write your own daemon files, you should consider having a look at this file and existing daemon scripts.<br />
<br />
===Boot Script Overview===<br />
#/etc/inittab (covered above)<br />
#/etc/rc.sysinit<br />
#/etc/rc.single<br />
#/etc/rc.multi<br />
#/etc/rc.local<br />
#/etc/profile<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, which mounts filesystems, runs udev, activates swap, loads modules, sets localization parameters, etc. When called, udev shall probe system hardware, loading appropriate kernel modules and creating device nodes under /dev. For more, open /etc/rc.sysinit in your editor of choice; the file is well commented.<br />
<br />
'''/etc/rc.single'''<br />
<br />
Single-user startup. Not used in a normal boot-up. If the system is started in single-user mode, for example with the kernel parameter 1 before booting or during normal multi-user operation with the command init 1, this script makes sure no daemons are running except for the bare minimum; syslog-ng and udev. The single-user mode is useful if you need to make any changes to the system while making sure that no remote user can do anything that might cause data loss or damage. <br />
For desktop users, this mode is usually quite useless.<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons (such as a logger, a network script, etc) specified in the DAEMONS= array in /etc/rc.conf, after which it calls /etc/rc.local. <br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. Empty by default. It is a good place to put any last-minute commands you want the system to run at the very end of the boot process. Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place where they belong. To avoid confusion, you should make sure that whatever you intend to add to your rc.local is not already residing in /etc/profile.d/, or any other existing configuration location instead.<br />
<br />
'''/etc/profile''' This script is run on each user login to initialize the system. It globally defines PS1, $PATH, bash aliases, etc. It is kept quite simple under Arch Linux, as most things are. You may wish to edit or customize it to suit your needs.<br />
<br />
'''/etc/rc.shutdown''' <br />
<br />
System shutdown script. It stops daemons, unmounts filesystems, deactivates the swap, etc. <br />
<br />
'''/etc/rc.local.shutdown''' (Optional)<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any commands you want to run right before the common rc.shutdown is executed. Please note that this file does not exist by default, and 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 rc.conf's DAEMONS= array. In addition to being called on boot, you can use these scripts when the system is running to manage the services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. This directory is not in the $PATH by default, but may be added for convenience. Obviously a corresponding daemon script only exists when the appropriate package has been installed (in this case postfix). With a base system install, there are few scripts in here, but rest assured that all relevant daemon scripts end up here. If you wish, you can, of course, create your own scripts and place them here, to be called by the DAEMONS= array in /etc/rc.conf on system startup. <br />
<br />
This directory is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/ directories of other distributions, but without all the symlink hassle. The lack of symlink requirement is a defining difference of a *BSD-style init framework, vs a sysvinit.<br />
<br />
===agetty and login===<br />
After the Arch boot scripts are completed, the <code>agetty</code> program prompts you for a login name. After a login name is received, <code>agetty</code> calls <code>login</code> to prompt for the login password.<br />
<br />
Finally, with a successful login, the <code>login</code> program starts your default shell. The default shell and environment variables may be globally defined within /etc/profile. All variables within a users home directory shall take precedence over those globally defined under /etc. For instance, if 2 conflicting variables are specified within /etc/profile and ~/.bashrc, the one dictated by ~/.bashrc shall prevail.<br />
<br />
For more, see [[The Arch boot process]]<br />
<br />
==Maintaining the system==<br />
===su===<br />
'''su''' or '''su -''' ?<br />
<br />
The default behavior of <br />
su<br />
is to remain within the current directory and to maintain the environmental variables of the original user (rather than switch to those of the new user).<br />
It sometimes can be advantageous for a system administrator to use the shell account of an ordinary user rather than its own. In particular, occasionally the most efficient way to solve a user's problem is to log into that user's account in order to reproduce or debug the problem.<br />
<br />
However, in many situations it is not desirable, or it can even be dangerous, for the root user to be operating from an ordinary user's shell account and with that account's environmental variables rather than from its own. While inadvertently using an ordinary user's shell account, root could install a program or make other changes to the system that would not have the same result as if they were made while using the root account. For instance, a program could be installed that could give the ordinary user power to accidentally damage the system or gain unauthorized access to certain data.<br />
<br />
Thus, it is advisable that administrative users, as well as any other users that are authorized to use su (of which there should be very few, if any), acquire the habit of always following the su command with a space and then a hyphen. (login shell option) The hyphen has two effects: (1) it switches from the current directory to the home directory of the new user (e.g., to /root in the case of the root user) by ''logging in'' as that user, and (2) it changes the environmental variables to those of the new user as dictated by their ~/.bashrc. That is, if the first argument to su is a hyphen, the current directory and environment will be changed to what would be expected if the new user had actually logged on to a new session (rather than just taking over an existing session).<br />
<br />
'''''Thus, administrators should generally use su as follows''''':<br />
$ su -<br />
An identical result is produced by adding the username root, i.e.,<br />
$ su - root<br />
Likewise, the same can be done for any other user, e.g., for a user named bob:<br />
# su - bob<br />
<br />
===Pacman===<br />
[[Pacman]] is both a binary and source package manager which is able to download, install, and upgrade packages from both remote and local repositories with full dependency handling, and has easy-to-understand tools for crafting your own packages too.<br />
<br />
A more-detailed description of Pacman can be found in [[Pacman|its article]].<br />
<br />
====Useful commands====<br />
To view the options available for a particular operational command, say '''-Q''', just append it with '''-h''':<br />
pacman -Qh<br />
<br />
To synchronize and update the local packages database with the remote repositories (it is a good idea to do this before installing and upgrading packages):<br />
pacman -Sy<br />
<br />
To '''upgrade''' all packages on the system:<br />
pacman -Su<br />
<br />
To sync, update, and '''upgrade''' all the packages on the system with one command:<br />
pacman -Syu<br />
<br />
To install or upgrade a single package or list of packages (including dependencies):<br />
pacman -S packageA packageB<br />
<br />
You can also sync, update the package database, and install packages in one command:<br />
pacman -Sy packageA packageB<br />
<br />
To remove a single package, leaving all of its dependencies installed:<br />
pacman -R package<br />
<br />
To remove a package and all of the package's dependencies which are not used by any other installed package:<br />
pacman -Rs package<br />
('''-Rs''' is typically preferred vs '''R''' to remove any package as it will clean up all unused dependencies)<br />
<br />
To remove all of the package's now unneeded dependencies and also instruct pacman to ignore file backup designations. (Normally, when a file is removed from the system the database is checked to see if the file should be renamed with a ".pacsave" extension.):<br />
pacman -Rsn package<br />
<br />
To search the remote (repo) package database for a list of packages matching a given keyword:<br />
pacman -Ss keyword<br />
List all available packages in a given repo. e.g., core:<br />
pacman -Sl core<br />
To list all packages on your system<br />
pacman -Q<br />
<br />
To list all packages on your system without the version strings, we add the '''-q''' option:<br />
pacman -Qq<br />
<br />
To search (query) the local (your machine) package database for a given package:<br />
pacman -Q package <br />
<br />
To search (query) the local (your machine) package database for a given package and list all pertinent information:<br />
pacman -Qi package<br />
<br />
To list all files installed by a given ''package'':<br />
<tt>pacman -Ql ''package''</tt><br />
Conversely, to find the package that owns a given file (in this example, the ''ls'' executable):<br />
<tt>pacman -Qo /bin/ls</tt><br />
To find all unused packages (orphans):<br />
pacman -Qdt<br />
Missing libraries: Suppose you receive an error message like this:<br />
<tt>mplayer: error while loading shared libraries: ''libgssapi.so.2'': cannot open shared object file: No such file or directory</tt><br />
This may be an indication that a package you have previously installed is now corrupt (some or all of its files are missing). You should try to find the package name that provides the missing shared library. In this example, you could type:<br />
<tt>pacman -Ql | grep ''libgssapi.so.2''</tt><br />
The first column in the output is the package name:<br />
<tt>heimdal /usr/lib/libgssapi.so.2<br />
heimdal /usr/lib/libgssapi.so.2.0.0<br />
</tt><br />
Then, you can just re-install it:<br />
<tt>pacman -Sy heimdal</tt><br />
<br />
To defragment pacman's cache database and optimize for speed:<br />
pacman-optimize<br />
<br />
To count how many packages are currently on your system:<br />
pacman -Q | wc -l<br />
<br />
To install a package compiled from source using ABS and makepkg:<br />
pacman -U packagename.pkg.tar.gz<br />
<br />
Note: There are countless additional pacman functions and commands. Try man pacman and consult the [[pacman]] wiki entries.<br />
<br />
====Files====<br />
There are a number of files left and created by pacman and other programs to facilitate maintenance and to conform to a safe computing practice. When pacman is installing something, the package contains information on whether to back up a particular file. Such files will have the '''.pacsave''' extension. When you force a "NoUpgrade" on a file via [http://www.archlinux.org/pacman/pacman.conf.5.html pacman.conf], it will not be replaced during an upgrade and the new file will come with the '''.pacnew''' extension. For example, you have edited a configuration file thoroughly and you do not want an upgrade of the respective package to replace the file with a new one, we must have the following line in '''/etc/pacman.conf''':<br />
NoUpgrade = /path/to/config/file<br />
To view the differences of the old and new versions of these files, we can either edit them manually or use a '''diff''' utility to take note of the differences. There is an automated tool to find and view such files available from the '''community''' repository:<br />
pacman -S pacman-contrib<br />
cd ~/<br />
pacdiff # as root<br />
There is a bug in the above tool where if you navigate to '''/etc''' and run it from there, the paths will be messed up. We remain on the safer side by being at "home". You may want to run it as user first in case you happen to be a careless person (you may just overwrite or remove files because you ''think'' that is the right way).<br><br />
<br />
There are other types of leftovers depending on the programs available on your system. Some will create backups with a '''.bak''' extension, while others with something like "'''~'''" or "'''-'''". Unfortunately, there is currently no way to "automatically" find and review them. Fear not, as we have no need for automated tools to deal with such trivial tasks. Simply use '''locate''' to search for them:<br />
locate -e *.~ *.- *.bak<br />
And we can use something useful like '''vimdiff''' to look at the differences manually:<br />
pacman -S vim<br />
vimdiff file1 file2<br />
<br />
==Tweaks/Finishing touches==<br />
<br />
<br />
===HAL===<br />
Since you have now installed a desktop environment/window manager, and if you did not do so earlier, now would be a good time to also install HAL. HAL allows plug-and-play for your mobile phone, your iPod, your external HD's, etc. It will mount the device and make a nice visual icon on your desktop and/or in 'My Computer', allowing you to access the device after you have plugged it in instead of having to manually configure the /etc/fstab file or udev rules for each and every new device.<br />
<br />
KDE, GNOME and XFCE all use HAL.<br />
<br />
The installation procedure is described in the [[HAL]] article. Some information can also be found at [http://en.wikipedia.org/wiki/HAL_(software) Wikipedia].<br />
<br />
===Backgrounding DAEMONS on startup===<br />
<br />
To speed up system start up procedure, background selected DAEMONS in /etc/rc.conf by prefixing them with a '@' e.g.:<br />
<br />
DAEMONS=(syslog-ng @network crond @alsa @hal @fam @kdm)<br />
This will enable daemons to load in the background, without waiting for the preceding daemon to load first.<br />
<br />
Prefix any daemons which you do not need with a bang (!) e.g.:<br />
<br />
DAEMONS=(syslog-ng @network !netfs !crond @alsa @hal @fam @kdm)<br />
<br />
Alternatively, you may also simply remove unneeded daemons.<br />
<br />
===Beautifying Fonts for LCD's===<br />
See [[Fonts]]<br />
<br />
===Adjusting Mouse for scroll wheel===<br />
While your mouse should be working out of the box, you may want to use your scroll wheel. Add this to your Input Section (mouse0):<br />
Option "ZAxisMapping" "4 5 6 7"<br />
<br />
===Get All Mouse Buttons Working===<br />
See [[Get All Mouse Buttons Working]]<br />
<br />
===Configuring Touchpad for Laptops===<br />
See [[Touchpad Synaptics]]<br />
<br />
===Adjusting Keyboard Layout===<br />
You may want to change your keyboard layout. To do this edit your /etc/X11/xorg.conf and add these lines in the InputDevice Section (Keyboard0) (the example shows a German keyboard layout with no dead keys; alter this to fit your needs).<br />
Option "XkbLayout" "de"<br />
Option "XkbVariant" "nodeadkeys"<br />
<br />
===Additional tweaks for laptops===<br />
ACPI support is needed if you want to use some special functions on your notebook (e.g. sleep, sleep when lid is closed, special keys...). Install <tt>acpid</tt> using<br />
pacman -S acpid<br />
and add it to the daemons in /etc/rc.conf. If you already have '''hal''' specified in your DAEMONS, there is no need to add '''acpid'''. HAL will automatically detect and load the acpid daemon. Manually, it can be started by<br />
/etc/rc.d/acpid start<br />
<br />
More-specific information about Arch Linux on various Laptops can be found at [[:Category:Laptops (English)]]<br />
<br />
===Configuring CPU frequency scaling===<br />
Modern processors can decrease their frequency and voltage to reduce heat and power consumption. Less heat leads to a quieter system; Laptop users will definitely want this, but even a desktop system will benefit from it. Install cpufrequtils with<br />
pacman -S cpufrequtils<br />
Edit the config file /etc/conf.d/cpufreq and change <br />
governor="ondemand"<br />
which dynamically increases the CPU frequency if needed (which is a safe choice on desktop systems too). Alter min_freq and max_freq to match your system's CPU spec. If you do not know the frequencies, run ''cpufreq-info'' after loading one of the frequency scaling modules. You can also comment out or delete the min_freq and max_freq lines: things will work automatically. Add the frequency scaling modules to your /etc/rc.conf modules line. Most modern notebooks and desktops can simply use the ''acpi-cpufreq'' driver, however other options include the ''p4-clockmod, powernow-k6, powernow-k7, powernow-k8, and speedstep-centrino'' drivers. Load the module with<br />
modprobe <modulname> <br />
and start cpufreq with<br />
/etc/rc.d/cpufreq start<br />
For more details, see [[Cpufrequtils]]<br />
<br />
===Pm-Utils===<br />
The pm-utils package will allow you to suspend-to-RAM and hibernate: <br />
pacman -S pm-utils<br />
[[Pm-utils]] wiki page.<br />
<br />
===Laptop-Mode===<br />
The laptop-mode-tools package is sort of a one-stop configuration for all laptop power management utilities. It works in conjunction with other installed tools to fully configure everything from hard disk spin-down to X display DPMS standby times, if desired.<br />
pacman -S laptop-mode-tools<br />
Add laptop-mode to your DAEMONS= line in /etc/rc.conf and configure /etc/laptop-mode/laptop-mode.conf.<br />
<br />
<br />
<br />
<br />
<br />
==Polishing & Further information==<br />
For further information and support you can go to the [http://www.archlinux.org/ homepage], [[Special:Search|search the wiki]], the [http://bbs.archlinux.org/ forums], the [[ArchChannel|IRC channel]], and the [http://www.archlinux.org/mailman/listinfo/ mailing lists].<br />
=====FAQs=====<br />
See [[Arch FAQs for newbies]]<br />
<br />
There is also an [http://bbs.archlinux.org/viewforum.php?id=23 Arch Subforum] devoted to beginners.<br />
<br />
=====Terminology=====<br />
For more information on the jargon used in Arch, look at [[Arch Terminology/Jargon for newbies|this article]].<br />
<br />
=====Where to go from here?=====<br />
<br />
You may also be interested in:<br />
<br />
[[Post Installation Tips]]<br />
<br />
[[ArchLinux User-community Repository (AUR)]]<br />
<br />
[[Get All Mouse Buttons Working]]<br />
<br />
[[Improve Pacman Performance]]<br />
<br />
[[Kernel Compilation]]<br />
<br />
[[Pm-utils]]<br />
<br />
[[Cpufrequtils]]<br />
<br />
[[:Category:Eye candy (English)| Eye Candy]]<br />
<br />
[[Useful Applications]]<br />
<br />
==External links==<br />
* [http://archux.com/page/installation-guide/ Arch Linux installation guide with images]<br />
* [http://archux.com/page/arch-linux-video-installation-guide Arch Linux video installation guide]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=NTFS-3G_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=48872
NTFS-3G (Русский)
2008-09-05T15:58:33Z
<p>Cucullus: /* Редактирование /etc/fstab */</p>
<hr />
<div>[[Category:Эмуляция]]<br />
[[Category:Русские HowTo]]<br />
[[Category:Русский]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|NTFS Write Support}}<br />
{{i18n_entry|עברית|תמיכה בכתיבה במחיצות NTFS}}<br />
{{i18n_entry|Русский|Поддержка NTFS Записи}}<br />
{{i18n_entry|简体中文|NTFS (简体中文)}}<br />
{{i18n_links_end}}<br />
<br />
=== Доступ к NTFS дискам для записи/чтения===<br />
<br />
Этот документ описывает, как получить доступ на чтение и запись для NTFS дисков с использованием ntfs-3g.<br />
<br />
==== Установка пакетов ====<br />
Установите пакет ntfs-3g с зависимостями:<br />
#pacman -S ntfs-3g<br />
<br />
==== Загрузка нужных модулей====<br />
Загрузите модуль fuse:<br />
#modprobe fuse<br />
<br />
==== Редактирование /etc/fstab ====<br />
<br />
Создайте директорию, в которую вы бы хотели монтировать NTFS раздел (например, /mnt/windows)<br />
Потом добавьте запись в /etc/fstab:<br />
/dev/sda1 /mnt/windows ntfs-3g defaults,locale=ru_RU.utf8 0 1<br />
<br />
==== Монтирование ====<br />
<br />
#mount /mnt/windows</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Pacman_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=48359
Pacman (Русский)
2008-08-29T15:42:47Z
<p>Cucullus: /* Ссылки по теме */</p>
<hr />
<div>[[Category:Управление пакетами]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|Česky|:Pacman (Česky)}}<br />
{{i18n_entry|Deutsch|:Pacman (Deutsch)}}<br />
{{i18n_entry|English|:Pacman}}<br />
{{i18n_entry|Español|:Pacman (Español)}}<br />
{{i18n_entry|Français|:Pacman (Français)}}<br />
{{i18n_entry|Italiano|:Pacman (Italiano)}}<br />
{{i18n_entry|Nederlands|:Pacman (Nederlands)}}<br />
{{i18n_entry|Polski|:Pacman (Polski)}}<br />
{{i18n_entry|Português de Portugal|:Pacman (Portugues)}}<br />
{{i18n_entry|Romanian|:Pacman (română)}}<br />
{{i18n_entry|Русский|:Pacman (Русский)}}<br />
{{i18n_entry|简体中文|:Pacman (简体中文)}}<br />
{{i18n_entry|한국어|:Pacman (한국어)}}<br />
{{i18n_links_end}}<br />
<br />
==Общее==<br />
Arch Linux использует менеджер пакетов '''Pacman''', который соединяет в себе простой формат бинарных пакетов и простую в использовании систему сборки (смотрите [[ABS_-_The_Arch_Build_System_(Russian)|ABS]]), позволяющую пользователям с легкостью управлять и настраивать под себя пакеты, вне зависимости от того, официальные ли они или собранные пользователем. Система репозиториев позволяет пользователям создавать и поддерживать собственные репозитории с собранными пакетами, что способствует росту сообщества (смотрите [[AUR]]).<br />
<br />
Pacman может держать систему в новейшем состоянии, синхронизируя пакеты с главным сервером, тем самым позволяя сознательному администратору поддерживать систему. Клиент-серверная модель позволяет скачивать/устанавливать пакеты одной командой со всеми требуемыми зависимостями (похоже на apt-get от Debian). <br />
<br />
NB: Pacman был написан (на языке С) и поддерживается Джаддом Винетом, создателем Arch Linux. Но он используется и как инструмент по управлению пакетами другими дистрибутивами, например [http://frugalware.org FrugalWare] (смотрите также [[http://wiki.frugalware.org/FwPacman]]), [http://www.rubixlinux.org Rubix], [http://www.ufficiozero.org UfficioZero] (на итальянском, основан на Ubuntu) и, конечно, производными от ArchLinux, [http://archie.dotsrc.org Archie] и [http://arch-egis.berlios.de/content.php?article.1 AEGIS].<br />
<br />
==Использование==<br />
<br />
'''Pacman''' является универсальным менеджером пакетов, способным скачивать, устанавливать и обновлять пакеты и из репозитория, и собственные локальные, удалять и искать их. Вам только необходимо знать, какой ключ используется функцией для желаемых действий.<br />
Вот несколько наиболее часто используемых:<br />
<br />
===Установка и удаление пакетов===<br />
<br />
Перед установкой и обновлением пакетов полезно синхронизировать базу данных локально установленных пакетов с удалёнными репозиториями <br />
<br />
pacman -Sy<br />
<br />
Для того чтобы установить или обновить один пакет или группу пакетов (включая зависимости), используйте следующую команду:<br />
<br />
pacman -S package_name1 package_name2<br />
<br />
Иногда пакет имеет несколько версий в разных репозиториях (например в extra и testing). Вы можете указать, какой именно вы хотите установить:<br />
pacman -S extra/package_name<br />
или<br />
pacman -S testing/package_name<br />
<br />
Вы можете совмещать параметры, например, эта команда установит пакет и синхронизирует базы данных:<br />
<br />
pacman -Sy package_name<br />
<br />
Удалить пакет (оставляя все зависимости в системе):<br />
pacman -R package_name<br />
<br />
Удалить пакет со всеми зависимостями, не используемыми другими установленными пакетами:<br />
pacman -Rs package_name<br />
<br />
===Обновление системы===<br />
<br />
'''Pacman''' может обновить все пакеты системы одной командой. Количество пакетов зависит от того, насколько ваша система современна.<br />
pacman -Su<br />
<br />
NB: вы можете синхронизировать базы данных репозиториев И обновить все установленные пакеты одной командой:<br />
pacman -Syu<br />
Хорошо выполнять эту команду каждые несколько дней.<br />
<br />
===Запросы к базе данных пакетов===<br />
<br />
* Поиск пакетов в репозиториях, вы можете указать только часть названия:<br />
pacman -Ss package<br />
<br />
* Поиск среди установленных пакетов:<br />
pacman -Qs package<br />
<br />
* Вывод информации о пакете:<br />
pacman -Si package<br />
pacman -Qi package<br />
<br />
* Вывод списка файлов пакета:<br />
pacman -Ql package<br />
<br />
* Какой пакет является владельцем файла?<br />
pacman -Qo /path/to/a/file<br />
<br />
===Одновременный поиск в репозитории и среди установленных пакетов===<br />
<br />
Вы можете использовать следующий bash скрипт в качестве эквивалента для одновременного вызова '''pacman -Ss foo''' и '''pacman -Qs foo''', для того чтобы узнать, какие из пакетов в выводе установлены на вашей системе. Последние будут помечены звёздочкой.<br />
<br />
#!/bin/bash<br />
<br />
if [ -z "$1" ]; then<br />
echo "usage: pacsearch [regex pattern]"<br />
echo "usage: pacsearch -h|--help"<br />
exit 0<br />
fi<br />
<br />
if [ "$1" = "-h" -o "$1" = "--help" ]; then<br />
echo "usage: pacsearch [regex pattern]"<br />
echo " Like pacman -Ss [regex pattern] but installed packages are flagged with a *"<br />
echo "usage: pacsearch -h|--help"<br />
echo " Prints this message. No other options allowed"<br />
exit 0<br />
fi<br />
<br />
firstchar=`echo "$1" | cut -c1`<br />
if [ $firstchar = "-" ]; then<br />
echo "Sorry, $1 is not a valid option!"<br />
echo "usage: pacsearch [regex pattern]"<br />
echo "usage: pacsearch -h|--help"<br />
exit 0<br />
fi<br />
<br />
instpkg=`pacman -Qs $1 | egrep '^[^ ]' | sed 's|^local/||' | sed 's/ .\+$//'` <br />
syncdump=`mktemp`<br />
pacman -Ss $1 > $syncdump<br />
<br />
for pkg in $instpkg; do<br />
sed -i "s@^\(.\+/$pkg\) @\*\1 @" $syncdump<br />
done<br />
<br />
cat $syncdump<br />
<br />
Сохраните этот скрипт в каталоге, включенном в переменную PATH (например, ~/bin/), и назовите его '''pacsearch'''. Сделайте его исполняемым с помощью <br />
chmod a+x pacsearch<br />
<br />
Теперь если вы напишете, например:<br />
pacsearch ^qt<br />
вывод может выглядеть так:<br />
extra/qca 1.0-1<br />
QT Cryptography Architecture<br />
extra/qsynth 0.2.5-1<br />
Qt GUI for fluidsynth<br />
*extra/qt 3.3.5-8<br />
The QT gui toolkit.<br />
extra/qt-doc 3.3.5-1<br />
The QT gui toolkit documentation.<br />
extra/qtella 0.6.5-1<br />
Qtella is a Gnutella client for Linux using QT<br />
extra/qtiplot 0.7.7-1<br />
Data analysis and scientific plotting - free clone of Origin<br />
extra/qtparted 0.4.5-3<br />
A Partition Magic clone written in C++ using the Qt toolkit<br />
extra/qwt 4.2.0-3<br />
Qt Widgets for Technical Applications<br />
extra/qwtplot3d 0.2.6-2<br />
Qt/OpenGL-based C++ programming library containing 3d-widgets<br />
<br />
В этом случае вы узнаете, что ни один из вышеперечисленных пакетов (кроме самого '''qt''') на вашей системе не установлен.<br />
<br />
'''NB1:''' ''был добавлен запрос на flyspray с предложением интегрировать вышеуказанную функциональность в сам pacman, чтобы 'грязные' хитрости bash стали стать ненужными с последующими версиями pacman.''<br />
<br />
'''NB2:''' ''вы можете изменить этот bash скрипт с помощью [[Colored_Pacman_output|этого wiki]], для того чтобы установленные пакеты были выделены различными цветами в выводе.''<br />
<br />
===Другое использование===<br />
<br />
* Скачать пакет, но не устанавливать его:<br />
pacman -Sw package_name<br />
<br />
* Установить локальный пакет (не из репозитория):<br />
pacman -U /путь/к/пакету/package_name-version.pkg.tar.gz<br />
<br />
* Очистка кэша pacman`а (/var/cache/pacman/pkg):<br />
pacman -Scc<br />
<br />
Для более детальной информацией о возможных ключах обратитесь к '''pacman --help''' или '''man pacman'''.<br />
<br />
==Настройка==<br />
Настройки pacman`a находятся в <code>/etc/pacman.conf</code>. Важными секциями являются:<br />
===Основные опции===<br />
Основные опции находятся в секции [options].<br />
Есть одна полезная опция '''IgnorePkg'''. Например, если вы изменяли или накладывали патч на пакет, добавление его в IgnorePkg укажет pacman'у не обновлять его при выходе следующей версии пакета. Но pacman всё же предупредит вас о том, что доступна более свежая версия, так что в итоге вы можете обновить ваш изменённый пакет. Опция также полезна для БОЛЬШИХ пакетов (например, openoffice-base), если вы хотите избежать скачивания и обновления всего пакета каждый раз, когда в репозитории появляется маленькое изменение. Поскольку pacman всё равно предупредит вас о последней версии, вы можете обновить пакет вручную.<br />
<br />
===Репозитории===<br />
В этой секции вы указываете используемые репозитории. Они могут быть указаны напрямую или как файл, содержащий список серверов. Последнее удобно для официальных репозиториев, имеющих множество зеркал.<br />
<pre><br />
[repository-name]<br />
Server = ftp://server.net/repo<br />
</pre><br />
<br />
<pre><br />
[current]<br />
Include = /etc/pacman.d/current<br />
</pre><br />
<br />
За более подробной информацией обратитесь к '''man pacman'''.<br />
<br />
==Ссылки по теме ==<br />
[[Boost Pacman]]<br><br />
[[Colored Pacman output]]<br><br />
[[Downgrade packages]]<br><br />
[[Redownloading all installed packages]]<br><br />
[[Server_configuration|Server configuration in pacman.conf]]<br><br />
[[ArchLinux User-community Repository (AUR)]]<br><br />
[[Local repository HOW-TO]]<br><br />
[[Собственный_локальный_репозиторий_(ABS_и_gensync)]]<br><br />
[[Howto Upgrade via Home Network]]<br><br />
[[rucksack]]<br><br />
[[Pacman GUI Frontends]]<br />
<br />
[[Category:Русский]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Pacman_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=48358
Pacman (Русский)
2008-08-29T15:42:04Z
<p>Cucullus: /* Ссылки по теме */</p>
<hr />
<div>[[Category:Управление пакетами]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|Česky|:Pacman (Česky)}}<br />
{{i18n_entry|Deutsch|:Pacman (Deutsch)}}<br />
{{i18n_entry|English|:Pacman}}<br />
{{i18n_entry|Español|:Pacman (Español)}}<br />
{{i18n_entry|Français|:Pacman (Français)}}<br />
{{i18n_entry|Italiano|:Pacman (Italiano)}}<br />
{{i18n_entry|Nederlands|:Pacman (Nederlands)}}<br />
{{i18n_entry|Polski|:Pacman (Polski)}}<br />
{{i18n_entry|Português de Portugal|:Pacman (Portugues)}}<br />
{{i18n_entry|Romanian|:Pacman (română)}}<br />
{{i18n_entry|Русский|:Pacman (Русский)}}<br />
{{i18n_entry|简体中文|:Pacman (简体中文)}}<br />
{{i18n_entry|한국어|:Pacman (한국어)}}<br />
{{i18n_links_end}}<br />
<br />
==Общее==<br />
Arch Linux использует менеджер пакетов '''Pacman''', который соединяет в себе простой формат бинарных пакетов и простую в использовании систему сборки (смотрите [[ABS_-_The_Arch_Build_System_(Russian)|ABS]]), позволяющую пользователям с легкостью управлять и настраивать под себя пакеты, вне зависимости от того, официальные ли они или собранные пользователем. Система репозиториев позволяет пользователям создавать и поддерживать собственные репозитории с собранными пакетами, что способствует росту сообщества (смотрите [[AUR]]).<br />
<br />
Pacman может держать систему в новейшем состоянии, синхронизируя пакеты с главным сервером, тем самым позволяя сознательному администратору поддерживать систему. Клиент-серверная модель позволяет скачивать/устанавливать пакеты одной командой со всеми требуемыми зависимостями (похоже на apt-get от Debian). <br />
<br />
NB: Pacman был написан (на языке С) и поддерживается Джаддом Винетом, создателем Arch Linux. Но он используется и как инструмент по управлению пакетами другими дистрибутивами, например [http://frugalware.org FrugalWare] (смотрите также [[http://wiki.frugalware.org/FwPacman]]), [http://www.rubixlinux.org Rubix], [http://www.ufficiozero.org UfficioZero] (на итальянском, основан на Ubuntu) и, конечно, производными от ArchLinux, [http://archie.dotsrc.org Archie] и [http://arch-egis.berlios.de/content.php?article.1 AEGIS].<br />
<br />
==Использование==<br />
<br />
'''Pacman''' является универсальным менеджером пакетов, способным скачивать, устанавливать и обновлять пакеты и из репозитория, и собственные локальные, удалять и искать их. Вам только необходимо знать, какой ключ используется функцией для желаемых действий.<br />
Вот несколько наиболее часто используемых:<br />
<br />
===Установка и удаление пакетов===<br />
<br />
Перед установкой и обновлением пакетов полезно синхронизировать базу данных локально установленных пакетов с удалёнными репозиториями <br />
<br />
pacman -Sy<br />
<br />
Для того чтобы установить или обновить один пакет или группу пакетов (включая зависимости), используйте следующую команду:<br />
<br />
pacman -S package_name1 package_name2<br />
<br />
Иногда пакет имеет несколько версий в разных репозиториях (например в extra и testing). Вы можете указать, какой именно вы хотите установить:<br />
pacman -S extra/package_name<br />
или<br />
pacman -S testing/package_name<br />
<br />
Вы можете совмещать параметры, например, эта команда установит пакет и синхронизирует базы данных:<br />
<br />
pacman -Sy package_name<br />
<br />
Удалить пакет (оставляя все зависимости в системе):<br />
pacman -R package_name<br />
<br />
Удалить пакет со всеми зависимостями, не используемыми другими установленными пакетами:<br />
pacman -Rs package_name<br />
<br />
===Обновление системы===<br />
<br />
'''Pacman''' может обновить все пакеты системы одной командой. Количество пакетов зависит от того, насколько ваша система современна.<br />
pacman -Su<br />
<br />
NB: вы можете синхронизировать базы данных репозиториев И обновить все установленные пакеты одной командой:<br />
pacman -Syu<br />
Хорошо выполнять эту команду каждые несколько дней.<br />
<br />
===Запросы к базе данных пакетов===<br />
<br />
* Поиск пакетов в репозиториях, вы можете указать только часть названия:<br />
pacman -Ss package<br />
<br />
* Поиск среди установленных пакетов:<br />
pacman -Qs package<br />
<br />
* Вывод информации о пакете:<br />
pacman -Si package<br />
pacman -Qi package<br />
<br />
* Вывод списка файлов пакета:<br />
pacman -Ql package<br />
<br />
* Какой пакет является владельцем файла?<br />
pacman -Qo /path/to/a/file<br />
<br />
===Одновременный поиск в репозитории и среди установленных пакетов===<br />
<br />
Вы можете использовать следующий bash скрипт в качестве эквивалента для одновременного вызова '''pacman -Ss foo''' и '''pacman -Qs foo''', для того чтобы узнать, какие из пакетов в выводе установлены на вашей системе. Последние будут помечены звёздочкой.<br />
<br />
#!/bin/bash<br />
<br />
if [ -z "$1" ]; then<br />
echo "usage: pacsearch [regex pattern]"<br />
echo "usage: pacsearch -h|--help"<br />
exit 0<br />
fi<br />
<br />
if [ "$1" = "-h" -o "$1" = "--help" ]; then<br />
echo "usage: pacsearch [regex pattern]"<br />
echo " Like pacman -Ss [regex pattern] but installed packages are flagged with a *"<br />
echo "usage: pacsearch -h|--help"<br />
echo " Prints this message. No other options allowed"<br />
exit 0<br />
fi<br />
<br />
firstchar=`echo "$1" | cut -c1`<br />
if [ $firstchar = "-" ]; then<br />
echo "Sorry, $1 is not a valid option!"<br />
echo "usage: pacsearch [regex pattern]"<br />
echo "usage: pacsearch -h|--help"<br />
exit 0<br />
fi<br />
<br />
instpkg=`pacman -Qs $1 | egrep '^[^ ]' | sed 's|^local/||' | sed 's/ .\+$//'` <br />
syncdump=`mktemp`<br />
pacman -Ss $1 > $syncdump<br />
<br />
for pkg in $instpkg; do<br />
sed -i "s@^\(.\+/$pkg\) @\*\1 @" $syncdump<br />
done<br />
<br />
cat $syncdump<br />
<br />
Сохраните этот скрипт в каталоге, включенном в переменную PATH (например, ~/bin/), и назовите его '''pacsearch'''. Сделайте его исполняемым с помощью <br />
chmod a+x pacsearch<br />
<br />
Теперь если вы напишете, например:<br />
pacsearch ^qt<br />
вывод может выглядеть так:<br />
extra/qca 1.0-1<br />
QT Cryptography Architecture<br />
extra/qsynth 0.2.5-1<br />
Qt GUI for fluidsynth<br />
*extra/qt 3.3.5-8<br />
The QT gui toolkit.<br />
extra/qt-doc 3.3.5-1<br />
The QT gui toolkit documentation.<br />
extra/qtella 0.6.5-1<br />
Qtella is a Gnutella client for Linux using QT<br />
extra/qtiplot 0.7.7-1<br />
Data analysis and scientific plotting - free clone of Origin<br />
extra/qtparted 0.4.5-3<br />
A Partition Magic clone written in C++ using the Qt toolkit<br />
extra/qwt 4.2.0-3<br />
Qt Widgets for Technical Applications<br />
extra/qwtplot3d 0.2.6-2<br />
Qt/OpenGL-based C++ programming library containing 3d-widgets<br />
<br />
В этом случае вы узнаете, что ни один из вышеперечисленных пакетов (кроме самого '''qt''') на вашей системе не установлен.<br />
<br />
'''NB1:''' ''был добавлен запрос на flyspray с предложением интегрировать вышеуказанную функциональность в сам pacman, чтобы 'грязные' хитрости bash стали стать ненужными с последующими версиями pacman.''<br />
<br />
'''NB2:''' ''вы можете изменить этот bash скрипт с помощью [[Colored_Pacman_output|этого wiki]], для того чтобы установленные пакеты были выделены различными цветами в выводе.''<br />
<br />
===Другое использование===<br />
<br />
* Скачать пакет, но не устанавливать его:<br />
pacman -Sw package_name<br />
<br />
* Установить локальный пакет (не из репозитория):<br />
pacman -U /путь/к/пакету/package_name-version.pkg.tar.gz<br />
<br />
* Очистка кэша pacman`а (/var/cache/pacman/pkg):<br />
pacman -Scc<br />
<br />
Для более детальной информацией о возможных ключах обратитесь к '''pacman --help''' или '''man pacman'''.<br />
<br />
==Настройка==<br />
Настройки pacman`a находятся в <code>/etc/pacman.conf</code>. Важными секциями являются:<br />
===Основные опции===<br />
Основные опции находятся в секции [options].<br />
Есть одна полезная опция '''IgnorePkg'''. Например, если вы изменяли или накладывали патч на пакет, добавление его в IgnorePkg укажет pacman'у не обновлять его при выходе следующей версии пакета. Но pacman всё же предупредит вас о том, что доступна более свежая версия, так что в итоге вы можете обновить ваш изменённый пакет. Опция также полезна для БОЛЬШИХ пакетов (например, openoffice-base), если вы хотите избежать скачивания и обновления всего пакета каждый раз, когда в репозитории появляется маленькое изменение. Поскольку pacman всё равно предупредит вас о последней версии, вы можете обновить пакет вручную.<br />
<br />
===Репозитории===<br />
В этой секции вы указываете используемые репозитории. Они могут быть указаны напрямую или как файл, содержащий список серверов. Последнее удобно для официальных репозиториев, имеющих множество зеркал.<br />
<pre><br />
[repository-name]<br />
Server = ftp://server.net/repo<br />
</pre><br />
<br />
<pre><br />
[current]<br />
Include = /etc/pacman.d/current<br />
</pre><br />
<br />
За более подробной информацией обратитесь к '''man pacman'''.<br />
<br />
==Ссылки по теме ==<br />
[[Boost Pacman]]<br><br />
[[Colored Pacman output]]<br><br />
[[Downgrade packages]]<br><br />
[[Redownloading all installed packages]]<br><br />
[[Server_configuration|Server configuration in pacman.conf]]<br><br />
[[ArchLinux User-community Repository (AUR)]]<br><br />
[[Local repository HOW-TO]]<br><br />
[[Собственный_локальный_репозиторий_(ABS_и_gensync)]<br><br />
[[Howto Upgrade via Home Network]]<br><br />
[[rucksack]]<br><br />
[[Pacman GUI Frontends]]<br />
<br />
[[Category:Русский]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=46686
Timezone (Русский)
2008-07-29T14:48:25Z
<p>Cucullus: /* UTC и localtime */</p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Русский]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_entry|Español|TIMEZONE (Español)}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное) или по местному (local time) времени.<br />
Как правило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно устанавливаются по местному времени.<br />
<br />
Установить режим машинных часов можно через переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>UTC</code>, то Linux переведёт часы с зимнего на летнее время (или наоборот) вне зависимости от того работал компьютер в момент перехода на другое время или нет.<br />
<br />
'''ВАЖНО:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (или наоборот), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботятся о переводе часов. В противном случае Вам придётся перевести часы вручную.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Arch_is_the_best&diff=46677
Arch is the best
2008-07-29T09:38:10Z
<p>Cucullus: Translations sorted</p>
<hr />
<div>[[Category:About Arch (English)]]<br />
<br />
==Purpose==<br />
The '''Arch is the best''' project is a very sophisticated and exquisite, ego-boosting and mind-blowing (albeit perhaps a bit over-engineered) project which aims to prove Arch's superiority.<br />
<br />
==History==<br />
The project was initiated in April 2008 by long time Arch community member [http://bbs.archlinux.org/profile.php?id=2529 lucke] as a simple shell script which provided irrefutable proof that "Arch is the best". Over the following weeks, this project gathered momentum and was ported to multiple different languages, both programming and verbal.<br />
<br />
==The Code==<br />
The "Arch is the best" project is ported to many programming languages.<br />
<br />
'''Bash''' - the original program, should be compatible with any shell<br />
#!/bin/sh<br />
<br />
echo "Arch is the best!"<br />
<br />
'''Bash (Alternate)''' - handy for piping the output to your favourite IRC/email/IM client. Should work with any shell.<br />
#!/bin/sh<br />
yes Arch is the best!<br />
<br />
'''C''' - note the three space indenting used in this project, much like that used by other superior beings.<br />
#include <stdio.h><br />
<br />
int main (int argc, char **argv)<br />
{<br />
fputs("Arch is the best!\n",stdout);<br />
}<br />
<br />
'''Python''' - a python version<br />
#!/usr/bin/env python<br />
<br />
print 'Arch is the best!'<br />
<br />
'''Ruby''' - a Ruby version<br />
#!/usr/bin/ruby -w<br />
<br />
puts 'Arch is the best!'<br />
<br />
'''Common Lisp''' - should run on any implementation (Clisp, Allegro, SBCL...)<br />
(format t "Arch is the best!")<br />
<br />
'''brainf*ck''' - doesn't the language name exaplain it?<br />
++>++++++>+++++<+[>[->+<]<->++++++++++<]>>.<[-]>[-<++>]<br />
<----------------.---------------.+++++.<+++[-<++++++++++>]<.<br />
>>+.++++++++++.<<.>>+.------------.---.<<.>>---.<br />
+++.++++++++++++++.+.<<+.[-]++++++++++.<br />
<br />
'''Befunge''' - believed to be the first two-dimensional, ASCII-based, general-purpose (in the sense of "you could plausibly write Hunt the Wumpus in it") programming language<br />
<v"Arch is the best!"0<br />
<,_@#:<br />
<br />
'''PHP''' - a PHP version<br />
<?<br />
print 'Arch is the best!'<br />
?><br />
<br />
'''JavaScript''' - a JavaScript version<br />
<script type="text/javascript><br />
alert('Arch is the best!');<br />
</script><br />
<br />
==Translations==<br />
'''Australian'''<br />
Arch is fair dinkum, mate!<br />
<br />
'''Bahasa Indonesia'''<br />
Arch terbaik!<br />
<br />
'''Basque'''<br />
Arch onena da!<br />
<br />
'''British'''<br />
Arch is simply spiffing.<br />
<br />
'''Bulgarian'''<br />
Арч е най-добрия!<br />
<br />
'''Czech'''<br />
Arch je nejlepší!<br />
<br />
'''Deutsch'''<br />
Arch ist das Beste!<br />
<br />
'''Filipino'''<br />
Mabuhay ang Arch!<br />
<br />
'''French'''<br />
Arch est le meilleur!<br />
<br />
'''Hantec'''<br />
Arch je nejbetélnější!<br />
<br />
'''Norwegian'''<br />
Arch er best!<br />
<br />
'''Polish'''<br />
Arch jest najlepszy!<br />
<br />
'''Portuguese'''<br />
Arch é o melhor!<br />
<br />
'''Russian'''<br />
Арч - лучший!<br />
<br />
'''Spanish'''<br />
¡Arch es la mejor!<br />
<br />
==Links==<br />
* [http://bbs.archlinux.org/viewtopic.php?id=47306 forum Thread]<br />
* [http://arch.yarrt.com Unofficially Official Project Website]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Beginners%27_guide_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=43971
Beginners' guide (Русский)
2008-06-30T11:50:41Z
<p>Cucullus: /* DON'T PANIC! */ ;)</p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Dansk|Dansk_Begynderguide}}<br />
{{i18n_entry|简体中文|Beginners Guide 新手指南}}<br />
{{i18n_entry|Deutsch|Beginners Guide (Deutsch)}}<br />
{{i18n_entry|English|Beginners Guide}}<br />
{{i18n_entry|Español|Guía Para Principiantes}}<br />
{{i18n_entry|Česky|Průvodce začátečníka (Česky)}}<br />
{{i18n_entry|Italiano|Beginners Guide (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Pradedančiųjų gidas (Lietuviškai)}}<br />
{{i18n_entry|Português Brasil|Guia do Iniciante(Português do Brasil)}}<br />
{{i18n_entry|Русский|Руководство для новичков}}<br />
{{i18n_links_end}}<br />
<br />
=====Всё, что вы хотели знать об установке Arch, но боялись спросить=====<br />
Добро пожаловать. Этот документ проведёт вас через процесс установки и настройки [[ArchLinux|Arch Linux]]; простого, быстрого и лёгкого GNU/Linux дистрибутива, <code>UNIX</code>-подобной операционной системы. Это больше, чем установочное руководство; Arch Linux требует определённого уровня глубоких знаний о его конфигурации, а так же методологии системы GNU/Linux и по этой причине, на этом пути содержится много дополнительной пояснительной информации. Он направлен на новых пользователей Arch, но стремится выступать как сильная справочная и информационная база для всех. Хоть это руководство предназначено для того, чтобы показать как получить полностью сконфигурированную систему Arch Linux (графическое окружени рабочего стола, возможность просмотра DVD, использования Интернет, работа с электронной почтой и прослушивания музыки), невозможно показать (или даже предположить) все возможности и варианты. По замыслу авторов, это руководство должно сфокусироваться на крайне полезных шагах; возможно вы захотите получить глубокие знания используя [[Main Page|Arch Linux Wiki]] или [http://bbs.archlinux.org/ Arch Linux Forums]. Вы также можете быть заинтересованы в чтении статьи [[Путь Arch]], в которой изложены основные принципы дистрибутива Arch Linux.<br />
<br />
Так как Arch Linux и все <code>UNIX</code>-подобные операционные системы являются в своей основе 'модульными', статья логически разбита на три основных части:<br />
<br />
'''[[#Часть 1: Установка базовой системы|Часть 1: Установка базовой системы]]'''<br />
<br />
'''[[#Часть 2: Установка X и установка ALSA|Часть 2: Установка X и установка ALSA]]'''<br />
<br />
'''[[#Часть 3: Установка и настройка окружения рабочего стола|Часть 3: Установка и настройка окружения рабочего стола]]'''<br />
<br />
=====DON'T PANIC!=====<br />
Имейте в виду, что процедура установки Arch Linux может быть очень различна от установки других GNU/Linux дистрибутивов и вы можете запутаться, особенно если вы новичок. Обычно, GNU/Linux дистрибутивы распространяются вместе с крупным набором софта на CD (или даже DVD), включающий стандартное Рабочее Окруженее(DE) , стандартный набор программ и установок, автонастройщик оборудования и графический установщик, все что выбрано за вас. Для различия, система Arch Linux создаётся '''пользователем''', из установщика с псевдографикой и базовой системы в которой нет ничего кроме bash и простых консольных программ. Это — '''[[Arch Way]].''' В отличие от большинства других дистрибутивов с жесткой структурой, здесь нет ни стандартного окружения, ни конфигурации сделанной за ползователя. По просту говоря, Arch ждет вашего вклада. Из командной строки, ''вы'' можете установить необходимые пакеты из репозитория используя [[pacman]] и ''вручную'' настроить вашу систему под ''свои'' потребности, до того как это сделает кто-то другой. Этот метод дает вам максимум гибкости, выбора и контроля за вашей системой. Потому что '''вы''' настраиваете систему, вы всегда знаете все "гайки и болты" вашей системы, и вам знакомо что находится "под капотом". <br />
<br />
Arch Linux настраивается редактированием текстовых файлов. Из-за этого не требуются графические инструменты для настройки. <br />
Также запомните, что Arch Linux направлен на опытных GNU/Linux пользователей, на тех кто хочет минимального 'разделения' оборудования и софта, на тех пользователей, которые могут тратить своё время на чтение манов о своей системе.<br />
<br />
''Arch — это инструмент созданный пользователем.''<br />
<br />
=====[[The Arch Way]]=====<br />
<br />
'''''The design principles behind Arch are aimed at keeping it [[The Arch Way|simple]].'' '''<br />
<br />
Note that 'simple' does ''not'' mean 'easy' nor 'user-friendly' in this context, but rather; 'without unnecessary additions, modifications, or complications'. In short; an elegant, minimalist approach.<br />
<br />
''"Simple' is defined from a technical standpoint, not a usability standpoint. It is better to be technically elegant with a higher learning curve, than to be easy to use, and technically crap." -Aaron Griffin''<br />
<br />
''"The extraordinary part of [my method] lies in its simplicity..I have always believed that the simple way is the right way."'' - Bruce Lee<br />
<br />
Occam's razor: ''Entia non sunt multiplicanda praeter necessitatem'' or "Entities should not be multiplied unnecessarily." The term razor refers to the act of shaving away unnecessary assumptions and complications to get to the simplest explanation, method or theory.<br />
<br />
{{Box Note |'''Following this guide closely is essential in order to successfully install a properly configured Arch Linux system, so ''please'' read it thoroughly.'''}}<br />
* You may wish to print out this guide as a 58 page book which will serve as a useful Arch Linux user reference. <br />
*''If you would like to add to this wiki, please include the "Why" as well as the "How", where appropriate. The best documentation teaches us how, as well as why!''<br />
* The Arch wiki is an excellent resource and should be consulted for issues [http://wiki.archlinux.org/index.php/Main_Page first]; IRC and the [http://bbs.archlinux.org/ forums] are also available if the answer cannot be found.<br />
----<br />
Welcome to Arch! Now, let's get started.<br />
<br />
==Часть I: Установка Базовой Системы ==<br />
===Скачайте самый последний инсталяционный образ ===<br />
<br />
Вы можете получить самый последний образ Archlinux'а [http://archlinux.org/download/ здесь].<br />
<br />
*Core-iso и FTP-downloads включают в себя только самые необходимые пакеты для создания '''базовой системы Archlinux'''. ''Нужно заметить что в Базовую Систему не включен GUI. Сюда главным образом входит GNU инструментарий, (компилятор, ассемблер, linker, библиотеки, и немного полезных утилит) ядро Linux, и немного extra-библиотек и модулей.'' Остальное в Archlinux, включая GUI, может быть установлено из консоли, ''пользователем'', используя менеджер пакетов - pacman to grab i686/x86-64 binary packages. Процесс описывается в деталях ниже.<br />
<br />
Запишите образ системы на CD. <br />
{{Box Note| При записи не используйте скорость больше чем 8x - это рекомендованная скорость для надежной записи, также некоторые пользователи рекомендуют устанавливать очень низкую скорость '''''4x или 2x!''''' Если вам встретились неожиданные проблемы с установкой, попытайтесь записать образ с самой низкой скоростью поддерживаемой вашей системой.}}<br />
<br />
===Загрузка с Arch Linux CD===<br />
Вы должны следовать этим инструкциям, но также вы можете найти весьма полезное [[Руководство_по_установке|Официальное руководство по установке Arch Linux]]. <br />
Вставте CD в ваш CD-ROM и загрузитесь с CD. Если ваш компьютер по умолчанию загружается не с CD, вы можете исправить это <br />
изменив порядок загрузки в биосе (чтобы войти в биос используйте клавиши DEL, F1, F2, F11 или F12 при запуске компьютера (в зависимости от типа биоса)).<br />
<br />
Полезные опции загрузки:<br />
* '''ide-legacy''' если у вас возникают проблемы с IDE приводами<br />
* '''noapic acpi=off pci=routeirq nosmp''' если ваша система зависает при загрузке системы<br />
* '''acpi=nommconf''' если у вас возникают "задержки" после загрузки pci:mmconfig <br />
* '''memtest86+''' если вы хотите проверить вашу оперативную память на ошибки<br />
* '''lowmem''' полезно для старых компьютеров с ограниченным объёмом оперативной памяти<br />
<br />
Требования к памяти:<br />
* CORE ISO: lowmem-загрузка образа - 64 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* CORE ISO: обычная загрузка образа - 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
* FTP ISO : 160 MB RAM x86_64/i686 (выбраны все пакеты, имеется swap раздел)<br />
<br />
Выберите "Arch Linux Installation / Rescue System". Если вы нуждаетесь в изменениях опций загрузки, нажмите "e" для редактирования конфига загрузки.<br />
Система будет загружена и вам будет представлено сообщение приветствия с некоторыми пояснениями.<br />
<br />
===Вход в систему и изменение раскладки===<br />
Войдите в систему как 'root'. Елси ваша клавиатура не имеет американскую раскладку клавиатуры, выполните в коммандной строке следующее:<br />
{{Box Note| Скорее всего, у вас клавиатура с "американской" раскладкой (если ваша клавиатура приобретена в России)}}<br />
loadkeys <ваша раскладка><br />
<br />
===Запуск установки===<br />
Введите<br />
/arch/setup <br />
чтобы начать установку Archlinux. <br />
<br />
<br />
====Выбор источника установки====<br />
После экрана приветствия, вам будет предложено выбрать источник установки. Выберите CD если используйте диск, или выберите FTP если хотите использовать образ из FTP. <br />
* If you chose the CORE-ISO, continue below with [[#Prepare Hard Drive|Prepare Hard Drive]].<br />
* FTP Only: If using FTP, you will be prompted to load ethernet drivers manually, if desired. Udev is quite effective at loading the required modules, so you may assume it has already done so. You may verify this by invoking ifconfig -a from vc2. (Select OK to continue.)<br />
<br />
====FTP: Configure Network====<br />
Available Interfaces will be presented. If an interface and HWaddr is listed, then your module has already been loaded. If your interface is not listed, you may probe it from the installer, or manually do so from another virtual console.<br />
<br />
The following screen will prompt you to Select the interface, Probe, or Cancel. Choose the appropriate interface and continue.<br />
<br />
The installer will then ask if you wish to use DHCP. Choosing Yes will run '''dhcpcd''' to discover an available gateway and request an IP address; Choosing No will prompt you for your static IP, netmask, broadcast, gateway DNS IP, HTTP proxy, and FTP proxy. Lastly, you will be presented with an overview to ensure your entries are correct.<br />
<br />
Continue with [[#Prepare Hard Drive|Prepare Hard Drive]]<br />
<br />
====Prepare Hard Drive====<br />
Select the first menu entry "Prepare Hard Drive". <br />
* Option 1: Auto Prepare<br />
Auto-Prepare divides your disk into the following configuration:<br />
<br />
* ext2 /boot partition, default size 32MB. You will be prompted to modify the size to you requirement.<br />
* swap partition, default size 256MB. You will be prompted to modify the size to you requirement. <br />
* A Separate / and /home partition, (sizes can also be specified). You may choose from ext2, ext3, reiserfs, xfs and jfs, but both / and /home must share the same fs type.<br />
<br />
Be warned that Auto-prepare will completely erase the chosen hard drive. Read the warning presented by the installer very carefully, and make sure the correct device is about to be partitioned.<br />
<br />
Of course, if you have but one hard drive in your system and have decided to dedicate it to Arch, you have nothing to worry about. <br />
<br />
* Option 2: '''(Recommended)''' Partition Hard Drives (with cfdisk)<br />
<br />
Select the hard drive you wish to install to (/dev/sd''x'').<br />
<br />
''At this point, more advanced GNU/Linux users who are familiar and comfortable with manually partitioning may wish to skip down to '''[[#Select Packages|Select Packages]]''' below.''<br />
<br />
=====Partition Info=====<br />
<br />
Partitioning a hard disk drive defines specific areas (the partitions) within the disk, that will each appear and behave as a separate disk and upon which a filesystem may be created (formatted). Partitions are broken up into "Primary", "Extended", and "Logical". <br />
<br />
'''Primary''' partitions can be bootable, and are limited to 4. Beyond 4 partitions, we are forced to use an '''extended''' partition which will contain '''logical''' partitions.<br />
<br />
Extended partitions are not usable by themselves; they are merely a "container" for logical partitions. A hard disk may contain only one extended partition; which can then be sub-divided into logical partitions. <br />
<br />
When partitioning a disk, one can see this numbering scheme by creating primary partitions sda1-3 followed by creating an extended partition, sda4, and subsequently creating logical partition(s) within the extended partition; sda5, sda6, and so on.<br />
<br />
=====Swap Partition=====<br />
A swap partition is a place on your hard drive where "virtual ram" resides, allowing the kernel to easily use disk storage for data that does not fit into physical RAM. <br />
<br />
Historically, the general rule for swap partition size was 2x the amount of physical RAM. Over time, as computers have gained ever larger memory capacities, this rule has become increasingly deprecated. Generally, on machines with up to 512MB RAM, the 2x rule is usually sufficient. On machines with 1GB RAM, generally a 1x rule is adequate. If you have gratuitous amounts of RAM (more than 1024 MB) it may be possible to completely forgo a swap partition altogether, though this is not recommended. We will create a 1 GB swap partition in this example.<br />
{{Box Note|If you plan on using suspend-to-disk, (hibernate) you must have a swap partition at least '''equal''' in size to the amount of physical RAM, and some users even recommend oversizing it beyond the amount of physical RAM by 15% to allow for possible bad sectors.}}<br />
<br />
=====Partition Scheme=====<br />
A disk partitioning scheme is a very personalized preference. Each user's choices will be unique to their own computing habits and requirements. What you need at the least is one primary partition which contains the root [http://en.wikipedia.org/wiki/File_system Filesystem] ( / ) and one for swap. Other candidates for separate partitions include /boot (which mainly contains the kernel) /var, and /home (which contains the user data). It is generally considered good practice and more versatile to have / and /home on separate partitions.<br />
In this example, we shall use one partition for /, one partition for /home, and a swap partition.<br />
<br />
=====cfdisk===== <br />
Let's start by creating the primary partition that will contain the '''root''', (/) filesystem. <br />
<br />
Choose '''N'''ew -> Primary and enter the size you want (something between 4 and 12 GB is a good choice for a full-featured Linux system). Put the partition at the beginning of the disk. Select the newly created partition and choose '''B'''ootable to make this partition bootable. <br />
<br />
Also choose the '''T'''ype by designating it as '83 Linux'. The created / partition should appear as sda1.<br />
<br />
Next, create a partition for swap. Select a size between 512 MB and 1 GB and change the '''T'''ype to 82 (Linux swap / Solaris). The created swap partition should appear as sda2.<br />
<br />
Lastly, another partition for your /home directory. Choose another primary partition and set the size to a value you like. The size really depends on what your users store in their home directories, so I cannot make any suggestions. The size may vary between a few hundred megabytes for some office documents up to hundreds of gigabytes for videos and MP3s. If you want to use the entire remaining space on your hard disc, remember to reserve a quantity for the swap partition. (1 GB, or 1024MB, in our example)<br />
<br />
Likewise, select the '''T'''ype as 83 Linux. The created /home partition should appear as sda3.<br />
<br />
<br />
<br />
This is what your Layout should look like (size may vary depending on your decisions):<br />
<br />
Name Flags Part Type FS Type [Label] Size (MB)<br />
-------------------------------------------------------------------------<br />
sda1 Boot Primary Linux (4096 - 8192)<br />
sda2 Primary Linux swap / Solaris (512 - 1024)<br />
sda3 Primary Linux (> 100 or remaining space)<br />
<br />
Choose '''W'''rite and type ''''yes''''. Beware that this operation may destroy data on your disk if you deleted partitions. Choose '''Q'''uit to leave the partitioner. <br />
Choose Done to leave this menu and continue with "Set Filesystem Mountpoints".<br />
<br />
=====I have IDE devices, why do they look like SCSI devices?=====<br />
Since the latest developments of the Linux kernel which include the libata and PATA modules, all IDE, SATA and SCSI drives have adopted the sd''x'' naming scheme. This is perfectly normal and should not be a concern.<br />
<br />
====Set File system Mountpoints====<br />
First you will be asked for your swap partition. Choose the appropriate partition (sda3 in this example). You will be asked if you want to create a swap filesystem; select yes. Next, choose where to mount the / (root) directory (sda1 in the example). You will be asked what kind of filesystem you want.<br />
<br />
=====Filesystem Types=====<br />
<br />
Again, a filesystem type is a very subjective matter which comes down to personal preference. Each one has its own advantages and disadvantages, and differences in performance are often more likely to be attributable to placebo than to human-perceivable measurements. Here is a very brief overview of supported filesystems:<br />
<br />
1. '''ext2''' - Old, reliable GNU/Linux filesystem. Very stable, but ''without journaling support''. May be inconvenient for root (/) and /home, due to very long fsck's. ''An ext2 filesystem can easily be converted to ext3.''<br />
<br />
2. '''ext3''' - Essentially the ext2 system, but with journaling support. ext3 is completely compatible with ext2. Generally perceived and benchmarked as ''slightly'' slower than other filesystems, but ''extremely'' stable and by far the most widely used, supported and developed GNU/Linux FS.<br />
<br />
3. '''ReiserFS''' - Hans Reiser's high-performance journaling FS uses a very interesting method of data throughput. ReiserFS is touted as very fast, especially when dealing with many small files. ReiserFS is comparatively slow at mounting. Quite well established and stable. ReiserFS isn't actively developed at this time (Reiser4 is the new Reiser filesystem).<br />
<br />
4. '''JFS''' - IBM's '''J'''ournaled '''F'''ile'''S'''ystem. JFS uses the least CPU resources of any filesystem. Very fast at mounting and fsck's, and very good all-around performance, especially in conjunction with the deadline scheduler. (See [[JFS]].) Not as widely supported as ext or ReiserFS. <br />
<br />
5. '''XFS''' - Journaling filesystem which is best suited for large files. Very fast at mounting. May be slower than ReiserFS for many small files. The only available GNU/Linux FS with online defragmentation ability.<br />
<br />
A major difference is [http://en.wikipedia.org/wiki/Journaling_file_system journaling] (something similar to transaction logs in database environments). All filesystems except ext2 use journaling. Note that not all journaling techniques are alike; specifically, only ext3 journals BOTH data AND meta-data (directory information). The others only journal meta-data. While all will return your filesystem to a valid state after recovering from a crash, only ext3 guarantees that you won't be left with some "stale data".<br />
<br />
Choose and create the filesystem (format the partition) for / by selecting '''yes'''. You will now be prompted to add any additional partitions. In our example, only sda2 is remaining. Choose a filesystem type and mount it as /home. Again, create the filesystem and choose Done. Return to main menu.<br />
<br />
===Select Packages===<br />
Now we shall select packages to install in our system.<br />
*Core ISO: Choose CD as source and select the appropriate CD drive if you have more than one.<br />
*FTP ISO: Select an FTP/HTTP mirror. ''Note that archlinux.org is throttled to 50KB/s''.<br />
<br />
Package selection is split into two stages. First, you will select package categories, then you will be presented will the full lists of packages in the selected categories, allowing you to fine-tune your selections. The space bar selects and unselects the categories.<br />
<br />
*'''BASE:''' Contains the minimal package set; just enough for a barebones system.<br />
*'''SUPPORT:''' Additional packages for networking and filesystems, etc, such as gpm, fuse, dnsutils, wireless drivers, ndiswrapper, ntfs-3g, and so forth.<br />
*'''DEVEL:''' Software compiling tools such as GCC, autoconf, automake and make.<br />
*'''LIB:''' Various libraries such as gmp, lebelf, libevent, etc. <br />
<br />
Choose OK to continue and then choose 'yes' for 'Select all packages by default', for now.<br />
<br />
The next screen will present you with the selected packages within your selected categories. Leaving all selected is a safe choice for beginners, while more experienced users will wish to trim a few unnecessary packages. (For instance, an unneeded filesystem type utility, unneeded drivers, etc.)<br />
<br />
===Install Packages===<br />
Next, choose 'Install Packages'. You will be asked if you wish to keep the packages in the pacman cache. If you choose 'yes', you will have the flexibility to [[Downgrade packages|downgrade]] to previous package versions in the future, so this is recommended (you can always clear the cache in the future). The installer script will now install the selected packages, as well as the default Arch 2.6 kernel, to your system. <br />
*FTP ISO: The [[Pacman]] package manager will now download and install your selected packages. (See VC5 for output, VC1 to return to the installer)<br />
*CORE ISO: The packages will be installed from the CD.<br />
<br />
Note: For Arch 2007.08 FTP installation: after 'Install Packages' you have to upgrade pacman (ALT+F2, pacman -Sy pacman) and again 'Install Packages'.<br />
<br />
===Configure The System===<br />
''Closely following and understanding these steps is of key importance to ensure a properly configured system.'' <br />
<br />
The installer will ask if you want to choose [[Hwdetect|hwdetect]] to gather information for your configuration. Beginners should choose 'yes'. <br />
<br />
Advanced users who are thoroughly familiar with their hardware, required modules, and who are able to manually configure /etc/rc.conf, /etc/mkinitcpio and /etc/fstab, etc. from scratch may wish to choose 'no'. (Needless to say, this option is very involved, beyond the scope of this guide, and therefore is not covered.)<br />
<br />
Next, you will be asked if you need support for booting from USB devices, FireWire devices, PCMCIA devices, NFS shares, software RAID arrays, LVM2 volumes, encrypted volumes, and DSDT support. Choose yes if you need it; in our example nothing is needed. <br />
<br />
Now you will be asked which text editor you want to use; choose [http://en.wikipedia.org/wiki/Nano_%28text_editor%29 nano] or [http://en.wikipedia.org/wiki/Vim_%28text_editor%29 vi/vim] (recommended). You will be presented with a menu including the most important configuration files for your system. If you want to look up the available options as stated in /etc/rc.conf just press Alt+F2 to get a shell, look it up, and switch back to the installer with Alt+F1. <br />
=====Why doesn't the installer handle this more automatically?=====<br />
Hiding the process of system configuration is in direct opposition to [[The Arch Way]]. While it is true that recent versions of the kernel and hardware probing tools offer excellent hardware support and autoconfiguration, Arch presents the user all pertinent configuration files during installation for the purpose of ''transparency''. By the time you have finished modifying these files to your specifications, you will have learned the simple method of manual Arch Linux system configuration and become more familiar with the base structure, leaving you better prepared to use your new installation productively.<br />
<br />
====='''/etc/rc.conf'''=====<br />
Arch Linux follows in the '''*BSD''' tradition of utilizing '''/etc/rc.conf''' as the principal location for system configuration. This one file contains a wide range of configuration information, principally used at system startup. As its name directly implies, it also contains settings for and invokes the /etc/rc* files, and is, of course, sourced ''by'' these files. /etc/rc.conf offers a simple, elegant method of streamlining system resource configuration by encompassing a wide range of control, readily accessible for the Arch user. <br />
* '''LOCALIZATION''' section<br />
** '''LOCALE'''=: This sets your system locale, which will be used by all i18n-aware applications and utilities. You can get a list of the available locales by running 'locale -a' from the command line. This setting's default is fine for US English users. <br />
** '''HARDWARECLOCK'''=: Specifies whether the hardware clock, which is synchronized on bootup and on shutdown, stores '''UTC''' time, or the '''localtime'''. UTC makes sense because it greatly simplifies changing timezones and daylight savings time. localtime is necessary if you dual boot with an operating system such as Windows, that only stores localtime to the hardware clock.<br />
** '''TIMEZONE'''=: Specify your TIMEZONE. (All available zones are under /usr/share/zoneinfo/).<br />
** '''KEYMAP'''=: The available keymaps are in /usr/share/kbd/keymaps. Please note that this setting is only valid for your TTYs, not any graphical window managers or X!<br />
** '''CONSOLEFONT'''=: Available console fonts reside under /usr/share/kbd/consolefonts/ if you must change. The default (blank) is safe.<br />
** '''CONSOLEMAP'''=: Defines the console map to load with the setfont program on bootup. Possible maps are found in /usr/share/kbd/consoletrans, if needed. The default (blank) is safe. <br />
** '''USECOLOR'''=: Select "yes" if you have a color monitor and wish to have colors in your consoles.<br />
<br />
LOCALE="en_US.utf8"<br />
HARDWARECLOCK="localtime"<br />
TIMEZONE="US/Eastern"<br />
KEYMAP="us"<br />
CONSOLEFONT=<br />
CONSOLEMAP=<br />
USECOLOR="yes"<br />
* '''HARDWARE''' section<br />
** '''MOD_AUTOLOAD'''=: Setting this to "yes" will utilize '''udev''' to automatically probe hardware and load the appropriate modules during boot-up, (convenient with the default modular kernel). Setting this to "no" will rely on the user's ability to specify this information manually, or compile their own custom kernel and modules, etc. <br />
** '''MOD_BLACKLIST'''=: This has become deprecated in favor of adding blacklisted modules directly to the '''MODULES=''' line below. <br />
** '''MODULES'''=: Specify additional MODULES if you know that an important module is missing, ('''hwdetect''' should have filled in the most important modules). Also specify any blacklisted modules by prefixing them with a bang (!). Udev will be forced NOT to load blacklisted modules. In the example, the IPv6 module as well as the annoying pcspeaker are blacklisted. <br />
# Scan hardware and load required modules at bootup<br />
MOD_AUTOLOAD="yes"<br />
# Module Blacklist - Deprecated<br />
MOD_BLACKLIST=()<br />
#<br />
MODULES=(e100 eepro100 mii slhc snd-ac97-codec snd-intel8x0 soundcore !net-pf-10 !pcspkr)<br />
* '''NETWORKING''' section<br />
** '''HOSTNAME'''=:Set your HOSTNAME to your liking.<br />
** '''eth0'''=: 'Ethernet, card 0'. Adjust the interface IP address, netmask and broadcast address ''if'' you are using '''static IP'''. Set eth0="dhcp" if you want to use '''DHCP'''<br />
** '''INTERFACES'''=: Specify any/all interfaces here. If you do not use DHCP to configure a device, just keep in mind that the value of the variable (whose name must be equal to the name of the device which is supposed to be configured) equals the line which would be appended to the ifconfig command if you were to configure the device manually in the shell.<br />
** '''gateway'''=: If you are using '''static IP''', set the gateway address. Ignore this entry if using '''DHCP'''<br />
** '''ROUTES'''=: If you are using static '''IP''', remove the '''!''' in front of 'gateway'. Leave the '''!''' if using '''DHCP'''<br />
<br />
Example, using '''DHCP''':<br />
HOSTNAME="arch"<br />
#eth0="eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255" <br />
eth0="dhcp"<br />
INTERFACES=(eth0)<br />
gateway="default gw 192.168.0.1"<br />
ROUTES=(!gateway)<br />
* '''DAEMONS''' section<br />
This array simply lists the names of those scripts contained in /etc/rc.d/ which are to be started during the boot process, and the order in which they start. <br />
DAEMONS=(@network syslog-ng netfs crond)<br />
*If a script name is prefixed with a bang (!), it is not executed. <br />
*If a script is prefixed with an "at" symbol (@), then it will be executed in the background; the startup sequence will not wait for successful completion of each daemon before continuing to the next. (Useful for speeding up system boot).<br />
*Edit this array whenever new system services are installed, if starting them automatically during bootup is desired. <br />
<br />
This 'BSD-style' init, is the Arch way of handling what others handle with various symlinks to an /etc/init.d directory.<br />
<br />
=====About DAEMONS=====<br />
You don't have to change the [[daemons]] line at this time, but it is useful to explain what daemons are, because we need them later in this guide. <br />
<br />
Analogous to a Windows service, a ''daemon'' is a program that runs in the background, waiting for events to occur and offering services. A good example is a webserver that waits for a request to deliver a page or an SSH server waiting for someone trying to log in. While these are full-featured applications, there are daemons whose work is not that visible. Examples are a daemon which writes messages into a log file (e.g. syslog, metalog), a daemon which lowers your CPU's frequency if your system has nothing to do (e.g.:cpufreq), and a daemon which offers you a graphical login (e.g.: gdm, kdm). All these programs can be added to the daemons line and will be started when the system boots. Useful daemons will be presented during this guide.<br />
<br />
Historically, the term ''daemon'' was coined by the programmers of MIT's Project MAC. They took the name from ''Maxwell's demon'', an imaginary being from a famous thought experiment that constantly works in the background, sorting molecules. <code>UNIX</code> systems inherited this terminology and created the backronym '''d'''isk '''a'''nd '''e'''xecution '''mon'''itor. <br />
<br />
*'''''Tip: All Arch daemons reside under /etc/rc.d/'''''<br />
<br />
=====/etc/fstab=====<br />
The '''fstab''' (for '''f'''ile '''s'''ystems '''tab'''le) is part of the system configuration listing all available disks and disk partitions, and indicating how they are to be initialized or otherwise integrated into the overall system's file system. The '''/etc/fstab''' file is most commonly used by the '''mount''' command, which reads /etc/fstab to determine which options should be used when mounting the specified device.<br />
<br />
<br />
An example '''/etc/fstab''':<br />
<br />
#<br />
# /etc/fstab: static file system information<br />
#<br />
# <file system> <dir> <type> <options> <dump> <pass><br />
none /dev/pts devpts defaults 0 0<br />
none /dev/shm tmpfs defaults 0 0<br />
#/dev/cdrom /mnt/cdrom iso9660 ro,user,noauto,unhide 0 0<br />
#/dev/dvd /mnt/dvd udf ro,user,noauto,unhide 0 0<br />
#/dev/fd0 /mnt/fd0 vfat user,noauto 0 0<br />
/dev/disk/by-uuid/0ec-9339 / jfs defaults,noatime,nodiratime 0 1<br />
/dev/disk/by-uuid/7ef-223-0 /home jfs defaults,noatime,nodiratime 0 2<br />
/dev/disk/by-uuid/530-1e-2c2 swap swap defaults 0 0<br />
<br />
Modify your '''fstab''' to your requirements.<br />
{{Box Note | As of 2008-04rc, Arch is now utilizing the UUID, or Universally Unique Identifier naming convention, for consistent device mapping. This is due to active developments in the kernel and also udev, which may randomly change the ordering in which drivers for storage controllers are loaded, yielding an unbootable system/kernel panic. Nearly every motherboard has several controllers (onboard SATA, onboard IDE), and due to the aforementioned development updates, /dev/sda may become /dev/sdb on the next reboot- hence the persistent device naming convention of UUID has been adopted for reliability.}}<br />
ls -lF /dev/disk/by-uuid/<br />
Will list all partitions by uuid.<br />
<br />
*If you plan on using '''hal''' to automount media such as DVDs, you may wish to comment out the cdrom and dvd entries in preparation for '''hal''', which will be installed later in this guide.<br />
<br />
{{Box Note | '''''The 'noatime' and 'nodiratime' options may safely be appended to / and /home regardless of your specified filesystem type for increased speed, performance, and power efficiency, for laptops as well as desktops.'''''}}<br />
<br />
Expanded information available in the [[Fstab]] wiki entry.<br />
<br />
====='''/etc/mkinitcpio.conf and /etc/modprobe.conf'''=====<br />
We shouldn't need to edit these configurations at this point. <br />
<br />
* '''mkinitcpio.conf''' This file allows you to fine-tune the initial ram filesystem (also commonly referred to as the initial ramdisk or "initrd") for your system. The initrd is a gzipped image that is read by the kernel during bootup. The purpose of the initrd is to bootstrap the system to the point where it can access the root filesystem. This means it has to load any modules that are required for devices like IDE, SCSI, or SATA drives (or USB/FW, if you are booting off a USB/FW drive). Once the initrd loads the proper modules, either manually or through udev, it passes control to the Arch system and your bootup continues. For this reason, the initrd only needs to contain the modules necessary to access the root filesystem. It does not need to contain every module you would ever want to use. The majority of your everyday modules will be loaded later on by udev, during the init process.<br />
<br />
* '''modprobe.conf''' can be used to set special configuration options for the kernel modules <br />
<br />
=====/etc/resolv.conf (for Static IP)=====<br />
The ''resolver'' is a set of routines in the C library that provide access to the Internet Domain Name System (DNS). One of the main functions of DNS is to translate domain names into IP addresses, to make the Web a friendlier place. The resolver configuration file, or /etc/resolv.conf, contains information that is read by the resolver routines the first time they are invoked by a process.<br />
<br />
*''If you are using DHCP, you may safely ignore this file, as by default, it will be dynamically created and destroyed by the dhcpcd daemon. You may change this default behavior if you wish. (See [[Network]]).''<br />
<br />
If you use a static IP, set your DNS servers in /etc/resolv.conf (nameserver <ip-address>). You may have as many as you wish, e.g.:<br />
nameserver 4.2.2.1<br />
nameserver 4.2.2.2<br />
<br />
If you are using a router, you will probably want to specify your DNS servers in the router itself, and merely point to it from your '''/etc/resolv.conf''', using your router's IP (which is also your gateway from '''/etc/rc.conf'''), e.g.:<br />
nameserver 192.168.1.1<br />
<br />
If using '''DHCP''', you may also specify your DNS servers in the router, or allow automatic assignment from your ISP, if your ISP is so equipped.<br />
<br />
=====/etc/hosts=====<br />
<br />
This file associates IP addresses with hostnames and aliases, one line per IP address. For each host a single line should be present with the following information:<br />
<IP-address> <hostname> [aliases...]<br />
Add your ''hostname'', coinciding with the one specified in /etc/rc.conf, as an alias, so that it looks like this:<br />
127.0.0.1 localhost.localdomain localhost '''''yourhostname'''''<br />
{{Box Note |''This format, '''including the 'localhost' and your actual host name''', is required for program compatibility! Errors in this entry may cause poor network performance and/or certain programs to open very slowly, or not work at all. This is a very common error for beginners.''}}<br />
<br />
If you use a static IP, add another line using the syntax: <static-IP> <hostname.domainname.org> <hostname> e.g.:<br />
192.168.1.100 '''''yourhostname'''''.domain.org '''''yourhostname'''''<br />
<br />
*'''TIP''': For convenience, you may also use /etc/hosts aliases for hosts on your network, and/or on the Web, e.g.:<br />
64.233.169.103 www.google.com g<br />
192.168.1.90 media<br />
192.168.1.88 data<br />
The above example would allow you to access google simply by typing 'g' into your browser, and access to a media and data server on your network by name and without the need for typing out their respective IP addresses.<br />
<br />
=====/etc/hosts.deny and /etc/hosts.allow=====<br />
Modify these configurations according to your needs if you plan on using the [[SSH|ssh]] daemon. The default configuration will reject all incoming connections, not only ssh connections. Edit your '''/etc/hosts.allow '''file and add: <br />
sshd:all <br />
This will allow all incoming ssh connections.<br />
<br />
If you do not plan on using the [[SSH|ssh]] daemon, leave this file at the default, (empty), for added security.<br />
<br />
=====/etc/locale.gen=====<br />
<br />
The '''locale-gen''' command reads from '''/etc/locale.gen''' to generate specific locales. They can then be used by '''glibc''' and any other locale-aware program or library for rendering "peculiar" text, correctly displaying regional monetary values, time and date formats, alphabetic idiosyncrasies, and other locale-specific standards. The ability to setup a default locale is a great built-in privilege of using a <code>UNIX</code>-like operating system.<br />
<br />
By default /etc/locale.gen is an empty file with commented documentation. Once edited, the file won't get touched again. '''locale-gen''' runs on every '''glibc''' upgrade, generating all the locales specified in /etc/locale.gen.<br />
<br />
Choose the locale(s) you need (remove the # in front of the lines you want), e.g.:<br />
en_US ISO-8859-1<br />
en_US.UTF-8 <br />
<br />
The installer will now run the locale-gen script, which will generate the locales you specified. You may change your locale in the future by editing /etc/locale.gen and subsequently running 'locale-gen' as root.<br />
<br />
{{Box Note |'''''If you fail to choose your locale, this will lead to a "The current locale is invalid..." error. This is perhaps the most common mistake by new Arch users, and also leads to the most commonly asked questions on the forum.'''''}}<br />
<br />
=====Root password=====<br />
Finally, set a root password and make sure that you remember it later. Return to the main menu and continue with installing bootloader.<br />
<br />
=====Pacman-Mirror=====<br />
Choose a mirror repository for '''pacman'''. <br />
*''archlinux.org is throttled, limiting downloads to 50KB/s'' <br />
<br />
Return to the main menu.<br />
<br />
===Install Bootloader===<br />
Because we have no secondary operating system in our example, we will need a bootloader. [http://www.gnu.org/software/grub/ GNU GRUB] is the recommended bootloader. Alternatively, you may choose [http://lilo.go.dyndns.org/ LILO]. <br />
===GRUB===<br />
The provided '''GRUB''' configuration ('''/boot/grub/menu.lst''') should be sufficient. The only thing you may want to alter is the resolution of the console. Add<br />
a vga=<number> to the first kernel line. (A table of resolutions and the corresponding numbers is printed in the menu.lst.)<br />
<br />
Example: <br />
title Arch Linux (Main)<br />
root (hd0,0)<br />
kernel /boot/vmlinuz26 root=/dev/disk/by-uuid/0ec1-9339.. ro vga=773<br />
initrd /boot/kernel26.img<br />
Explanation:<br />
<br />
Line 1: '''title''': A printed menu selection. "Arch Linux (Main)" will be printed on the screen as a menu selection.<br />
<br />
Line 2: '''root''': GRUB's root; the drive and partition where the kernel (/boot) resides. '''NOT necesarily the root''' (/) file system, as they can reside on separate partitions. GRUB's numbering scheme starts at 0, and uses an hd''x,x'' format regardless of IDE or SATA, enclosed within parentheses. <br />
<br />
The example indicates that /boot is on the first partition of the first drive, or, (hd0,0).<br />
<br />
Line 3: '''kernel''': This line specifies:<br />
<br />
* The path and filename of the kernel '''''relative to GRUB's root''''' (within the partition containing the kernel). <br />
<br />
In the example, /boot is merely a directory residing on the same partition as / and '''vmlinuz26''' is the kernel filename; '''/boot/vmlinuz26'''. ''If /boot were on a separate partition, the path and filename would be simply '''/vmlinuz26''', being relative to '''GRUB''''s root.'' <br />
<br />
* The root= argument to the kernel statement specifies the partition containing the root (/) directory in the booted system, (more accurately, the partition containing '''/sbin/init'''), ''according to the UUID numbering scheme'' as of 2008-04rc, which uses the /dev/disk/by-uuid/xxxx-xxxx-xxxx format. <br />
<br />
* Kernel options. <br />
<br />
In our example, '''ro''' mounts the filesystem as read only during startup, and the '''"vga=773"''' argument will give a 1024x768 framebuffer with 256 color depth.<br />
<br />
Line 4: '''initrd''': (For Initial RAM disk) The path and filename of the initial RAM filesystem '''relative to GRUB''''s root (within the partition containing the kernel). Again, in the example, /boot is merely a directory residing on the same partition as / and '''kernel26.img''' is the initrd filename; '''/boot/kernel26.img'''. ''If /boot were on a separate partition, the path and filename would be simply '''/kernel26.img''', being relative to '''GRUB''''s root.'' <br />
<br />
Install the '''GRUB''' bootloader to the master boot record, (sda in our example).<br />
<br />
That's it; You have configured and installed your Arch Linux base system. Exit the install, eject the installer CD, and type the magic word:<br />
<br />
reboot<br />
<br />
Your new Arch Linux system will boot up and finish with a login prompt (you may want to change the boot order in your '''BIOS''' back to booting from hard disk).<br />
<br />
'''Congratulations, and welcome to your shiny, new Arch Linux base system!'''<br />
<br />
==The Base System ==<br />
Your new Arch Linux base system is now a functional GNU/Linux environment ready for customization. From here, you may build this elegant set of tools into whatever you wish or require for your purposes. <br />
<br />
Let's begin.<br />
<br />
Login with your root account. We will configure pacman and update the system as root, then add a normal user. <br />
{{Box Note |Virtual consoles 1-6 are available, as is the '''links''' command line web browser.}}<br />
<br />
===Configuring the network (if necessary)===<br />
*''This section will assist you in configuring most types of networks, if your network configuration is not working for you.''<br />
<br />
If you properly configured your system, you should have a working network. Try to ping www.google.com to verify this.<br />
ping -c 3 www.google.com<br />
<br />
''If you have successfully established a network connection, continue with '''[[#Update, Sync and Upgrade the system with pacman|Update, Sync and Upgrade the system with pacman]]'''.''<br />
<br />
If, after trying to ping www.google.com, you get an "unknown host" error, you may conclude that your network is not properly configured. You may choose to double-check the following files for integrity and proper settings:<br />
<br />
'''/etc/rc.conf''' # Specifically, check your HOSTNAME= and NETWORKING section for typos and errors.<br />
<br />
'''/etc/hosts''' # Double-check your format. (See above.)<br />
<br />
'''/etc/resolv.conf''' # If you are using a static IP. If you are using DHCP, this file will be dynamically created and destroyed by default, but can be changed to your preference. (See [[Network]].)<br />
<br />
Advanced instructions for configuring the network can be found in the [[Network]] article.<br />
<br />
====Wired LAN====<br />
<br />
Check your Ethernet with<br />
ifconfig -a<br />
All interfaces will be listed. You should see an entry for eth0, or perhaps eth1. If required, you can set a new static IP with<br />
ifconfig eth0 <ip address> netmask <netmask> up <br />
and the default gateway with<br />
route add default gw <ip address of the gateway><br />
Check to see if /etc/resolv.conf contains your DNS server and add it if it is missing. <br />
Check your network again with ping www.google.de. If everything is working now, adjust /etc/rc.conf as described above for static IP. If you have a DHCP server/router in your network try<br />
dhcpcd eth0<br />
If this is working, adjust /etc/rc.conf as described above, for dynamic IP.<br />
<br />
====Wireless LAN====<br />
Detailed setup guide: [[Wireless Setup]]<br />
<br />
====Analog Modem====<br />
To be able to use a Hayes-compatible, external, analog modem, you need to at least have the ppp package installed. Modify the file /etc/ppp/options to suit your needs and according to man pppd. You will need to define a chat script to supply your username and password to the ISP after the initial connection has been established. The manpages for pppd and chat have examples in them that should suffice to get a connection up and running if you're either experienced or stubborn enough. With udev, your serial ports usually are /dev/tts/0 and /dev/tts/1.<br />
Tip: Read [[Dialup without a dialer HOWTO]].<br />
<br />
Instead of fighting a glorious battle with the plain pppd, you may opt to install wvdial or a similar tool to ease the setup process considerably. In case you're using a so-called WinModem, which is basically a PCI plugin card working as an internal analog modem, you should indulge in the vast information found on the [http://www.linmodems.org/ LinModem] homepage.<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, meaning that you won't need to recompile your kernel unless you're about to use rather odd ISDN hardware. After physically installing your ISDN card in your machine or plugging in your USB ISDN-Box, you can try loading the modules with modprobe. Nearly all passive ISDN PCI cards are handled by the hisax module, which needs two parameters: type and protocol. You must set protocol to '1' if your country uses the 1TR6 standard, '2' if it uses EuroISDN (EDSS1), '3' if you're hooked to a so-called leased-line without D-channel, and '4' for US NI1.<br />
<br />
Details on all those settings and how to set them is included in the kernel documentation, more specifically in the isdn subdirectory, and available online. The type parameter depends on your card; a list of all possible types can be found in the README.HiSax kernel documentation. Choose your card and load the module with the appropriate options like this:<br />
<br />
modprobe hisax type=18 protocol=2<br />
<br />
This will load the hisax module for my ELSA Quickstep 1000PCI, being used in Germany with the EDSS1 protocol. You should find helpful debugging output in your /var/log/everything.log file, in which you should see your card being prepared for action. Please note that you will probably need to load some USB modules before you can work with an external USB ISDN Adapter.<br />
<br />
Once you have confirmed that your card works with certain settings, you can add the module options to your /etc/modprobe.conf:<br />
<br />
alias ippp0 hisax<br />
options hisax type=18 protocol=2<br />
<br />
Alternatively, you can add only the options line here, and add hisax to your MODULES array in the rc.conf. It's your choice, really, but this example has the advantage that the module will not be loaded until it's really needed.<br />
<br />
That being done, you should have working, supported hardware. Now you need the basic utilities to actually use it!<br />
<br />
Install the isdn4k-utils package, and read the manpage to isdnctrl; it'll get you started. Further down in the manpage you will find explanations on how to create a configuration file that can be parsed by isdnctrl, as well as some helpful setup examples. Please note that you have to add your SPID to your MSN setting separated by a colon if you use US NI1.<br />
<br />
After you have configured your ISDN card with the isdnctrl utility, you should be able to dial into the machine you specified with the PHONE_OUT parameter, but fail the username and password authentication. To make this work add your username and password to /etc/ppp/pap-secrets or /etc/ppp/chap-secrets as if you were configuring a normal analogous PPP link, depending on which protocol your ISP uses for authentication. If in doubt, put your data into both files.<br />
<br />
If you set up everything correctly, you should now be able to establish a dial-up connection with<br />
isdnctrl dial ippp0<br />
as root. If you have any problems, remember to check the logfiles!<br />
<br />
====DSL (PPPoE)====<br />
<br />
These instructions are relevant to you only if your PC itself is supposed to manage the connection to your ISP. You do not need to do anything but define a correct default gateway if you are using a separate router of some sort to do the grunt work.<br />
<br />
Before you can use your DSL online connection, you will have to physically install the network card that is supposed to be connected to the DSL-Modem into your computer. After adding your newly installed network card to the modules.conf/modprobe.conf or the MODULES array, you should install the rp-pppoe package and run the pppoe-setup script to configure your connection. After you have entered all the data, you can connect and disconnect your line with<br />
<br />
/etc/rc.d/adsl start<br />
<br />
and<br />
<br />
/etc/rc.d/adsl stop<br />
<br />
respectively. The setup usually is rather easy and straightforward, but feel free to read the manpages for hints. If you want to automatically dial in on boot-up, add adsl to your DAEMONS array.<br />
<br />
==Update, Sync and Upgrade the system with [[pacman]]==<br />
Now we will update the system using [[pacman]]. <br />
<br />
=====What is pacman ?=====<br />
[[Pacman]] is the '''pac'''kage '''man'''ager of Arch Linux. Pacman is written in C and is fast, simple, and extremely powerful. It manages your entire package system and handles installation, removal, package downgrade (through cache), custom compiled package handling, automatic dependency resolution, remote and local searches and much more. Arch uses the .tar.gz package format, which further enhances pacman's speed; Gzipped tarballs, though slightly larger, are decompressed much faster than their Bzipped counterparts, and are therefore generally installed more expediently. <br />
<br />
We will use pacman to download software packages from remote repositories and install them onto your system.<br />
<br />
Pacman is the most important tool in your Arch Linux toolbox for building the base system into whatsoever you please.<br />
<br />
===Configuring pacman===<br />
<br />
=====Package Repositories and /etc/pacman.conf=====<br />
Arch currently offers the following repositories readily accessible through pacman:<br />
<br />
'''[core]'''<br />
<br />
The simple principle behind [core] is to provide only one of each necessary tool for a base Arch Linux system; The GNU toolchain, the Linux kernel, one editor, one command line browser, etc. (There are a few exceptions to this. For instance, both vi and nano are provided, allowing the user to choose one or both.) Developer maintained.<br />
<br />
*''The Core installation cd simply contains an installer script, and a snapshot of the core repository.''<br />
<br />
'''[extra]'''<br />
<br />
The [extra] repository contains all Arch packages that are not themselves necessary for a base Arch system, but contribute to a more full-featured environment. '''X''', KDE and GNOME, for instance, can be found here. Developer maintained.<br />
<br />
'''[unstable]'''<br />
<br />
The [unstable] repository contains experimental and unstable software, especially if the development version of a package has become popular for some reason. For example, perhaps the upstream stable version is hopelessly out of date, or the unstable version has some groundbreaking changes that a lot of users seem interested in, like experimental kernel drivers or -svn package versions. Developer maintained.<br />
<br />
{{Box Note |'''Contrary to popular belief, it is perfectly safe to enable the unstable repository, as there are no name collisions with [core], [community] or [extra]. Packages from [unstable] are only installed if you explicitly do so. If there is a conflict between an [Unstable] package and an installed package, pacman will warn you and resolve the conflict, if prompted, by removing the installed package.'''}}<br />
<br />
The [unstable] repository is currently not maintained for ''x86_64''.<br />
<br />
'''[testing]'''<br />
<br />
The [testing] repository contains packages that are candidates for the [core], [extra] or [unstable] repositories. New packages go into [testing] if:<br />
* they are expected to break something on update and need to be tested first<br />
* they require other packages to be rebuilt. In this case, all packages that need to be rebuilt are put into [testing] first and when all rebuilds are done, they are moved back to the other repositories. Developer maintained.<br />
<br />
[testing] is the only repository that can have name collisions with any of the other official repositories. If enabled, it has to be the first repo listed in your ''pacman.conf'' file.<br />
<br />
{{Box Note|'''''Be careful when enabling [testing]. Your system may break after you update with [testing] enabled. Only experienced users should use it.'''''}}<br />
<br />
'''[community]'''<br />
<br />
The [community] repository is maintained by the ''Trusted Users (TUs)'' and is part of the ''Arch User Repository ([[AUR]])''. It contains binary packages from the ''AUR'' that have enough votes and were adopted by a ''TU''. Like all repos listed above, [community] may be readily accessed by pacman.<br />
<br />
The '''[[AUR]]''' also contains the '''unsupported''' branch, which cannot be accessed directly by pacman*. [unsupported] contains more than 8 thousand PKGBUILD scripts for building packages from source, that may be unavailable through the other repos. <br />
<br />
<nowiki>*</nowiki>''The '''''[[#Install Yaourt| yaourt]]''''' tool, an extremely popular, community contributed wrapper for pacman, can seamlessly access the '''AUR'''.''<br />
<br />
'''/etc/pacman.conf'''<br />
<br />
pacman will attempt to read /etc/pacman.conf each time it is invoked. This configuration file is divided into sections, or repositories. Each section defines a package [[Official Repositories|repository]] that pacman can use when searching for packages. The exception to this is the options section, which defines global options.<br />
nano /etc/pacman.conf<br />
Example:<br />
[core]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[extra]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
#[unstable]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
[community]<br />
# Add your preferred servers here, they will be used first<br />
Include = /etc/pacman.d/mirrorlist<br />
Enable all desired repositories (remove the # in front of the 'Include =' and '[repository]' lines).<br />
<br />
<br />
*'''''When choosing repos, be sure to uncomment both the repository header lines in [brackets] as well as the 'Include =' lines. Failure to do so will result in the selected repository being omitted! This is a very common error.'' '''<br />
<br />
====/etc/pacman.d/mirrorlist====<br />
Faster mirrors will dramatically improve pacman performance, and your overall Arch Linux experience.<br />
<br />
Edit /etc/pacman.d/mirrorlist:<br />
nano /etc/pacman.d/mirrorlist<br />
Remove all mirrors which are not on your continent, or are extremely distant. (Using nano, you may use CTRL-K to cut each unneeded line.) <br />
<br />
Edit /etc/pacman.d/mirrorlist by placing the best mirror at the top of the list. (Recall that archlinux.org is throttled to 50KB/s). If using nano, you can cut a line with CTRL-K and paste with CTRL-U. <br />
<br />
After changing mirrors, issue the following command:<br />
pacman -Syy<br />
This will force pacman to resynchronize with the new repo. Issuing pacman -Syy ''whenever a mirror is changed'', is good practice and will avoid possible headaches.<br />
=====Ignoring packages=====<br />
When you execute the command "pacman -Syu", your entire system will be updated. It is possible that you want to prevent a package from being upgraded. An example could be the kernel (kernel26) or a package for which an upgrade may prove problematic for your system. In this case, you have two options; indicate the packages you want to skip in the pacman command line using the --ignore switch (do pacman -S --help for details) or permanently indicate the packages you want to skip in your /etc.pacman.conf file:<br />
<br />
IgnorePkg = kernel26<br />
The typical way to use Arch is to use pacman to install all packages unless there is no package available, in which case you can build your own package using [[ABS]]. Many user-contributed packages are available in the Arch User Repository. You are expected to keep your system up to date with pacman -Syu, rather than selectively upgrading packages. Use of '''IgnorePkg''' in /etc/pacman.conf is therefore discouraged, and should be used sparingly, if you know what you are doing.<br />
<br />
You may diverge from this typical usage as you wish; just be warned that there is a greater chance that things will not work as intended and that it could break your system. The majority of complaints happen when selective upgrading or unusual compilation is performed.<br />
<br />
=====Ignoring Configuration Files=====<br />
In the same vein, you can also "protect" your configuration/system files from being overwritten during "pacman -Su" using the following option in your /etc/pacman.conf<br />
<br />
NoUpgrade = etc/lilo.conf boot/grub/menu.lst<br />
<br />
==Update System==<br />
Update, sync, and '''upgrade''' your entire new system with:<br />
pacman -Syu<br />
pacman will now fetch the latest information about available packages and perform all available upgrades. (You may be prompted to upgrade pacman itself at this point. If so, say yes, and then reissue the pacman -Syu command when finished.) <br />
Reboot if a kernel upgrade has occurred. <br />
{{Box Note|'''''Occasionally, configuration changes may take place requiring user action during an update; read pacman's output for any pertinent information.'''''}}<br />
<br />
=====The beauty of the Arch rolling release model=====<br />
Keep in mind that Arch is a '''rolling release''' distribution. This means there is never a reason to reinstall or perform elaborate system rebuilds to upgrade to the newest version. Simply issuing '''pacman -Syu''' periodically keeps your entire system up-to-date and on the bleeding edge. At the end of this upgrade, your system is completely current. <br />
Reboot if a kernel upgrade has occurred.<br />
<br />
=====Get familiar with pacman=====<br />
Pacman is the Arch user's best friend. It is highly recommended to study and learn how to use the pacman tool. Try:<br />
man pacman<br />
Check out the bottom of this article, and look up the [[pacman]] wiki entries at your leisure.<br />
<br />
<br />
<br />
===Add a user and setup groups===<br />
You should not do your everyday work using the root account. It is more than poor practice; it is dangerous. Root is for administrative tasks. Instead, add a normal user account using:<br />
adduser<br />
While most default options are safe to use, you may want to add storage, audio, video, optical, and wheel to your additional groups- especially if you are planning on having a full-featured desktop environment. <br />
<br />
Groups and users thereof are defined in /etc/group. <br />
<br />
They include:<br />
<br />
*'''audio''' - for tasks involving sound card and related software<br />
<br />
*'''wheel''' - for using sudo<br />
<br />
*'''storage''' - for managing storage devices<br />
<br />
*'''video''' - for video tasks and 3d acceleration<br />
<br />
*'''optical''' - for managing tasks pertaining to the optical drive(s)<br />
<br />
*'''floppy''' - for access to a floppy if applicable<br />
<br />
*'''lp''' - for managing printing tasks<br />
<br />
See the [[Groups]] article to understand what groups you need to be a member of. <br />
<br />
Check the man pages for usermod and gpasswd for more information.<br />
=====Install and setup Sudo=====<br />
<br />
See [[Sudo]]<br />
<br />
==Part II: Install X and configure ALSA==<br />
<br />
<br />
===Configure the audio card with alsamixer===<br />
The Advanced Linux Sound Architecture (known by the acronym '''ALSA''') is a Linux kernel component intended to replace the original Open Sound System (OSS) for providing device drivers for sound cards. Besides the sound device drivers, '''ALSA''' also bundles a user space library for application developers who want to use driver features with a higher level API than direct interaction with the kernel drivers. <br />
-----<br />
{{Box Note|udev will automatically probe your hardware on boot-up, loading the corresponding module for your audio card. Your sound should already be working, but you can't hear anything because it is muted by default.}} <br />
The alsa-utils package contains alsamixer, which will allow us to configure the sound device from the console. (You may also run alsamixer from an '''X''' environment later.)<br />
<br />
Install the alsa-utils package:<br />
pacman -S alsa-utils<br />
Did you add your normal user to the audio group? If not, now would be a good time. As root do:<br />
gpasswd -a yourusername audio<br />
Log your normal user out and back in to ensure the audio group is loaded.<br />
<br />
As '''''normal, non-root''''' user, do: <br />
'''$''' alsamixer<br />
Unmute the Master and PCM channels by scrolling to them with cursor left/right and pressing '''M'''. Increase the volume levels with the cursor-up key. (70-90 Should be a safe range.) Leave alsamixer by pressing ESC. <br />
==== Sound Test ====<br />
Test your sound configuration as normal user using aplay:<br />
aplay /usr/share/sounds/alsa/Front_Center.wav<br />
You should hear a very eloquent woman say, "Front, center."<br />
<br />
Then run alsactl as root:<br />
alsactl store<br />
This will create '/etc/asound.state', saving the alsamixer settings. <br />
<br />
Also, add the alsa ''daemon'' to your DAEMONS section in /etc/rc.conf to automatically restore the mixer settings on boot-up.<br />
nano /etc/rc.conf<br />
DAEMONS=(syslog-ng network crond '''alsa''')<br />
''Note that the alsa daemon merely restores your volume mixer levels on boot up by reading /etc/asound.state. It is separate from the alsa audio library (and kernel level API).''<br />
<br />
Expanded information available in the [[ALSA]] wiki entry.<br />
<br />
===Installing and configuring X===<br />
The '''X''' Window System (commonly '''X11''', or just simply '''X''') is a networking and display protocol which provides windowing on bitmap displays. It provides the standard toolkit and protocol to build graphical user interfaces (GUIs) on <code>UNIX</code>-like operating systems.<br />
<br />
'''X''' provides the basic framework, or primitives, for building GUI environments: drawing and moving windows on the screen and interacting with a mouse and/or keyboard. '''X''' does not mandate the user interface — individual client programs handle this. <br />
<br />
'''X''' is so named because it was preceded by the '''W''' Window System, originally developed at Stanford University. <br />
-----<br />
<br />
{{Box Note| If you plan on using an '''open-source''' video driver, and need 3d acceleration, it is recommended to install the libgl library before installing Xorg:}}<br />
pacman -S libgl<br />
''(Proprietary video drivers provide their own gl library implementations.)''<br />
----- <br />
Now we will install the base Xorg packages using pacman. This is the first step in building a GUI.<br />
<br />
pacman -S xorg<br />
3d utilities such as glxgears are included in the '''mesa''' package:<br />
pacman -S mesa<br />
<br />
Now we have the base packages we need for running the '''X''' Server. You should add the driver for your graphics card now (e.g. xf86-video-<name>). The easiest way to configure X.org is by installing the correct driver packages first, and then generating /etc/X11/xorg.conf using an autoconfiguration script, like Xorg -configure.<br />
<br />
If you need a list of all '''open-source''' video drivers, do: <br />
pacman -Ss xf86-video | less<br />
You will need knowledge of which video chipset your machine has. If you don't know, do:<br />
lspci | grep VGA<br />
Here is a list of '''open source''' drivers, and corresponding video chipsets.<br />
*'''xf86-video-apm''' Alliance ProMotion video driver<br />
*'''xf86-video-ark''' ark video driver<br />
*'''xf86-video-ati''' ati video driver<br />
*'''xf86-video-chips''' Chips and Technologies video driver<br />
*'''xf86-video-cirrus''' Cirrus Logic video driver<br />
*'''xf86-video-dummy''' dummy video driver<br />
*'''xf86-video-fbdev''' framebuffer video driver<br />
*'''xf86-video-glint''' GLINT/Permedia video driver<br />
*'''xf86-video-i128''' Number 0 i128 video driver<br />
*'''xf86-video-i740''' Intel i740 video driver<br />
*'''xf86-video-i810''' Intel i810/i830/i9xx video drivers (deprecated - use -intel)<br />
*'''xf86-video-intel''' Newer Version of Intel i810/i830/i9xx video drivers<br />
*'''xf86-video-imstt''' Integrated Micro Solutions Twin Turbo vidoe driver<br />
*'''xf86-video-mga''' mga video driver (Matrox Graphics Adapter)<br />
*'''xf86-video-neomagic''' neomagic video driver<br />
*'''xf86-video-nv''' nvidia nv video driver<br />
*'''xf86-video-rendition''' Rendition video driver<br />
*'''xf86-video-s3''' S3 video driver<br />
*'''xf86-video-s3virge''' S3 Virge video driver<br />
*'''xf86-video-savage''' savage video driver<br />
*'''xf86-video-siliconmotion''' siliconmotion video driver<br />
*'''xf86-video-sis''' SiS video driver<br />
*'''xf86-video-sisusb''' SiS USB video driver<br />
*'''xf86-video-tdfx''' tdfx video driver<br />
*'''xf86-video-trident''' Trident video driver<br />
*'''xf86-video-tseng''' tseng video driver<br />
*'''xf86-video-unichrome''' Unichrome video drivers<br />
*'''xf86-video-v4l''' v4l video driver<br />
*'''xf86-video-vesa''' vesa video driver<br />
*'''xf86-video-vga''' VGA 16 color video driver<br />
*'''xf86-video-via''' via video driver<br />
*'''xf86-video-vmware ''' vmware video driver<br />
*'''xf86-video-voodoo ''' voodoo video driver<br />
<br />
* Note that the '''vesa''' driver is the most generic, and should work with almost any modern video chipset. If you cannot find a suitable driver for your video chipset, vesa '''should''' work.<br />
<br />
*If you have an NVIDIA or ATI video adapter, you may wish to install the proprietary NVIDIA or ATI drivers. '''Installing proprietary video drivers is covered [[#Using proprietary Graphics Driver (NVIDIA, ATI)|below]].'''<br />
<br />
Use pacman to install the appropriate video driver for your video card/onboard video. e.g.:<br />
pacman -S xf86-video-savage<br />
(for the Savage driver.)<br />
<br />
==Create /etc/X11/xorg.conf==<br />
=====What is /etc/X11/xorg.conf?=====<br />
/etc/X11/xorg.conf is the main configuration file for your '''X''' Window System, the foundation of your '''G'''raphical '''U'''ser '''I'''nterface. It is a plain text file ordered into sections and subsections. Important sections are ''Files, InputDevice, Module, Monitor, Modes, Screen, Device, and ServerLayout''. Sections can appear in any order and there may be more than one section of each kind, for example, if you have more than one monitor, or if your laptop has a trackpoint as well as a mouse. <br />
------<br />
By default, you will not have an Xorg config file, and with the newest versions of Xorg, you don't need one ''if'' the autodetection ''works satisfactorily'' and you don't need to turn on features such as aiglx and so on. <br />
<br />
''Most people will still find that they need to generate a config file, however.''<br />
<br />
<br />
Advanced users may wish to manually create their own xorg.conf file. You may also use the Xorg -configure script to make a basic config file. As root, do:<br />
Xorg -configure<br />
This will create a config file at /root/xorg.conf.new <br />
<br />
To test the server, run:<br />
X -config /root/xorg.conf.new<br />
'''X''' should start with the white hollow vector '''X''' in the center of the screen, which should respond to mouse, trackpoint or touchpad movement. Use CTRL-Alt-Backspace to exit '''X'''.<br />
<br />
Inspect your config file in case of errors:<br />
<br />
nano /root/xorg.conf.new<br />
<br />
Ensure the Xorg -configure script has correctly specified your video driver. e.g.:<br />
Section "Device"<br />
<br />
...<br />
<br />
Driver "savage"<br />
<br />
...<br />
<br />
EndSection<br />
<br />
Ensure there are horizontal sync and vertical refresh specs under section "Monitor". If not, add them:<br />
Section "Monitor"<br />
Identifier "Monitor0"<br />
VendorName "Monitor Vendor"<br />
ModelName "Monitor Model"<br />
HorizSync 30.0 - 130.0 # Safe for LCD's<br />
VertRefresh 50.0 - 100.0 # Safe for LCD's and most CRT's.<br />
EndSection<br />
(If you do not know these specs, consult your monitor's documentation.)<br />
<br />
Specify your default color depth under section "Screen":<br />
Section "Screen"<br />
Identifier "Screen0"<br />
Device "Card0"<br />
Monitor "Monitor0"<br />
DefaultDepth 24<br />
(Typically, this will be set to 24 for true color.)<br />
<br />
Also add your desired Modes to your "Display" subsection, at least under the Depth 24 header, e.g.:<br />
SubSection "Display"<br />
Viewport 0 0<br />
Depth 24<br />
Modes "1024x768" "800x600" "640x480"<br />
Add the following section, if you wish to enable eye candy which requires the composite extension: <br />
Section "Extensions"<br />
Option "Composite" "Enable"<br />
EndSection<br />
Try your config again, after modifying:<br />
X -config /root/xorg.conf.new<br />
Ensure an '''X''' session opens, without errors, and move the generated config file to /etc/X11/:<br />
mv /root/xorg.conf.new /etc/X11/xorg.conf<br />
Detailed instructions in the [[Xorg]] article.<br />
<br />
====Alternative xorg.conf generation====<br />
If Xorg -configure is not generating a usable xorg.conf, you may alternatively use the hwd tool. Install with:<br />
pacman -S hwd<br />
And run with<br />
hwd -xa <br />
Lastly, you may choose xorgconfig, which will interactively prompt you for hardware information to create a basic xorg.conf:<br />
xorgconfig<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
===Using proprietary Graphics Driver (NVIDIA, ATI)===<br />
You may choose to use the proprietary video drivers from NVIDIA or ATI. <br />
====NVIDIA Graphic Cards====<br />
The NVIDIA proprietary drivers are generally considered to be of good quality, and offer 3D performance, whereas the open source '''nv''' driver offers only 2d support at this time. <br />
<br />
Before you configure your Graphics Card you will need to know which driver fits. Arch currently has 3 different driver packages that each match a certain subset of Cards: <br />
<br />
'''1. nvidia-71xx''' ''for very old Cards like TNT and TNT2''<br />
<br />
'''2. nvidia-96xx''' ''slightly newer cards up to the GF 4''<br />
<br />
'''3. nvidia''' ''newest GPUs after the GF 4''<br />
<br />
Consult the NVIDIA-Homepage to see which one is for you. The difference is only for the installation; Configuration works the same with every driver.<br />
<br />
Select and install the appropriate NVIDIA driver ''for your card'', e.g.: <br />
pacman -S nvidia-96xx<br />
<br />
The NVIDIA package has a utility for updating your existing /etc/X11/xorg.conf for use with the NVIDIA driver:<br />
nvidia-xconfig<br />
<br />
It also has several options which will further specify the contents and options of the xorg.conf file.<br />
For example,<br />
nvidia-xconfig --composite --add-argb-glx-visuals<br />
<br />
For more detailed information, see nvidia-xconfig(1).<br />
<br />
Some useful tweaking options in the device section are (beware that these may not work on your system):<br />
Option "RenderAccel" "true"<br />
Option "NoLogo" "true"<br />
Option "AGPFastWrite" "true"<br />
Option "EnablePageFlip" "true"<br />
Make sure all instances of DRI are commented out:<br />
# Load "dri"<br />
Double check your /etc/X11/xorg.conf to make sure your default depth, horizontal sync, vertical refresh, and resolutions are acceptable.<br />
<br />
Update kernel module dependencies:<br />
depmod -a<br />
<br />
Advanced instructions for nvidia configuration can be found in the [[NVIDIA]] article.<br />
<br />
Continue with '''[[#Simple baseline X test|Simple baseline X test]]'''<br />
<br />
====ATI Graphic Cards====<br />
ATI owners have two options for drivers. If you are unsure which driver to use, please try the open-source one first. The open-source driver will suit most needs along with being generally less problematic.<br />
<br />
Install the '''proprietary''' ATI Driver with<br />
pacman -S catalyst<br />
Use the aticonfig tool to modify the xorg.conf.<br />
<br />
Install the '''open-source''' ATI Driver with<br />
pacman -S xf86-video-ati<br />
Currently, the performance of the open-source driver is not on par with that of the proprietary one. It also lacks TV-out, dual-link DVI support, and possibly other features. On the other hand, it supports Aiglx and has better dual-head support.<br />
{{Box Note| The latest proprietary driver does support [[AIGLX]] now. To use [[Compiz]] or [[Beryl]] add Option "AIGLX" "True" to Section ServerFlags and Option "Composite" "True" to Section Extensions.}}<br />
Advanced instructions for ATI configuration can be found in the [[ATI | ATI wiki]].<br />
<br />
===Simple baseline X test===<br />
<br />
At this point, you should have xorg installed, with a suitable video driver and an /etc/X11/xorg.conf configuration file. If you want to test your configuration quickly, to ensure your ability to start '''X''' from the command line before installing a complete desktop environment, you can do so by invoking '''xterm'''. Xterm is a very simple terminal emulator which runs in the '''X '''Server environment; it is installed as part of the base xorg packages.<br />
<br />
Prepare for the test by configuring a ~/.xinitrc:<br />
<br />
===== ~/.xinitrc =====<br />
This file dictates what '''X''' Window client is invoked with the '''startx''' and/or '''xinit''' command ''on a per-user basis''. (The '''startx''' script is merely a front end to the more versatile '''xinit''' command.) <br />
<br />
To determine the client to run, '''startx/xinit''' will first look for a .xinitrc file in the user's home directory. In the absence of file ~/.xinitrc, it defaults to the global xinitrc in the xinit library directory; /etc/X11/xinit/xinitrc, which defaults to using the TWM window manager. (Hence, if you invoke startx without a ~/.xinitrc file, a TWM session will start.)<br />
<br />
Switch to your '''''normal, non-root''''' user:<br />
su yourusername<br />
* /etc/skel/ contains files and directories to provide sane defaults for newly created user accounts. The name '''skel''' is derived from the word '''skeleton''', because the files it contains form the basic structure for users' home directories.<br />
Copy the sample xinitrc file from /etc/skel/ to your home directory: <br />
<br />
cp /etc/skel/.xinitrc ~/<br />
Edit the file: <br />
nano ~/.xinitrc<br />
and add:<br />
<br />
exec xterm<br />
<br />
So that it looks like this:<br />
<br />
#!/bin/sh<br />
#<br />
# ~/.xinitrc<br />
#<br />
# Executed by startx (run your window manager from here)<br />
#<br />
exec xterm<br />
# exec wmaker<br />
# exec startkde<br />
# exec icewm<br />
# exec blackbox<br />
# exec fluxbox<br />
<br />
''Be sure to have only one uncommented '''exec''' line in your ~/.xinitrc at this time''. Below, we shall edit this file again to specify the appropriate desktop environment/window manager of your choice.<br />
<br />
Start '''X''' Server as '''normal, non-root''' user, with:<br />
<br />
startx<br />
or<br />
xinit<br />
You should have an '''xterm''' session open up. You can exit the '''X''' Server with Ctrl+Alt+Backspace, or by typing "exit". If you have problems starting '''X''', you can look for errors in the /var/log/Xorg.0.log file and on the console output of the console you started '''X''' from.<br />
<br />
If you prove a properly configured /etc/X11/xorg.conf by successfully running the test, you can be assured that your DE/WM of choice will work smoothly.<br />
<br />
Advanced instructions for Xorg configuration can be found in the [[Xorg]] article.<br />
<br />
==Part III: Installing and configuring a Desktop Environment ==<br />
While The '''X''' Window System provides the basic framework for building a ''graphical user interface'' (GUI), a '''Desktop Environment''' (DE), works atop and in conjunction with '''X''', to provide a completely functional and dynamic GUI. A DE typically provides icons, applets, windows, toolbars, folders, wallpapers, applications and abilities like drag and drop. The particular functionalities and designs of each DE will uniquely affect your overall environment and experience. Therefore, choosing a DE is a very subjective and personal decision. Choose the best environment for ''your'' needs.<br />
<br />
* If you want something full-featured and similar to Windows and Mac OSX, '''[[#KDE|KDE]]''' is a good choice<br />
* If you want something slightly more minimalist, which follows the K.I.S.S. principle more closely, '''[[#GNOME|GNOME]]''' is a good choice<br />
* '''[[#Xfce|Xfce]]''' is generally perceived as similar to GNOME, but lighter and less demanding on system resources, yet still visually pleasing and providing a very complete environment.<br />
<br />
If you have an older machine, or desire a lighter, less demanding GUI, you may choose to simply install a '''Window Manager''', or WM. A WM controls the placement and appearance of application windows in conjunction with the X Window System but does NOT provide such additions as panels, applets, icons, applications, etc.<br />
* Lightweight WM's include: '''Openbox, Fluxbox, fvwm2''', '''Windowmaker, Awesome and TWM'''.<br />
* If you need something completely different, try '''ion, wmii, dwm, or xmonad'''.<br />
<br />
===Install Fonts===<br />
At this point, you may want to install some good-looking fonts, '''before''' installing a desktop environment/window manager, (so you don't have to stare at ugly bitmap fonts in X). Dejavu and bitstream-vera are nice font sets. For websites, you may want to have the Microsoft fonts too. Install with:<br />
pacman -S ttf-ms-fonts ttf-dejavu ttf-bitstream-vera<br />
<br />
===~/.xinitrc (again)===<br />
<br />
As '''non-root user''', edit your /home/username/.xinitrc to utilize the DE you wish to use. This will allow you to use '''startx/xinit''' from the shell to open your DE/WM of choice:<br />
<br />
nano ~/.xinitrc<br />
<br />
Uncomment or add the ''''exec''' ..' line of the appropriate desktop environment/window manager. Some examples are below.<br />
<br />
For the Xfce4 desktop environment:<br />
exec startxfce4 <br />
<br />
For the KDE desktop environment:<br />
exec startkde<br />
A '''startkde''' or '''startxfce4''' command starts the KDE or Xfce4 desktop environment. This command does not finish until you logout of the DE. Normally the shell would wait for KDE to finish, then run the next command. The "exec" prefix to this command tells the shell that this is the last command, so the shell does not need to wait to run a subsequent command.<br />
<br />
Remember to have only one uncommented '''exec''' line in your ~/.xinitrc for now. <br />
<br />
Continue below, installing the DE/WM of your choice.<br />
<br />
===GNOME===<br />
====About GNOME====<br />
The '''G'''NU '''N'''etwork '''O'''bject '''M'''odel '''E'''nvironment. The GNOME project provides two things: The GNOME desktop environment, an intuitive and attractive desktop for end-users, and the GNOME development platform, an extensive framework for building applications that integrate into the rest of the desktop.<br />
<br />
====Installation====<br />
Install the GNOME environment with:<br />
pacman -S gnome<br />
<br />
You can also optionally install gnome-extra with:<br />
pacman -S gnome-extra<br />
<br />
It's safe to choose all packages shown in the extra package. <br />
<br />
=====Useful DAEMONS for GNOME=====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The '''hal''' daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The '''fam''' daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. Both '''hal''' and '''fam''' make life easier for the GNOME user. The hal and fam packages are installed when you install GNOME, but must be invoked to become useful.<br />
<br />
You may want to install a graphical login manager. For GNOME, the '''gdm''' daemon is a good choice. <br />
<br />
As root:<br />
pacman -S gdm<br />
You will almost certainly want the '''hal''' and '''fam''' daemons.<br />
<br />
Start hal and fam:<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
<br />
Add them to your /etc/rc.conf DAEMONS section, so they will be invoked on bootup:<br />
nano /etc/rc.conf<br />
<br />
DAEMONS=(syslog-ng network crond alsa '''hal fam gdm''')<br />
(If you prefer to log into the console and manually start X in the 'Slackware tradition', leave out gdm.)<br />
<br />
<br />
As normal user, start X:<br />
startx<br />
If ~/.xinitrc is not configured for GNOME, you may always start it with '''xinit''':<br />
xinit /usr/bin/gnome-session<br />
You may want to install a terminal and an editor. I would recommend gnome-terminal (part of the group gnome-extra) and geany:<br />
pacman -S geany gnome-terminal<br />
<br />
Advanced instructions for installing and configuring GNOME can be found in the [[Gnome]] article.<br />
<br />
Congratulations! Welcome to your GNOME desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
====Eye Candy====<br />
You may find the default GNOME theme and icons not very attractive. A nice gtk theme is murrine. Install it with<br />
pacman -S gtk-engine-murrine<br />
and select it with System->Preferences->Theme. You can find more themes, icons, and wallpaper at [http://www.gnome-look.org Gnome Look].<br />
<br />
===KDE===<br />
====О KDE====<br />
'''K''' '''D'''esktop '''E'''nvironment. KDE - это мощное свободное окружение рабочего стола для рабочих станций GNU/Linux и <code>UNIX</code>. KDE сочетает лёгкость в использовании, современную функциональность и выдающийся графический дизайн с технологическим превосходством UNIX-подобных операционных систем.<br />
<br />
====Установка====<br />
Arch предлагает несколько вариантов kde: '''kde, kdebase, и KDEmod'''. Выберите '''один''' из представленных ниже, и продолжите дальше с '''[[#Useful KDE DAEMONS|Useful KDE DAEMONS]]''': <br />
<br />
'''1.)''' Пакет '''kde''' это полный, стандартнй KDE, ~300MB.<br />
pacman -S kde<br />
'''2.)''' Пакет '''kdebase''' это урезанная версия с меньшим количеством приложений, ~80MB.<br />
pacman -S kdebase<br />
'''3.)''' Наконец, '''KDEmod''' - это эксклюзив для Arch Linux, созданный по инициативе сообщества, которое модифицировало KDE для максимальной производительности и модульности. Веб-сайт проекта KDEmod может быть найден на [http://kdemod.ath.cx/ http://kdemod.ath.cx/]. KDEmod очень быстрый, легкий и гибкий, с приятной, собственной темой оформления<br />
<br />
====Useful KDE DAEMONS====<br />
<br />
KDE will require the '''hal''' ('''H'''ardware '''A'''bstraction '''L'''ayer) and '''fam''' ('''F'''ile '''A'''lteration '''M'''onitor) daemons. The '''kdm''' daemon is the '''K''' '''D'''isplay '''M'''anager, which provides a '''graphical login''', if desired.<br />
<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system.. Both '''hal''' and '''fam''' make life easier for the KDE user. The hal, fam and kdm packages are installed when you install KDE, but must be invoked to become useful.<br />
-----<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup. If you prefer a graphical login, add '''kdm''' as well: <br />
DAEMONS=(syslog-ng network crond alsa '''hal fam kdm''')<br />
*This method will start the system at runlevel 3, (/etc/inittab default, multiuser mode), and then start KDM as a daemon. <br />
<br />
*Some users prefer an alternative method of starting a display manager like KDM on bootup by utilizing the /etc/inittab method and starting the system at runlevel 5. See [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]] for more.<br />
<br />
*If you prefer to log into the '''console''' at runlevel 3, and manually start X in the 'Slackware tradition', leave out kdm, or comment it out with an exclamation. ( ! )<br />
<br />
Now try starting your X Server as normal user:<br />
startx<br />
Advanced instructions for installing and configuring KDE can be found in the [[KDE]] article.<br />
<br />
Congratulations! Welcome to your KDE desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===Xfce===<br />
====About Xfce====<br />
The cholesterol-free '''X''' environment. Xfce, like GNOME or KDE, is a desktop environment, but aims to be fast and lightweight while remaining visually appealing and easy to use. It contains a suite of apps like a root window app, window manager, file manager, panel, etc. Xfce is written using the GTK2 toolkit (like GNOME) and contains its own development environment (libraries, daemons, etc) similar to other big DEs. Unlike GNOME or KDE, Xfce is lightweight and designed more around CDE than Windows or Mac. It has a much slower development cycle, but is very stable and extremely fast. Xfce is great for older hardware, and will fly with especially great speed on newer machines as well.<br />
<br />
====Installation====<br />
Install Xfce: <br />
pacman -S xfce4 <br />
You may also wish to install themes and extras:<br />
pacman -S xfce4-goodies gtk2-themes-collection<br />
If you want to admire 'Tips and Tricks' on login, you must install the '''fortune-mod''' package:<br />
pacman -S fortune-mod <br />
====Useful DAEMONS====<br />
Recall from above that a daemon is a program that runs in the background, waiting for events to occur and offering services. The hal daemon, among other things, will automate the mounting of disks, optical drives, and USB drives/thumbdrives for use in the GUI. The fam daemon will allow real-time representation of file alterations in the GUI, allowing instant access to recently installed programs, or changes in the file system. The hal and fam packages are installed when you install Xfce, but must be invoked to become useful.<br />
<br />
Start hal and fam:<br />
<br />
/etc/rc.d/hal start<br />
<br />
/etc/rc.d/fam start<br />
{{Box Note|The hal daemon relies on, and will automatically start, the dbus daemon.}}<br />
Edit your DAEMONS section in /etc/rc.conf:<br />
nano /etc/rc.conf<br />
Add '''hal''' and '''fam''' to your DAEMONS section, to invoke them on bootup.<br />
<br />
Advanced instructions for installing and configuring Xfce can be found in the [[Xfce]] article.<br />
<br />
If you wish to install one, see [[Adding a login manager (KDM, GDM, or XDM) to automatically boot on startup]]<br />
<br />
Congratulations! Welcome to your Xfce desktop environment on your new Arch Linux system! You may wish to continue by viewing '''[[#Tweaks/Finishing touches|Tweaks and finishing touches]]''', or the rest of the information below. You may also be interested in the [[Post Installation Tips]] wiki article.<br />
<br />
===*box===<br />
====Fluxbox====<br />
Fluxbox © is yet another windowmanager for X.<br />
It's based on the Blackbox 0.61.1 code. Fluxbox looks like blackbox and handles styles, colors, window placement and similar things exactly like blackbox (100% theme/style compability).<br />
<br />
Install Fluxbox using <br />
pacman -S fluxbox fluxconf<br />
<br />
If you use gdm/kdm a new fluxbox session will be automatically added. Otherwise, you should modify your user's .xinitrc and add this to it:<br />
exec startfluxbox <br />
<br />
More information is available in the [[Fluxbox]] article.<br />
<br />
====Openbox====<br />
Openbox is a standards compliant, fast, light-weight, extensible window manager.<br />
<br />
Openbox works with your applications, and makes your desktop easier to manage. This is because the approach to its development was the opposite of what seems to be the general case for window managers. Openbox was written first to comply with standards and to work properly. Only when that was in place did the team turn to the visual interface.<br />
<br />
Openbox is fully functional as a stand-alone working environment, or can be used as a drop-in replacement for the default window manager in the GNOME or KDE desktop environments. <br />
<br />
Install openbox using<br />
pacman -S openbox obconf obmenu<br />
<br />
Once openbox is installed you will get a message to move menu.xml & rc.xml to ~/.config/openbox/ in your home directory:<br />
<br />
mkdir -p ~/.config/openbox/<br />
cp /etc/xdg/openbox/rc.xml ~/.config/openbox/<br />
cp /etc/xdg/openbox/menu.xml ~/.config/openbox/<br />
<br />
In the file "rc.xml" you can change various settings for Openbox (or you can use OBconf). In "menu.xml" you can change your right-click menu.<br />
<br />
To be able to log into openbox you can either go via graphical login using KDM/GDM or startx, in which case you will need to edit your ~/.xinitrc (as user) and add the following:<br />
<br />
exec openbox<br />
You may also start openbox from the shell using '''xinit''':<br />
xinit /usr/bin/openbox-session<br />
* Openbox may also be used as the window manager for GNOME, KDE, and Xfce.<br />
For KDM there is nothing left to do; openbox is listed in the sessions menu in KDM.<br />
<br />
Useful programs for openbox are:<br />
* PyPanel or LXpanel if you want a panel<br />
* feh if you want to set the background<br />
* ROX if you want a simple file manager and desktop icons<br />
<br />
More information is available in the [[Openbox]] article.<br />
<br />
===fvwm2===<br />
FVWM is an extremely powerful ICCCM-compliant multiple virtual desktop window manager for the X Window system. Development is active, and support is excellent. <br />
<br />
Install fvwm2 with<br />
pacman -S fvwm <br />
<br />
fvwm will automatically be listed in kdm/gdm in the sessions menu. Otherwise, add <br />
exec fvwm <br />
<br />
to your user's .xinitrc.<br />
<br />
Note that this stable version of fvwm is a few years old. If you want a more recent version of fvwm, there is a fvwm-devel package in the unstable repo.<br />
<br />
=APPENDIX=<br />
==Tweaks/Finishing touches==<br />
===Install [http://archlinux.fr/yaourt-en# Yaourt]===<br />
'''Y'''et '''A'''n'''O'''ther '''U'''ser '''R'''epository '''T'''ool. Yaourt is a community-contributed wrapper for pacman which adds seamless access to the [[AUR]], allowing and automating package compilation and installation from your choice of the 8000+ PKGBUILDs in the [[AUR]], in addition to the many thousands of available Arch binary packages. Yaourt uses the same exact syntax as pacman, which saves you from relearning an entirely new method of system maintenance, but also adds new options. Yaourt expands the power and simplicity of pacman by adding even more useful features and provides pleasing, colorized output, interactive search mode, and much more. You will almost certainly want this. <br />
<br />
The easiest way to install Yaourt is to add the yaourt repository to your /etc/pacman.conf:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/i686<br />
for i686 or:<br />
[archlinuxfr]<br />
Server = http://repo.archlinux.fr/x86_64<br />
for x86-64.<br />
<br />
Sync and install:<br />
pacman -Sy yaourt<br />
<br />
If you wish, you may then create your own command aliases in ~/.bashrc to save typing: <br />
nano ~/.bashrc<br />
<br />
alias p="pacman"<br />
alias y="yaourt" <br />
Save and then source:<br />
source ~/.bashrc<br />
See the [http://archlinux.fr/yaourt-en# yaourt] man page for more.<br />
<br />
===HAL===<br />
Since you have now installed a desktop environment, and if you did not do so earlier, now would be a good time to also install HAL. HAL allows plug-and-play for your mobile phone, your iPod, your external HD's, etc. It will mount the device and make a nice visual icon on your desktop and/or in 'My Computer', allowing you to access the device after you have plugged it in instead of having to manually configure the /etc/fstab file or udev rules for each and every new device.<br />
<br />
KDE, GNOME and XFCE all use HAL.<br />
<br />
The installation procedure is described in the [[HAL]] article. Some information can also be found at [http://en.wikipedia.org/wiki/HAL_(software) Wikipedia].<br />
<br />
===Backgrounding DAEMONS on startup===<br />
<br />
To speed up system start up procedure, background selected DAEMONS in /etc/rc.conf by prefixing them with a '@' e.g.:<br />
<br />
DAEMONS=(syslog-ng @network crond @alsa @hal @fam @kdm)<br />
This will enable daemons to load in the background, without waiting for the preceding daemon to load first.<br />
<br />
Prefix any daemons which you do not need with a bang (!) e.g.:<br />
<br />
DAEMONS=(syslog-ng @network !netfs !crond @alsa @hal @fam @kdm)<br />
<br />
Alternatively, you may also simply remove unneeded daemons.<br />
<br />
===Beautifying Fonts for LCD's===<br />
See [[Fonts]]<br />
<br />
===Adjusting Mouse for scroll wheel===<br />
While your mouse should be working out of the box, you may want to use your scroll wheel. Add this to your Input Section (mouse0):<br />
Option "ZAxisMapping" "4 5 6 7"<br />
<br />
===Get All Mouse Buttons Working===<br />
See [[Get All Mouse Buttons Working]]<br />
<br />
===Configuring Touchpad for Laptops===<br />
See [[Touchpad Synaptics]]<br />
<br />
===Adjusting Keyboard Layout===<br />
You may want to change your keyboard layout. To do this edit your /etc/X11/xorg.conf and add these lines in the InputDevice Section (Keyboard0) (the example shows a German keyboard layout with no dead keys; alter this to fit your needs).<br />
Option "XkbLayout" "de"<br />
Option "XkbVariant" "nodeadkeys"<br />
<br />
===Additional tweaks for laptops===<br />
ACPI support is needed if you want to use some special functions on your notebook (e.g. sleep, sleep when lid is closed, special keys...). Install <tt>acpid</tt> using<br />
pacman -S acpid<br />
and add it to the daemons in /etc/rc.conf. <tt>acpid</tt> should be started before <tt>hal</tt> and <tt>dbus</tt>, so take care to place it before any calls to hal and dbus. Manually, it can be started by<br />
/etc/rc.d/acpid start<br />
<br />
More-specific information about Arch Linux on various Laptops can be found at [[:Category:Laptops (English)]]<br />
<br />
===Configuring CPU frequency scaling===<br />
Modern processors can decrease their frequency and voltage to reduce heat and power consumption. Less heat leads to a quieter system; Laptop users will definitely want this, but even a desktop system will benefit from it. Install cpufrequtils with<br />
pacman -S cpufrequtils<br />
Edit the config file /etc/conf.d/cpufreq and change <br />
governor="ondemand"<br />
which dynamically increases the CPU frequency if needed (which is a safe choice on desktop systems too). Alter min_freq and max_freq to match your system's CPU spec. If you don't know the frequencies, run ''cpufreq-info'' after loading one of the frequency scaling modules. You can also comment out or delete the min_freq and max_freq lines: things will work automatically. Add the frequency scaling modules to your /etc/rc.conf modules line. Most modern notebooks and desktops can simply use the ''acpi-cpufreq'' driver, however other options include the ''p4-clockmod, powernow-k6, powernow-k7, powernow-k8, and speedstep-centrino'' drivers. Load the module with<br />
modprobe <modulname> <br />
and start cpufreq with<br />
/etc/rc.d/cpufreq start<br />
For more details, see [[Cpufrequtils]]<br />
<br />
===Pm-Utils===<br />
The pm-utils package will allow you to suspend-to-RAM and hibernate: <br />
pacman -S pm-utils<br />
[[Pm-utils]] wiki page.<br />
<br />
===Laptop-Mode===<br />
The laptop-mode-tools package is sort of a one-stop configuration for all laptop power management utilities. It works in conjunction with other installed tools to fully configure everything from hard disk spin-down to X display DPMS standby times, if desired.<br />
pacman -S laptop-mode-tools<br />
Add laptop-mode to your DAEMONS= line in /etc/rc.conf and configure /etc/laptop-mode/laptop-mode.conf.<br />
<br />
==File and directory explanation==<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, (as dictated by BIOS) just like the sda, sdb, etc.<br />
names in /dev. The partitions of a disk are referred to with (hd0,0),<br />
(hd0,1) and so on, with 0 corresponding to the first entity. A few<br />
conversion examples are included in the default menu.lst to aid your<br />
understanding. <br />
<br />
{{ Box Note | The first appearance of 'root (hdx,x)' may be misleading. The '''root''' command is specifying '''''GRUB''''''s root, which corresponds to ''where the kernel resides, i.e. '''/boot'''''. Ensure that the drive and partition are correct, since '''''/boot''', does not necessarily share the same partition as the root filesystem, or /''.}}<br />
<br />
Once you have grasped the concept of device naming, choose a title for your boot section(s), create a kernel line that includes the partition and path to where the kernel resides, and supply the correct root filesystem device and partition as a parameter to the kernel root option to have it mounted as / on bootup, 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 to the initramfs on the initrd line will be the same as<br />
the path to vmlinuz26 that you provide on the kernel line, since both reside under /boot. You should<br />
be fine with the defaults, just check whether the partition<br />
information is correct in the root and kernel lines.<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 />
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 also globally defines PS1, $PATH, bash aliases, etc. It is kept quite simple under Arch Linux, as most things are. You may wish 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 runlevels. 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 mounting filesystems, running udev, activating swap, loading modules, setting localization parameters, etc. You will most likely never need 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 started in single-user mode, for example with the kernel parameter 1 before booting or during normal multi-user operation with the command init 1, this script makes sure no daemons are running except for the bare minimum; syslog-ng and udev. The single-user mode is useful if you need to make any changes to the system while making sure that no remote user can do anything that might cause data loss or damage. <br />
For desktop users, this mode is usually quite useless. You should most likely have no need to edit this script.<br />
<br />
<br />
'''/etc/rc.multi'''<br />
<br />
Multi-user startup script. It starts all daemons you configured in the DAEMONS array (set in /etc/rc.conf) after which it calls /etc/rc.local. You shouldn't feel a pressing need to edit this file. <br />
<br />
'''/etc/rc.local'''<br />
<br />
Local multi-user startup script. It is a good place to put any last-minute commands you want the system to run at the very end of the bootup process. This is finally the one and only script you should modify if needed, and you have total freedom on what to add to this script. Most common system configuration tasks, like loading modules, changing<br />
the console font or setting up devices, usually have a dedicated place where they belong. To avoid confusion, you should make sure that whatever you intend to add to your rc.local isn't feeling just as home in /etc/profile.d/ or any other already existant config location instead.<br />
<br />
<br />
'''/etc/rc.shutdown'''<br />
<br />
System shutdown script. It stops daemons, unmounts filesystems, deactivates the swap, etc. <br />
<br />
<br />
'''/etc/rc.local.shutdown'''<br />
<br />
Analogous to the /etc/rc.local file, this file may contain any commands you want to run right before the common rc.shutdown is executed. Please note that this file does not exist by default, and 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 rc.conf's DAEMONS= array. In addition to being called on bootup, you can use these scripts when the system is running to manage the services of your system. For example the command<br />
/etc/rc.d/postfix stop<br />
<br />
will stop the postfix daemon. This directory is not in the $PATH by default, but may be added for convenience. Obviously a corresponding daemon script only exists when the appropriate package has been installed (in this case postfix). With a base system install, you don't have many scripts in here, but rest assured that all relevant daemon scripts end up here. If you wish, you can, of course, create your own scripts and place them here, to be called by the DAEMONS= array in /etc/rc.conf on system startup. <br />
<br />
This directory is pretty much the equivalent to the /etc/rc3.d/ or /etc/init.d/ directories of other distributions, but without all the symlink hassle. The lack of symlink requirement is a defining difference of a *BSD-style init framework, vs a sysvinit.<br />
<br />
==Useful Applications==<br />
This section will never be complete. It just shows some good applications for the everyday user. <br />
<br />
'''KDE users NOTE''': Since KDE resides in /opt, you will most likely have to log out and in after initial installation to update your PATH before these programs can be used.<br />
===Internet===<br />
<br />
=====Firefox=====<br />
The ever-popular Firefox web browser is available through pacman, although it doesnt have its official branding, so the program appears when opened as Bon Echo. Install with:<br />
<br />
pacman -S firefox<br />
Be sure and install 'flashplugin', 'mplayer', 'mplayer-plugin', and the 'codecs' packages for a complete web experience:<br />
pacman -S flashplugin mplayer mplayer-plugin codecs<br />
(The codecs package contains codecs for Quicktime and Realplayer content.)<br />
<br />
Thunderbird is useful for managing your emails. If you are using GNOME you may want to take a look at Epiphany and Evolution; if you are using KDE Konqueror and KMail could be your choice. If you want something completely different you can still use Opera. Finally, if you are working on the system console - or in a terminal session - you could use various text-based browsers like ELinks, Links and Lynx, and manage your emails with [[Mutt]]. Pidgin (previously known as Gaim) and Kopete are good instant messengers for GNOME and KDE, respectively. PSI and Gajim are perfect if you are using only Jabber or Google Talk.<br />
<br />
===Office===<br />
OpenOffice is a complete office suite (similar to Microsoft Office). Abiword is a good, small alternative word processor, and Gnumeric an Excel replacement for the GNOME desktop. KOffice is a complete office suite for the KDE Desktop. GIMP (or GIMPShop) is a pixel-based graphics program (similar to Adobe Photoshop), while Inkscape is a vector-based graphics program (like Adobe Illustrator). And, of course, Arch comes with a full set of LaTeX Programs: tetex has been popular for many years and still works, and its successor [[Texlive]] is available from the [[AUR]] repository.<br />
<br />
==Multimedia ==<br />
<br />
<br />
===Video Player===<br />
====VLC====<br />
VLC Player is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S vlc<br />
<br />
(TODO) Instructions for VLC mozilla plug-in<br />
<br />
====Mplayer====<br />
MPlayer is a multimedia player for Linux. To install it, simply type the code below.<br />
<br />
pacman -S mplayer<br />
<br />
It also has a Mozilla plug-in for videos and streams embedded in web pages. To install it, simply type the code below.<br />
<br />
pacman -S mplayer-plugin<br />
<br />
If you use KDE, KMplayer is a better choice. It comes with a plug-in for videos and streams embedded in web pages, which works with Konqueror. To install it, simply type the code below.<br />
<br />
pacman -S kmplayer<br />
<br />
(TODO) GMPlayer instructions<br />
<br />
====Xine====<br />
<br />
Xine is an excellent player, especially for DVDs.<br />
<br />
pacman -S xine-ui<br />
The libdvdcss library provides DVD decoding for encrypted DVDs. ''Ensure the legality of using libdvdcss in your country before installing!''<br />
pacman -S libdvdcss<br />
<br />
====GNOME====<br />
=====Totem=====<br />
[http://www.gnome.org/projects/totem/ Totem] is the official movie player of the GNOME desktop environment based on xine-lib or GStreamer (gstreamer is the default which installs with the arch totem package). It features a playlist, a full-screen mode, seek and volume controls, as well as keyboard navigation.<br />
It comes with added functionality such as:<br />
<br />
* Video thumbnailer for the file manager<br />
* Nautilus properties tab<br />
* Epiphany / Mozilla (Firefox) plugin to view movies inside your browser <br />
* Webcam utility (in development)<br />
<br />
Totem-xine is still the better choice if you want to watch DVDs.<br />
<br />
Totem is part of the gnome-extra group; the Totem webbrowser plugin isn't.<br />
<br />
To install separately:<br />
pacman -S totem<br />
<br />
To install the Totem webbrowser plugin:<br />
pacman -S totem-plugin<br />
<br />
====KDE====<br />
=====Kaffeine=====<br />
Kaffeine is a good option for KDE users. To install it, simply type the code below.<br />
<br />
pacman -S kaffeine<br />
<br />
===Audio Player===<br />
====Gnome/Xfce====<br />
=====Exaile=====<br />
[[Exaile]] is a music player written in Python that makes use of the GTK+ toolkit. It tries to be close to the popular Amarok, but in GTK. It is in [community], so install with:<br />
pacman -S exaile<br />
<br />
=====Rhythmbox=====<br />
[http://www.gnome.org/projects/rhythmbox/ Rhythmbox] is an integrated music management application, originally inspired by Apple's iTunes. It is free software, designed to work well under the GNOME Desktop, and based on the powerful GStreamer media framework.<br />
<br />
Rhythmbox has a number of features, including:<br />
<br />
* Easy-to-use music browser<br />
* Searching and sorting<br />
* Comprehensive audio format support through GStreamer<br />
* Internet radio support<br />
* Playlists<br />
<br />
To install rhythmbox:<br />
pacman -S rhythmbox<br />
<br />
=====Quod Libet=====<br />
[http://www.sacredchao.net/quodlibet Quod Libet] is a music manager that uses the GStreamer media framework to play audio files. This allows it to play all the file-types that Rhythmbox (which uses GStreamer too) can play. Quod Libet is more suited to non-Gnome desktops since it has a smaller footprint and fewer dependencies than Rhythmbox (Rhythmbox depends on nautilus, which requires a lot of GNOME to be installed).<br />
<br />
In addition to the music player/manager, Quod Libet also includes Ex Falso, a tag editor.<br />
<br />
Quod Libet's features include:<br />
<br />
* Easy-to-use music browser<br />
* Searching<br />
* Comprehensive audio format support through GStreamer<br />
* Easy Playlist management<br />
<br />
To install Quod Libet:<br />
pacman -S quodlibet<br />
<br />
Other good audio players are Banshee and Listen. See [http://gnomefiles.org/ Gnomefiles] to compare them.<br />
<br />
====KDE====<br />
=====Amarok=====<br />
[http://amarok.kde.org/ Amarok] is one of the best audio players and music library systems available for KDE. To install it, simply type the code below.<br />
<br />
pacman -S amarok-base<br />
<br />
====Console====<br />
[http://moc.daper.net/ Moc] is a ncurses-based audio player for the console; another good choice is [http://musicpd.org/ mpd].<br />
<br />
Another excellent choice is [http://freshmeat.net/projects/cmus/ cmus].<br />
<br />
====Other X-based====<br />
(TODO) Xmms, audacious, bmpx.<br />
<br />
===Codecs and other multimedia content types (i686 only) ===<br />
====DVD====<br />
You can use xine-ui, totem-xine, mplayer or kaffeine (just to name three of the big ones) to watch DVDs. The only thing you may miss is libdvdcss. Beware that using it may be illegal in some countries.<br />
<br />
====Flash====<br />
Install the flash plugin using<br />
pacman -S flashplugin<br />
to enable Macromedia (now Adobe) Flash in your browser, if you run KDE you should see this after installing flash. http://wiki.archlinux.org/index.php/Flash_and_Adobe_Acrobat_browser_plugins#Fixing_Flash_in_Konqueror<br />
<br />
====Quicktime====<br />
Quicktime codecs are contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them.<br />
====Realplayer====<br />
The codec for Realplayer 9 is contained in the codecs package. Just type<br />
pacman -S codecs<br />
to install them. Realplayer 10 is available as a binary package for Linux. You can get it from AUR [http://aur.archlinux.org/packages.php?do_Details=1&ID=1590&O=0&L=0&C=0&K=realplay&SB=&SO=&PP=25&do_MyPackages=0&do_Orphans=0&SeB=nd here].<br />
<br />
===CD and DVD Burning===<br />
====GNOME====<br />
=====Brasero=====<br />
[http://www.gnome.org/projects/brasero/ Brasero] is an application that burns CDs/DVDs for the GNOME Desktop. It is designed to be as simple as possible and has some unique features to enable users to create their discs easily and quickly.<br />
<br />
To install:<br />
pacman -S brasero<br />
<br />
====KDE====<br />
=====K3b=====<br />
K3b (from '''K'''DE '''B'''urn '''B'''aby '''B'''urn) is a free software CD and DVD authoring application for GNU/Linux and other <code>UNIX</code>-like operating systems designed for KDE. As is the case with most KDE applications, K3b is written in the C++ programming language and uses the Qt GUI toolkit. K3b provides a graphical user interface to perform most CD/DVD burning tasks like creating an Audio CD from a set of audio files or copying a CD/DVD, as well as more advanced tasks such as burning eMoviX CD/DVDs. It can also perform direct disc-to-disc copies. The program has many default settings which can be customized by more experienced users. The actual disc recording in K3b is done by the command line utilities cdrecord or wodim, cdrdao, and growisofs. As of version 1.0, K3b features a built-in DVD ripper.- licensed under the GPL.<br />
<br />
K3b was voted LinuxQuestions.org's Multimedia Utility of the Year (2006) by the majority (70%) of voters. <br />
-----<br />
To install:<br />
pacman -S k3b<br />
<br />
=====(Todo) cdrecord, graveman...=====<br />
<br />
<br />
<br />
<br />
Most CD burners are wrappers for cdrecord:<br />
<br />
pacman -S cdrkit<br />
<br />
If you install packages for CD/DVD burning applications like Brasero or K3B it also installs the CD/DVD burning library for it, like libburn or cdrkit.<br />
<br />
A good command-line DVD-burning tool is growisofs:<br />
<br />
pacman -S dvd+rw-tools<br />
<br />
===TV-Cards===<br />
<br />
There are several things to do if you want to watch TV under (Arch) Linux. The most important task is to find out which chip your tuner is using. However, quite a lot are supported. Be sure to check at a Hardware Database to be sure (see [http://en.opensuse.org/HCL/TV_Cards this list], for example). Once you know your Model, there are just a few steps ahead to get you going.<br />
<br />
In most cases, you will need to use the bttv-drivers (other drivers exist, like [http://linux.bytesex.org/v4l2/drivers.html V4L]) together with the I2C-modules. Configuring those is the hardest task. If you are lucky, a<br />
modprobe bttv<br />
will autodetect the card (check dmesg for results). In that case, you need only to install an application to watch TV. We will look at that later, though.<br />
If the autodetection did not work, you will need to check the file CARDLIST, which is included in the tarball of [http://dl.bytesex.org/releases/video4linux/ bttv] to find out the right parameters for your card. A PV951 without radio support would need this line:<br />
modprobe bttv card=42 radio=0<br />
Some cards need the following line to produce sound:<br />
modprobe tvaudio<br />
However, that varies. So just try it out. Some other cards demand the following line:<br />
modprobe tuner<br />
This is subject to trial-and-error, too.<br />
<br />
TODO: clarify the installation-procedure<br />
<br />
To actually watch TV, install the xawtv-package with<br />
pacman -S xawtv <br />
and read its manpage.<br />
<br />
TODO: clarify some possible problems and procedures. Introduction to XAWTV on another page?<br />
<br />
===Digital Cameras===<br />
Most newer digital cameras are supported as USB mass storage devices, which means that you can simply plug it in and copy the images. Older cameras may use the PTP (Picture Transfer Protocol) which requires a "special driver". gPhoto2 provides this driver and allows a shell-based transfer of the images; digikam (for KDE) and gthumb (for GNOME, gtkam would be another choice) use this driver and offer a nice GUI.<br />
<br />
===USB Memory Sticks / Hard Disks===<br />
USB Memory Sticks and hard disks are supported out of the box with the USB mass storage device driver and will appear as a new SCSI device (/dev/sdX). If you are using KDE or GNOME you should use dbus and hal (add them to your daemons in /etc/rc.conf), and they will be automatically mounted. If you use a different Desktop Environment you may have a look at ivman.<br />
<br />
==Maintaining the system==<br />
===Pacman===<br />
[[Pacman]] is both a binary and source package manager which is able to download, install, and upgrade packages from both remote and local repositories with full dependency handling, and has easy-to-understand tools for crafting your own packages too.<br />
<br />
A more-detailed description of Pacman can be found in [[Pacman|its article]].<br />
<br />
====Useful commands====<br />
To view the options available for a particular operational command, say '''-Q''', just append it with '''-h''':<br />
pacman -Qh<br />
<br />
To synchronize and update the local packages database with the remote repositories (it is a good idea to do this before installing and upgrading packages):<br />
pacman -Sy<br />
<br />
To '''upgrade''' all packages on the system:<br />
pacman -Su<br />
<br />
To sync, update, and '''upgrade''' all the packages on the system with one command:<br />
pacman -Syu<br />
<br />
To install or upgrade a single package or list of packages (including dependencies):<br />
pacman -S packageA packageB<br />
<br />
You can also sync, update the package database, and install packages in one command:<br />
pacman -Sy packageA packageB<br />
<br />
To remove a single package, leaving all of its dependencies installed:<br />
pacman -R package<br />
<br />
To remove a package and all of the package's dependencies which aren't used by any other installed package:<br />
pacman -Rs package<br />
('''-Rs''' is typically preferred vs '''R''' to remove any package as it will clean up all unused dependencies)<br />
<br />
To remove all of the package's now unneeded dependencies and also instruct pacman to ignore file backup designations. (Normally, when a file is removed from the system the database is checked to see if the file should be renamed with a ".pacsave" extension.):<br />
pacman -Rsn package<br />
<br />
To search the remote (repo) package database for a list of packages matching a given keyword:<br />
pacman -Ss keyword<br />
<br />
To list all packages on your system<br />
pacman -Q<br />
<br />
To list all packages on your system without the version strings, we add the '''-q''' option:<br />
pacman -Qq<br />
<br />
To search (query) the local (your machine) package database for a given package:<br />
pacman -Q package <br />
<br />
To search (query) the local (your machine) package database for a given package and list all pertinent information:<br />
pacman -Qi package<br />
<br />
To list all files installed by a given ''package'':<br />
<tt>pacman -Ql ''package''</tt><br />
Conversely, to find the package that owns a given file (in this example, the ''ls'' executable):<br />
<tt>pacman -Qo /bin/ls</tt><br />
To find all unused packages (orphans):<br />
pacman -Qdt<br />
Missing libraries: Suppose you receive an error message like this:<br />
<tt>mplayer: error while loading shared libraries: ''libgssapi.so.2'': cannot open shared object file: No such file or directory</tt><br />
This may be an indication that a package you have previously installed is now corrupt (some or all of its files are missing). You should try to find the package name that provides the missing shared library. In this example, you could type:<br />
<tt>pacman -Ql | grep ''libgssapi.so.2''</tt><br />
The first column in the output is the package name:<br />
<tt>heimdal /usr/lib/libgssapi.so.2<br />
heimdal /usr/lib/libgssapi.so.2.0.0<br />
</tt><br />
Then, you can just re-install it:<br />
<tt>pacman -Sy heimdal</tt><br />
<br />
To defragment pacman's cache database and optimize for speed:<br />
pacman-optimize<br />
<br />
To count how many packages are currently on your system:<br />
pacman -Q | wc -l<br />
<br />
To install a package compiled from source using ABS and makepkg:<br />
pacman -U packagename.pkg.tar.gz<br />
<br />
Note: There are countless additional pacman functions and commands. Try man pacman and consult the [[pacman]] wiki entries.<br />
<br />
====Files====<br />
There are a number of files left and created by pacman and other programs to facilitate maintenance and to conform to a safe computing practice. When pacman is installing something, the package contains information on whether to back up a particular file. Such files will have the '''.pacsave''' extension. When you force a "NoUpgrade" on a file via [http://www.archlinux.org/pacman/pacman.conf.5.html pacman.conf], it will not be replaced during an upgrade and the new file will come with the '''.pacnew''' extension. For example, you have edited a configuration file thoroughly and you do not want an upgrade of the respective package to replace the file with a new one, we must have the following line in '''/etc/pacman.conf''':<br />
NoUpgrade = /path/to/config/file<br />
To view the differences of the old and new versions of these files, we can either edit them manually or use a '''diff''' utility to take note of the differences. There is an automated tool to find and view such files available from the '''community''' repository:<br />
pacman -S pacman-contrib<br />
cd ~/<br />
pacdiff # as root<br />
There is a bug in the above tool where if you navigate to '''/etc''' and run it from there, the paths will be messed up. We remain on the safer side by being at "home". You may want to run it as user first in case you happen to be a careless person (you may just overwrite or remove files because you ''think'' that is the right way).<br><br />
<br />
There are other types of leftovers depending on the programs available on your system. Some will create backups with a '''.bak''' extension, while others with something like "'''~'''" or "'''-'''". Unfortunately, there is currently no way to "automatically" find and review them. Fear not, as we have no need for automated tools to deal with such trivial tasks. Simply use '''locate''' to search for them:<br />
locate -e *.~ *.- *.bak<br />
And we can use something useful like '''vimdiff''' to look at the differences manually:<br />
pacman -S vim<br />
vimdiff file1 file2<br />
<br />
==Polishing & Further information==<br />
For further information and support you can go to the [http://www.archlinux.org/ homepage], [[Special:Search|search the wiki]], the [http://bbs.archlinux.org/ forums], the [[ArchChannel|IRC channel]], and the [http://www.archlinux.org/mailman/listinfo/ mailing lists].<br />
=====FAQs=====<br />
See [[Arch FAQs for newbies]]<br />
<br />
There is also an [http://bbs.archlinux.org/viewforum.php?id=23 Arch Subforum] devoted to beginners.<br />
<br />
=====Terminology=====<br />
For more information on the jargon used in Arch, look at [[Arch Terminology/Jargon for newbies|this article]].<br />
<br />
=====Where to go from here?=====<br />
<br />
You may also be interested in:<br />
<br />
[[Post Installation Tips]]<br />
<br />
[[ArchLinux User-community Repository (AUR)]]<br />
<br />
[[Get All Mouse Buttons Working]]<br />
<br />
[[Improve Pacman Performance]]<br />
<br />
[[Kernel Compilation]]<br />
<br />
[[Pm-utils]]<br />
<br />
[[Cpufrequtils]]<br />
<br />
[[:Category:Eye candy (English)| Eye Candy]]<br />
<br />
==External links==<br />
* [http://archux.com/page/installation-guide/ Arch Linux installation guide with images and videos]<br />
{{translateme}}</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=41339
Timezone (Русский)
2008-05-15T12:43:07Z
<p>Cucullus: /* UTC и localtime */</p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Русский]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное) или по местному (local time) времени.<br />
Как правило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно установливаются по местному времени.<br />
<br />
Установить режим машинных часов можно через переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>UTC</code>, то Linux переведёт часы с зимнего на летнее время (или наоборот) вне зависимости от того работал компьютер в момент перехода на другое время или нет.<br />
<br />
'''ВАЖНО:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (или наоборот), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботятся о переводе часов. В противном случае Вам придётся перевести часы вручную.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Table_of_contents_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=39696
Table of contents (Русский)
2008-04-09T08:11:53Z
<p>Cucullus: rm spam</p>
<hr />
<div>[[Category:ArchWiki Tools (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Česky|Table of Contents (Česky)}}<br />
{{i18n_entry|Deutsch|Table of Contents (Deutsch)}}<br />
{{i18n_entry|English|Table of Contents (English)}}<br />
{{i18n_entry|Español|Table of Contents (Español)}}<br />
{{i18n_entry|Français|Table des matières (Français)}}<br />
{{i18n_entry|Italiano|Table of Contents (Italiano)}}<br />
{{i18n_entry|Lietuviškai|Table of Contents (Lietuviškai)}}<br />
{{i18n_entry|Nederlands|Table of Contents (Nederlands)}}<br />
{{i18n_entry|Polski|Table of Contents (Polski)}}<br />
{{i18n_entry|Português do Brasil|Table of Contents (Português do Brasil)}}<br />
{{i18n_entry|Português|Table of Contents (Português)}}<br />
{{i18n_entry|Русский|Table of Contents (Русский)}}<br />
{{i18n_entry|Slovensky|Table of Contents (Slovensky)}}<br />
{{i18n_entry|ไทย|Table of Contents (ไทย)}}<br />
{{i18n_entry|Українська|Table of Contents (Українська)}}<br />
{{i18n_entry|简体中文|Table of Contents (简体中文)}}<br />
{{i18n_entry|正體中文|Table of Contents (正體中文)}}<br />
{{i18n_links_end}}<br />
<br />
*[[:Category: About Arch (English)|Об Arch]]<br />
**[[:Category:Events (English)|События]]<br />
*[[:Category: Getting and installing Arch (English)|Получение и установка Arch]]<br />
*[[:Category: System administration (English)|Администрирование]]<br />
**[[:Category:Hardware (English)|Аппаратная часть]]<br />
***[[:Category:Arch64 (English)|Arch64]]<br />
***[[:Category:CPU (English)|Процессор]]<br />
***[[:Category:Communication and network (English)|Устройства связи]]<br />
***[[:Category:Graphics (English)|Видеокарты]]<br />
***[[:Category:Hardware detection and troubleshooting (English)|Обнаружение устройств и вероятные проблемы]]<br />
***[[:Category:I586 (English)|I586]]<br />
***[[:Category:Imaging (English)|Устройства обработки изображений]]<br />
***[[:Category:Input devices (English)|Устройства ввода]]<br />
***[[:Category:Laptops (English)|Ноутбуки]]<br />
***[[:Category:Mainboards and BIOS (English)|Материнские платы и BIOS]]<br />
***[[:Category:Optical (English)|Оптические устройства]]<br />
***[[:Category:Other hardware (English)|Другое оборудование]]<br />
***[[:Category:PowerPC (English)|PowerPC]]<br />
***[[:Category:Printers (English)|Принтеры]]<br />
***[[:Category:Sound (English)|Аудио устройства]]<br />
***[[:Category:Storage (English)|Накопители информации]]<br />
**[[:Category:Kernel (English)|Ядро]]<br />
**[[:Category:Networking (English)|Сетевое оборудование]]<br />
**[[:Category:Security (English)|Безопасность]]<br />
**[[:Category:Software (English)|ПО]]<br />
***[[:Category:Boot process (English)|Загрузочные процессы]]<br />
***[[:Category:Command shells (English)|Командная оболочка]]<br />
***[[:Category:Daemons and system services (English)|Системные службы и сервисы]]<br />
***[[:Category:Desktop environments (English)|Окружение рабочего стола(DE)]]<br />
***[[:Category:Display managers (English)|Оконные менеджеры]]<br />
***[[:Category:File systems (English)|Файловая система]]<br />
***[[:Category:Fonts (English)|Шрифты]]<br />
***[[:Category:Hardware detection and troubleshooting (English)|Обнаружение устройств и вероятные проблемы]]<br />
***[[:Category:Package management (English)|Управление пакетами]]<br />
***[[:Category:Power management (English)|Управление питанием]]<br />
***[[:Category:X Server (English)|X Server]]<br />
*[[:Category: Desktop user's guide (English)|Руководство пользователя]]<br />
**[[:Category:Audio/Video (English)|Audio/Video]]<br />
**[[:Category:Development (English)|Разработка]]<br />
**[[:Category:Educational (English)|Образование]]<br />
**[[:Category:Emulators (English)|Эмуляторы]]<br />
***[[:Category:Wine (English)|Wine]]<br />
**[[:Category:Eye candy (English)|Визульные спецэффекты]]<br />
**[[:Category:Games and entertainment (English)|Игры и развлечения]]<br />
**[[:Category:Graphics and DTP (English)|Графические приложения]]<br />
**[[:Category:Internationalization (English)|Интернационализация]]<br />
**[[:Category:Internet and Email (English)|Интернет и электронная почта]]<br />
**[[:Category:Office (English)|Офисные приложения]]<br />
**[[:Category:Other desktop user's resources (English)|Другое пользовательское ПО]]<br />
**[[:Category:Scripts (English)|Скрипты]]<br />
**[[:Category:Utilities (English)|Инструменты (Утилиты)]]<br />
*[[:Category:System recovery (English)|Восстановление системы]]<br />
*[[:Category: Arch development (English)|Разработка Arch]]<br />
**[[:Category:Package development (English)|Разработка пакетов]]<br />
*[[:Category: Live Arch systems (English)|Системы Live Arch]]<br />
*[[:Category:ArchWiki Tools (English)|Инструменты ArchWiki]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Splashy_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=39455
Splashy (Русский)
2008-04-01T21:47:15Z
<p>Cucullus: Splashy(Русский) moved to Splashy (Русский)</p>
<hr />
<div>[[Category: Русский]]<br />
[[Category: Загрузка]]<br />
[[Category: Красивости]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Splashy}}<br />
{{i18n_entry|Русский|Splashy(русский)}}<br />
{{i18n_entry|简体中文|Splashy (简体中文)}}<br />
{{i18n_links_end}}<br />
<br />
[http://splashy.alioth.debian.org Splashy] это пользовательская реализация экранной заставки при загрузке Линукс, использующая графическую среду предоставляемую [http://www.directfb.org directfb].<br />
<br />
<br />
=Установка=<br />
#Загрузите [http://aur.archlinux.org/packages.php?do_Details=1&ID=10211 пакет] в AUR, создайте его с помощью makepkg (или любой другой заменой makepkg, которая вам нравиться) и установите с помощью Pacman.<br />
<br />
'''Внимание!''' "initscripts-splash" теперь зависят от splashy. Они заменяют "initscripts", поэтому некоторые файлы в /etc будут сохранены как *.pacsave.<br />
<br />
=Конфигурирование=<br />
====/boot/grub/menu.lst====<br />
Добавьте '''quiet vga=791 splash''' к командной строке вашего ядра в ''/boot/grub/menu.lst''. Т.е.:<br />
kernel (hd0,6)/vmlinuz26 root=/dev/sda6 ro quiet vga=791 splash<br />
====/etc/rc.conf====<br />
Добавьте SPLASH="splashy" в ''/etc/rc.conf''. Т.е.:<br />
SPLASH="splashy"<br />
====/etc/mkinitcpio.conf====<br />
* '''Не забудьте пересоздать initramfs образ после того, как изменилась конфигурация Splashy.''' (например, когда изменили тему Splashy)<br />
#Добавьте '''splashy''' в '''конец''' строки HOOKS в файле ''/etc/mkinitcpio.conf''. Т.е.:<pre>HOOKS="base udev autodetect ide sata filesystems ... splashy"</pre><br />
#Пересоздайте загрузочный образ ядра <pre># mkinitcpio -p <имя ядра></pre>Т.е.:<pre># mkinitcpio -p kernel26</pre><br />
<br />
===Модернизация(апгрейд)===<br />
* Не забудьте пересоздать initramfs образ после апгрейда Splashy.<br />
<br />
=Известные проблемы=<br />
#Splashy не сбрасывается и не переключается автоматически в режим обзора при возникновении ошибки или при отказе инициализационного скрипта.<br />
#Возникает неприятная ситуация, когда при запущенном Splashy происходит вынужденная проверка файловой системы. В некоторых неопределенных случаях (на текущий момент) система перезагружается после отрабатывания команды fsck.<br />
#Система X-Window может отображать артефакты на экране, если splashy активна при загрузке.<br />
<br />
=Ссылки=<br />
* http://splashy.alioth.debian.org<br />
* http://www.directfb.org</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Splashy_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=39454
Splashy (Русский)
2008-04-01T21:46:05Z
<p>Cucullus: </p>
<hr />
<div>[[Category: Русский]]<br />
[[Category: Загрузка]]<br />
[[Category: Красивости]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Splashy}}<br />
{{i18n_entry|Русский|Splashy(русский)}}<br />
{{i18n_entry|简体中文|Splashy (简体中文)}}<br />
{{i18n_links_end}}<br />
<br />
[http://splashy.alioth.debian.org Splashy] это пользовательская реализация экранной заставки при загрузке Линукс, использующая графическую среду предоставляемую [http://www.directfb.org directfb].<br />
<br />
<br />
=Установка=<br />
#Загрузите [http://aur.archlinux.org/packages.php?do_Details=1&ID=10211 пакет] в AUR, создайте его с помощью makepkg (или любой другой заменой makepkg, которая вам нравиться) и установите с помощью Pacman.<br />
<br />
'''Внимание!''' "initscripts-splash" теперь зависят от splashy. Они заменяют "initscripts", поэтому некоторые файлы в /etc будут сохранены как *.pacsave.<br />
<br />
=Конфигурирование=<br />
====/boot/grub/menu.lst====<br />
Добавьте '''quiet vga=791 splash''' к командной строке вашего ядра в ''/boot/grub/menu.lst''. Т.е.:<br />
kernel (hd0,6)/vmlinuz26 root=/dev/sda6 ro quiet vga=791 splash<br />
====/etc/rc.conf====<br />
Добавьте SPLASH="splashy" в ''/etc/rc.conf''. Т.е.:<br />
SPLASH="splashy"<br />
====/etc/mkinitcpio.conf====<br />
* '''Не забудьте пересоздать initramfs образ после того, как изменилась конфигурация Splashy.''' (например, когда изменили тему Splashy)<br />
#Добавьте '''splashy''' в '''конец''' строки HOOKS в файле ''/etc/mkinitcpio.conf''. Т.е.:<pre>HOOKS="base udev autodetect ide sata filesystems ... splashy"</pre><br />
#Пересоздайте загрузочный образ ядра <pre># mkinitcpio -p <имя ядра></pre>Т.е.:<pre># mkinitcpio -p kernel26</pre><br />
<br />
===Модернизация(апгрейд)===<br />
* Не забудьте пересоздать initramfs образ после апгрейда Splashy.<br />
<br />
=Известные проблемы=<br />
#Splashy не сбрасывается и не переключается автоматически в режим обзора при возникновении ошибки или при отказе инициализационного скрипта.<br />
#Возникает неприятная ситуация, когда при запущенном Splashy происходит вынужденная проверка файловой системы. В некоторых неопределенных случаях (на текущий момент) система перезагружается после отрабатывания команды fsck.<br />
#Система X-Window может отображать артефакты на экране, если splashy активна при загрузке.<br />
<br />
=Ссылки=<br />
* http://splashy.alioth.debian.org<br />
* http://www.directfb.org</div>
Cucullus
https://wiki.archlinux.org/index.php?title=PowerNow&diff=38110
PowerNow
2008-03-05T15:01:10Z
<p>Cucullus: </p>
<hr />
<div>[[Category:CPU (English)]]<br />
[[Category:Power management (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|PowerNow}}<br />
{{i18n_entry|Русский|PowerNow (Русский)}}<br />
{{i18n_entry|简体中文(翻译中)|PowerNow (简体中文)}}<br />
{{i18n_links_end}}<br />
<br />
'''PowerNow''' is a technology availible on some AMD processors. It dynamically scales the voltage and speed of the processor to reduce power consumption and heat dissapation. It is also called ''Cool'n'Quiet''.<br />
<br />
== Checking if your CPU supports PowerNow ==<br />
<br />
If you have an AMD64:<br />
# modprobe powernow-k8<br />
<br />
If you have an older CPU, the module is <tt>powernow-k7</tt> or <tt>powernow-k6</tt>.<br />
<br />
If your processor does not support PowerNow, or Cool'n'Quiet is disabled in the BIOS, it will throw an error immediately upon insertion of the module:<br />
<br />
FATAL: Error inserting powernow_k8 (/lib/modules/2.6.16-ARCH/kernel/arch/i386/kernel/cpu/cpufreq/powernow-k8.ko): No such device<br />
<br />
To check if your currently running kernel supports PowerNow!, do <br />
# dmesg | grep powernow<br />
<br />
The output should look something like this (example is an AMD64 3400+ Clawhammer)<br />
<br />
powernow-k8: Found 1 AMD Athlon 64 / Opteron processors (version 1.60.2)<br />
powernow-k8: 0 : fid 0x10 (2400 MHz), vid 0x2 (1500 mV)<br />
powernow-k8: 1 : fid 0xe (2200 MHz), vid 0x6 (1400 mV)<br />
powernow-k8: 2 : fid 0xc (2000 MHz), vid 0xa (1300 mV)<br />
powernow-k8: 3 : fid 0xa (1800 MHz), vid 0xe (1200 mV)<br />
powernow-k8: 4 : fid 0x2 (1000 MHz), vid 0x12 (1100 mV)<br />
<br />
== Setting up PowerNow in the kernel==<br />
<br />
Load the <tt>powernow-k8</tt>, <tt>cpufreq_powersave</tt>, <tt>cpufreq_userspace</tt>, <tt>cpufreq_conservative</tt>, <tt>cpufreq_ondemand</tt> and <tt>freq_table</tt> modules using <tt>modprobe</tt>, and add them to the <tt>MODULES</tt> array in <tt>/etc/rc.conf</tt>.<br />
<br />
== Setting up Frequency Scaling in userspace (with cpudyn) ==<br />
# pacman -S acpid cpudyn<br />
<br />
Start cpudyn with:<br />
# /etc/rc.d/cpudyn start<br />
<br />
and add <tt>cpudyn</tt> to the <tt>DAEMONS</tt> array in <tt>/etc/rc.conf</tt>.<br />
<br />
The configuration of cpudyn and acpid is beyond the scope of this article.<br />
<br />
== Testing ==<br />
<br />
To check if the scaling works, execute:<br />
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq<br />
<br />
and compare it to:<br />
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq<br />
<br />
You can also execute:<br />
cat /dev/urandom > /dev/null<br />
<br />
in a second console and <tt>scaling_cur_freq</tt> should equal <tt>scaling_max_freq</tt>.<br />
<br />
== Alternative Method: cpufrequtils ==<br />
This is a much easier and straight-forward method of setting this up.<br />
<br />
1. Install cpufrequtils<br />
pacman -S cpufrequtils<br />
<br />
2. Edit /etc/conf.d/cpufreq for your requested settings<br />
# valid governors:<br />
# ondemand, performance, powersave, conservative, userspace<br />
governor="ondemand"<br />
<br />
# valid freq suffixes: Hz, kHz (default), MHz, GHz, THz<br />
min_freq="2.25GHz"<br />
max_freq="3GHz"<br />
<br />
3. Add your cpufreq module for your processor (i.e. powernow, powernow-k6, or powernow-k8) to the MODULES array in /etc/rc.conf - it is NOT autoloaded by default.<br />
<br />
4. Add 'cpufreq' to the DAEMONS array in /etc/rc.conf to have it start on startup. To start it right now, run:<br />
/etc/rc.d/cpufreq start</div>
Cucullus
https://wiki.archlinux.org/index.php?title=PowerNow-ru&diff=38109
PowerNow-ru
2008-03-05T15:00:43Z
<p>Cucullus: PowerNow-ru moved to PowerNow (Русский)</p>
<hr />
<div>#REDIRECT [[PowerNow (Русский)]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=PowerNow_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=38108
PowerNow (Русский)
2008-03-05T15:00:43Z
<p>Cucullus: PowerNow-ru moved to PowerNow (Русский)</p>
<hr />
<div>[[Category:Прочее железо]]<br />
[[Category:Управление питанием]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|PowerNow}}<br />
{{i18n_entry|Русский|PowerNow-ru}}<br />
{{i18n_links_end}}<br />
<br />
'''PowerNow''' это технология используемая в некоторых процессорах AMD. Она динамически изменяет напряжение и скорость процессора с целью уменьшить энергопотребление и тепловыделение. Ее еще называют ''Cool'n'Quiet''.<br />
<br />
== Проверка поддержки PowerNow процессором ==<br />
<br />
Если у Вас AMD64 (или Sempron-k8):<br />
# modprobe powernow-k8<br />
<br />
Если у Вас более старый процессор попробуйте модули <tt>powernow-k7</tt> или <tt>powernow-k6</tt>.<br />
<br />
Если процессор не поддерживает PowerNow, или Cool'n'Quiet отключен в BIOS'e Вы увидите ошибку сразу после попытки загрузки модуля:<br />
<br />
FATAL: Error inserting powernow_k8 (/lib/modules/2.6.16-ARCH/kernel/arch/i386/kernel/cpu/cpufreq/powernow-k8.ko): No such device<br />
<br />
Чтобы проверить поддерживает ли загруженное ядро PowerNow! напишите<br />
# dmesg | grep powernow<br />
<br />
Вывод должен выглядеть примерно так (пример для AMD64 3400+ Clawhammer)<br />
<br />
powernow-k8: Found 1 AMD Athlon 64 / Opteron processors (version 1.60.2)<br />
powernow-k8: 0 : fid 0x10 (2400 MHz), vid 0x2 (1500 mV)<br />
powernow-k8: 1 : fid 0xe (2200 MHz), vid 0x6 (1400 mV)<br />
powernow-k8: 2 : fid 0xc (2000 MHz), vid 0xa (1300 mV)<br />
powernow-k8: 3 : fid 0xa (1800 MHz), vid 0xe (1200 mV)<br />
powernow-k8: 4 : fid 0x2 (1000 MHz), vid 0x12 (1100 mV)<br />
<br />
== Настройка PowerNow в ядре==<br />
<br />
Загрузите модули <tt>powernow-k8</tt>, <tt>cpufreq_powersave</tt>, <tt>cpufreq_userspace</tt>, <tt>cpufreq_conservative</tt>, <tt>cpufreq_ondemand</tt> и <tt>freq_table</tt> используя <tt>modprobe</tt>, добавьте их в массив <tt>MODULES</tt> в файле <tt>/etc/rc.conf</tt>.<br />
<br />
Затем воспользуйтесь одной из команд для загрузки соответствующей политики энергосбережения<br />
статичное минимальное энергопотребление<br />
# echo powersave > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor<br />
динамическая политика, повышающая энергопотребление по надобности (рекомендуется для мобильных устройств вроде ноутбуков)<br />
# echo conservative > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor<br />
аналог предыдущей, но рекомендуется для настольных систем<br />
# echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor<br />
<br />
== Настройка Изменения Частоты из пространства пользователя (с использованием cpudyn) == <br />
# pacman -S acpid cpudyn<br />
<br />
Запуск cpudyn:<br />
# /etc/rc.d/cpudyn start<br />
<br />
добавьте <tt>cpudyn</tt> в массив <tt>DAEMONS</tt> в файле <tt>/etc/rc.conf</tt>.<br />
<br />
Настройка cpudyn и acpid вне этой статьи (FIXME)<br />
The configuration of cpudyn and acpid is beyond the scope of this article.<br />
<br />
== Тестирование ==<br />
<br />
Чтобы проверить работает ли изменение частоты, выполните:<br />
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq<br />
<br />
и сравните с:<br />
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq<br />
<br />
Также можно выполнить:<br />
cat /dev/urandom > /dev/null<br />
<br />
в другой консоли, <tt>scaling_cur_freq</tt> должен сравняться с <tt>scaling_max_freq</tt>.<br />
<br />
== Альтернатива: cpufrequtils ==<br />
Это более простой и прямолинейный способ настройки.<br />
This is a much easier and straight-forward method of setting this up.<br />
<br />
1. Установите cpufrequtils<br />
pacman -S cpufrequtils<br />
<br />
2. Отредактируйте должным образом /etc/conf.d/cpufreq <br />
# доступные политики:<br />
# ondemand, performance, powersave, conservative, userspace<br />
governor="ondemand"<br />
<br />
# возможные суффиксы: Hz, kHz (default), MHz, GHz, THz<br />
min_freq="2.25GHz"<br />
max_freq="3GHz"<br />
<br />
3. Добавьте нужный модуль (напр. powernow, powernow-k6, или powernow-k8) в массив MODULES в файле /etc/rc.conf - по умолчанию они не загружаются.<br />
<br />
4. Добавьте 'cpufreq' в массив DAEMONS в файле /etc/rc.conf чтобы он запускался во время загрузки. Чтобы запустить его прямо сейчас:<br />
/etc/rc.d/cpufreq start<br />
<br />
[[Category:Русский]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=%D0%A3%D1%81%D1%82%D0%B0%D0%BD%D0%BE%D0%B2%D0%BA%D0%B0_%D0%B8_%D0%BD%D0%B0%D1%81%D1%82%D1%80%D0%BE%D0%B9%D0%BA%D0%B0_Xorg&diff=34953
Установка и настройка Xorg
2008-01-12T13:05:54Z
<p>Cucullus: /* hwd */</p>
<hr />
<div>[[Category:XServer (Русский)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Русский|Установка и настройка Xorg}}<br />
{{i18n_entry|English|Xorg}}<br />
{{i18n_entry|繁體中文|Xorg 的安裝與設定}}<br />
{{i18n_entry|Polski|Xorg_(Polski)}}<br />
{{i18n_links_end}}<br />
<br />
==Установка Xorg==<br />
Перед тем, как начать, убедитесь в следующем:<br />
#Что [[pacman_(Русский)|pacman]] сконфигурирован и обновлен.<br />
#Если у вас запущен другой Х сервер - закройте его: <code>ctrl+alt+backspace</code><br />
#Проверьте необходимость сторонних драйверов (например nVidia или ATI). <br />
<br />
Теперь установим xorg сервер и xorg клиент:<br />
<pre><br />
# pacman -S xorg-server xorg-clients<br />
</pre><br />
<br><br />
Если установка прошла нормально, самое время создать <code>xorg.conf</code> с помощью <code>xorgconfig</code>.<br />
<br />
==Настройка Xorg==<br />
Перед тем, как запускать Xorg, вам необходимо его сконфигурировать, чтобы он знал о вашей видеокарте, мониторе, мыши и клавиатуре. Для этого есть 2 пути: <tt>xorgconfig</tt> или <tt>hwd</tt>.<br />
===xorgconfig===<br />
Чтобы запустить <tt>xorgconfig</tt> наберите:<br />
<br />
xorgconfig<br />
<br />
Так будет сгенерирован новый <tt>xorg.conf</tt>.<br />
<br />
Отвечайте на вопросы, остальное сделает программа. Однако обратите внимание на вопрос о мыши. Устройством по умолчанию, согласно <code>xorgconfig</code>, является <code>/dev/mouse</code>. Однако вам придется заменить его на <code>/dev/input/mice</code>. В противном случае, вы можете столкнуться с проблемой зависания Х при запуске.<br />
Конфиги, созданные таким способом, не совсем удачны и вам придется некоторые изменения вносить вручную.<br />
===hwd===<br />
Hwd было написано пользователями Arch Linux. В основе своей - это инструмент для определения оборудования со множеством функций, одной из которых является настройка Х сервера. К счастью, hwd гораздо удобнее и не требует ввода какой-либо информации.<br />
<br />
Для начала, вам необходимо установить hwd:<br />
pacman -S hwd<br />
<br />
Затем, необходимо запустить hwd (из под root`а) с ключом "-х", который укажет на то, что необходимо сгенерировать <code>xorg.conf</code>:<br />
<br />
hwd -x<br />
<br />
Эта команда не перезапишет существующий xorg.conf, а создаст новый с именем <tt>/etc/X11/xorg.conf.hwd</tt> (если вы хотите, чтобы старый xorg.conf был перезаписан - используйте ключ "-ха"). Переименуйте созданный конфиг <br />
<br />
mv xorg.conf.hwd xorg.conf<br />
<br />
Советуется сделать резервную копию существующего конфига перед выполнением выше описанных действий.<br />
<br />
===Тонкая настройка===<br />
Возможно, после генерации, вам захочется исправить конфиг. Для этого откройте его в своем любимом редакторе, например Vim (вам понадобятся права root`а):<br />
<br />
vim /etc/X11/xorg.conf<br />
<br />
Если вы хотите настроить колесо на мышке, посмотрите статью [[Настройка колеса прокрутки мыши]].<br />
<br />
Некоторым может понадобится указать размер дисплея. Это можно сделать в секции <code>"Monitor"</code> под <code>VertRefresh</code>, указав размер в мм:<br />
<br />
VertRefresh 50-70<br />
DisplaySize 305 230<br />
<br />
Если вы хотите использовать стороннние драйвера, сначала убедитесь, что Х сервер работает. Сторонние драйвера нужны в основном для 3D ускорения в играх, 2х мониторных конфигураций и TV-Out. За помощью в установке Nvidia драйверов обратитесь к статье [[NVIDIA]].<br />
<br />
Несколько советов по настройке шрифтов есть в статье [[Xorg Font Configuration]].<br />
<br />
==Запуск Xorg==<br />
Просто наберите:<br />
<br />
startx<br />
<br />
Х по умолчанию является достаточно жалким зрелищем, вы наверняка захотите установить один из множества WM/DE.<br />
<br />
Если возникнут проблемы, просмотрите лог (<tt>/var/log/Xorg.0.log</tt>). Обращайте внимание на строки начинающиеся с "(ЕЕ)",которые сигнализируют об ошибках, а также ("WW"), которые означают предупреждения.<br />
<br />
==Настройка запуска X (/usr/bin/startx)==<br />
За полным списком опций обратитесь к <br />
<br />
man Xserver<br />
<br />
Следуюцие опции добавляются в переменную defaultserverargs.<br />
<br />
Запретить Х серверу слушать tcp : <br />
-nolisten tcp<br />
<br />
избавиться от волнистой серой заливки при старте Х и установить черный цвет в качестве фона:<br />
-br<br />
<br />
включить задержку загрузки глифов для 16 битных шрифтов:<br />
-deferglyphs 16<br />
<br />
Для внесения изменений в эту переменную отредактируйте usr/bin/startx.<br />
<br />
[[Category:Русский]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=%D0%A3%D1%81%D1%82%D0%B0%D0%BD%D0%BE%D0%B2%D0%BA%D0%B0_%D0%B8_%D0%BD%D0%B0%D1%81%D1%82%D1%80%D0%BE%D0%B9%D0%BA%D0%B0_Xorg&diff=32569
Установка и настройка Xorg
2007-11-19T22:29:17Z
<p>Cucullus: /* hwd */</p>
<hr />
<div>[[Category:XServer (Русский)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|Русский|Установка и настройка Xorg}}<br />
{{i18n_entry|English|Xorg}}<br />
{{i18n_entry|繁體中文|Xorg 的安裝與設定}}<br />
{{i18n_entry|Polski|Xorg_(Polski)}}<br />
{{i18n_links_end}}<br />
<br />
==Установка Xorg==<br />
Перед тем, как начать, убедитесь в следующем:<br />
#Что [[pacman_(Русский)|pacman]] сконфигурирован и обновлен.<br />
#Если у вас запущен другой Х сервер - закройте его: <code>ctrl+alt+backspace</code><br />
#Проверьте необходимость сторонних драйверов (например nVidia или ATI). <br />
<br />
Теперь установим xorg сервер и xorg клиент:<br />
<pre><br />
# pacman -S xorg-server xorg-clients<br />
</pre><br />
<br><br />
Если установка прошла нормально, самое время создать <code>xorg.conf</code> с помощью <code>xorgconfig</code>.<br />
<br />
==Настройка Xorg==<br />
Перед тем, как запускать Xorg, вам необходимо его сконфигурировать, чтобы он знал о вашей видеокарте, мониторе, мыши и клавиатуре. Для этого есть 2 пути: <tt>xorgconfig</tt> или <tt>hwd</tt>.<br />
===xorgconfig===<br />
Чтобы запустить <tt>xorgconfig</tt> наберите:<br />
<br />
xorgconfig<br />
<br />
Так будет сгенерирован новый <tt>xorg.conf</tt>.<br />
<br />
Отвечайте на вопросы, остальное сделает программа. Однако обратите внимание на вопрос о мыши. Устройством по умолчанию, согласно <code>xorgconfig</code>, является <code>/dev/mouse</code>. Однако вам придется заменить его на <code>/dev/input/mice</code>. В противном случае, вы можете столкнуться с проблемой зависания Х при запуске.<br />
Конфиги, созданные таким способом, не совсем удачны и вам придется некоторые изменения вносить вручную.<br />
===hwd===<br />
'''Внимание:''' hwd не работает с последней (7.3) версией Xorg!<br />
<br />
Hwd было написано пользователями Arch Linux. В основе своей - это инструмент для определения оборудования со множеством функций, одной из которых является настройка Х сервера. К счастью, hwd гораздо удобнее и не требует ввода какой-либо информации.<br />
<br />
Для начала, вам необходимо установить hwd:<br />
pacman -S hwd<br />
<br />
Затем, необходимо запустить hwd (из под root`а) с ключом "-х", который укажет на то, что необходимо сгенерировать <code>xorg.conf</code>:<br />
<br />
hwd -x<br />
<br />
Эта команда не перезапишет существующий xorg.conf, а создаст новый с именем <tt>/etc/X11/xorg.conf.hwd</tt> (если вы хотите, чтобы старый xorg.conf был перезаписан - используйте ключ "-ха"). Переименуйте созданный конфиг <br />
<br />
mv xorg.conf.hwd xorg.conf<br />
<br />
Советуется сделать резервную копию существующего конфига перед выполнением выше описанных действий.<br />
<br />
===Тонкая настройка===<br />
Возможно, после генерации, вам захочется исправить конфиг. Для этого откройте его в своем любимом редакторе, например Vim (вам понадобятся права root`а):<br />
<br />
vim /etc/X11/xorg.conf<br />
<br />
Если вы хотите настроить колесо на мышке, посмотрите статью [[Настройка колеса прокрутки мыши]].<br />
<br />
Некоторым может понадобится указать размер дисплея. Это можно сделать в секции <code>"Monitor"</code> под <code>VertRefresh</code>, указав размер в мм:<br />
<br />
VertRefresh 50-70<br />
DisplaySize 305 230<br />
<br />
Если вы хотите использовать стороннние драйвера, сначала убедитесь, что Х сервер работает. Сторонние драйвера нужны в основном для 3D ускорения в играх, 2х мониторных конфигураций и TV-Out. За помощью в установке Nvidia драйверов обратитесь к статье [[NVIDIA]].<br />
<br />
Несколько советов по настройке шрифтов есть в статье [[Xorg Font Configuration]].<br />
<br />
==Запуск Xorg==<br />
Просто наберите:<br />
<br />
startx<br />
<br />
Х по умолчанию является достаточно жалким зрелищем, вы наверняка захотите установить один из множества WM/DE.<br />
<br />
Если возникнут проблемы, просмотрите лог (<tt>/var/log/Xorg.0.log</tt>). Обращайте внимание на строки начинающиеся с "(ЕЕ)",которые сигнализируют об ошибках, а также ("WW"), которые означают предупреждения.<br />
<br />
==Настройка запуска X (/usr/bin/startx)==<br />
За полным списком опций обратитесь к <br />
<br />
man Xserver<br />
<br />
Следуюцие опции добавляются в переменную defaultserverargs.<br />
<br />
Запретить Х серверу слушать tcp : <br />
-nolisten tcp<br />
<br />
избавиться от волнистой серой заливки при старте Х и установить черный цвет в качестве фона:<br />
-br<br />
<br />
включить задержку загрузки глифов для 16 битных шрифтов:<br />
-deferglyphs 16<br />
<br />
Для внесения изменений в эту переменную отредактируйте usr/bin/startx.<br />
<br />
[[Category:Русский]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=DOSBox_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=32364
DOSBox (Русский)
2007-11-12T14:00:25Z
<p>Cucullus: </p>
<hr />
<div>[[category:Русский]]<br />
[[Category:Эмуляция]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|DOSBox}}<br />
{{i18n_entry|Русский|DOSBox (Русский)}}<br />
{{i18n_links_end}}<br />
<br />
=Введение=<br />
DOSBox это эмулятор PC со встроенным DOS'ом предназначенный для запуска старых DOS'овских игр и программ.<br />
<br />
=Установка=<br />
Установка очень проста:<br />
# pacman -S dosbox<br />
=Настройка=<br />
Никакой начальной конфигурации не требуется.<br />
Тем не менее, официальное руководство DOSBox'a говорит о конфигурационном файле "dosbox.conf"<br />
<br><br />
Изначально этого файла не существует, Вы можете его создать:<br />
<br />
Просто запустите dosbox без параметров:<br />
$ dosbox<br />
<br />
Затем в командной строке DOS:<br />
Z:\> config -wc dosbox.conf<br />
<br />
Конфигурационный файл dosbox.conf будет сохранен в текущем каталоге<br />
<br />
=Использование=<br />
Положите вашу любимую игру/программу в каталог, затем запустите dosbox с именем этого каталога:<br />
$ dosbox ./theoldgame/<br />
<br />
Вот и все. Вы в командной строке DOS и можете начать играть в ваши любимые старые игры.<br />
<br />
За дополнительной информацией обращайтесь на официальный сайт DOSBox:<br />
http://dosbox.sourceforge.net/</div>
Cucullus
https://wiki.archlinux.org/index.php?title=DOSBox&diff=32363
DOSBox
2007-11-12T13:59:52Z
<p>Cucullus: i18n_links added</p>
<hr />
<div>[[Category:Emulators (English)]]<br />
[[Category:HOWTOs (English)]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|DOSBox}}<br />
{{i18n_entry|Русский|DOSBox (Русский)}}<br />
{{i18n_links_end}}<br />
<br />
=Introduction=<br />
[http://dosbox.sourceforge.net/ DOSBox] is an x86 PC DOS-emulator for running old DOS games or programs.<br />
<br />
=Installation=<br />
The installation is very simple:<br />
# pacman -S dosbox<br />
<br />
=Configuration=<br />
No initial configuration is needed, however the official DOSBox Manual refers to a configuration file named "dosbox.conf". By default that file does not exist<br />
<br />
To recreate that file, simply run <tt>dosbox</tt> without any parameters:<br />
$ dosbox<br />
<br />
Then at the DOS prompt, type:<br />
'''Z:\>''' config -wc dosbox.conf<br />
<br />
The configuration file "dosbox.conf" will then be saved in the current directory.<br />
<br />
=Usage=<br />
A simple way to run dosbox is to place your DOS game (or its setup files) into a directory and then run dosbox with the directory path appended. For example:<br />
$ dosbox ./game-folder/<br />
<br />
You should now have a DOS prompt whose working directory is the one specified above. From there, you can execute the desired program(s):<br />
<br />
'''C:\>''' SETUP.EXE<br />
<br />
= Other Resources =<br />
For more information visit the official DOSBox site: http://dosbox.sourceforge.net/<br />
<br />
[http://www.abandonia.com/ Abandonia] - A large repository of old and abandoned DOS games</div>
Cucullus
https://wiki.archlinux.org/index.php?title=DOSBox-ru&diff=32362
DOSBox-ru
2007-11-12T13:56:38Z
<p>Cucullus: DOSBox-ru moved to DOSBox (Русский)</p>
<hr />
<div>#REDIRECT [[DOSBox (Русский)]]</div>
Cucullus
https://wiki.archlinux.org/index.php?title=DOSBox_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=32361
DOSBox (Русский)
2007-11-12T13:56:37Z
<p>Cucullus: DOSBox-ru moved to DOSBox (Русский)</p>
<hr />
<div>[[category:Русский]]<br />
[[Category:Эмуляция]]<br />
=Введение=<br />
DOSBox это эмулятор PC со встроенным DOS'ом предназначенный для запуска старых DOS'овских игр и программ.<br />
<br />
=Установка=<br />
Установка очень проста:<br />
# pacman -S dosbox<br />
=Настройка=<br />
Никакой начальной конфигурации не требуется.<br />
Тем не менее, официальное руководство DOSBox'a говорит о конфигурационном файле "dosbox.conf"<br />
<br><br />
Изначально этого файла не существует, Вы можете его создать:<br />
<br />
Просто запустите dosbox без параметров:<br />
$ dosbox<br />
<br />
Затем в командной строке DOS:<br />
Z:\> config -wc dosbox.conf<br />
<br />
Конфигурационный файл dosbox.conf будет сохранен в текущем каталоге<br />
<br />
=Использование=<br />
Положите вашу любимую игру/программу в каталог, затем запустите dosbox с именем этого каталога:<br />
$ dosbox ./theoldgame/<br />
<br />
Вот и все. Вы в командной строке DOS и можете начать играть в ваши любимые старые игры.<br />
<br />
За дополнительной информацией обращайтесь на официальный сайт DOSBox:<br />
http://dosbox.sourceforge.net/</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Remastering_the_Install_ISO_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=32360
Remastering the Install ISO (Русский)
2007-11-12T13:48:20Z
<p>Cucullus: </p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Русские HowTo]]<br />
{{out of date}}<br />
<br />
=== Зачем создавать Live CD? ===<br />
Часто бывает удобно иметь под рукой версию Arch Linux, работающую полностью с CD. Live CD может использоваться для восстановления вашей системы, для проверки новых машин или оборудования на совместимость с GNU/Linux, для создания демонстрационного диска для показа ваших проектов и многого другого.<br />
<br />
=== Прежде чем начать, вам потребуется ===<br />
# Для создания iso-образа, форматирования файловой системы и для изменения размера образа, вам понадобятся пакеты "cdrtools" и "e2fsprogs".<br />
pacman -S cdrtools<br />
pacman -S e2fsprogs<br />
# Также вам понадобятся создать на жестком диске<br />
## 1 раздел для установки дистрибутива<br />
## 1 директория на вашем активном разделе, чтобы сохранить образ для записи на диск. <br />
# CD-RW диск для записи и проверки разных версий образов, и пишущий привод.<br />
# Установить пакет для записи CD (если вы не знаете, что выбрать, устанавливайте "k3b").<br />
pacman -S k3b<br />
<br />
=== Детали ===<br />
Для примера, в этой статье мы рассмотрим создание mini Arch Linux Live CD (110MB). Он основан на базовых пакетах, установленных с помощью Arch Linux's CD installer версии 0.5<br />
<br />
==== Зазрузитесь с помощью Arch Linux CD installer и установите базовые пакеты ====<br />
<br />
Установив пакеты, установите ядро, но не устанавливайте загрузчик. Также вы можете копировать образ вашего собсвенного ядра (<tt>/boot/vmlinuz</tt>), и соответствующих ему модулей (<tt>/lib/modules/2.x.x</tt>) с вашей системы. Чтобы загрузиться в новую систему, настройте соответствующим образом ваш загрузчик.<br />
<br />
'''Совет:''' Для проверки на наличие ошибок в процессе загрузки, примонтируйте раздел с новой системой в ваш Arch Linux и исправьте следующие строчки в файле <tt>/etc/rc.local</tt> для приостановки системы перед аутентификацей пользователя:<br />
<br />
echo "Press any key to continue..."<br />
read KEY<br />
<br />
'''Внимание:''' Не забудьте убрать паузу!!<br />
<br />
В вашей системе, в <tt>/root</tt> создайте каталог "''mylivecd''" и два подкаталога: "''isolinux''" и "''system''" (вы можете использовать свои имена).<br />
<br />
# cd /root<br />
# mkdir mylivecd<br />
# cd mylivecd<br />
# mkdir isolinux<br />
# mkdir system<br />
<br />
==== Установите isolinux. Скопируйте его с Live CD====<br />
<br />
# Загрузите "''isolinux.bin''" и "''boot.cat''" в каталог <tt>/root/mylivecd/isolinux/</tt> :<br />
http://amlug.bliss-solutions.org/live-cd/distfiles/0.5.1/isolinux/<br />
# Создайте загрузочное сообщение "''boot.msg''" (текстовый файл) и запишите туда краткое описание вашего live CD. Сохраните этот файл в <tt>/root/mylivecd/isolinux/</tt>. <br />
Пример <tt>boot.msg</tt>:<br />
This is a Live CD test ver. 0.1.<br />
F1 - boot message<br />
F2 - package list<br />
<br />
Press Enter<br />
# Создайте "''isolinux.cfg''" и поместите туда следующий текст. Сохраните файл в <tt>/root/mylivecd/isolinux/</tt><br />
prompt 1<br />
timeout 0<br />
display boot.msg<br />
F1 boot.msg<br />
F2 package.txt<br />
default vmlinuz initrd=miniroot.gz init=/sbin/init ramdisk_size=100000 load_ramdisk=1 prompt_ramdisk=0 vga=788 root=/dev/ram0<br />
<br />
==== Создайте один miniroot образ ====<br />
Miniroot загружается в оперативную память во время загрузки и действует также как и на HD. Используйте файловую систему Ext2.<br />
<br />
'''Внимание:''' Настройка miniroot зависит от <tt>/etc/inittab</tt>, <tt>/etc/rc.sysinit</tt>, <tt>/etc/rc.multi</tt>, и <tt>/etc/rc.shutdown</tt>. Перед созданием miniroot-образа, внимательно изучите эти файлы и продумайте как они могут быть изменены при необходимости. В каталоге <tt>/sbin</tt> вам понадобятся слеующие файлы:<br><br />
http://amlug.bliss-solutions.org/live-cd/distfiles/0.5.1/miniroot/init/sbin/<br />
<br />
# Создайте текстовый файл "''miniroot''" в <tt>/root/mylivecd</tt> с файловой системой Ext2. Размер образа зависит от того, как много пакетов вы собираетесь включить в него. В нашем примере мы создадим образ 15.8MB. Рекомендуется создавать образ как можно меньше. Когда будете готовы, примонтируйте образ например в <tt>/mnt/image</tt><br />
# cd /root/mylivecd<br />
# touch miniroot<br />
# mkfs.ext2 miniroot 15840 (press "y" for each question)<br />
# mkdir /mnt/image<br />
# mount -t auto -o loop miniroot /mnt/image<br />
# rm -R /mnt/image/lost+found<br />
'''Внимание: ''' Если вы хотите поменять размер, используйте следующие команды (для уменьшения размера до 11.5MB):<br />
# e2fsck -f miniroot (press "y" for /lost+found not found. Create<y>?)<br />
# resize2fs miniroot 11520<br />
# Примонтируйте раздел с новой системой. Копируйте файлы и каталоги из нового раздела в <tt>/mnt/image</tt><br />
# mkdir /mnt/tmp<br />
# mount /dev/hda3 /mnt/tmp<br />
# cp -Ra /mnt/tmp/bin /mnt/image/<br />
# cp -Ra /mnt/tmp/etc /mnt/image/<br />
# cp -Ra /mnt/tmp/sbin /mnt/image/<br />
# cp -Ra /mnt/tmp/tmp /mnt/image/<br />
# cp -Ra /mnt/tmp/var /mnt/image/<br />
# Копируйте <tt>/usr</tt>, <tt>/lib/modules/2.x.x/</tt>, <tt>/lib/modules/evms/</tt>, <tt>/lib/modules/security/</tt> в <tt>/root/mylivecd/system/</tt> :<br />
# cp -Ra /mnt/tmp/usr /root/mylivecd/system/<br />
# cp -Ra /mnt/tmp/opt /root/mylivecd/system/<br />
# mkdir /root/mylivecd/system/lib<br />
# cp -Ra /mnt/tmp/lib/modules /root/mylivecd/system/lib/<br />
# cp -Ra /mnt/tmp/lib/evms /root/mylivecd/system/lib/<br />
# cp -Ra /mnt/tmp/lib/security /root/mylivecd/system/lib/<br />
'''Внимание: ''': Если <tt>/bin</tt> и <tt>/sbin</tt> слишком велики вы можете попробовать использовать busybox:<br />
http://www.busybox.net/<br />
'''Или''' использовать временные папки, которые будут удалены или переименованы при загрузке <tt>/rc.sysinit</tt>. Здесь пример как это можно сделать:<br />
http://amlug.bliss-solutions.org/live-cd/distfiles/0.5.1/miniroot/init/sbin/rc.sysinit<br />
# Создайте следующие каталоги в <tt>/mnt/image</tt> и копируйте <tt>/mnt/tmp/lib</tt> файлы в <tt>/mnt/image/lib/</tt> (не копируйте <tt>/mnt/tmp/lib/module</tt>, <tt>~/lib/evms</tt> и <tt>~/lib/security)</tt>:<br />
# cd /mnt/image<br />
# mkdir dev<br />
# mkdir home<br />
# mkdir lib<br />
# mkdir mnt/cdrom<br />
# mkdir mnt/floppy<br />
# mkdir root<br />
# mkdir proc<br />
# mkdir lib/modules<br />
# cd /mnt/tmp/lib/<br />
# cp -a l* /mnt/image/lib/<br />
# С каталогами <tt>/usr</tt> и <tt>/opt</tt> создайте ссылки в <tt>/mnt/image/</tt>. Также создайте ссылку на <tt>/system/lib/modules/2.x.x/</tt>. Копируйте образ ядра в <tt>/root/mylivecd/isolinux/</tt>:<br />
# cd /mnt/image<br />
# ln -sf /mnt/cdrom/system/usr usr<br />
# ln -sf /mnt/cdrom/system/opt opt<br />
# cd /mnt/image/lib/modules/<br />
# ln -sf /mnt/cdrom/system/lib/modules/2.4.22 2.4.22<br />
# cd /mnt/image/lib/<br />
# ln -sf /mnt/cdrom/system/lib/evms evms<br />
# ln -sf /mnt/cdrom/system/lib/security security<br />
# cp /mnt/tmp/boot/vmlinuz /root/mylivecd/isolinux/<br />
# Исправьте <tt>/mnt/image/etc/fstab как показано здесь:</tt><br />
/dev/root / ext2 defaults 0 0<br />
none /proc proc defaults 0 0<br />
/dev/floppy/0 /mnt/floppy auto user,rw,noauto,unhide 0 0<br />
/dev/cdroms/cdrom0 /mnt/cdrom iso9660 ro,user,noauto,unhide 0 0<br />
# Добавьте следующие строчки в файл <tt>rc.sysinit</tt> (после строки: <tt>stat_busy "Mounting Local Filesystems"</tt>) в <tt>/mnt/image/etc/</tt>. Это позволит чтение файлов из каталога /system с CD.<br />
/bin/mount /dev/cdroms/cdrom0 /mnt/cdrom -o ro -t iso9660<br />
# Сожмите miniroot и поместите miniroot.gz в /root/mylivecd/isolinux/<br />
# cd /root/mylivecd/<br />
# umount /mnt/image<br />
# gzip -c miniroot >> miniroot.gz<br />
# mv miniroot.gz isolinux/<br />
# Перед компиляцией, переместите <tt>/root/mylivecd/miniroot</tt> в безопасное место. Создайте временный каталог для iso образа (не внутри <tt>/mylivecd</tt>). Выполните следующий код (не забудьте "." в конце строки):<br />
# cd /root/mylivecd<br />
# mkdir /root/isotmp<br />
# Создайте ISO:<br />
mkisofs -o /root/isotmp/test-livecd-0.1.iso -R -V "Test 0.1" \<br />
-T -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot \<br />
-boot-load-size 4 -boot-info-table -A "Test Live CD 0.1" .<br />
<br />
==== Заключение ====<br />
Надеемся это руководство помогло вам. Удачи!<br />
<br />
------<br />
<br />
=== Дополнительная информация:===<br />
<br />
Исходные коды и содержимое AMLUG Live CD:<br />
http://www.amlug.net/new-projects/forum/index.php?showforum=23<br />
<br />
Создание Live CD в других дистрибутивах:<br />
http://www.babytux.org/articles/howto/how2livecd.php<br />
----</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Remastering_the_Install_ISO_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=32359
Remastering the Install ISO (Русский)
2007-11-12T13:46:33Z
<p>Cucullus: </p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Русские HowTo]]<br />
<br />
<br />
=== Зачем создавать Live CD? ===<br />
Часто бывает удобно иметь под рукой версию Arch Linux, работающую полностью с CD. Live CD может использоваться для восстановления вашей системы, для проверки новых машин или оборудования на совместимость с GNU/Linux, для создания демонстрационного диска для показа ваших проектов и многого другого.<br />
<br />
=== Прежде чем начать, вам потребуется ===<br />
# Для создания iso-образа, форматирования файловой системы и для изменения размера образа, вам понадобятся пакеты "cdrtools" и "e2fsprogs".<br />
pacman -S cdrtools<br />
pacman -S e2fsprogs<br />
# Также вам понадобятся создать на жестком диске<br />
## 1 раздел для установки дистрибутива<br />
## 1 директория на вашем активном разделе, чтобы сохранить образ для записи на диск. <br />
# CD-RW диск для записи и проверки разных версий образов, и пишущий привод.<br />
# Установить пакет для записи CD (если вы не знаете, что выбрать, устанавливайте "k3b").<br />
pacman -S k3b<br />
<br />
=== Детали ===<br />
Для примера, в этой статье мы рассмотрим создание mini Arch Linux Live CD (110MB). Он основан на базовых пакетах, установленных с помощью Arch Linux's CD installer версии 0.5<br />
<br />
==== Зазрузитесь с помощью Arch Linux CD installer и установите базовые пакеты ====<br />
<br />
Установив пакеты, установите ядро, но не устанавливайте загрузчик. Также вы можете копировать образ вашего собсвенного ядра (<tt>/boot/vmlinuz</tt>), и соответствующих ему модулей (<tt>/lib/modules/2.x.x</tt>) с вашей системы. Чтобы загрузиться в новую систему, настройте соответствующим образом ваш загрузчик.<br />
<br />
'''Совет:''' Для проверки на наличие ошибок в процессе загрузки, примонтируйте раздел с новой системой в ваш Arch Linux и исправьте следующие строчки в файле <tt>/etc/rc.local</tt> для приостановки системы перед аутентификацей пользователя:<br />
<br />
echo "Press any key to continue..."<br />
read KEY<br />
<br />
'''Внимание:''' Не забудьте убрать паузу!!<br />
<br />
В вашей системе, в <tt>/root</tt> создайте каталог "''mylivecd''" и два подкаталога: "''isolinux''" и "''system''" (вы можете использовать свои имена).<br />
<br />
# cd /root<br />
# mkdir mylivecd<br />
# cd mylivecd<br />
# mkdir isolinux<br />
# mkdir system<br />
<br />
==== Установите isolinux. Скопируйте его с Live CD====<br />
<br />
# Загрузите "''isolinux.bin''" и "''boot.cat''" в каталог <tt>/root/mylivecd/isolinux/</tt> :<br />
http://amlug.bliss-solutions.org/live-cd/distfiles/0.5.1/isolinux/<br />
# Создайте загрузочное сообщение "''boot.msg''" (текстовый файл) и запишите туда краткое описание вашего live CD. Сохраните этот файл в <tt>/root/mylivecd/isolinux/</tt>. <br />
Пример <tt>boot.msg</tt>:<br />
This is a Live CD test ver. 0.1.<br />
F1 - boot message<br />
F2 - package list<br />
<br />
Press Enter<br />
# Создайте "''isolinux.cfg''" и поместите туда следующий текст. Сохраните файл в <tt>/root/mylivecd/isolinux/</tt><br />
prompt 1<br />
timeout 0<br />
display boot.msg<br />
F1 boot.msg<br />
F2 package.txt<br />
default vmlinuz initrd=miniroot.gz init=/sbin/init ramdisk_size=100000 load_ramdisk=1 prompt_ramdisk=0 vga=788 root=/dev/ram0<br />
<br />
==== Создайте один miniroot образ ====<br />
Miniroot загружается в оперативную память во время загрузки и действует также как и на HD. Используйте файловую систему Ext2.<br />
<br />
'''Внимание:''' Настройка miniroot зависит от <tt>/etc/inittab</tt>, <tt>/etc/rc.sysinit</tt>, <tt>/etc/rc.multi</tt>, и <tt>/etc/rc.shutdown</tt>. Перед созданием miniroot-образа, внимательно изучите эти файлы и продумайте как они могут быть изменены при необходимости. В каталоге <tt>/sbin</tt> вам понадобятся слеующие файлы:<br><br />
http://amlug.bliss-solutions.org/live-cd/distfiles/0.5.1/miniroot/init/sbin/<br />
<br />
# Создайте текстовый файл "''miniroot''" в <tt>/root/mylivecd</tt> с файловой системой Ext2. Размер образа зависит от того, как много пакетов вы собираетесь включить в него. В нашем примере мы создадим образ 15.8MB. Рекомендуется создавать образ как можно меньше. Когда будете готовы, примонтируйте образ например в <tt>/mnt/image</tt><br />
# cd /root/mylivecd<br />
# touch miniroot<br />
# mkfs.ext2 miniroot 15840 (press "y" for each question)<br />
# mkdir /mnt/image<br />
# mount -t auto -o loop miniroot /mnt/image<br />
# rm -R /mnt/image/lost+found<br />
'''Внимание: ''' Если вы хотите поменять размер, используйте следующие команды (для уменьшения размера до 11.5MB):<br />
# e2fsck -f miniroot (press "y" for /lost+found not found. Create<y>?)<br />
# resize2fs miniroot 11520<br />
# Примонтируйте раздел с новой системой. Копируйте файлы и каталоги из нового раздела в <tt>/mnt/image</tt><br />
# mkdir /mnt/tmp<br />
# mount /dev/hda3 /mnt/tmp<br />
# cp -Ra /mnt/tmp/bin /mnt/image/<br />
# cp -Ra /mnt/tmp/etc /mnt/image/<br />
# cp -Ra /mnt/tmp/sbin /mnt/image/<br />
# cp -Ra /mnt/tmp/tmp /mnt/image/<br />
# cp -Ra /mnt/tmp/var /mnt/image/<br />
# Копируйте <tt>/usr</tt>, <tt>/lib/modules/2.x.x/</tt>, <tt>/lib/modules/evms/</tt>, <tt>/lib/modules/security/</tt> в <tt>/root/mylivecd/system/</tt> :<br />
# cp -Ra /mnt/tmp/usr /root/mylivecd/system/<br />
# cp -Ra /mnt/tmp/opt /root/mylivecd/system/<br />
# mkdir /root/mylivecd/system/lib<br />
# cp -Ra /mnt/tmp/lib/modules /root/mylivecd/system/lib/<br />
# cp -Ra /mnt/tmp/lib/evms /root/mylivecd/system/lib/<br />
# cp -Ra /mnt/tmp/lib/security /root/mylivecd/system/lib/<br />
'''Внимание: ''': Если <tt>/bin</tt> и <tt>/sbin</tt> слишком велики вы можете попробовать использовать busybox:<br />
http://www.busybox.net/<br />
'''Или''' использовать временные папки, которые будут удалены или переименованы при загрузке <tt>/rc.sysinit</tt>. Здесь пример как это можно сделать:<br />
http://amlug.bliss-solutions.org/live-cd/distfiles/0.5.1/miniroot/init/sbin/rc.sysinit<br />
# Создайте следующие каталоги в <tt>/mnt/image</tt> и копируйте <tt>/mnt/tmp/lib</tt> файлы в <tt>/mnt/image/lib/</tt> (не копируйте <tt>/mnt/tmp/lib/module</tt>, <tt>~/lib/evms</tt> и <tt>~/lib/security)</tt>:<br />
# cd /mnt/image<br />
# mkdir dev<br />
# mkdir home<br />
# mkdir lib<br />
# mkdir mnt/cdrom<br />
# mkdir mnt/floppy<br />
# mkdir root<br />
# mkdir proc<br />
# mkdir lib/modules<br />
# cd /mnt/tmp/lib/<br />
# cp -a l* /mnt/image/lib/<br />
# С каталогами <tt>/usr</tt> и <tt>/opt</tt> создайте ссылки в <tt>/mnt/image/</tt>. Также создайте ссылку на <tt>/system/lib/modules/2.x.x/</tt>. Копируйте образ ядра в <tt>/root/mylivecd/isolinux/</tt>:<br />
# cd /mnt/image<br />
# ln -sf /mnt/cdrom/system/usr usr<br />
# ln -sf /mnt/cdrom/system/opt opt<br />
# cd /mnt/image/lib/modules/<br />
# ln -sf /mnt/cdrom/system/lib/modules/2.4.22 2.4.22<br />
# cd /mnt/image/lib/<br />
# ln -sf /mnt/cdrom/system/lib/evms evms<br />
# ln -sf /mnt/cdrom/system/lib/security security<br />
# cp /mnt/tmp/boot/vmlinuz /root/mylivecd/isolinux/<br />
# Исправьте <tt>/mnt/image/etc/fstab как показано здесь:</tt><br />
/dev/root / ext2 defaults 0 0<br />
none /proc proc defaults 0 0<br />
/dev/floppy/0 /mnt/floppy auto user,rw,noauto,unhide 0 0<br />
/dev/cdroms/cdrom0 /mnt/cdrom iso9660 ro,user,noauto,unhide 0 0<br />
# Добавьте следующие строчки в файл <tt>rc.sysinit</tt> (после строки: <tt>stat_busy "Mounting Local Filesystems"</tt>) в <tt>/mnt/image/etc/</tt>. Это позволит чтение файлов из каталога /system с CD.<br />
/bin/mount /dev/cdroms/cdrom0 /mnt/cdrom -o ro -t iso9660<br />
# Сожмите miniroot и поместите miniroot.gz в /root/mylivecd/isolinux/<br />
# cd /root/mylivecd/<br />
# umount /mnt/image<br />
# gzip -c miniroot >> miniroot.gz<br />
# mv miniroot.gz isolinux/<br />
# Перед компиляцией, переместите <tt>/root/mylivecd/miniroot</tt> в безопасное место. Создайте временный каталог для iso образа (не внутри <tt>/mylivecd</tt>). Выполните следующий код (не забудьте "." в конце строки):<br />
# cd /root/mylivecd<br />
# mkdir /root/isotmp<br />
# Создайте ISO:<br />
mkisofs -o /root/isotmp/test-livecd-0.1.iso -R -V "Test 0.1" \<br />
-T -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot \<br />
-boot-load-size 4 -boot-info-table -A "Test Live CD 0.1" .<br />
<br />
==== Заключение ====<br />
Надеемся это руководство помогло вам. Удачи!<br />
<br />
------<br />
<br />
=== Дополнительная информация:===<br />
<br />
Исходные коды и содержимое AMLUG Live CD:<br />
http://www.amlug.net/new-projects/forum/index.php?showforum=23<br />
<br />
Создание Live CD в других дистрибутивах:<br />
http://www.babytux.org/articles/howto/how2livecd.php<br />
----</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Font_configuration_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=32283
Font configuration (Русский)
2007-11-11T13:12:26Z
<p>Cucullus: /* Не люблю <Шрифт Такой> и хочу использовать вместо него <Шрифт Сякой> */</p>
<hr />
<div>[[Category:XServer (Русский)]]<br />
[[Category:Tutorials (Русский)]]<br />
[[Category:Русский]]<br />
[[Category:Руководства]]<br />
[[Category:Красивости]]<br />
<br />
by PhrakTure<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Xorg_Font_Configuration}}<br />
{{i18n_entry|Русский|Xorg_Font_Configuration_(Русский)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}} <br />
==X.org Font Configuration и украшательство==<br />
:Наиболее полная информация тут: [http://www.x.org/X11R6.8.2/doc/fonts.html Документация по шрифтам Xorg Font].<br />
:Информацию по модулю freetype для X.org ищите здесь: [http://freetype.sourceforge.net/freetype2/ FreeType2 Project Page].<br />
:Много общей информации по шрифтам в Линукс тут:[http://avi.alkalay.net/linux/docs/font-howto/Font.html Optimal Use of Fonts on Linux].<br />
<br />
===Модули xorg.conf===<br />
*freetype - поддержка шрифтов True Type (ttf, ttc), Type1 (pfa, pfb), CID (cid), CFF, Open Type, bitmap (bdf, pcf, snf), Windows (fnt), PFR, and Type42<br />
*type1 - поддержка шрифтов Type1 (pfa, pfb) and CID (cid)<br />
*speedo - поддержка шрифтов Bitstream Speedo (spd)<br />
*xtt - поддержка True Type (ttf, ttc) шрифтов ('''конфликтует с модулем freetype''')<br />
*bitmap - поддержка bitmap (bdf, pcf, snf) шрифтов<br />
<br />
Как вы видите, freetype предоставляет те же возможности что и все остальные модули. Модуль xtt конфликтует с модулем freetype.<br />
<br />
==Пути шрифтов X.org и /etc/fonts/==<br />
===Пути шрифтов xorg.conf===<br />
Путь к шрифтам прописаный в файле xorg.conf используется только для не-Xft шрифтов. Хорошо бы указать здесь побольше шрифтов. Приложения не поддерживающие Xft будут искать шрифты по пути шрифтов X сервера. В частности я держу здесь минимум шрифтов - для xterm и его собратьев.<br />
<br />
===/etc/fonts/ папки со шрифтами===<br />
conf файлы в /etc/fonts (fonts.conf и local.conf) используются fontconfig (шрифты Xft). fonts.conf никогда не должен изменяться, и все изменения должны производиться в local.conf (для общесистемных изменений) или ~/.fonts.conf (для конкретного пользователя).<br />
Файлы в /etc/fonts/conf.d начинаются с цифры и заканчиваются .conf.<br />
<br />
Папки, указанные в fonts.conf (/usr/share/fonts и ~/.fonts) для использования fontconfig сканируются с помощью fc-cache. Все шрифты должны быть расположены в этих папках. После установки новых шрифтов, чтобы система их увидела, необходимо выполнить '''fc-cache -fv'''.<br />
<br />
===Добавляем новые шрифты===<br />
Если вы скопировали в папку со шрифтами новые шрифты, то они пока всего лишь файлы в файловой системе. Чтобы сообщить системе о новых шрифтах надо запустить несколько дополнительных утилит.<br />
/usr/bin/fc-cache<br />
Это обновит кэш fontconfig, что позволит fontconfig искать нужные шрифты среди вновь установленых(смотрите секцию выше про /etc/fonts)<br />
/usr/bin/mkfontscale<br />
/usr/bin/mkfontdir<br />
ln -s /usr/X11R6/lib/X11/fonts/encodings/encodings.dir encodings.dir<br />
<br />
Запускать эти утилиты надо из папки с новыми шрифтами. mkfontscale создаст файл fonts.scale а mkfontdir создаст файл fonts.dir. Эти файлы используются X сервером, и нужны только для того, чтобы шрифты были доступны через FontPath из X.org. The Програмная связь шрифтов с кодировками позволяет X Server использовать новые шрифты со всеми поддерживаемыми кодировками. После всего этого, в папке для шрифтов у вас должно быть 3 новых файла: fonts.scale, fonts.dir, и encodings.dir.<br />
<br />
===Утилиты fc-list и xlsfont===<br />
Эти утилиты из командной строки показывают все доступные шрифты для каждой подсистемы. fc-list покажет все шрифты fontconfig, в то время, как xlsfont покажет все X шрифты. Это может быть полезным в комбинации с grep, т.о. чтобы увидеть все доступные шрифты bitstream надо набрать "xlsfonts || grep -i bitstream".<br />
<br />
==Места откуда можно скачать шрифты==<br />
*[http://www.users.bigpond.net.au/gavindi/ Arkpandora TrueType fonts] - Замена шрифтам Arial и Times New Roman.<br />
*[http://themes.freshmeat.net/projects/ppantsfonts/ PPants Angular Font Collection]-небольшая коллекция Angular-стилизованных шрифтов шириной в 6 пикселов. <br />
*[http://www.tobias-jung.de/seekingprofont/ Profont]-шрифты для программирования.<br />
<br />
==Полезности(Goodies)==<br />
===Мои шрифты выглядят ужасно - Я всё правильно настроил, но такое ощущение, что у меня просто нет хороших шрифтов.===<br />
Я бы предположил, что следующие пакеты из pacman-а исправят это:<br />
pacman -S ttf-ms-fonts ttf-cheapskate artwiz-fonts<br />
<br />
===У меня есть несколько приложений под Gtk+ 2.2 и ниже, но шрифты выглядят ужасно.===<br />
Да, это бывает. В современных приложениях GTK шрифты Xft включены по умолчанию, тем не менее, до версии 2.2 этого не было. Возможно стоит обновить эти приложения до более нового GTK. Если такой опции нет, тогда добавив строку '''export GDK_USE_XFT=1''' в файл глобальных установок (/etc/profile, /etc/profile.d/gnome.sh, ~/.xinitrc, и т.п.) вы включите Xft для старых приложений<br />
<br />
===У меня сходная проблема как и выше со старыми приложениями, основанными на Qt.===<br />
Похожее решение, добавьте '''export QT_XFT=true''' куда-либо в загрузочный файл.<br />
<br />
===Шрифты в приложениях Gtk при использовании KDE слишком маленькие===<br />
Установите gtk-qt-engine:<br />
pacman -Sy gtk-qt-engine<br />
*Измените размер шрифта для приложений Gtk в `Control Center' -> `Appearance & Themes' -> `GTK Styles and Fonts'.<br />
<br />
===Интерпретатор bytecode делает мои шрифты некрасивыми, к тому же он наглухо вкомпилен, что мне делать, перекомпилировать?===<br />
Нет, не совсем. Встроенное во Freetype auto-hinting выключается достаточно просто. В некоторых дистрибутивах интерпретатор bytecode вкомпилен и включен по умолчанию. Как результат - интерпретатор bytecode перекрывает autohinter freetype-а(которым так гордятся разработчики). Чтобы всё же включить autohinter добавьте следующее в /etc/fonts/local.conf или ~/.fonts.conf<br />
<!-- Использование Autohinter --><br />
<match target="pattern"><br />
<edit name=<code>"autohint" mode=</code>"assign"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
Вопрос: Я не понимаю... Интерпретатор bytecode interpreter предполагался как долговременная лучшая замена для autohinter, так что я не понимаю, зачем кому-то использовать autohinter.<br />
Ответ: Похоже, что интерпретатор bytecode в ветке 2.3 явно слабоват. О нем есть вот такой пост на нашем форуме: http://bbs.archlinux.org/viewtopic.php?id=29976 Этот код сделал мои шрифты гораздо лучше. После перезагрузки всё вернулось на свои места - без понятия почему.<br />
<br />
===Autohint работает отлично, но только не для жирных шрифтов. Как можно выключить его только для жирных шрифтов?===<br />
Autohinter может сделать ваши шрифты красивее, но часто может сделать их слишком широкими. Это особенно раздражает при использовании жирных шрифтов. К счастью, autohinter можно выключить только для жирных шрифтов и оставить включенным для остальных.<br />
*Включите autohinter (см. выше) и добавьте в /etc/fonts/local.conf или ~/.fonts.conf следующее: <br />
<match target="font"><br />
<test name=<code>"weight" compare=</code>"more"><br />
<const>medium</const><br />
</test><br />
<edit name=<code>"autohint" mode=</code>"assign"><br />
<bool>false</bool><br />
</edit><br />
</match><br />
<br />
===Мой TFT/DFP/LCD-дисплей использует DVI-кабель, и шрифты выглядят нечётко и размыто===<br />
Такое происходит из-за различий между CRT и не-CRT мониторами. Исправить данную проблему можно, включив субпиксельное отображение. Откройте файл /etc/fonts/local.conf для правки и найдите закомментированную секцию "Enable subpixel rendering". Раскомментируйте для включения. Заметим, что это нисколько не улучшит качество изображения на CRT-мониторах. Возможные значения для секции '''const''' такие: rgb, bgr, vrgb, bgrv, и none.<br />
<!-- Enable sub-pixel rendering --><br />
<match target="font"><br />
<test qual=<code>"all" name=</code>"rgba"><const>unknown</const></test><br />
<edit name=<code>"rgba" mode=</code>"assign"><const>rgb</const></edit><br />
</match><br />
<br />
===Хочу отключить сглаживание для шрифтов меньше определённого размера.===<br />
В файле /etc/fonts/local.conf есть соответствующий пример. Он закомментирован, так же как и секция subpixel rendering. Измените '''compare="less_eq"''' и '''<int>12</int>''' на желаемые значения, сконфигурировав таким образом операцию сравнения и предельного размера шрифта соответственно.<br />
<!-- Disable anti-aliasing for fonts that are size <=12 --><br />
<match target="pattern"><br />
<test qual="any" name="size" compare="less_eq"><br />
<int>12</int><br />
</test><br />
<edit name="antialias" mode="assign"><bool>false</bool></edit><br />
</match><br />
<br />
===I'm using MS TrueType fonts (verdana) and want to enable anti-aliasing but only for bigger fonts that look too jagged.===<br />
<?xml version="1.0"?><br />
<!DOCTYPE fontconfig SYSTEM "fonts.dtd"><br />
<fontconfig><br />
<br />
<match target="font" ><br />
<test compare<code>"more" name</code>"size" qual="any" ><br />
<double>12</double><br />
</test><br />
<edit mode<code>"assign" name</code>"antialias" ><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
<match target="font" ><br />
<test compare<code>"more" name</code>"pixelsize" qual="any" ><br />
<double>17</double><br />
</test><br />
<edit mode<code>"assign" name</code>"antialias" ><br />
<bool>true</bool><br />
</edit><br />
</match><br />
</fontconfig><br />
<br />
===Я хочу добавить больше шрифтов.===<br />
Сохраните ваши шрифты в директории и добавьте путь до нее в файл '''/etc/fonts/local.conf'''<br />
<br />
<!-- Additional font directories --><br />
<dir>/путь/до/директории</dir><br />
<br />
===I want my font sizes to match my dpi settings===<br />
This goes into '''/etc/fonts/local.conf'''. This setting should match your dpi settings in either xorg.conf or your startx command. Use xdpyinfo to get your current dpi setting. Most people recommend/use a value of 96 or 100. Changing and setting the dpi of X is beyond the scope of this document (see [[Xorg#Display_Size.2FDPI|Xorg DisplaySize/DPI]]).<br />
<!-- Setup for DPI = 100 --><br />
<match target="pattern"><br />
<edit name=<code>"dpi" mode=</code>"assign"><double>100</double></edit><br />
</match><br />
<br />
===Не люблю <Шрифт Такой> и хочу использовать вместо него <Шрифт Сякой>===<br />
<br />
Наиболее подходящий способ сделать это -- добавить нижеприведённый фрагмент XML кода в /etc/fonts/local.conf. В данном случае Nimbus Sans будет использоваться вместо Helvetica:<br />
<br />
<match target="pattern"><br />
<test name="family"><string>Helvetica</string></test><br />
<edit name="family" mode="assign"><br />
<string>Nimbus Sans</string><br />
</edit><br />
</match><br />
<br />
<br />
Ещё одни вариант -- это использование "предпочтительного" (preferred) шрифта, но это будет работать только если '''оригинальный шрифт отсутствует в системе'''. Таким образом, вышеприведённый пример будет выглядеть так:<br />
<br />
<!-- Replace Helvetica with Bitstream Vera Sans Mono --><br />
<!-- Note, an alias for Helvetica should already exist in default local.conf files --><br />
<alias><br />
<family>Helvetica </family><br />
<prefer><family>Bitstream Vera Sans Mono</family></prefer><br />
<default><family>fixed</family></default><br />
</alias><br />
<br />
===I have tons of disgusting pixel fonts that I don't want===<br />
The only two fonts that you absolutely have to have in order to start X are 'cursor' and 'fixed', both of which are in the fonts/misc directory. If you want to get rid of all the pixel fonts besides these two, you can delete all the files in the misc directory besides cursor.pcf.gz and all the fonts that are similar to either 9x18.pcf.gz or 9x18-ISO8859-1.pcf.gz. When I deleted all the fonts besides those from the misc directory, I had about 337 files still in it, so if you have a lot less than that you should probably put them back before restarting X.<br />
<br />
===Something or someone disabled all my non-scalable (bitmap) fonts, I want them back===<br />
By default, fontconfig 2.3.2-4 and higher will disable the use of bitmap fonts. This setting is managed in /etc/fonts/conf.d/10-no-bitmaps.conf, or in higher versions, /etc/fonts/conf.d/10-bitmaps.conf.<br />
To enable bitmap fonts and keep them enabled after upgrades of fontconfig, place a symlink from yes-bitmaps.conf to 10-bitmaps.conf, overwriting the symlink to no-bitmaps.conf.<br />
<br />
===Fake bold & italic styles for incomplete fonts===<br />
Freetype already has had this capability for some time, but only if app asks so (which never happens) - it's not going to add Bold or Italic style for those regular-only fonts anyway. To make up them, you need to edit ''/usr/share/fonts/fonts.cache-1'' manually (and keep your modification somewhere because font update (fc-cache) overrides it). Assume you have a font Dupree:<br />
"dupree.ttf" 0 "Dupree:style=Regular:slant=0:weight=80:width=100:foundry=unknown:index=0:outline=True:....<br />
Duplicate the line, change ''style=Regular'' to ''style=Bold'' or other styles you want. Also change ''slant=0'' to ''slant=100'' for italic, ''weight=80'' to ''weight=200'' for bold (combine for bold italic):<br />
"dupree.ttf" 0 "Dupree:style=Bold Italic:slant=100:weight=200:width=100:foundry=unknown:index=0:outline=True:....<br />
Now add necessary modification to ''~/.fonts.conf'':<br />
<match target="font"><br />
<test name="family" qual="any"><br />
<string>Dupree</string><br />
&lt;!-- other fonts here .... --&gt;<br />
</test><br />
<test compare="more_eq" name="weight"><int>140</int></test><br />
<edit mode="assign" name="embolden"><bool>true</bool></edit><br />
</match><br />
<match target="font"><br />
<test name="family" qual="any"><br />
<string>Dupree</string><br />
&lt;!-- other fonts here .... --&gt;<br />
</test><br />
<test compare="more_eq" name="slant"><int>80</int></test><br />
<edit mode="assign" name="matrix"><br />
<times><br />
<name>matrix</name><br />
<matrix><br />
<double>1</double><double>0.2</double><br />
<double>0</double><double>1</double><br />
</matrix><br />
</times><br />
</edit><br />
</match><br />
(Note that you can use embolden for bold fonts as well - to make them even bolder)<br />
<br />
===A web developer's fonts/local.conf taken from arch forums===<br />
Backup your current config and give this one a try. I noticed it especially improved the Georgia font.<br />
<pre><br />
<?xml version="1.0"?><br />
<!DOCTYPE fontconfig SYSTEM "fonts.dtd"><br />
<br />
<!-- the cathectic LCD tweaks, from linuxquestions.org,<br />
http://www.linuxquestions.org/questions/showthread.php?postid=1361098#post1361098 --><br />
<br />
<fontconfig><br />
<br />
<!-- Disable sub-pixel rendering.<br />
X detects it anyway, and if you set this as well, it just looks really horrible --><br />
<match target="font" ><br />
<edit mode="assign" name="rgba" ><br />
<const>none</const><br />
</edit><br />
</match><br />
<match target="font" ><br />
<edit mode="assign" name="hinting"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<match target="font" ><br />
<edit mode="assign" name="hintstyle"><br />
<const>hintfull</const><br />
</edit><br />
</match><br />
<br />
<!-- The first part of the 'magic.'<br />
This makes the fonts start to look nice,<br />
but some of the shapes will be distorted, so hinting is needed still --><br />
<match target="font" ><br />
<edit mode="assign" name="antialias"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
<!-- Autohinter is not turned on automatically.<br />
Only disable this if you have recompiled Freetype with the bytecode interpreter,<br />
which is run automatically.<br /> --><br />
<match target="pattern" ><br />
<edit mode="assign" name="autohint"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<match target="font"><br />
<test name="weight" compare="more"><br />
<const>medium</const><br />
</test><br />
<edit name="autohint" mode="assign"><br />
<bool>false</bool><br />
</edit><br />
</match><br />
<!-- Helvetica is a non true type font, and will look bad.<br />
This replaces it with whatever is the default sans-serif font --><br />
<match target="pattern" name="family" ><br />
<test name="family" qual="any" ><br />
<string>Helvetica</string><br />
</test><br />
<edit mode="assign" name="family" ><br />
<string>sans-serif</string><br />
</edit><br />
</match><br />
<dir>~/.fonts</dir><br />
</fontconfig><br />
</pre></div>
Cucullus
https://wiki.archlinux.org/index.php?title=Font_configuration_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=32282
Font configuration (Русский)
2007-11-11T13:11:00Z
<p>Cucullus: /* I don't like font <enter name here> and want to use <another font name> instead */</p>
<hr />
<div>[[Category:XServer (Русский)]]<br />
[[Category:Tutorials (Русский)]]<br />
[[Category:Русский]]<br />
[[Category:Руководства]]<br />
[[Category:Красивости]]<br />
<br />
by PhrakTure<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Xorg_Font_Configuration}}<br />
{{i18n_entry|Русский|Xorg_Font_Configuration_(Русский)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}} <br />
==X.org Font Configuration и украшательство==<br />
:Наиболее полная информация тут: [http://www.x.org/X11R6.8.2/doc/fonts.html Документация по шрифтам Xorg Font].<br />
:Информацию по модулю freetype для X.org ищите здесь: [http://freetype.sourceforge.net/freetype2/ FreeType2 Project Page].<br />
:Много общей информации по шрифтам в Линукс тут:[http://avi.alkalay.net/linux/docs/font-howto/Font.html Optimal Use of Fonts on Linux].<br />
<br />
===Модули xorg.conf===<br />
*freetype - поддержка шрифтов True Type (ttf, ttc), Type1 (pfa, pfb), CID (cid), CFF, Open Type, bitmap (bdf, pcf, snf), Windows (fnt), PFR, and Type42<br />
*type1 - поддержка шрифтов Type1 (pfa, pfb) and CID (cid)<br />
*speedo - поддержка шрифтов Bitstream Speedo (spd)<br />
*xtt - поддержка True Type (ttf, ttc) шрифтов ('''конфликтует с модулем freetype''')<br />
*bitmap - поддержка bitmap (bdf, pcf, snf) шрифтов<br />
<br />
Как вы видите, freetype предоставляет те же возможности что и все остальные модули. Модуль xtt конфликтует с модулем freetype.<br />
<br />
==Пути шрифтов X.org и /etc/fonts/==<br />
===Пути шрифтов xorg.conf===<br />
Путь к шрифтам прописаный в файле xorg.conf используется только для не-Xft шрифтов. Хорошо бы указать здесь побольше шрифтов. Приложения не поддерживающие Xft будут искать шрифты по пути шрифтов X сервера. В частности я держу здесь минимум шрифтов - для xterm и его собратьев.<br />
<br />
===/etc/fonts/ папки со шрифтами===<br />
conf файлы в /etc/fonts (fonts.conf и local.conf) используются fontconfig (шрифты Xft). fonts.conf никогда не должен изменяться, и все изменения должны производиться в local.conf (для общесистемных изменений) или ~/.fonts.conf (для конкретного пользователя).<br />
Файлы в /etc/fonts/conf.d начинаются с цифры и заканчиваются .conf.<br />
<br />
Папки, указанные в fonts.conf (/usr/share/fonts и ~/.fonts) для использования fontconfig сканируются с помощью fc-cache. Все шрифты должны быть расположены в этих папках. После установки новых шрифтов, чтобы система их увидела, необходимо выполнить '''fc-cache -fv'''.<br />
<br />
===Добавляем новые шрифты===<br />
Если вы скопировали в папку со шрифтами новые шрифты, то они пока всего лишь файлы в файловой системе. Чтобы сообщить системе о новых шрифтах надо запустить несколько дополнительных утилит.<br />
/usr/bin/fc-cache<br />
Это обновит кэш fontconfig, что позволит fontconfig искать нужные шрифты среди вновь установленых(смотрите секцию выше про /etc/fonts)<br />
/usr/bin/mkfontscale<br />
/usr/bin/mkfontdir<br />
ln -s /usr/X11R6/lib/X11/fonts/encodings/encodings.dir encodings.dir<br />
<br />
Запускать эти утилиты надо из папки с новыми шрифтами. mkfontscale создаст файл fonts.scale а mkfontdir создаст файл fonts.dir. Эти файлы используются X сервером, и нужны только для того, чтобы шрифты были доступны через FontPath из X.org. The Програмная связь шрифтов с кодировками позволяет X Server использовать новые шрифты со всеми поддерживаемыми кодировками. После всего этого, в папке для шрифтов у вас должно быть 3 новых файла: fonts.scale, fonts.dir, и encodings.dir.<br />
<br />
===Утилиты fc-list и xlsfont===<br />
Эти утилиты из командной строки показывают все доступные шрифты для каждой подсистемы. fc-list покажет все шрифты fontconfig, в то время, как xlsfont покажет все X шрифты. Это может быть полезным в комбинации с grep, т.о. чтобы увидеть все доступные шрифты bitstream надо набрать "xlsfonts || grep -i bitstream".<br />
<br />
==Места откуда можно скачать шрифты==<br />
*[http://www.users.bigpond.net.au/gavindi/ Arkpandora TrueType fonts] - Замена шрифтам Arial и Times New Roman.<br />
*[http://themes.freshmeat.net/projects/ppantsfonts/ PPants Angular Font Collection]-небольшая коллекция Angular-стилизованных шрифтов шириной в 6 пикселов. <br />
*[http://www.tobias-jung.de/seekingprofont/ Profont]-шрифты для программирования.<br />
<br />
==Полезности(Goodies)==<br />
===Мои шрифты выглядят ужасно - Я всё правильно настроил, но такое ощущение, что у меня просто нет хороших шрифтов.===<br />
Я бы предположил, что следующие пакеты из pacman-а исправят это:<br />
pacman -S ttf-ms-fonts ttf-cheapskate artwiz-fonts<br />
<br />
===У меня есть несколько приложений под Gtk+ 2.2 и ниже, но шрифты выглядят ужасно.===<br />
Да, это бывает. В современных приложениях GTK шрифты Xft включены по умолчанию, тем не менее, до версии 2.2 этого не было. Возможно стоит обновить эти приложения до более нового GTK. Если такой опции нет, тогда добавив строку '''export GDK_USE_XFT=1''' в файл глобальных установок (/etc/profile, /etc/profile.d/gnome.sh, ~/.xinitrc, и т.п.) вы включите Xft для старых приложений<br />
<br />
===У меня сходная проблема как и выше со старыми приложениями, основанными на Qt.===<br />
Похожее решение, добавьте '''export QT_XFT=true''' куда-либо в загрузочный файл.<br />
<br />
===Шрифты в приложениях Gtk при использовании KDE слишком маленькие===<br />
Установите gtk-qt-engine:<br />
pacman -Sy gtk-qt-engine<br />
*Измените размер шрифта для приложений Gtk в `Control Center' -> `Appearance & Themes' -> `GTK Styles and Fonts'.<br />
<br />
===Интерпретатор bytecode делает мои шрифты некрасивыми, к тому же он наглухо вкомпилен, что мне делать, перекомпилировать?===<br />
Нет, не совсем. Встроенное во Freetype auto-hinting выключается достаточно просто. В некоторых дистрибутивах интерпретатор bytecode вкомпилен и включен по умолчанию. Как результат - интерпретатор bytecode перекрывает autohinter freetype-а(которым так гордятся разработчики). Чтобы всё же включить autohinter добавьте следующее в /etc/fonts/local.conf или ~/.fonts.conf<br />
<!-- Использование Autohinter --><br />
<match target="pattern"><br />
<edit name=<code>"autohint" mode=</code>"assign"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
Вопрос: Я не понимаю... Интерпретатор bytecode interpreter предполагался как долговременная лучшая замена для autohinter, так что я не понимаю, зачем кому-то использовать autohinter.<br />
Ответ: Похоже, что интерпретатор bytecode в ветке 2.3 явно слабоват. О нем есть вот такой пост на нашем форуме: http://bbs.archlinux.org/viewtopic.php?id=29976 Этот код сделал мои шрифты гораздо лучше. После перезагрузки всё вернулось на свои места - без понятия почему.<br />
<br />
===Autohint работает отлично, но только не для жирных шрифтов. Как можно выключить его только для жирных шрифтов?===<br />
Autohinter может сделать ваши шрифты красивее, но часто может сделать их слишком широкими. Это особенно раздражает при использовании жирных шрифтов. К счастью, autohinter можно выключить только для жирных шрифтов и оставить включенным для остальных.<br />
*Включите autohinter (см. выше) и добавьте в /etc/fonts/local.conf или ~/.fonts.conf следующее: <br />
<match target="font"><br />
<test name=<code>"weight" compare=</code>"more"><br />
<const>medium</const><br />
</test><br />
<edit name=<code>"autohint" mode=</code>"assign"><br />
<bool>false</bool><br />
</edit><br />
</match><br />
<br />
===Мой TFT/DFP/LCD-дисплей использует DVI-кабель, и шрифты выглядят нечётко и размыто===<br />
Такое происходит из-за различий между CRT и не-CRT мониторами. Исправить данную проблему можно, включив субпиксельное отображение. Откройте файл /etc/fonts/local.conf для правки и найдите закомментированную секцию "Enable subpixel rendering". Раскомментируйте для включения. Заметим, что это нисколько не улучшит качество изображения на CRT-мониторах. Возможные значения для секции '''const''' такие: rgb, bgr, vrgb, bgrv, и none.<br />
<!-- Enable sub-pixel rendering --><br />
<match target="font"><br />
<test qual=<code>"all" name=</code>"rgba"><const>unknown</const></test><br />
<edit name=<code>"rgba" mode=</code>"assign"><const>rgb</const></edit><br />
</match><br />
<br />
===Хочу отключить сглаживание для шрифтов меньше определённого размера.===<br />
В файле /etc/fonts/local.conf есть соответствующий пример. Он закомментирован, так же как и секция subpixel rendering. Измените '''compare="less_eq"''' и '''<int>12</int>''' на желаемые значения, сконфигурировав таким образом операцию сравнения и предельного размера шрифта соответственно.<br />
<!-- Disable anti-aliasing for fonts that are size <=12 --><br />
<match target="pattern"><br />
<test qual="any" name="size" compare="less_eq"><br />
<int>12</int><br />
</test><br />
<edit name="antialias" mode="assign"><bool>false</bool></edit><br />
</match><br />
<br />
===I'm using MS TrueType fonts (verdana) and want to enable anti-aliasing but only for bigger fonts that look too jagged.===<br />
<?xml version="1.0"?><br />
<!DOCTYPE fontconfig SYSTEM "fonts.dtd"><br />
<fontconfig><br />
<br />
<match target="font" ><br />
<test compare<code>"more" name</code>"size" qual="any" ><br />
<double>12</double><br />
</test><br />
<edit mode<code>"assign" name</code>"antialias" ><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
<match target="font" ><br />
<test compare<code>"more" name</code>"pixelsize" qual="any" ><br />
<double>17</double><br />
</test><br />
<edit mode<code>"assign" name</code>"antialias" ><br />
<bool>true</bool><br />
</edit><br />
</match><br />
</fontconfig><br />
<br />
===Я хочу добавить больше шрифтов.===<br />
Сохраните ваши шрифты в директории и добавьте путь до нее в файл '''/etc/fonts/local.conf'''<br />
<br />
<!-- Additional font directories --><br />
<dir>/путь/до/директории</dir><br />
<br />
===I want my font sizes to match my dpi settings===<br />
This goes into '''/etc/fonts/local.conf'''. This setting should match your dpi settings in either xorg.conf or your startx command. Use xdpyinfo to get your current dpi setting. Most people recommend/use a value of 96 or 100. Changing and setting the dpi of X is beyond the scope of this document (see [[Xorg#Display_Size.2FDPI|Xorg DisplaySize/DPI]]).<br />
<!-- Setup for DPI = 100 --><br />
<match target="pattern"><br />
<edit name=<code>"dpi" mode=</code>"assign"><double>100</double></edit><br />
</match><br />
<br />
===Не люблю <Шрифт Такой> и хочу использовать вместо него <Шрифт Сякой>===<br />
<br />
Наиболее подходящий способ сделать это -- добавить нижеприведённый фрагмент XML кода в /etc/fonts/local.conf. В данном случае Nimbus Sans будет использоваться вместо Helvetica:<br />
<br />
<match target="pattern"><br />
<test name="family"><string>Helvetica</string></test><br />
<edit name="family" mode="assign"><br />
<string>Nimbus Sans</string><br />
</edit><br />
</match><br />
<br />
<br />
Ещё одни вариант -- это использование "предпочтительного" (preferred) шрифта, но это будет работать только если '''оригинальный шрифт отсутствует в системе'''. Таким образом вышеприведённый пример будет выглядеть так:<br />
<br />
<!-- Replace Helvetica with Bitstream Vera Sans Mono --><br />
<!-- Note, an alias for Helvetica should already exist in default local.conf files --><br />
<alias><br />
<family>Helvetica </family><br />
<prefer><family>Bitstream Vera Sans Mono</family></prefer><br />
<default><family>fixed</family></default><br />
</alias><br />
<br />
===I have tons of disgusting pixel fonts that I don't want===<br />
The only two fonts that you absolutely have to have in order to start X are 'cursor' and 'fixed', both of which are in the fonts/misc directory. If you want to get rid of all the pixel fonts besides these two, you can delete all the files in the misc directory besides cursor.pcf.gz and all the fonts that are similar to either 9x18.pcf.gz or 9x18-ISO8859-1.pcf.gz. When I deleted all the fonts besides those from the misc directory, I had about 337 files still in it, so if you have a lot less than that you should probably put them back before restarting X.<br />
<br />
===Something or someone disabled all my non-scalable (bitmap) fonts, I want them back===<br />
By default, fontconfig 2.3.2-4 and higher will disable the use of bitmap fonts. This setting is managed in /etc/fonts/conf.d/10-no-bitmaps.conf, or in higher versions, /etc/fonts/conf.d/10-bitmaps.conf.<br />
To enable bitmap fonts and keep them enabled after upgrades of fontconfig, place a symlink from yes-bitmaps.conf to 10-bitmaps.conf, overwriting the symlink to no-bitmaps.conf.<br />
<br />
===Fake bold & italic styles for incomplete fonts===<br />
Freetype already has had this capability for some time, but only if app asks so (which never happens) - it's not going to add Bold or Italic style for those regular-only fonts anyway. To make up them, you need to edit ''/usr/share/fonts/fonts.cache-1'' manually (and keep your modification somewhere because font update (fc-cache) overrides it). Assume you have a font Dupree:<br />
"dupree.ttf" 0 "Dupree:style=Regular:slant=0:weight=80:width=100:foundry=unknown:index=0:outline=True:....<br />
Duplicate the line, change ''style=Regular'' to ''style=Bold'' or other styles you want. Also change ''slant=0'' to ''slant=100'' for italic, ''weight=80'' to ''weight=200'' for bold (combine for bold italic):<br />
"dupree.ttf" 0 "Dupree:style=Bold Italic:slant=100:weight=200:width=100:foundry=unknown:index=0:outline=True:....<br />
Now add necessary modification to ''~/.fonts.conf'':<br />
<match target="font"><br />
<test name="family" qual="any"><br />
<string>Dupree</string><br />
&lt;!-- other fonts here .... --&gt;<br />
</test><br />
<test compare="more_eq" name="weight"><int>140</int></test><br />
<edit mode="assign" name="embolden"><bool>true</bool></edit><br />
</match><br />
<match target="font"><br />
<test name="family" qual="any"><br />
<string>Dupree</string><br />
&lt;!-- other fonts here .... --&gt;<br />
</test><br />
<test compare="more_eq" name="slant"><int>80</int></test><br />
<edit mode="assign" name="matrix"><br />
<times><br />
<name>matrix</name><br />
<matrix><br />
<double>1</double><double>0.2</double><br />
<double>0</double><double>1</double><br />
</matrix><br />
</times><br />
</edit><br />
</match><br />
(Note that you can use embolden for bold fonts as well - to make them even bolder)<br />
<br />
===A web developer's fonts/local.conf taken from arch forums===<br />
Backup your current config and give this one a try. I noticed it especially improved the Georgia font.<br />
<pre><br />
<?xml version="1.0"?><br />
<!DOCTYPE fontconfig SYSTEM "fonts.dtd"><br />
<br />
<!-- the cathectic LCD tweaks, from linuxquestions.org,<br />
http://www.linuxquestions.org/questions/showthread.php?postid=1361098#post1361098 --><br />
<br />
<fontconfig><br />
<br />
<!-- Disable sub-pixel rendering.<br />
X detects it anyway, and if you set this as well, it just looks really horrible --><br />
<match target="font" ><br />
<edit mode="assign" name="rgba" ><br />
<const>none</const><br />
</edit><br />
</match><br />
<match target="font" ><br />
<edit mode="assign" name="hinting"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<match target="font" ><br />
<edit mode="assign" name="hintstyle"><br />
<const>hintfull</const><br />
</edit><br />
</match><br />
<br />
<!-- The first part of the 'magic.'<br />
This makes the fonts start to look nice,<br />
but some of the shapes will be distorted, so hinting is needed still --><br />
<match target="font" ><br />
<edit mode="assign" name="antialias"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
<!-- Autohinter is not turned on automatically.<br />
Only disable this if you have recompiled Freetype with the bytecode interpreter,<br />
which is run automatically.<br /> --><br />
<match target="pattern" ><br />
<edit mode="assign" name="autohint"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<match target="font"><br />
<test name="weight" compare="more"><br />
<const>medium</const><br />
</test><br />
<edit name="autohint" mode="assign"><br />
<bool>false</bool><br />
</edit><br />
</match><br />
<!-- Helvetica is a non true type font, and will look bad.<br />
This replaces it with whatever is the default sans-serif font --><br />
<match target="pattern" name="family" ><br />
<test name="family" qual="any" ><br />
<string>Helvetica</string><br />
</test><br />
<edit mode="assign" name="family" ><br />
<string>sans-serif</string><br />
</edit><br />
</match><br />
<dir>~/.fonts</dir><br />
</fontconfig><br />
</pre></div>
Cucullus
https://wiki.archlinux.org/index.php?title=Font_configuration_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=32281
Font configuration (Русский)
2007-11-11T13:00:50Z
<p>Cucullus: /* I don't want my fonts Antialiased under a certain point size. */</p>
<hr />
<div>[[Category:XServer (Русский)]]<br />
[[Category:Tutorials (Русский)]]<br />
[[Category:Русский]]<br />
[[Category:Руководства]]<br />
[[Category:Красивости]]<br />
<br />
by PhrakTure<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Xorg_Font_Configuration}}<br />
{{i18n_entry|Русский|Xorg_Font_Configuration_(Русский)}}<br />
{{i18n_links_end}}<br />
<br />
{{translateme}} <br />
==X.org Font Configuration и украшательство==<br />
:Наиболее полная информация тут: [http://www.x.org/X11R6.8.2/doc/fonts.html Документация по шрифтам Xorg Font].<br />
:Информацию по модулю freetype для X.org ищите здесь: [http://freetype.sourceforge.net/freetype2/ FreeType2 Project Page].<br />
:Много общей информации по шрифтам в Линукс тут:[http://avi.alkalay.net/linux/docs/font-howto/Font.html Optimal Use of Fonts on Linux].<br />
<br />
===Модули xorg.conf===<br />
*freetype - поддержка шрифтов True Type (ttf, ttc), Type1 (pfa, pfb), CID (cid), CFF, Open Type, bitmap (bdf, pcf, snf), Windows (fnt), PFR, and Type42<br />
*type1 - поддержка шрифтов Type1 (pfa, pfb) and CID (cid)<br />
*speedo - поддержка шрифтов Bitstream Speedo (spd)<br />
*xtt - поддержка True Type (ttf, ttc) шрифтов ('''конфликтует с модулем freetype''')<br />
*bitmap - поддержка bitmap (bdf, pcf, snf) шрифтов<br />
<br />
Как вы видите, freetype предоставляет те же возможности что и все остальные модули. Модуль xtt конфликтует с модулем freetype.<br />
<br />
==Пути шрифтов X.org и /etc/fonts/==<br />
===Пути шрифтов xorg.conf===<br />
Путь к шрифтам прописаный в файле xorg.conf используется только для не-Xft шрифтов. Хорошо бы указать здесь побольше шрифтов. Приложения не поддерживающие Xft будут искать шрифты по пути шрифтов X сервера. В частности я держу здесь минимум шрифтов - для xterm и его собратьев.<br />
<br />
===/etc/fonts/ папки со шрифтами===<br />
conf файлы в /etc/fonts (fonts.conf и local.conf) используются fontconfig (шрифты Xft). fonts.conf никогда не должен изменяться, и все изменения должны производиться в local.conf (для общесистемных изменений) или ~/.fonts.conf (для конкретного пользователя).<br />
Файлы в /etc/fonts/conf.d начинаются с цифры и заканчиваются .conf.<br />
<br />
Папки, указанные в fonts.conf (/usr/share/fonts и ~/.fonts) для использования fontconfig сканируются с помощью fc-cache. Все шрифты должны быть расположены в этих папках. После установки новых шрифтов, чтобы система их увидела, необходимо выполнить '''fc-cache -fv'''.<br />
<br />
===Добавляем новые шрифты===<br />
Если вы скопировали в папку со шрифтами новые шрифты, то они пока всего лишь файлы в файловой системе. Чтобы сообщить системе о новых шрифтах надо запустить несколько дополнительных утилит.<br />
/usr/bin/fc-cache<br />
Это обновит кэш fontconfig, что позволит fontconfig искать нужные шрифты среди вновь установленых(смотрите секцию выше про /etc/fonts)<br />
/usr/bin/mkfontscale<br />
/usr/bin/mkfontdir<br />
ln -s /usr/X11R6/lib/X11/fonts/encodings/encodings.dir encodings.dir<br />
<br />
Запускать эти утилиты надо из папки с новыми шрифтами. mkfontscale создаст файл fonts.scale а mkfontdir создаст файл fonts.dir. Эти файлы используются X сервером, и нужны только для того, чтобы шрифты были доступны через FontPath из X.org. The Програмная связь шрифтов с кодировками позволяет X Server использовать новые шрифты со всеми поддерживаемыми кодировками. После всего этого, в папке для шрифтов у вас должно быть 3 новых файла: fonts.scale, fonts.dir, и encodings.dir.<br />
<br />
===Утилиты fc-list и xlsfont===<br />
Эти утилиты из командной строки показывают все доступные шрифты для каждой подсистемы. fc-list покажет все шрифты fontconfig, в то время, как xlsfont покажет все X шрифты. Это может быть полезным в комбинации с grep, т.о. чтобы увидеть все доступные шрифты bitstream надо набрать "xlsfonts || grep -i bitstream".<br />
<br />
==Места откуда можно скачать шрифты==<br />
*[http://www.users.bigpond.net.au/gavindi/ Arkpandora TrueType fonts] - Замена шрифтам Arial и Times New Roman.<br />
*[http://themes.freshmeat.net/projects/ppantsfonts/ PPants Angular Font Collection]-небольшая коллекция Angular-стилизованных шрифтов шириной в 6 пикселов. <br />
*[http://www.tobias-jung.de/seekingprofont/ Profont]-шрифты для программирования.<br />
<br />
==Полезности(Goodies)==<br />
===Мои шрифты выглядят ужасно - Я всё правильно настроил, но такое ощущение, что у меня просто нет хороших шрифтов.===<br />
Я бы предположил, что следующие пакеты из pacman-а исправят это:<br />
pacman -S ttf-ms-fonts ttf-cheapskate artwiz-fonts<br />
<br />
===У меня есть несколько приложений под Gtk+ 2.2 и ниже, но шрифты выглядят ужасно.===<br />
Да, это бывает. В современных приложениях GTK шрифты Xft включены по умолчанию, тем не менее, до версии 2.2 этого не было. Возможно стоит обновить эти приложения до более нового GTK. Если такой опции нет, тогда добавив строку '''export GDK_USE_XFT=1''' в файл глобальных установок (/etc/profile, /etc/profile.d/gnome.sh, ~/.xinitrc, и т.п.) вы включите Xft для старых приложений<br />
<br />
===У меня сходная проблема как и выше со старыми приложениями, основанными на Qt.===<br />
Похожее решение, добавьте '''export QT_XFT=true''' куда-либо в загрузочный файл.<br />
<br />
===Шрифты в приложениях Gtk при использовании KDE слишком маленькие===<br />
Установите gtk-qt-engine:<br />
pacman -Sy gtk-qt-engine<br />
*Измените размер шрифта для приложений Gtk в `Control Center' -> `Appearance & Themes' -> `GTK Styles and Fonts'.<br />
<br />
===Интерпретатор bytecode делает мои шрифты некрасивыми, к тому же он наглухо вкомпилен, что мне делать, перекомпилировать?===<br />
Нет, не совсем. Встроенное во Freetype auto-hinting выключается достаточно просто. В некоторых дистрибутивах интерпретатор bytecode вкомпилен и включен по умолчанию. Как результат - интерпретатор bytecode перекрывает autohinter freetype-а(которым так гордятся разработчики). Чтобы всё же включить autohinter добавьте следующее в /etc/fonts/local.conf или ~/.fonts.conf<br />
<!-- Использование Autohinter --><br />
<match target="pattern"><br />
<edit name=<code>"autohint" mode=</code>"assign"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
Вопрос: Я не понимаю... Интерпретатор bytecode interpreter предполагался как долговременная лучшая замена для autohinter, так что я не понимаю, зачем кому-то использовать autohinter.<br />
Ответ: Похоже, что интерпретатор bytecode в ветке 2.3 явно слабоват. О нем есть вот такой пост на нашем форуме: http://bbs.archlinux.org/viewtopic.php?id=29976 Этот код сделал мои шрифты гораздо лучше. После перезагрузки всё вернулось на свои места - без понятия почему.<br />
<br />
===Autohint работает отлично, но только не для жирных шрифтов. Как можно выключить его только для жирных шрифтов?===<br />
Autohinter может сделать ваши шрифты красивее, но часто может сделать их слишком широкими. Это особенно раздражает при использовании жирных шрифтов. К счастью, autohinter можно выключить только для жирных шрифтов и оставить включенным для остальных.<br />
*Включите autohinter (см. выше) и добавьте в /etc/fonts/local.conf или ~/.fonts.conf следующее: <br />
<match target="font"><br />
<test name=<code>"weight" compare=</code>"more"><br />
<const>medium</const><br />
</test><br />
<edit name=<code>"autohint" mode=</code>"assign"><br />
<bool>false</bool><br />
</edit><br />
</match><br />
<br />
===Мой TFT/DFP/LCD-дисплей использует DVI-кабель, и шрифты выглядят нечётко и размыто===<br />
Такое происходит из-за различий между CRT и не-CRT мониторами. Исправить данную проблему можно, включив субпиксельное отображение. Откройте файл /etc/fonts/local.conf для правки и найдите закомментированную секцию "Enable subpixel rendering". Раскомментируйте для включения. Заметим, что это нисколько не улучшит качество изображения на CRT-мониторах. Возможные значения для секции '''const''' такие: rgb, bgr, vrgb, bgrv, и none.<br />
<!-- Enable sub-pixel rendering --><br />
<match target="font"><br />
<test qual=<code>"all" name=</code>"rgba"><const>unknown</const></test><br />
<edit name=<code>"rgba" mode=</code>"assign"><const>rgb</const></edit><br />
</match><br />
<br />
===Хочу отключить сглаживание для шрифтов меньше определённого размера.===<br />
В файле /etc/fonts/local.conf есть соответствующий пример. Он закомментирован, так же как и секция subpixel rendering. Измените '''compare="less_eq"''' и '''<int>12</int>''' на желаемые значения, сконфигурировав таким образом операцию сравнения и предельного размера шрифта соответственно.<br />
<!-- Disable anti-aliasing for fonts that are size <=12 --><br />
<match target="pattern"><br />
<test qual="any" name="size" compare="less_eq"><br />
<int>12</int><br />
</test><br />
<edit name="antialias" mode="assign"><bool>false</bool></edit><br />
</match><br />
<br />
===I'm using MS TrueType fonts (verdana) and want to enable anti-aliasing but only for bigger fonts that look too jagged.===<br />
<?xml version="1.0"?><br />
<!DOCTYPE fontconfig SYSTEM "fonts.dtd"><br />
<fontconfig><br />
<br />
<match target="font" ><br />
<test compare<code>"more" name</code>"size" qual="any" ><br />
<double>12</double><br />
</test><br />
<edit mode<code>"assign" name</code>"antialias" ><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
<match target="font" ><br />
<test compare<code>"more" name</code>"pixelsize" qual="any" ><br />
<double>17</double><br />
</test><br />
<edit mode<code>"assign" name</code>"antialias" ><br />
<bool>true</bool><br />
</edit><br />
</match><br />
</fontconfig><br />
<br />
===Я хочу добавить больше шрифтов.===<br />
Сохраните ваши шрифты в директории и добавьте путь до нее в файл '''/etc/fonts/local.conf'''<br />
<br />
<!-- Additional font directories --><br />
<dir>/путь/до/директории</dir><br />
<br />
===I want my font sizes to match my dpi settings===<br />
This goes into '''/etc/fonts/local.conf'''. This setting should match your dpi settings in either xorg.conf or your startx command. Use xdpyinfo to get your current dpi setting. Most people recommend/use a value of 96 or 100. Changing and setting the dpi of X is beyond the scope of this document (see [[Xorg#Display_Size.2FDPI|Xorg DisplaySize/DPI]]).<br />
<!-- Setup for DPI = 100 --><br />
<match target="pattern"><br />
<edit name=<code>"dpi" mode=</code>"assign"><double>100</double></edit><br />
</match><br />
<br />
===I don't like font <enter name here> and want to use <another font name> instead===<br />
<br />
The most reliable way to do this is to add an XML fragment similar to the one below to /etc/fonts/local.conf. This will cause Nimbus Sans to be used in place of Helvetica:<br />
<br />
<br />
<match target="pattern"><br />
<test name="family"><string>Helvetica</string></test><br />
<edit name="family" mode="assign"><br />
<string>Nimbus Sans</string><br />
</edit><br />
</match><br />
<br />
<br />
An alternate approach is to set the "preferred" font, but '''this only works if the original font is not on your system''', in which case the one you specify will be substituted:<br />
<br />
<br />
<!-- Replace Helvetica with Bitstream Vera Sans Mono --><br />
<!-- Note, an alias for Helvetica should already exist in default local.conf files --><br />
<alias><br />
<family>Helvetica </family><br />
<prefer><family>Bitstream Vera Sans Mono</family></prefer><br />
<default><family>fixed</family></default><br />
</alias><br />
<br />
===I have tons of disgusting pixel fonts that I don't want===<br />
The only two fonts that you absolutely have to have in order to start X are 'cursor' and 'fixed', both of which are in the fonts/misc directory. If you want to get rid of all the pixel fonts besides these two, you can delete all the files in the misc directory besides cursor.pcf.gz and all the fonts that are similar to either 9x18.pcf.gz or 9x18-ISO8859-1.pcf.gz. When I deleted all the fonts besides those from the misc directory, I had about 337 files still in it, so if you have a lot less than that you should probably put them back before restarting X.<br />
<br />
===Something or someone disabled all my non-scalable (bitmap) fonts, I want them back===<br />
By default, fontconfig 2.3.2-4 and higher will disable the use of bitmap fonts. This setting is managed in /etc/fonts/conf.d/10-no-bitmaps.conf, or in higher versions, /etc/fonts/conf.d/10-bitmaps.conf.<br />
To enable bitmap fonts and keep them enabled after upgrades of fontconfig, place a symlink from yes-bitmaps.conf to 10-bitmaps.conf, overwriting the symlink to no-bitmaps.conf.<br />
<br />
===Fake bold & italic styles for incomplete fonts===<br />
Freetype already has had this capability for some time, but only if app asks so (which never happens) - it's not going to add Bold or Italic style for those regular-only fonts anyway. To make up them, you need to edit ''/usr/share/fonts/fonts.cache-1'' manually (and keep your modification somewhere because font update (fc-cache) overrides it). Assume you have a font Dupree:<br />
"dupree.ttf" 0 "Dupree:style=Regular:slant=0:weight=80:width=100:foundry=unknown:index=0:outline=True:....<br />
Duplicate the line, change ''style=Regular'' to ''style=Bold'' or other styles you want. Also change ''slant=0'' to ''slant=100'' for italic, ''weight=80'' to ''weight=200'' for bold (combine for bold italic):<br />
"dupree.ttf" 0 "Dupree:style=Bold Italic:slant=100:weight=200:width=100:foundry=unknown:index=0:outline=True:....<br />
Now add necessary modification to ''~/.fonts.conf'':<br />
<match target="font"><br />
<test name="family" qual="any"><br />
<string>Dupree</string><br />
&lt;!-- other fonts here .... --&gt;<br />
</test><br />
<test compare="more_eq" name="weight"><int>140</int></test><br />
<edit mode="assign" name="embolden"><bool>true</bool></edit><br />
</match><br />
<match target="font"><br />
<test name="family" qual="any"><br />
<string>Dupree</string><br />
&lt;!-- other fonts here .... --&gt;<br />
</test><br />
<test compare="more_eq" name="slant"><int>80</int></test><br />
<edit mode="assign" name="matrix"><br />
<times><br />
<name>matrix</name><br />
<matrix><br />
<double>1</double><double>0.2</double><br />
<double>0</double><double>1</double><br />
</matrix><br />
</times><br />
</edit><br />
</match><br />
(Note that you can use embolden for bold fonts as well - to make them even bolder)<br />
<br />
===A web developer's fonts/local.conf taken from arch forums===<br />
Backup your current config and give this one a try. I noticed it especially improved the Georgia font.<br />
<pre><br />
<?xml version="1.0"?><br />
<!DOCTYPE fontconfig SYSTEM "fonts.dtd"><br />
<br />
<!-- the cathectic LCD tweaks, from linuxquestions.org,<br />
http://www.linuxquestions.org/questions/showthread.php?postid=1361098#post1361098 --><br />
<br />
<fontconfig><br />
<br />
<!-- Disable sub-pixel rendering.<br />
X detects it anyway, and if you set this as well, it just looks really horrible --><br />
<match target="font" ><br />
<edit mode="assign" name="rgba" ><br />
<const>none</const><br />
</edit><br />
</match><br />
<match target="font" ><br />
<edit mode="assign" name="hinting"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<match target="font" ><br />
<edit mode="assign" name="hintstyle"><br />
<const>hintfull</const><br />
</edit><br />
</match><br />
<br />
<!-- The first part of the 'magic.'<br />
This makes the fonts start to look nice,<br />
but some of the shapes will be distorted, so hinting is needed still --><br />
<match target="font" ><br />
<edit mode="assign" name="antialias"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<br />
<!-- Autohinter is not turned on automatically.<br />
Only disable this if you have recompiled Freetype with the bytecode interpreter,<br />
which is run automatically.<br /> --><br />
<match target="pattern" ><br />
<edit mode="assign" name="autohint"><br />
<bool>true</bool><br />
</edit><br />
</match><br />
<match target="font"><br />
<test name="weight" compare="more"><br />
<const>medium</const><br />
</test><br />
<edit name="autohint" mode="assign"><br />
<bool>false</bool><br />
</edit><br />
</match><br />
<!-- Helvetica is a non true type font, and will look bad.<br />
This replaces it with whatever is the default sans-serif font --><br />
<match target="pattern" name="family" ><br />
<test name="family" qual="any" ><br />
<string>Helvetica</string><br />
</test><br />
<edit mode="assign" name="family" ><br />
<string>sans-serif</string><br />
</edit><br />
</match><br />
<dir>~/.fonts</dir><br />
</fontconfig><br />
</pre></div>
Cucullus
https://wiki.archlinux.org/index.php?title=HAL_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31691
HAL (Русский)
2007-11-04T10:46:52Z
<p>Cucullus: /* Dbus and HAL User Groups */</p>
<hr />
<div>[[Category: Русский]]<br />
[[Category: Обнаружение и диагностика оборудования]]<br />
[[Category: Демоны и системные службы]]<br />
[[Category: Русские_HowTo]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|HAL}}<br />
{{i18n_entry|Polish|HAL_(Polski)}}<br />
{{i18n_entry|Русский|HAL_(Русский)}}<br />
{{i18n_links_end}}<br />
<br />
=Обзор HAL=<br />
HAL (Hardware Abstraction Layer) это демон, который представляет програмам быстрый доступ к информации об оборудовании. Взаимодействуя с HAL приложения сами могут определять и использовать железо, не обращая внимания на такие особенности как шина или тип устройства. Таким образом графический интерфейс оказывается способным представлять пользователю все ресурсы компьютера в однотипном и унифицированном виде.<br />
<br />
Например, HAL способен собирать информацию об устройствах хранения информации (флешках, внешних HDD, и.пр.) и создавать иконки этих устройств на рабочем столе пользователя, упрощающие доступ к этим устройствам.<br />
<br />
=Начальные установки=<br />
HAL требует для своего функционирования наличие запущенного демона dbus, поэтому необходимо быть уверенным, что они оба установлены. Откройте терминал и запустите следующее под root`ом:<br />
# pacman -S dbus hal<br />
Далее нужно отредактировать файл ''/etc/rc.conf'' (под root`ом) своим любимым текстовым редактором, добавив '''hal''' в список DAEMONS, например:<br />
DAEMONS=(syslog-ng '''hal''' network netfs ...)<br />
Теперь демон hal будет стартовать во время загрузки системы. Во время своей инициализации hal проверяет наличие dbus и загружает его автоматически. Если вы обнаружите, что dbus каким-либо образом попал в список DAEMONS (файл /etc/rc.conf), удалите его оттуда, т.к. в ином случае возможны непредвиденные последствия.<br />
<br />
Вы также можете запустить hal вручную, введя под root`ом следующую команду:<br />
# /etc/rc.d/hal start<br />
<br />
Для того, чтобы dbus и hal нармально функционировали необходимо добавить локальных пользователей в группы: '''optical''' и '''storage'''. Это можно сделать, открыв терминал и введя под root`ом следующие команды:<br />
# gpasswd -a ''username'' optical<br />
# gpasswd -a ''username'' storage<br />
Замените ''username'' именем реально существующего пользователя (например, johndoe).<br />
<br />
Если демон hal был запущен до того, как вы добавили себя в эти группы необходимо перезапустить и ''dbus'' и ''hal'' для того, чтобы изменения вступили в силу. Это можно проделать, запустив под root`ом следующие команды:<br />
# /etc/rc.d/dbus restart<br />
# /etc/rc.d/hal restart<br />
<br />
=Тонкости и хитрости=<br />
==Автомонтирование NTFS с поддержкой записи (ntfs-3g)==<br />
Если у вас появилось желание автомонтировать разделы с NTFS с поддержкой записи, вам необходимо для установить [[NTFS Write Support|ntfs-3g]] и создать файл 10-ntfs-policy.fdi в /etc/hal/fdi/policy следующего содержания:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?><br />
<deviceinfo version="0.2"><br />
<!-- mount ntfs volume with the ntfs-3g driver to enable write support --><br />
<device><br />
<match key="volume.fstype" string="ntfs"><br />
<match key="@block.storage_device:storage.hotpluggable" bool="true"><br />
<merge key="volume.fstype" type="string">ntfs-3g</merge><br />
<merge key="volume.policy.mount_filesystem" type="string">ntfs-3g</merge><br />
<append key="volume.mount.valid_options" type="strlist">locale=</append><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Задание точки монтирования iPod ==<br />
Если вы не укажите hal куда монтировать ваш ipod, он будет монтироваться в папку с тем именем, которое вы ему присвоили. Чтобы испавать это недаразумение надо создать правило для hal. Это правило можно добавить, например, в /etc/hal/fdi/policy/90-user-methods.fdi. Если этого файла не существует просто создайте его.<br />
<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="@block.storage_device:storage.model" string="iPod"><br />
<merge key="volume.policy.desired_mount_point" type="string">ipod</merge><br />
<merge key="volume.policy.mount_option.iocharset=iso8859-15" type="bool">true</merge><br />
<merge key="volume.policy.mount_option.sync" type="bool">true</merge><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Автомонтирование только съёмных устройств==<br />
По умолчанию hal автомонтирует все доступные (включая скрытые) разделы не смонтированные в /etc/fstab и создает ярлыки на рабочем столе для них. Чтобы переопределить это правило достаточно создать файл 90-user-methods.fdi в /etc/hal/fdi/policy со следующим содержанием:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="volume.fsusage" string="filesystem"><br />
<!-- Here follow volumes we specifically want to ignore - it is the --><br />
<!-- responsibility of software higher in the stack (e.g. gnome-vfs) --><br />
<!-- amd mount programs (e.g. Mount() on HAL) to respect volume.ignore --> <br />
<merge key="volume.ignore" type="bool">true</merge><br />
<match key="@block.storage_device:storage.removable" bool="true"><br />
<merge key="volume.ignore" type="bool">false</merge><br />
<merge key="storage.policy.should_mount" type="bool">true</merge><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
Далее необходимо перезапустить hal:<br />
# /etc/rc.d/hal restart<br />
<br />
=Возможные проблемы=<br />
==Вставленный CD/DVD диск не распознается hal`ом==<br />
Если вставленный CDs/DVDs диски не распознаются hal`ом (не создаются иконки на рабочем столе), просмотрите файл /etc/fstab и удалите из него все строки, касающиеся оптических приводов.<br />
<br />
==USB диски и флешки не автомонтируются корректно==<br />
Данный подраздел взят с [http://bbs.archlinux.org/viewtopic.php?pid=248224 форума].<br />
<br />
Если вы испытываете проблемы с автомонтированием usb дисков, но проблем с CD/DVD дисками у вас не возникает, и монтировать вручную USB диски вы можете, вы можете попробовать создать файл "preferences.fdi" в папке /etc/hal/fdi/policy и вставить туда следующую строку<br />
<merge key="volume.ignore" type="bool">false</merge><br />
<br />
==Группы Dbus and HAL==<br />
Некоторые пользователи считают, что HAL работает если ваш пользователь также является членом групп '''dbus''' и '''hal''' .<br />
Чтобы это проверить запустите следующие команды от пользователя root:<br />
# gpasswd -a ''username'' dbus<br />
# gpasswd -a ''username'' hal<br />
Если это не решит вашей проблемы удалите пользователя из этих групп на всякий случай, чтобы избежать в дальнейшем проблем:<br />
# gpasswd -d ''username'' dbus<br />
# gpasswd -d ''username'' hal<br />
<br />
==Использвание PMount==<br />
Если всё вышеперечисленное у вас так и не заработало, то можете попробовать устоновить '''pmount'''. PMount - это обёртка для стандартного mount, позволяющая обычным пользователям монтировать устройства без прописывания их в /etc/fstab.<br />
# pacman -Sy pmount</div>
Cucullus
https://wiki.archlinux.org/index.php?title=HAL_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31688
HAL (Русский)
2007-11-04T10:40:59Z
<p>Cucullus: </p>
<hr />
<div>[[Category: Русский]]<br />
[[Category: Обнаружение и диагностика оборудования]]<br />
[[Category: Демоны и системные службы]]<br />
[[Category: Русские_HowTo]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|HAL}}<br />
{{i18n_entry|Polish|HAL_(Polski)}}<br />
{{i18n_entry|Русский|HAL_(Русский)}}<br />
{{i18n_links_end}}<br />
<br />
=Обзор HAL=<br />
HAL (Hardware Abstraction Layer) это демон, который представляет програмам быстрый доступ к информации об оборудовании. Взаимодействуя с HAL приложения сами могут определять и использовать железо, не обращая внимания на такие особенности как шина или тип устройства. Таким образом графический интерфейс оказывается способным представлять пользователю все ресурсы компьютера в однотипном и унифицированном виде.<br />
<br />
Например, HAL способен собирать информацию об устройствах хранения информации (флешках, внешних HDD, и.пр.) и создавать иконки этих устройств на рабочем столе пользователя, упрощающие доступ к этим устройствам.<br />
<br />
=Начальные установки=<br />
HAL требует для своего функционирования наличие запущенного демона dbus, поэтому необходимо быть уверенным, что они оба установлены. Откройте терминал и запустите следующее под root`ом:<br />
# pacman -S dbus hal<br />
Далее нужно отредактировать файл ''/etc/rc.conf'' (под root`ом) своим любимым текстовым редактором, добавив '''hal''' в список DAEMONS, например:<br />
DAEMONS=(syslog-ng '''hal''' network netfs ...)<br />
Теперь демон hal будет стартовать во время загрузки системы. Во время своей инициализации hal проверяет наличие dbus и загружает его автоматически. Если вы обнаружите, что dbus каким-либо образом попал в список DAEMONS (файл /etc/rc.conf), удалите его оттуда, т.к. в ином случае возможны непредвиденные последствия.<br />
<br />
Вы также можете запустить hal вручную, введя под root`ом следующую команду:<br />
# /etc/rc.d/hal start<br />
<br />
Для того, чтобы dbus и hal нармально функционировали необходимо добавить локальных пользователей в группы: '''optical''' и '''storage'''. Это можно сделать, открыв терминал и введя под root`ом следующие команды:<br />
# gpasswd -a ''username'' optical<br />
# gpasswd -a ''username'' storage<br />
Замените ''username'' именем реально существующего пользователя (например, johndoe).<br />
<br />
Если демон hal был запущен до того, как вы добавили себя в эти группы необходимо перезапустить и ''dbus'' и ''hal'' для того, чтобы изменения вступили в силу. Это можно проделать, запустив под root`ом следующие команды:<br />
# /etc/rc.d/dbus restart<br />
# /etc/rc.d/hal restart<br />
<br />
=Тонкости и хитрости=<br />
==Автомонтирование NTFS с поддержкой записи (ntfs-3g)==<br />
Если у вас появилось желание автомонтировать разделы с NTFS с поддержкой записи, вам необходимо для установить [[NTFS Write Support|ntfs-3g]] и создать файл 10-ntfs-policy.fdi в /etc/hal/fdi/policy следующего содержания:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?><br />
<deviceinfo version="0.2"><br />
<!-- mount ntfs volume with the ntfs-3g driver to enable write support --><br />
<device><br />
<match key="volume.fstype" string="ntfs"><br />
<match key="@block.storage_device:storage.hotpluggable" bool="true"><br />
<merge key="volume.fstype" type="string">ntfs-3g</merge><br />
<merge key="volume.policy.mount_filesystem" type="string">ntfs-3g</merge><br />
<append key="volume.mount.valid_options" type="strlist">locale=</append><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Задание точки монтирования iPod ==<br />
Если вы не укажите hal куда монтировать ваш ipod, он будет монтироваться в папку с тем именем, которое вы ему присвоили. Чтобы испавать это недаразумение надо создать правило для hal. Это правило можно добавить, например, в /etc/hal/fdi/policy/90-user-methods.fdi. Если этого файла не существует просто создайте его.<br />
<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="@block.storage_device:storage.model" string="iPod"><br />
<merge key="volume.policy.desired_mount_point" type="string">ipod</merge><br />
<merge key="volume.policy.mount_option.iocharset=iso8859-15" type="bool">true</merge><br />
<merge key="volume.policy.mount_option.sync" type="bool">true</merge><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Автомонтирование только съёмных устройств==<br />
По умолчанию hal автомонтирует все доступные (включая скрытые) разделы не смонтированные в /etc/fstab и создает ярлыки на рабочем столе для них. Чтобы переопределить это правило достаточно создать файл 90-user-methods.fdi в /etc/hal/fdi/policy со следующим содержанием:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="volume.fsusage" string="filesystem"><br />
<!-- Here follow volumes we specifically want to ignore - it is the --><br />
<!-- responsibility of software higher in the stack (e.g. gnome-vfs) --><br />
<!-- amd mount programs (e.g. Mount() on HAL) to respect volume.ignore --> <br />
<merge key="volume.ignore" type="bool">true</merge><br />
<match key="@block.storage_device:storage.removable" bool="true"><br />
<merge key="volume.ignore" type="bool">false</merge><br />
<merge key="storage.policy.should_mount" type="bool">true</merge><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
Далее необходимо перезапустить hal:<br />
# /etc/rc.d/hal restart<br />
<br />
=Возможные проблемы=<br />
==Вставленный CD/DVD диск не распознается hal`ом==<br />
Если вставленный CDs/DVDs диски не распознаются hal`ом (не создаются иконки на рабочем столе), просмотрите файл /etc/fstab и удалите из него все строки, касающиеся оптических приводов.<br />
<br />
==USB диски и флешки не автомонтируются корректно==<br />
Данный подраздел взят с [http://bbs.archlinux.org/viewtopic.php?pid=248224 форума].<br />
<br />
Если вы испытываете проблемы с автомонтированием usb дисков, но проблем с CD/DVD дисками у вас не возникает, и монтировать вручную USB диски вы можете, вы можете попробовать создать файл "preferences.fdi" в папке /etc/hal/fdi/policy и вставить туда следующую строку<br />
<merge key="volume.ignore" type="bool">false</merge><br />
<br />
==Dbus and HAL User Groups==<br />
Некоторые пользователи считают, что HAL работает если ваш пользователь также является членом групп '''dbus''' и '''hal''' .<br />
Чтобы это проверить запустите следующие команды от пользователя root:<br />
# gpasswd -a ''username'' dbus<br />
# gpasswd -a ''username'' hal<br />
Если это не решит вашей проблемы удалите пользователя из этих групп на всякий случай, чтобы избежать в дальнейшем проблем:<br />
# gpasswd -d ''username'' dbus<br />
# gpasswd -d ''username'' hal<br />
<br />
==Использвание PMount==<br />
Если всё вышеперечисленное у вас так и не заработало, то можете попробовать устоновить '''pmount'''. PMount - это обёртка для стандартного mount, позволяющая обычным пользователям монтировать устройства без прописывания их в /etc/fstab.<br />
# pacman -Sy pmount</div>
Cucullus
https://wiki.archlinux.org/index.php?title=HAL_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31687
HAL (Русский)
2007-11-04T10:37:59Z
<p>Cucullus: </p>
<hr />
<div>[[Category:Русский]]<br />
[[Category: Hardware detection and troubleshooting (English)]]<br />
[[Category:Daemons and system services (English)]]<br />
[[Category:Русские_HowTo]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|HAL}}<br />
{{i18n_entry|Polish|HAL_(Polski)}}<br />
{{i18n_entry|Русский|HAL_(Русский)}}<br />
{{i18n_links_end}}<br />
<br />
=Обзор HAL=<br />
HAL (Hardware Abstraction Layer) это демон, который представляет програмам быстрый доступ к информации об оборудовании. Взаимодействуя с HAL приложения сами могут определять и использовать железо, не обращая внимания на такие особенности как шина или тип устройства. Таким образом графический интерфейс оказывается способным представлять пользователю все ресурсы компьютера в однотипном и унифицированном виде.<br />
<br />
Например, HAL способен собирать информацию об устройствах хранения информации (флешках, внешних HDD, и.пр.) и создавать иконки этих устройств на рабочем столе пользователя, упрощающие доступ к этим устройствам.<br />
<br />
=Начальные установки=<br />
HAL требует для своего функционирования наличие запущенного демона dbus, поэтому необходимо быть уверенным, что они оба установлены. Откройте терминал и запустите следующее под root`ом:<br />
# pacman -S dbus hal<br />
Далее нужно отредактировать файл ''/etc/rc.conf'' (под root`ом) своим любимым текстовым редактором, добавив '''hal''' в список DAEMONS, например:<br />
DAEMONS=(syslog-ng '''hal''' network netfs ...)<br />
Теперь демон hal будет стартовать во время загрузки системы. Во время своей инициализации hal проверяет наличие dbus и загружает его автоматически. Если вы обнаружите, что dbus каким-либо образом попал в список DAEMONS (файл /etc/rc.conf), удалите его оттуда, т.к. в ином случае возможны непредвиденные последствия.<br />
<br />
Вы также можете запустить hal вручную, введя под root`ом следующую команду:<br />
# /etc/rc.d/hal start<br />
<br />
Для того, чтобы dbus и hal нармально функционировали необходимо добавить локальных пользователей в группы: '''optical''' и '''storage'''. Это можно сделать, открыв терминал и введя под root`ом следующие команды:<br />
# gpasswd -a ''username'' optical<br />
# gpasswd -a ''username'' storage<br />
Замените ''username'' именем реально существующего пользователя (например, johndoe).<br />
<br />
Если демон hal был запущен до того, как вы добавили себя в эти группы необходимо перезапустить и ''dbus'' и ''hal'' для того, чтобы изменения вступили в силу. Это можно проделать, запустив под root`ом следующие команды:<br />
# /etc/rc.d/dbus restart<br />
# /etc/rc.d/hal restart<br />
<br />
=Тонкости и хитрости=<br />
==Автомонтирование NTFS с поддержкой записи (ntfs-3g)==<br />
Если у вас появилось желание автомонтировать разделы с NTFS с поддержкой записи, вам необходимо для установить [[NTFS Write Support|ntfs-3g]] и создать файл 10-ntfs-policy.fdi в /etc/hal/fdi/policy следующего содержания:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?><br />
<deviceinfo version="0.2"><br />
<!-- mount ntfs volume with the ntfs-3g driver to enable write support --><br />
<device><br />
<match key="volume.fstype" string="ntfs"><br />
<match key="@block.storage_device:storage.hotpluggable" bool="true"><br />
<merge key="volume.fstype" type="string">ntfs-3g</merge><br />
<merge key="volume.policy.mount_filesystem" type="string">ntfs-3g</merge><br />
<append key="volume.mount.valid_options" type="strlist">locale=</append><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Задание точки монтирования iPod ==<br />
Если вы не укажите hal куда монтировать ваш ipod, он будет монтироваться в папку с тем именем, которое вы ему присвоили. Чтобы испавать это недаразумение надо создать правило для hal. Это правило можно добавить, например, в /etc/hal/fdi/policy/90-user-methods.fdi. Если этого файла не существует просто создайте его.<br />
<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="@block.storage_device:storage.model" string="iPod"><br />
<merge key="volume.policy.desired_mount_point" type="string">ipod</merge><br />
<merge key="volume.policy.mount_option.iocharset=iso8859-15" type="bool">true</merge><br />
<merge key="volume.policy.mount_option.sync" type="bool">true</merge><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Автомонтирование только съёмных устройств==<br />
По умолчанию hal автомонтирует все доступные (включая скрытые) разделы не смонтированные в /etc/fstab и создает ярлыки на рабочем столе для них. Чтобы переопределить это правило достаточно создать файл 90-user-methods.fdi в /etc/hal/fdi/policy со следующим содержанием:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="volume.fsusage" string="filesystem"><br />
<!-- Here follow volumes we specifically want to ignore - it is the --><br />
<!-- responsibility of software higher in the stack (e.g. gnome-vfs) --><br />
<!-- amd mount programs (e.g. Mount() on HAL) to respect volume.ignore --> <br />
<merge key="volume.ignore" type="bool">true</merge><br />
<match key="@block.storage_device:storage.removable" bool="true"><br />
<merge key="volume.ignore" type="bool">false</merge><br />
<merge key="storage.policy.should_mount" type="bool">true</merge><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
Далее необходимо перезапустить hal:<br />
# /etc/rc.d/hal restart<br />
<br />
=Возможные проблемы=<br />
==Вставленный CD/DVD диск не распознается hal`ом==<br />
Если вставленный CDs/DVDs диски не распознаются hal`ом (не создаются иконки на рабочем столе), просмотрите файл /etc/fstab и удалите из него все строки, касающиеся оптических приводов.<br />
<br />
==USB диски и флешки не автомонтируются корректно==<br />
Данный подраздел взят с [http://bbs.archlinux.org/viewtopic.php?pid=248224 форума].<br />
<br />
Если вы испытываете проблемы с автомонтированием usb дисков, но проблем с CD/DVD дисками у вас не возникает, и монтировать вручную USB диски вы можете, вы можете попробовать создать файл "preferences.fdi" в папке /etc/hal/fdi/policy и вставить туда следующую строку<br />
<merge key="volume.ignore" type="bool">false</merge><br />
<br />
==Dbus and HAL User Groups==<br />
Некоторые пользователи считают, что HAL работает если ваш пользователь также является членом групп '''dbus''' и '''hal''' .<br />
Чтобы это проверить запустите следующие команды от пользователя root:<br />
# gpasswd -a ''username'' dbus<br />
# gpasswd -a ''username'' hal<br />
Если это не решит вашей проблемы удалите пользователя из этих групп на всякий случай, чтобы избежать в дальнейшем проблем:<br />
# gpasswd -d ''username'' dbus<br />
# gpasswd -d ''username'' hal<br />
<br />
==Использвание PMount==<br />
Если всё вышеперечисленное у вас так и не заработало, то можете попробовать устоновить '''pmount'''. PMount - это обёртка для стандартного mount, позволяющая обычным пользователям монтировать устройства без прописывания их в /etc/fstab.<br />
# pacman -Sy pmount</div>
Cucullus
https://wiki.archlinux.org/index.php?title=HAL_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31686
HAL (Русский)
2007-11-04T10:35:21Z
<p>Cucullus: /* USB диски и флешки не автомонтируются корректно */</p>
<hr />
<div>[[Category: Hardware detection and troubleshooting (English)]]<br />
[[Category:Daemons and system services (English)]]<br />
[[Category:Русские_HowTo]]<br />
<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|HAL}}<br />
{{i18n_entry|Polish|HAL_(Polski)}}<br />
{{i18n_entry|Русский|HAL_(Русский)}}<br />
{{i18n_links_end}}<br />
<br />
=Обзор HAL=<br />
HAL (Hardware Abstraction Layer) это демон, который представляет програмам быстрый доступ к информации об оборудовании. Взаимодействуя с HAL приложения сами могут определять и использовать железо, не обращая внимания на такие особенности как шина или тип устройства. Таким образом графический интерфейс оказывается способным представлять пользователю все ресурсы компьютера в однотипном и унифицированном виде.<br />
<br />
Например, HAL способен собирать информацию об устройствах хранения информации (флешках, внешних HDD, и.пр.) и создавать иконки этих устройств на рабочем столе пользователя, упрощающие доступ к этим устройствам.<br />
<br />
=Начальные установки=<br />
HAL требует для своего функционирования наличие запущенного демона dbus, поэтому необходимо быть уверенным, что они оба установлены. Откройте терминал и запустите следующее под root`ом:<br />
# pacman -S dbus hal<br />
Далее нужно отредактировать файл ''/etc/rc.conf'' (под root`ом) своим любимым текстовым редактором, добавив '''hal''' в список DAEMONS, например:<br />
DAEMONS=(syslog-ng '''hal''' network netfs ...)<br />
Теперь демон hal будет стартовать во время загрузки системы. Во время своей инициализации hal проверяет наличие dbus и загружает его автоматически. Если вы обнаружите, что dbus каким-либо образом попал в список DAEMONS (файл /etc/rc.conf), удалите его оттуда, т.к. в ином случае возможны непредвиденные последствия.<br />
<br />
Вы также можете запустить hal вручную, введя под root`ом следующую команду:<br />
# /etc/rc.d/hal start<br />
<br />
Для того, чтобы dbus и hal нармально функционировали необходимо добавить локальных пользователей в группы: '''optical''' и '''storage'''. Это можно сделать, открыв терминал и введя под root`ом следующие команды:<br />
# gpasswd -a ''username'' optical<br />
# gpasswd -a ''username'' storage<br />
Замените ''username'' именем реально существующего пользователя (например, johndoe).<br />
<br />
Если демон hal был запущен до того, как вы добавили себя в эти группы необходимо перезапустить и ''dbus'' и ''hal'' для того, чтобы изменения вступили в силу. Это можно проделать, запустив под root`ом следующие команды:<br />
# /etc/rc.d/dbus restart<br />
# /etc/rc.d/hal restart<br />
<br />
=Тонкости и хитрости=<br />
==Автомонтирование NTFS с поддержкой записи (ntfs-3g)==<br />
Если у вас появилось желание автомонтировать разделы с NTFS с поддержкой записи, вам необходимо для установить [[NTFS Write Support|ntfs-3g]] и создать файл 10-ntfs-policy.fdi в /etc/hal/fdi/policy следующего содержания:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?><br />
<deviceinfo version="0.2"><br />
<!-- mount ntfs volume with the ntfs-3g driver to enable write support --><br />
<device><br />
<match key="volume.fstype" string="ntfs"><br />
<match key="@block.storage_device:storage.hotpluggable" bool="true"><br />
<merge key="volume.fstype" type="string">ntfs-3g</merge><br />
<merge key="volume.policy.mount_filesystem" type="string">ntfs-3g</merge><br />
<append key="volume.mount.valid_options" type="strlist">locale=</append><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Задание точки монтирования iPod ==<br />
Если вы не укажите hal куда монтировать ваш ipod, он будет монтироваться в папку с тем именем, которое вы ему присвоили. Чтобы испавать это недаразумение надо создать правило для hal. Это правило можно добавить, например, в /etc/hal/fdi/policy/90-user-methods.fdi. Если этого файла не существует просто создайте его.<br />
<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="@block.storage_device:storage.model" string="iPod"><br />
<merge key="volume.policy.desired_mount_point" type="string">ipod</merge><br />
<merge key="volume.policy.mount_option.iocharset=iso8859-15" type="bool">true</merge><br />
<merge key="volume.policy.mount_option.sync" type="bool">true</merge><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
==Автомонтирование только съёмных устройств==<br />
По умолчанию hal автомонтирует все доступные (включая скрытые) разделы не смонтированные в /etc/fstab и создает ярлыки на рабочем столе для них. Чтобы переопределить это правило достаточно создать файл 90-user-methods.fdi в /etc/hal/fdi/policy со следующим содержанием:<br />
<br />
<?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- --><br />
<deviceinfo version="0.2"><br />
<device><br />
<match key="volume.fsusage" string="filesystem"><br />
<!-- Here follow volumes we specifically want to ignore - it is the --><br />
<!-- responsibility of software higher in the stack (e.g. gnome-vfs) --><br />
<!-- amd mount programs (e.g. Mount() on HAL) to respect volume.ignore --> <br />
<merge key="volume.ignore" type="bool">true</merge><br />
<match key="@block.storage_device:storage.removable" bool="true"><br />
<merge key="volume.ignore" type="bool">false</merge><br />
<merge key="storage.policy.should_mount" type="bool">true</merge><br />
</match><br />
</match><br />
</device><br />
</deviceinfo><br />
<br />
Далее необходимо перезапустить hal:<br />
# /etc/rc.d/hal restart<br />
<br />
=Возможные проблемы=<br />
==Вставленный CD/DVD диск не распознается hal`ом==<br />
Если вставленный CDs/DVDs диски не распознаются hal`ом (не создаются иконки на рабочем столе), просмотрите файл /etc/fstab и удалите из него все строки, касающиеся оптических приводов.<br />
<br />
==USB диски и флешки не автомонтируются корректно==<br />
Данный подраздел взят с [http://bbs.archlinux.org/viewtopic.php?pid=248224 форума].<br />
<br />
Если вы испытываете проблемы с автомонтированием usb дисков, но проблем с CD/DVD дисками у вас не возникает, и монтировать вручную USB диски вы можете, вы можете попробовать создать файл "preferences.fdi" в папке /etc/hal/fdi/policy и вставить туда следующую строку<br />
<merge key="volume.ignore" type="bool">false</merge><br />
<br />
==Dbus and HAL User Groups==<br />
Некоторые пользователи считают, что HAL работает если ваш пользователь также является членом групп '''dbus''' и '''hal''' .<br />
Чтобы это проверить запустите следующие команды от пользователя root:<br />
# gpasswd -a ''username'' dbus<br />
# gpasswd -a ''username'' hal<br />
Если это не решит вашей проблемы удалите пользователя из этих групп на всякий случай, чтобы избежать в дальнейшем проблем:<br />
# gpasswd -d ''username'' dbus<br />
# gpasswd -d ''username'' hal<br />
<br />
==Использвание PMount==<br />
Если всё вышеперечисленное у вас так и не заработало, то можете попробовать устоновить '''pmount'''. PMount - это обёртка для стандартного mount, позволяющая обычным пользователям монтировать устройства без прописывания их в /etc/fstab.<br />
# pacman -Sy pmount</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Official_Installation_Guide_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31626
Official Installation Guide (Русский)
2007-11-02T12:18:54Z
<p>Cucullus: /* I can't ssh into my machine! */</p>
<hr />
<div>[[Category:Русский]]<br />
[[Category:Руководства]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|Official Arch Linux Install Guide}}<br />
{{i18n_entry|Česky|Oficiální instalační příručka (Česky)}}<br />
{{i18n_entry|Русский|Руководство по установке}}<br />
{{i18n_links_end}}<br />
<br />
:''Это документация для обычного пользователя Arch Linux. Здесь описано получение необходимых файлов, установка и базовая настройка системы. Также есть короткое описание структуры системы и описание специфичных для Arch вещей таких как менеджер пакетов pacman и ABS.''<br />
<br />
==Введение==<br />
===Что такое Arch Linux?===<br />
<br />
Arch Linux - это оптимизированный под i686 и x86_64 дистрибутив операционной системы Linux, который был основан на идеях дистрибутива CRUX, созданного Per Lidén.<br />
<br />
Arch быстрый, легковесный, гибкий и простой. Не очень броские эпитеты, зато<br />
правда. Arch оптимизирован под i686 и x86_64, а это значит, что вы сможете выжать из<br />
своего процессора максимум. Arch очень легковесный по сравнению с Red Hat и ему<br />
подобными, а его простота позволяет с легкостью расширить и превратить в любую желаемую<br />
систему.<br />
<br />
Простая в использовании система бинарных пакетов - [[Pacman_(Русский)|pacman]], которая позволяет обновить всю систему всего одной командой. Arch также использует похожую на порты систему сборки пакетов (Arch Build System) , которые тоже могут быть синхронизированы одной командой. Ах, да, вы также можете пересобрать всю систему одной командой. Все делается просто и прозрачно.<br />
<br />
Arch Linux старается поддерживать последние стабильные версии программного обеспечения.<br />
На данный момент мы поддерживаем довольно ограниченый набор системных пакетов и растущую коллекцию экстра пакетов, созданных пользователями и разработчиками Arch Linux.<br />
<br />
Чтобы достигнуть нашей цели - быть простым и легковесным - мы оставили за бортом некоторые относительно бесполезные части Linux системы, такие как /usr/doc и info страницы. Из моего личного опыта, они практически не используются, и эквивалентная информация может быть получена из сети при необходимости. Man`ы,только man`ы... Если конечно вам очень нужна локально установленная документация, то она есть в отдельных пакетах.<br />
<br />
Arch Linux также старается использовать самые последние достижения, которые доступны пользователям Linux, такие как поддержка Ext3/ReiserFS и udev. Arch Linux 2007.05 (Duke) использует по умолчанию udev и ядро linux версии 2.6, где есть поддержка EXT2/EXT3/REISERFS/XFS/JFS, RAID/LVM и шифрованых файловых систем.<br />
<br />
===Лицензия===<br />
Arch Linux, pacman, документация и скрипты имеют copyright ©2002-2006 Judd Vinet и лицензированы под общественной лицензией GNU.<br />
<br />
==Установка Arch Linux==<br />
===Перед установкой===<br />
Arch Linux оптимизирован для i686 или x86-64 процессоров (дистрибутив для i686 и дистрибутив для x86_64 - это два разных дистрибутива) и не будет работать на старых процессорах (i386,i486,i586). Требуется процессор Pentium II или выше. (Если вы используете старые процессоры, вас может заинтересовать проект lowarch)<br />
<br />
Перед установкой Arch Linux, вы должны выбрать способ установки. Arch Linux предоставляет три разных загрузочных ISO образа для установки с CD-ROM.<br />
<br />
Т.к предпочитаемый метод установки с помощью CD-ROM'а, мы предлагаем Вам три варианта ISO образов. Вы можете выбрать в инсталляторе установку пакетов через FTP используя любой из этих ISO образов, и все ISO также могут быть использованы в качестве восстановительного диска.<br />
<br />
*Весь 570 MB Archlinux-i686-2007.08-Don't-Panic.current.iso содержит текущий репозитарий пакетов со времени последнего релиза. Для подробностей какие пакеты включены, проверте список пакетов доступный online. Используя этот образ, создав установочный диск вы можеет установить полную рабочую Линукс систему включая некоторые свистелки и перделки такие, как менеджер окон и хорошую связку программ, которые обычно не рассматриваются обязательными, и все же не все приложения могут быть включены, кторые вы желаете использовать. Если Вы вообще не имеете доступа в Интернет с вашей текущей машины, скорее всего будет хорошей идеей последовать этому варианту увеличив количество пакетов доступных на CD. <br />
<br />
<br />
*Значительно меньший Archlinux-i686-2007.08-Don't-Panic.base.iso (150MB) содержит только основные пакеты и ядро, в остальном они идентичны. Пожалуйста учтите что больше не необходимо загружать полный iso образ, если вы планируете использовать RAID/LVM во время установки поскольку необходимые пакеты были перемещены недавно в категорию base. Устанавливая с диска систему созданого с этим образом, приведет к полностью функциональной linux системе, без любых оборок, готовой к использованию командной строки. Этот образ идеально подходит для минималистов и экспертов, которые хотят только базовую, рабочую систему и начинают с этого, но довольно медленное интернет соединение делает установку по FTP почти неосуществимой. <br />
<br />
<br />
* Наконец, есть другой вариант доступный для высокоскоростных линий инета, крохотный 26 MB Archlinux-i686-2007.08-Don't-Panic.ftp.iso содержит только минимум для запуска установки. Этот вариант не содерижит пакеты вобще, и поэтому пригоден только для установке по FTP, особенно если у вас быстрый интренет или есть локальный сервер с репозитариями пакетов. Это самый быстрый путь с 22мб начать установку ArchLinux, и имеет дополнительное преимущество использования новейших пакетов доступных во время установки, вместо пакетов включенных в другой диск. Конечно все пакеты которые в выбрали для установки будут скачены из сети, но по крайней мере вам не надо бдет обновлять систему прямо после установки. Если у вас быстрый и дешевый интернет, выберете этот образ.<br />
<br />
Если у вас нет CD-ROM в вашем компьютере, вы конкретно застряли.<br />
<br />
Получите установочный CD Arch, скачав и записав образ на диск или купив его в магазине.<br />
<br />
Вы можете не беспокоиться если используете старый установочный диск. Система может быть приведена в состояние, соответствующее состоянию обновленной, одной командой. При условии, что у вас есть хороший Интернет-канал.<br />
<br />
Для успешной установки с FTP вам нужен шлюз имеющий выход в интернет, который мог бы выполнять маршрутизацию или FTP сервер с дистрибутивом в локальной сети.<br />
<br />
Использую соединение dialup PPP тепреь можно получить доступ к интернету во время установки. ppp утилиты, rp-pppoe и ISDN userspace утилиты включены в установочный диск.<br />
<br />
Duke Isos теперь запускаются как и любые другие системы arch, <br />
здесь некоторые особенности: <br />
* pacman разрешает установку любого нужного пакета в установочную среду<br />
* полная поддержка /etc/rc.d/ и /etc/rc.conf<br />
* полная поддержка сети, включая ssh,telnet и portmap services<br />
* выборочная поддержка конфигов:<br />
любой диск с директорией /config и файлами будут скопированы в /etc/ установочной среды<br />
* загрузка пакетов как расширений(аддонов) во время загрузки:<br />
любой диск с директорией /packages включая pacman пакеты будут установлены во время загрузки<br />
* включенные ссылки и имена могут сообщаться с интернетом.<br />
* полная поддержка kexec<br />
<br />
Наиболее удобный способ установки для новичка - это установка пакетов группы base и пакетов для получения доступа к интернет с CD. После установки соединения с интернетом, вы сможете обновить систему до текущего состояния и установить любой из пакетов Arch.<br />
<br />
Еще одна вещь, которую вам нужно знать перед установкой - это то, что инсталятор потребует от вас подготовить жесткий диск (разбить на разделы и указать точки монтирования), указать модули для загрузки и отредактировать системные файлы, такие как lilo.conf/menu.lst и rc.conf. Инсталятор не будет проверять корректность введенных данных, следовательно вы должны четко знать как разбить диск, какие нужны модули, что писать в файлах конфигурации. Это требования для новичка, так что если это уже отпугивает вас, убедитесь что вы прочитали весь этот документ для получения хотя бы смутного представления, что будет происходить, загляните в IRC, форумы или к гуру linux, если чтолибо вам не ясно, пока вы еще не навели полный беспорядок в системе. Вы конечео можете пытаться все починить пока все не заработает, но не говорите потом что вас не предупердили. Не в обиду сказано. ;)<br />
<br />
====Что вам потребуется====<br />
* Умение работать в Линуксе и информация о устройствах внутри вашего компьютера<br />
* Установочный CD с Arch Linux<br />
* Компьютер с архитектурой i686 и выше (PPro, Pentium 2 или выше, Athlon/Duron, VIA-C7 и т.д. ВНИМАНИЕ: AMD K6, Transmeta Crusoe, CyrixIII и VIA-C3 НЕ ПОДДЕРЖИВАЮТСЯ.), или<br />
* Компьютер с архитектурой x86-64 (Pentium 4/Celeron с поддержкой x64, Athlon x64, Core2)<br />
* 96 MB RAM<br />
* Некоторое количество времени<br />
<br />
====Получение дистрибутива Arch Linux====<br />
Вы можете скачать Arch с любого зеркала. (См. страницу [http://www.archlinux.org/download].<br />
<br />
====Установка с CD====<br />
# Скачайте образ Archlinux-i686-2007.08-Don't-Panic.<версия>.iso (current, base или ftp)<br />
# Скачайте md5sum.txt файл к нему<br />
# Проверьте целостность .iso образа командой md5sum:<br />
<pre>md5sum --check md5sum.txt<br />
Archlinux-i686-2007.08-Don't-Panic.<версия>.iso: OK</pre><br />
# Запишите образ на чистую CD-R болванку (этот шаг сильно зависит от ОС/ПО которое вы используете).<br />
# Запомните все сетевые настройки, чтобы ввести их потом для установки по FTP:<br />
## IP адрес<br />
## Маска подсети<br />
## Шлюз по умолчанию<br />
## Ethernet драйвер для вашей сетевой карты (т.е.: eepro100, 8139too)<br />
<br />
===Использование CD-ROM===<br />
Если вы уже умеете загружаться с CD, вы можете пропустить эту главу и перейти к Общей процедуре установки, в которой описан процесс установки Arch.<br />
<br />
Перезагрузите ваш компьютер со вставленым в привод диском, убедившись, что ваш BIOS умеет загружаться с CD (см. руководство к материнской плате чтобы узнать, как изменить настройки установки BIOS, чтобы загрузиться с CD)<br />
<br />
В начале загрузки с CD, вы увидите приглашение к вводу. Тут вы можете ввести опции загрузки, но большинству пользователей достаточно просто нажать Enter.<br />
Если ядро по каким-то причинам не грузится, вы можете попробовать загрузить ядро без SCSI драйверов, набрав arch-noscsi.<br />
<br />
Некоторые старые приводы не хотят читать CD-RW. Если загрузки с CD не происходит без видимых причин, скорее всего причина в этом.<br />
<br />
В конце загрузки вы получите shell и инструкцию о том, что делать дальше чуть выше от приглашения shell'а. Теперь можно приступить непосредственно к установке.<br />
<br />
===Обычная процедура установки===<br />
<br />
Проверьте, что все ресурсы необходимые для установки доступны, драйвера загружены и т.д.<br />
<br />
====Этапы установки====<br />
# Загрузка национальной раскладки клавиатуры (если требуется)<br />
# Запуск инсталятора<br />
# Настройка сети (только для FTP)<br />
# Подготовка жесткого диска<br />
## Автоматическая<br />
## Разбиение на разделы<br />
## Установка соответствий разделов точкам монтирования<br />
# Выбор пакетов для установки<br />
# Установка пакетов<br />
# Настройка системы (редактирование основных файлов)<br />
# Установка ядра<br />
# Установка загрузчика<br />
# Выход из инсталятора и перезагрузка<br />
<br />
Используя доступные инструменты оболочки shell, опытные пользователи также могут подготовить жесткий диск или любые дригие устройства нужные для установки, до запуска инсталятора. Вы можеет просто пропустить этот параграф, если вы не видите необходимости для дальнейшей установки вручную. Учтите что установочный CD Arch Linux также содержит скрипт /arch/quickinst для опытных пользователей. Этот скрипт установит основной, базовый набор пакетов в указаную пользователем дерикторию. Если вы производите экзотичную установку с такими забавными устройствами как RAID и LVM, или не хотите использовать инсталятор вообще, вы возможно зохотите использовать скрипт quickinst. <br />
Все крутые ребята делают так.<br />
<br />
====Загрузка национальной раскладки клавиатуры====<br />
Если вам нужна ракладка клавиатуры отличная от US, вы можете использовать утилиту km чтобы загрузить новую раскладку. Просто наберите km в коммандной строке, дальше используйте клавишы со стрелками для выбора нужной раскладки и/или консольного шрифта.<br />
Запуск программы установки<br />
<br />
Теперь вы можеет запустить /arch/setup тем самым, вызвав программу инсталяции. После нескольких сообщений вам предоставят выбор метода инсталяции по вашему усмотрению. Если у вас быстрое интернет соединение, вы возможно предпочтете установку с FTP сервера, чтобы быть увереным, что вы получите последние пакеты вместо того, чтобы использовать потенциально устаревшие пакеты с CD-диска. Учтите что у вас возможно будут проблемы, если у вы делаете устновку по FTP с прокси с авторизацией. У вас должен быть работающий CD-ROM, т.к это почти единственный осуществимый способ установки Arch Linux.<br />
<br />
Перемещаясь по инсталлятору, убедитесь что вы выбрали DONE из подменю после выполнения каждого шага. Это сохранит любые изменения которые вы сделали и подготовит к следущему шагу. Избегайте повторных шагов в процесе установки так как это может поставить в замешательство инсталятор.<br />
<br />
Вобщето создать ваше собственное FTP зеркало довольно легко, или создать ваш собственный загрузочный установочный CD с нужными вам пакетами, создав свой CD вы упростите тиражирование арча на разные машины, в тоже самое время сохраняя высокую пропускную способность зеркал. Сделай свою и наши жизни проще, и посмотри на эти альтернативные решения!<br />
<br />
Выбрав установку с CD-ROM вы сможете установить только пакеты содержащиеся на CD, которые могут быть несколько устаревшими . Конечно это достоинство что вамн не нужно будет интернет соединение, и - поэтому рекомендованный выбор для dialup пользователей или кого - либо еще, кто не испытывает желание загружать о по крайней мере 100 MB пакетов.<br />
<br />
Выбрав оду из двух альтернатив, вам будет предоставлено меню инсталятора, со списком необходимых шагов в порядке в котором они должны быть закочены.<br />
<br />
В любой момент установки, вы можете переключиться на 5th виртуальную консоль (ALT-F5) и посмотреть вывод логов инсталятора. Используйте (ALT-F1) чтобы вернуться к первой виртуальной консоли, где запущен инсталятор, и любую F-key, если вам надо открыть другую консоль чтоб вносить изминения по какой-либо причине.<br />
<br />
====Настройка сети (только для установки с FTP )====<br />
Настройка сети позволит вам установить и сконфигурировать ваше сетевое устройство.<br />
Список всех доступных сетевых устройств предоставляется вам.<br />
Если сетевое устройство все еще не доступно, или не то что вам нужно, вы можеет перйти на другой терминал и загрузить модуль вручную. Другой вариант, вы можете просто следовать инструкциям, нажать OK, загрузить модуль, выбрав Probe command. Если инсталятор не смог найти соответсвуйщий модуль , убедитесь что вы ранее запустили коммнаду loaddisk правильно чтобы сделать модули доступными, если вы используеет флоппи. При загрузке с CD-ROM, это не обязательно. Если ваша карта все еще не доступна, убедитесь что она физически правильно подключена к компьютеры и полностью поддкрживается ядром. Иногда это необходимо получить пропиетрарные бинарные драйвера от изготовителя вашей сетевой карты, и как-нибудь скопировать его в систему и загрузив вручную. Но эта морока не для слабого сердца, и благораумней использовать другую модель сетевушки.<br />
<br />
Когда нужный модуль загружен, и ваша сетевая карта обнаружена, вы дожны выбрать какое сеетвое устройство настраивать, и вам будут даны опции для настройки сети DHCP. Если вы соединяетесь к серверу DHCP, нажмите YES и пусть инсталятор сделает все остальное. Если вы выбеоете NO, вас попросят ввести вручную сеетвые данные, которые вы записали, как вам уже было сказано.В любом случае, ваша сеть должна быть удачно настроена, и если вы скептик, вы можете проверить соединение используя стандартные средства в другой консоли.<br />
<br />
Так как автоматизм не идеален, возможно вы не сможеет успешно настроить вашу сеть. В таких редких случаях не беспокойтесь, и настройте вручную ваше устройство в другой консоли. Все что надо инсталятору прямое соединение к серверу ftp который вы выберете позже во время установки.<br />
<br />
По довольно очевидным причинам, это меню доступно только при выборе установки с ftp.<br />
<br />
====Подготовка жестких дисков====<br />
Далее отобразиться субменю предложив два варианта подготовки жестких дисков для последущей установки.<br />
<br />
=====Автоматический=====<br />
Первый пункт это пункт, который автоматически создаст разделы на вашем жестком диске на /boot, swap, и root раздел, и создаст файловые системы на всех трех разделах. Эти разделы также будут автоматически подмонтированы в соответствующие места. Чтобы быть точным, создадуться<br />
* 32 MB ext2 /boot раздел<br />
* 256 MB swap раздел<br />
* ext3 root раздел, заняв оставшеся место<br />
<br />
Реальные размеры могут быть слегка разными из-за разной геометрии дисков. Вы можете выбрать эту опцию, если вы мало знаете о разделах жесткого диска, но предупреждаем: автоматическое разбиение уничтожит все данные на выбраном диске!<br />
<br />
Прочитайте предупреждение выведеное инсталятором очень внимательно, и убедитесь что вы разбиваете именно тот жесткий диск, который вам нужен!<br />
<br />
Чтобы проверить какой диск нужно разбить откройте другой терминал (ALT-F2, Enter) и введите<br />
<pre># cfdisk -P s <name of device></pre><br />
тут будет показана текущая таблица разделов выбраного устройства, что должно быть достаточно для идентификации диска.<br />
<br />
Если не указано не одно устройство ([пусто] то все будет уничтожено! ...), если инсталятор выводит ошибку после нажатия YES - неверное устройство, убедитесь что вы загрузили все необходимые модули, если у вас SCSI, RAID, или др. устройство. Вы все еще можете загрузить любые модули, перейдя в другой терминал вводя комманды там, после вернуться к инсталятору на терминале один (ALT-F1).<br />
<br />
Если вы предпочитаете разбивать диск вручную, используйтеuse другие две опции, Partition Hard Drives и Set Filesystem Mountpoints чтобы подготовить диски по вашим вкусам как выделено ниже. В противном случае вернитесь в Main Menu после удачного авторазбиения.<br />
<br />
=====Разбивка на разделы жестких дисков=====<br />
Пропустите разбивку жестких дисков, если вы выбрали автоматический режим.<br />
<br />
В другом случае вы должны выбрать диск(и) которые хотите разделить, и вы будете перемещены в программу cfdisk где вы можеет свободно изменять разделы диска, далее нажмите [Write] и [Quit] для записи изменений и выхода.<br />
<br />
Вам нужен по крайней мере своп и корневой раздел для продолжения установки. И полезно запомнить какой раздел и куда вы будете монтировать, у вас об этом сросят при следущем шаге.<br />
<br />
=====Точки монтирования файловых систем=====<br />
Пометка точек монтирования также должна быть пропущена, если вы выбрали автоматическую разбивку вашего жесткого диска. Делайте это после того как ваши жесткие диски разбиты по вашему усмотрению, или разделены ранее на разделы каками либо другими средствами.<br />
<br />
Первый вопрос будет какой раздел использовать в качестве свопа. Выберет ранее созданный раздел свопа из списка или NONE если не хотите использовать своп вообще. Использование файла свопа не поддерживается инсталлятором; вместо этого выберете здесь NONE, закончите установку точек монтирования, и активируйте файл свопа по вашему желанию, командой swapon.<br />
<br />
После установки раздела свопа, у вас спросят какой раздел использовать для корня. Это обязательно.<br />
<br />
Этот процесс повторяется до того пока вы не выберете DONE из списка, идеально после всех разделов на котрые вы установили точки монтирования. Инсталлятор предложит /boot для всех последующих точек монтирования после выбора свопа и корневого раздела.<br />
<br />
Каждый раз когда вы монтируете раздел, у вас спросят хотите ли вы создать файловую систему на соответствующем разделе. Если вы выберете YES, у вас спросят какую файловую систему создавать (вопрос вкуса. действительно. Выберете ext3 если вы без понятия), и раздел будет отформатирован выбраной файловой системой, и уничтожив всю информацию на разделе. Это не должно быть проблемой, тем не менее скажите NO, для сохранения всех уже существующих файлов на разделе.<br />
<br />
Если вы хотите сохранить существующие данные на разделе, вам сильно рекомендуется создать резервные копии вместо того чтоб надеятся что ничего плохого не произойдет во время установки. Не говорите что я не предупредил вас!<br />
<br />
У вас не спросят какую файловую систему использовать на разделе свопа, т.к. раздел использует свою собственную специфичную файловую систему.<br />
<br />
Если вы хотите подмонтировать любые другие разделы, например отдельный /boot или /home разделы, вы можете это сделать сейчас. Просто<br />
* выберете раздел для монтирования<br />
* выберете файловую систему (если вы хотите создать ее вместо сохранения данных)<br />
* выберете точку монтирования для раздела<br />
<br />
Повторяйте эти шаги пока вы пока вы не будете довольны результатом, потом выберете DONE для создания любой файловой системы и монтируйте разделы в их соответствующие места. После форматирования и монтирования всех разделов, вы будете переброшены в Main Menu, для следующего шага.<br />
<br />
Не монтируйте /tmp на отдельный раздел, т.к. это может ввести в замешательство инсталлятор! Просто оставьте назначенный /tmp раздел не тронутым, до конца установки, и настройте вручную раздел, после загрузки системы, если вам так нужен отдельный раздел для /tmp.<br />
<br />
====Выбор пакетов====<br />
Выбор пакетов позволит вам выбрать пакеты которые вы желаете установить с CD или вашего FTP зеркала.<br />
<br />
Если вы выбрали устновку с CD-ROM, вам надо указать инсталятору следует ли ему пробовать монтировать CD самому, или вы уже подмонтировали источник с пакетами в /src. Выберете опцию соответсвующую тому что вам надо; В большинстве случаев вы захотите выбрать CD, после чего вам буден дана возможность выбрать CDROM из списка всех обнаруженых утсройств.<br />
<br />
Если вашего CD-ROM нет в списке, убедитесь что загружены любые модули, которы могут быть нужны, такие как SCSI или USB storage support.<br />
<br />
Если вы выбрали установку с FTP, вас попросят выбрать наиближайшее зеркало из списка, или выбрать CUSTOM и ввести ваш собственный полный путь FTP к источнику установки(или IP адрес), подготовленному локальному серверу в LAN, или зеркало которого нет в списке по какой либо причине и после полный путь к дериктории на сревере кторый содержит пакеты в частности файл current.db.tar.gz. интсталятор проверит адрес на достоверность, и позволит сделать правки до того как вы введете адрес и путь и позволит скачать список пакетов.<br />
<br />
Независимо какой источник вы выбрали, после получения списка пакетов вы будеет перемещены в таблицу выбора пакетов по категориям.<br />
<br />
Если произошла ошибка при получении списка пакетов , выберете другое FTP зеркало, убедитесь что ваша сеть полностю работает, и вы парвильно ввели ваш адрес сервера. Вы также можете иметь подмонтированый источник с данными в /src директорию, если вы выбирали эту опцию. Читайте внимательно сообщения? в большинстве сслучаев вам надо подправить адрес или путь к дериктории.<br />
<br />
Теперь, как только это сделано, у вас есть возможность определить целые группы пакетов из которых вы бы хотели установить пакеты, и уберить лишние не нужные вам пакеты.<br />
<br />
Любые пакеты в категории BASE должны оставаться помеченными как выбранные, при любых обстоятельствах, также можете выбрать другие категории, которые содержат пакеты, нужные вам. Пожалуйста учтите что программа выбора пакетов предложит только пакеты которые есть в выбранных вами категориях, так что если вы выбрали только BASE, вы не сможете добавить другие пакеты, чем те которые в категории BASE.<br />
<br />
Если вы хотите выбрать только самый минимум для установки, но иметь возможность обозревать все доступные пакеты, и смотреть есть ли что интересное для установки в систему, выберете all package categories, но отметъте не выбирать все пакеты по умолчанию.<br />
<br />
Выбрать все пакеты по умолчанию? вопрос может быть легко неправильно понят; В основном у вас спросят хотите ли вы все пакеты в категориях, вы просто решите выбирать их или нет.<br />
Если вы выбрали YES, целый список пакетов которые содержатся в выбранной категории будет отображен и выбран, и вам останется выкинуть не нужные пакеты.<br />
Если вы выберете NO, то же самый список пакетов отобразиться, но только пакеты категории BASE будут выбраны, и вам надо явно выбирать другие пакеты, которые вы хотите установить.<br />
<br />
Выбор NO помогает установить самый минимум!<br />
<br />
Рекомендуется установить все пакеты категории BASE, и ничего больше на данный момент. Не беспокойтесь об установке других пакетов, которые вам нужны - вы можете легко установить больше пакетов, как только ваша базовая система будет установлена и загружена. Исключение из правил это установка пакетов нужных ля установки интернет соединения. Этими пакетами обычно являются:<br />
<br />
;dhcpcd (base) : Добавтье, если авша машина использует DHCP.<br />
;isdn4k-utils (network) : Добавтье, если вы используете ISDN для dialup.<br />
;ppp (base) : Добавтье, если вы используете аналоговый модем для dialup.<br />
;wvdial (network): Добавте если вы хотите иметь простой фронтэнд для настройки аналогового модема<br />
;rp-pppoe (base) : Добавтье, если вы исользуете DSL для pseudo-dialup.<br />
<br />
Загрузочный базовый ISO не содержит каких-либо пакетов, но есть в категории BASE, так что рекомендуется получить полный ISO если вам нужен ISDN утилиты!<br />
<br />
Как только вы выбрали нужные вам пакеты, покиньте список выбора пакетов и продолжайте к следущему шагу, Установке пакетов.<br />
<br />
====Установка пакетов====<br />
Установка пакетов установит pacman и любые другие пакеты которые вы выбрали с разрешенными зависимотями, на ваш жесткий диск. Не удивляйтесь, если установиться больше пакетов, чем вы выбирали, эти пакеты являются зависимостями от тех которые вы выбрали и инсталятор не сросит разрешение на установку этих дополнительных пакетов, т.к предпологается что вы знаете что делаете.<br />
<br />
После выбора пакетов инсталятор не будет пролверять свободное мечто на диске! Эта простая на вид задача может убить кучу времени, и поэтому инсталятор просто принимает как должное, что у вас достаточно свободного места на разделах дисков. В случае если нет, установка оборвется. df -h в другом терминале может показать что один или больше разделов смонтированы на /mnt заполнены, что не есть хорошо :) Расмотрите переразметку дисков или уменьшите количество пакетов.<br />
<br />
Сообщения ошибок и вывод отладчика выводится на терминал 5 (ALT-F5). После установки пакетов, следуйте дальше, Configure System.<br />
<br />
====Конфигурация системы====<br />
Конфигурация системы позволяет вам редактировать жизнено важные конфигурационные файлы для вашей свежеустановленой системы. Вначале вам зададут вопрос позволять ли скрипту hwdetect пробовать обнаружить железо(оборудование) и произвезти некторые( даже больше) sensible defaults for your configuration files. Если у вас ет проблем\сбоев, вы должны дать согласие, and work from what it generates.<br />
<br />
Ответьте на последущие вопросы о RAID, LVM и encrypted volumes на Yes, если ваш корневой каталог находится на RAID, LVM или encrypted volume, соответсвенно чтобы атоматически добавить нужные HOOKS в mkinitcpio.conf. Иначе вы получите во время загрузки kernel panic, так как ваш корневой каталог не будет доступен во время загрузки. Большинство людей ответит на эти воросы No, даже не думайте долго об этом.<br />
<br />
После автоматической преконфигурайии у вас попросят выбрать любимый текстовой редактор? для ручной правки конфигурационных файлов это или VIM или nano. Если сомневаетесь, выбирайте nano.<br />
<br />
Если вы действительно торопитесь, вы можете полностью пропустить этот шаг и надеятся что настройки по умолчанию подойдут и будут работать, но сильно рекомендуется пройтись еще раз через список конфигов прдоставленых здесь и изменить опции соответсвующим образом. Пожалуйста обратитесь к [[#System Configuration|System Configuration]] для более подробных инструкций.<br />
<br />
====Установка ядра====<br />
При установке ядра вас спросят какое ядро устанавливать на ваш жесткий диск.<br />
<br />
Рекомендуется: Установить 2.6.x ядро с SCSI/SATA/IDE поддержкой. Что конкретно будет поддерживать ядро будет зависить от того как вы сконфигурировали ваш initial ramdisk, но по умолчанию есть подержка для всех известных SCSI, SATA, и IDE систем. Смотрите the System Configuration section для подробностей о новом initramfs, особенно о возможной проблеме с новым PATA и старым IDE драйверами.<br />
<br />
Пожалуйста учтите что релиз Arch Linux предлагает только одно ядро для установки, так как теперь initramfs создаваемый тулзой mkinitcpio очень прозрачный и гибкий.<br />
<br />
Диск включает в себя ядро 2.6.21.1. Если вы устанвливаете через FTP, будет установлено текущее ядро, доступное на FTP, которое теоретически может содержать изменения и/или несовместимость, на текущий момоент времени. Это маловероятно, но имейте ввиду.<br />
<br />
====Установка загрузчика====<br />
Теперь настал черед установки загрузчика на ваш жесткий диск, это или GRUB (рекомендуется) или LILO, в зависимости от ваши личных предпочтений.<br />
<br />
До установки загрузчика, скрипт установки попросит вас проверить соответсвуйщий конфигурационый файл, чтобы убедится в правильности настроек. Убедитесь что вы знаете на каких разделах ваш корневой каталог(root) (и /boot, если он у вас есть).<br />
<br />
Если вы выбрали устновку LILO, загрузчик будет автоматически установлен в соответсвии вашим настройкам в конфигурационом файле, в то время как GRUB потребует выбора раздела для установки загрузчика также. Здесь вы должны выбрать, что вы хотите назначить в качестве загрузочной опции LILO, которая обычно бывает /dev/hda, т.к это является the master boot record первого жесткого диска. Подробные сообщения о ошибках как обычно находятся на VC5 (виртуальная консоль 5), если что-либо идет не так.<br />
<br />
Если вы планируете ставить мультизагрузочную систему, лучшим вариантом будет установка загрузчика в root или /boot раздел, и указать этот бутсектор другому загрузчику, который вы хотите поместить в MBR.<br />
<br />
Установка загрузчика в MBR безвозвратно перепишет любой существующий загрузчик! Убедитесь, что понимаете последствия этого, если используете несколько ОС или если хотите сохранить установленный загрузчик другой ОС!<br />
<br />
====Конец установки====<br />
<br />
Установка закончилась, извлеките CD из привода, наберите reboot в коммандной строке и надейтесь на удачу!<br />
<br />
Если ваша система загрузилась, вы можете войти как суперпользователь(root) без всякого пароля, так что первым делом устновите пароль для root коммандой passwd, добавте повседневного пользователя как сказано в the User Management section, и настройте интернет соединение.<br />
<br />
Поздравляем! Теперь вы можете продолжить выполнять конфигурацию интересующих частей вашей системы.<br />
<br />
==Настройка системы==<br />
Нижеперечисленные конфигурационные файлы - основные в Arch Linux. Вы должны без проблем редактировать вручную эти файлы, потому что не существует каких-либо GUI рограмм, которые могли бы помочь вам. В этом списке большинство основных конфигурационных файлов. Если вам нужна помощь в настройке специфического сервиса, пожалуйста читайте соответсвующую man-страницу или любую другую документацию в инете. Во многих случаях, Archlinux Wiki и форумы - богатый источник для поиска помощи.<br />
<br />
Arch Linux не использует any abstraction layer для администрирования вашей системы. Как результат, вы обычно следуете инструкциям опубликоваными автором програмного обеспечения, или то что вы находите в поисковике, и это будет работать без замусоривания системы, так как системе не наплевать на это.<br />
<br />
====Конфигурационные файлы====<br />
Перед попыткой загрузки свежеустановленной системы, вы должны в последний раз взглянуть на эти файлы, чтобы убедиться все ли там правильно записано.<br />
# /etc/rc.conf<br />
# /boot/grub/menu.lst<br />
# /etc/lilo.conf<br />
# /etc/mkinitcpio.conf<br />
# /etc/hosts<br />
# /etc/fstab<br />
# /etc/modprobe.conf<br />
# /etc/modules.conf<br />
# /etc/resolv.conf<br />
# /etc/locale.gen<br />
# /etc/conf.d/*<br />
# /etc/profile<br />
<br />
=====/etc/rc.conf=====<br />
Это основной конфигурационый файл в Arch Linux. Он позволяет настроить клавиатуру, часовой пояс, имя машины, сеть и демоны и модули, профили и другое. Вы должны просмотреть все настройки в этом файле и убедиться что вы их понимаете:<br />
<br />
;LOCALE : Это установит системный язык, который будет исрользоваться всеми i18n-совместимыми приложениями и утилитами. Смотрите нижн locale.gen для доступных опций. Вы можете получить список всех доступных локалей выполнив '''locale -a''' из коммандной строки. Настройки по умолчнию подходят для англоязычных пользователей. <br />
;HARDWARECLOCK : Введите '''UTC''' если ваши часы BIOS установлены по UTC или GMT, или '''localtime''' если часы BIOS поставлены по местому времени. Если у вас устаовлена OS которая не может управлять UTC BIOS временем правильно, например Windows, в этом случае выберете localtime, в противном случае предпочтите UTC, что решает проблему декретного времени и имеет другие положительные функции. <br />
;TIMEZONE : Описывает ваш часавой пояс. Возможные часовые пояся это путь к файлу zoneinfo находящийся в дериктории /usr/share/zoneinfo. Например, немецкий часовой пояс может быть '''Europe/Berlin''', который относиться к файлу /usr/share/zoneinfo/Europe/Berlin. Если вы не знаете точное название вашего часового пояся, не слишком беспокойтесь об этом. Комманда '''tzselect''' может найти правильный часовой пояс за вас.<br />
;KEYMAP : Определяет keymap(раскладку клавиатуры) которая грузиться программой loadkeys при загрузке. Возможные keymaps находятся в /usr/share/kbd/keymaps. Пожалуйста учтите что, эти настройки годны только для вашихTTYs(консоли), но не менеджера онон или X. Орять жн для англоязычных юзероа дефолтные настройки замечательны.<br />
;CONSOLEFONT : Определяет кокой консольный шрифт загружается программой setfont при загрузке. Возможные шрифты находятся в /usr/share/kbd/consolefonts. <br />
;CONSOLEMAP: Определяет загрузку console map программой setfont при загрузке. Возможные maps находятся в /usr/share/kbd/consoletrans. Вы захотите это установить в карту(map) подходящей вам локали(напрмер 8859-1 для Latin1) если вы используете локаль utf8, и используеет программы генерирующие 8-bit вывод. Если вы используете X11 для каждодневной работы, не беспокойтесь, так как это повлияет на консольные программы.<br />
;USECOLOR : Включить ('''yes''') или выключить ('''no''') цветные сообщения при загрузке. <br />
;MOD_AUTOLOAD : Если установить "YES", Arch будет сканировать жесткий диск и пытаться автоматически загружать соответсвующие модули для вашей системы. Это делаеться при помощи hwdetect утилиты. <br />
;MOD_BLACKLIST : Это список модулей которые бы вы хотели запретить загружать при старте системы. Например, если вы не хотите слышать раздражающий спикер, вы можете добаывить модуль pcspkr в MOD_BLACKLIST. <br />
;MODULES : В этой строке вы можете отметить модули, которые вы бы хотели загружать при старте системы без необходимости привязывать их (модули) к оборудованию как это делается в modprobe.conf (или modules.conf, если вы исрользуете ядро серии 2.4.x). Просто добавтье сюда название модуля, и если необходимо пропишите нужные опции в modprobe.conf. Модуль помеченный знаком ('!') не будет запускатся при загрузке системы (это не тоже самое что и MOD_BLACKLIST), это позволяет закомментировать определенные модули, если необходимо. Определенная выгода сетевых модулей, здесь то что сетевые карты запрещеные закоментроваными модулями будет всегда обнаруживаться в том порядке как записаны модули. This prevents the dreaded interface confusion where your ethernet hardware is assigned to seemingly random interfaces after each boot. Гораздо луче путь обработать это используя статичные метки интерфейса, соответсвенно настроив udev. <br />
;USELVM : Поставтье "YES" для запуска vgchange во время sysinit, Это активирует любые группы LVM. Если вы не имеете понятия что это значит, значит это вм не нужно.<br />
;HOSTNAME : Установит hostname(имя машины), без домена. Это полностью ваш выбор, т.к вы можете составлять из букв, цифр некоторых символов например черточки. Не выпендривайтесь, придумывая имя компьютера. <br />
;INTERFACES : Здесь вы определяете настройки для ваших сетевых интерфейсов. Примеры и включенные комментарии описывают настройку достаточно полно. Если вы не пользуетесь DHCP, просто имейте ввиду, что значение переменной (чье имя должно быть эквивалентно имени настраемого устройства) определяет строку, которая будет добавлена к команде ifconfig, также как вы настраиваете устройство вручную в шелле. <br />
;ROUTES : ВЫ можете здесь прописать ваш статичный шлюз с нужным именем. Посмотрите на пример для шлюза по умолчанию, чтобы понять что к чему. Обычно указанная часть просто передается команде route add, поэтому рекомендуется чтение man route если вы не знаеет что здесь прописывать или просто оставте как есть.<br />
;NET_PROFILES : включить определенные сетевые профили во время загрузки. Сетевые профили предоставляют удобный путь управлением несколькими сетевыми конфигурациями, и предназначены для замены стандартной настройки INTERFACES/ROUTES которая все же рекомендуется для сситем столько одной сетевой конфигурацией. Если ваш компьютер будет работать в разных сетях в разное время (например ноутбук) вы должны посмотреть в дерикторию /etc/network-profiles для натройки некоторых профилей. Шаблон файла включен и можнт исрользоваться для создания новых профилей. <br />
;DAEMONS : Это просто список скриптов, которые содержаться в /etc/rc.d/ которые скорее всего будут запущены при загрузке системы. Если перед названием скрипта стоит знак (!), он не будет выполнятся. Если перед скриптом стоит "at" символ (@), тогда скрипт будет выполнятся в фоне (,стартовый скрипт не будет ждать успешного завершения, перед запуском следующего). Обычно вам не нужно менять настройки по умолчанию для старта системы, но вы будуте редактировать этот файл достаточно часто, если вы установите сервисы наподобие sshd. Восновном у Arch's такой путь, обрабатывать то что дургие обрабатывают при поомощи разных симлинков на директорию init.d.<br />
<br />
=====/boot/grub/menu.lst=====<br />
GRUB загрузчик по умолчанию в Arch Linux. Если вы хотите исрользовать GRUB, вы должны проверить и отредактировать этот файл настроив нужные загрузочные параметры , в противном случае читайте настройка LILO.<br />
<br />
Убедитесь что вы внимательно прочитали о проблеме PATA описаной в разделе про fstab.<br />
<br />
Конфигурация GRUB очень проста, наибольшее препятсвие то что он использует другую схему имен устройств, отличную от /dev; Ваши жесткие диски в челом представлены как (hd0), (hd1), и т.д., в последовательности пронумерованы в порядке появления IDE/SCSI шины, как hda, hdb, и т.д. имена в Linux. Разделы диска названы как (hd0,0), (hd0,1) и так далее, 0 обозначает первый раздел. Несколько примеров включены в дефолтный menu.lst для понимания сути.<br />
<br />
Как только вы поняли концепцию наименования устройств, все что вам надо сделать это это выбрать красивый title(заголовок) для вашего загрузочной секции(й) , исправте на правильный раздел as a parameter to the root option to have it mounted as / on bootup, и создайте строку kernel с разделом где расположено ядро и полным путем, и также любые параметры загрузки. Если используете the stock Arch 2.6.x ядро, вам также надо строка с initrd который указывет на файл initrd26.img в вашей директории /boot. Путь который вы указали в строке initrd должен быть такой же как путь к vmlinuz26 который вы прописали в троке kernel. Вы скорее всего будете довольны дефолтными настройками, просто проверте правильность данных в строчках root и kernel особенно в отношении проблемы pata! .<br />
<br />
Для написания опций загрузки которые загружают бутсектор другой OS, этот пример может быть весьма полезным. Вы скорее всего успешно запустите любую операционную систему от Microsoft, только добавтье этот блок в файл после любых других секций, и исправте раздел на тот который содержит бутсектор операционной системы, которую вы хотите загружать.<br />
<br />
<pre># (1) Other OS<br />
title My Other OS<br />
rootnoverify (hd0,1)<br />
makeactive<br />
chainloader +1</pre><br />
<br />
Для расширенной настройки других ОС, пожалйста обратитесь в инет [http://www.gnu.org/software/grub/manual/grub.html руководство GRUB].<br />
<br />
После проверки конфигурации загрузчика на предмет корректности, запросится выбрать раздел для установки сабжа. Если вы не используете еще другой загрузчик вамн надо установить GRUB в MBR этого диска, который обычно представляется соответсвуйщим именем устройства, без number suffix.<br />
<br />
=====/etc/lilo.conf=====<br />
Это конфигурационный файл загрузчика LILO. Убедитесь, что вы проверили этот файл, если хотите использовать lilo для загрузки системы. См. документацию LILO.<br />
<br />
Вы должны проверить: строки с root= в секции образа и строку с boot= в начале файла. Строки со словом root указывают устройство с корневой файловой системой. Если вы не знаете, что писать, переключитесь в другой терминал и выполните команду mount, чтобы увидеть смонтированные устройства. Найдите строку вида <имя устройства> mounted on /mnt type [...]. Имя устройства - это то, что вам нужно написать после root= в lilo.conf.<br />
<br />
Строку boot= в большинстве случаев менять не нужно. Эта строка должна быть такой же как и root=, но без номера раздела в конце. Например, если root=/dev/hda3 и вы хотите установить LILO в MBR, вы должны установить boot=/dev/hda.<br />
Если у вас установлена другая система, вам следует убедиться в возможности восстановления ее boot-сектора (например утилиты FIXBOOT/FIXMBR в windows)<br />
<br />
Для надежности оставьте опцию lba32 после строки prompt. Это поможет избежать проблем с геометрией диска.<br />
<br />
В некоторых случаях (в зависимости от вашего BIOS), LILO не будет работать бесконечно выводя код ошибки. Скорее всего это означает, что вы убрали опцию lba32, или у вас какая-то особенная конфигурация оборудования (например CD-ROM установлен как primary master, а жесткий диск как secondary slave. Поставьте ваш жесткий диск как primary master на шине IDE. В случае наличия IDE и SCSI, вам скорее всего придется поэкспериментировать, чтобы узнать номер BIOS. BIOS нумерует диски последовательно, начиная с 0x80. Если вам повезет, SCSI скажет вам BIOS ID своих устройств, но обычно он этого не делает. Обычно вы можете только гадать, как BIOS пронумеровал диски. Обычно это выглядит так:<br />
<pre>boot=/dev/hda<br />
disk=/dev/hda bios=0x80</pre><br />
<br />
Опция disk сопоставляет BIOS ID с названием устройства понятным для linux. Если все пойдет совсем плохо, вы можете попробовать GRUB вместо LILO.<br />
<br />
Как восстановить бутсектор LILO с помощью rescue-диска описано ниже.<br />
<br />
=====/etc/mkinitcpio.conf=====<br />
Этот файл позволит вам настроить initial ramdisk (ткаже упоминаемый как "initrd") для вашей системы. initrd это сжатый образ читаемый ядром во время загрузки. Цель initrd это загрузить систему до момента, когда она уже может иметь доступ к root filesystem. Это означает ему нужно загрузить любые модули, нужные для того чтобы "увидеть" устройства такие как IDE, SCSI, или SATA (или USB/FW, если вы загружаетесь от USB/FW устройства). Как только initrd загрузило нужные модули, само или через udev, оно передает контроль к Arch системе и загрузка продолжается. По этой причине, initrd может содержать только те модули? которые необходимы к доступу root filesystem. не обязательно иметь каждый модуль, кторый вы захотите когда-нибудь использовать. Большинство частоиспользуемых модулей будут загружены позже при помощи udev при загрузке.<br />
<br />
По умолчанию, mkinitcpio.conf сконфигурирован и обеспечивает всеми известными модулями для IDE, SCSI, или SATA систем через так называемые HOOKS. Это значит умольчальное initrd должно работать почти у всех. Обратная сторона этого, что грузяцццо много модулей кторые вам совсем не нужны. Это легко видно, смотря на список модулей после загрузки (командой lsmod). Ничего плохого фактически в этом нет, однако некоторые люди этим не довольны. Уменьшить этот список, оставив только то что нужно, вы можете путем правки mkinitcpio.conf и отключив подсистемы HOOKS (ie, IDE, SCSI, RAID, USB, etc) которые вам не нужны. <br />
<br />
Вы можете настроить еще больше, определяя точные модули, нужные вам в строке MODULES и удалить не нужные hooks, но внимательно прочитайте комментарии ы этом файле, т.к это чувствительный файл к необдуманным изменениям!<br />
<br />
Если вы исрользуете RAID или шифровку на вашем root filesystem, тогда вам надо подкоректировать настройки RAID/CRYPT near the bottom. Смотрите страницы wiki для RAID/LVM, filesystem encryption, и mkinitcpio для подробностей.<br />
<br />
Когда кончите настраивать mkinitcpio.conf, вы должны запустить mkinitcpio -p kernel26 от рута(root) для регенерации образа, unless you're still installing the system; В этом случае этот шаг будет сделан автоматически, после того, когда вы выберете Установка Ядра немного позже в процесе установки<br />
<br />
Предупреждение: Если вы настроите неправильно свой mkinitcpio.conf, система не загрузиться! По этой причине, вы должны быть предельно осторожными когда настраиваете этот файл. <br />
<br />
Если вы умудрились сделать систему не способной к загрузке, вы можете использовать аварийный образ (fallback image) который установлен паралельно the stock kernel. По умолчанию в GRUB и LILO эта опция вклбчена.<br />
<br />
<br />
Читайте внимательно о проблеме pata transition описанный в секции файла fstab!<br />
<br />
=====/etc/hosts=====<br />
В этом файле вы можете задать жесткую связь между IP и именем компьютеров в сети. Если имени компьютера нет в DNS, вы можете добавить его сюда. Обычно не нужно ничего менять, но возможно вы захотите добавить hostname и hostname + domain машины в этот файл, для получения IP вашего сетевого интерфейса по имени. Если вы не знаете, что тут сделать, оставьте этот файл в покое пока не прочитаете man hosts.<br />
<br />
=====/etc/fstab=====<br />
Здесь устанавливаются точки монтирования и файловые системы. Инсталятор должен создать нужные записи за вас, но вам следует взглянуть в этот файл и убедиться что все правильно, в особености если вы используете шифрованный рут раздел, LVM или RAID.<br />
<br />
С текущим ядром, важное изменение было введено, относящиесе к подсистеме ATA/IDE. Новые pata (Parallel ATA) драйвера заменяют старую подсистему IDE, и одно важное изменение то что схема имен для IDE дисков изменилась со старых hda,hdb, на имена устройств sda, sdb, etc, тка же как обозачаются устройства SCSI и SATA. Из за этого, когда используется новый pata драйвер в HOOKS файла /etc/mkinitcpio.conf, не забудте использовать соответсвующие имена устройств в /etc/fstab и конфиге загрузчика! Или, вы можете использовать /dev/disk/by-uuid/... или /dev/disk/by-label/... обозначения ваших жестких дисков, где можно быть абсолютно увереным, что вы обращаетесть к правильному разделу, и оградите себя от проблем разновидности названий, вне зависимости используете ли вы sda или hda. Если это не вариант, вот - краткое изложение; Если вы используете pata вместо ide в строке HOOKS файла /etc/mkinitcpio.conf, вы будете использовать sd? названия. Если нет, тогда названия старого стиля hd?. Поэтому важно проверить строку HOOKS файла /etc/mkinitcpio.conf, чтобы была возможность адаптировать другие файлы соответсвенно.<br />
<br />
=====/etc/modprobe.conf=====<br />
<br />
Этот файл определяет кокой модуль следует загружать ядру для оборудования, и какие опции устанавливать. <br />
Например, автоматически загрузить драйвер сетевой карты Realtek 8139 для eth0 (при попытке настройки eth0), напишите такую строчку:<br />
<pre>alias eth0 8139too</pre><br />
<br />
Синтаксис файла похож на старый modules.conf, только без экзотических опций типа post-install. Теперь вы можете полистать man modprobe.conf.<br />
<br />
Большинству людей не понадобиться редактировать этот файл.<br />
<br />
=====/etc/modules.conf (устарел)=====<br />
Этот файл нужен только для ядер 2.4.x.<br />
<br />
Он рассказывает ядру, какой модуль для какого устройства нужно загрузить. Например, автоматически загрузить драйвер сетевой карты Realtek 8139 для eth0 (при попытке настройки eth0), напишите такую строчку:<br />
<pre>alias eth0 8139too</pre><br />
<br />
=====/etc/resolv.conf=====<br />
Используйте этот файл для указания серверов DNS, которые вы будете использовать. Обычно он выглядит так:<br />
<pre>search domain.tld<br />
nameserver 192.168.0.1<br />
nameserver 192.168.0.2</pre><br />
<br />
Замените domain.tld и ip-адреса на ваш домен и адреса ваших dns-серверов. Домен - это так называемый домен поиска по умолчанию, который будет добавляться к именам компьютеров. Устанавив его, ping myhost будет преобразован в ping myhost.domain.tld. Настройка домена поиска обычно не очень важна и лишь упрощает использование имен компьютеров. (Доменов в списке поиска может быть несколько) Если вы используете DHCP, этот файл будет получен от DHCP сервера автоматически во время старта сетевого интерфейса, что означает, что вы можете игнорировать этот файл целиком. (См. man resolv.conf)<br />
<br />
=====/etc/locale.gen/=====<br />
Этот файл содержит список всех поддерживаемых локалей и кодировок достыпных вам. При выборе LOCALE в /etc/rc.conf или когда запускается программа, требуется разкомментировать нужные локали в этом файле, чтобы сделать доступные бинарные версии для системы, и запустить комману locale-gen от рута для генерации всех разкомментированых локалей и переместить их надлежайшие места. Вы должны снять # со всех локалей кторыми вы намеерваетесь пользоваться.<br />
<br />
Во время установки, вам не надо запускать вручную locale-gen, об этом позаботятся автоматически, после сохранения изменеий в этом файле.<br />
<br />
По умолчанию, все локали закомментированы, включая умольчальную en_US.utf8 отсылая в файл /etc/rc.conf file. Для гладкой работы системы, вы должны править этот файл и снять # по меньшей мере с одной локали, используемой в вашем rc.conf.<br />
<br />
=====/etc/conf.d/*=====<br />
В момент установки эти файлы совершенно не важны.<br />
<br />
Некоторые стартовые (rc) скрипты демонов используют эту директорию для хранения некоторых значений по умолчанию. Когда вы запускаете демона, скрипт сначала подключит файл из этой директории (при помощи source, см. man bash), а затем и /etc/rc.conf. Это означает, что вы можете централизовано хранить некоторые параметры демонов в rc.conf, просто добавив туда переменную с подходящим значением, или разделить вашу конфигурацию на несколько файлов, если вам так удобнее. Не правда ли жизнь была бы прекрасна, если бы все так просто скриптовалось?<br />
<br />
=====/etc/profile=====<br />
Этот скрипт выполняется при каждом входе пользователя в систему. В Arch Linux он довольно простой. Возможно вы захотите его поправить, например для добавления глобальных переменных окружения.<br />
<br />
====Загрузочные скрипты====<br />
<br />
Arch Linux использует довольно простую загрузочную последовательность похожую на *BSDs. Первый загрузочный скрипт это /etc/rc.sysinit. Когда он запущен, далее запуститься /etc/rc.multi (при нормальной загрузке). Последним запускается скрипт /etc/rc.local. Когда запустился runlevel 1, однопользовательский режим, скрипт /etc/rc.single выполняется вместо /etc/rc.multi. Вы не найдете нескончаемую коллекцию симлинков в дерикториях /etc/rc.d/ для определения всех возможных режимов начальной загрузки. На самом деле, из-из этотоо метода due to this approach Arch имеет только 3 режима (runlevels),если вы запустите X в режимеl 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 /etc/rc.d/functions script. If you plan to write your own daemon files, you should consider having a look at this file and existing daemon scripts.<br />
<br />
Обзор загрузочных скриптов<br />
# /etc/rc.sysinit<br />
# /etc/rc.single<br />
# /etc/rc.multi<br />
# /etc/rc.local<br />
# /etc/rc.shutdown<br />
# /etc/rc.d/*<br />
<br />
=====/etc/rc.sysinit=====<br />
<br />
Основной системный загрузочный скрипт. Он совершает критичные для загрузки процедуры, такие как монтирование файловых систем, запуск devfsd, активизация свопа, загрузка модулей, установка параметров локализации, и т.д. Скорее всего вы никогда не будеет редактировать этот файл!<br />
<br />
=====/etc/rc.single=====<br />
<br />
Однопользовательский скрипт. Не используется при нормальной загрузке. Если система запускается в одно-пользовательском режиме, например с параметром ядра 1 до загрузки или во время нормальной много-пользовательской загрузки с коммандой init 1, этот скрипт проверяет чтоб не было запущено демонов, кроме самого минимума; syslog-ng и udev. Однопользовательский режим полезен, если вам надо сделать изменения в системе, while making sure that no remote user can do anything that might cause data loss or damage.<br />
<br />
Для домашних пользователей этот режим обычно бесполезен ак и crud. Возможно вам никогда не понадобится править этот скрипт.<br />
<br />
=====/etc/rc.multi=====<br />
Многопользовательский загрузочный скрипт. Он запускает все демоны сконфигурированые вами в строке DAEMONS (устанавливается в /etc/rc.conf) после чего он вызывает /etc/rc.local. Вы не должны чувствовать потребности в редактировании этого файла.<br />
<br />
=====/etc/rc.local=====<br />
Локальный многопользовательский загрузочный скрипт. Это хорошее место чтобы поместить сюда любые команды которые вы хотите запускались бы в конце загрузки системы. Это один и единственный скрипт, который вы должны править при необходимости, и вы имеете полную свободу, что добавлять в этот скрипт.<br />
<br />
Большинство обычных задач системной конфигурации, такие как загрузка модулей, изменение консольного шрифта мили установке устройства, обычно имеют специальнле место where they belong. Избегая беспорядка, вы должны быть уверены, не важно что вы назначили добавить в ваш rc.local isn't feeling just as home in /etc/profile.d/ or any other already existant config location instead.<br />
<br />
=====/etc/rc.shutdown=====<br />
System shutdown script. Он останавливает демонов, отмонтировает файловые системы, деактивирует своп и т.д. Просто не трогайте этот файл.<br />
<br />
=====/etc/rc.d/*=====<br />
Эта дериктория содержит скрипты демонов ссылающиеся с строки DAEMONS файла rc.conf. В дополнение to being called on bootup, you can use these scripts when the system is running to manage the services of your system. Например коммнада<br />
<pre># /etc/rc.d/postfix stop</pre><br />
<br />
остановит демона postfix. Конечно скрипт существует тлоько когда соответсвущий пакет установлен(в этом случае postfix). При установленной базовой системе, здесь мало скриптов, но будте уверены что все существующие скрипты демонов живут здесь. Эта директория больше похожа на /etc/rc3.d/ или /etc/init.d/ директории других дистрибутивов, without all the symlink hassle.<br />
<br />
====Управление пользователями====<br />
<br />
Пользователи и группы могут быть добавлены/удалены с помощью стандартных команд из пакета util-linux: useradd, userdel, groupadd, groupdel, passwd, and gpasswd. Обычно добавляют пользователей так:<br />
<pre># useradd -m -s /bin/bash vasya<br />
# passwd vasya</pre><br />
<br />
Первая команда добавит пользователя vasya, сделав ему домашнюю директорию /home/vasya и поместит туда некоторые файлы из каталога /etc/skel. Команда также задаст шелл по умолчанию /bin/bash. Вторая команда попросит поменять пароль для пользователя vasya. Задание пароль необходимо для активации учетной записи.<br />
<br />
Альтернатива команде useradd - скрипт adduser который создает пользователя интерактивно спрашивая у вас нужную информацию.<br />
<br />
См man-страницы для более полной информации. Хорошая идея создать пользователей для повседневных нужд наилучшим образом использовав средства разграничения доступа и сведя к минимуму риск случайного удаления файлов при входе в систему пользователем root.<br />
<br />
Никогда не входите в систему пользователем root. Используйте команды su или sudo. (См. man su, man sudo)<br />
<br />
===Доступ в Internet===<br />
Из-за нехватки разработчиков с dialup'ом, настройка dialup соединения требует совершить много действий вручную. Если это вообще возможно, настройте отдельный маршрутизатор который будет шлюзом по умолчанию для вашей Arch-машины.<br />
Есть некоторое количество документов по настройке dialup соединения в Arch Linux Wiki.<br />
<br />
====Аналоговый модем====<br />
Для использования Hayes-совместимого внешнего аналогового модема, вам нужно как минимум установить пакет ppp. Измените файл /etc/ppp/options как вам нужно в соответствии с man pppd. Вам потребуется создать chat скрипт для дозвона и передачи имени пользователя и пароля вашему провайдеру после установления соединения. Man-страницы pppd и chat содержат примеры которых достаточно для настройки если вы достаточно опытны или упорны. При использовании udev, ваши последовательные порты обычно называются /dev/tts/0 и /dev/tts/1.<br />
<br />
Вместо непосредственной настройки pppd, вы можете попробовать установить wvdial или похожую утилиту (например kppp из пакета kdenetwork) для упрощения настройки.<br />
Если вы используете так называемый Win-модем, который обычно является PCI картой работающей как внутренний аналоговый модем, вам нужно поискать информацию о вашем модеме на домашней странице LinModem (http://www.linmodems.org).<br />
<br />
====ISDN====<br />
Три шага по настройке ISDN:<br />
<br />
# Установить и настроить железо<br />
# Установить и настроить утилиты<br />
# Добавить настройки вашего провайдера<br />
<br />
Почти все пассивные ISDN PCI карты работают с модулем hisax, которому нужно два параметра: тип и протокол. Протокол = '1', если вы используете стандарт 1TR6, '2' - если EuroISDN (EDSS1), '3' - если это выделенная линию без D-канала, и '4' для US NI1.<br />
<br />
Список возможных типов карт приведен в файле README.HiSax в документации ядра. Загружайте модуль таким образом:<br />
<pre># modprobe hisax type=18 protocol=2</pre><br />
<br />
(Для ELSA Quickstep 1000PCI с протоколом EDSS1)<br />
<br />
Не забудьте загрузить USB модули, если используете USB ISDN адаптер.<br />
<br />
После того как вы убедились, что карта работает добавьте в /etc/modprobe.conf:<br />
<pre>alias ippp0 hisax<br />
options hisax type=18 protocol=2</pre><br />
<br />
Или только строку с опциями и добавьте модуль в массив MODULES в /etc/rc.conf.<br />
<br />
Установите пакет isdn4k-utils и прочитайте man isdnctrl. Затем создайте конфигурацию понятную программе isdnctrl.<br />
Нужно через запятую добавить SPID к настройкам MSN если вы используете US NI1.<br />
<br />
Далее отредактируйте /etc/ppp/pap-secrets или /etc/ppp/chap-secrets в соответствии с настройками провайдера.<br />
<br />
====DSL (PPPoE)====<br />
В этой главе описан случай, когда ваш компьютер подключен непосредственно к провайдеру при помощи PPPoE.<br />
<br />
Сначала вы должны активировать сетевую карту к которой подключен DSL модем или витая пара, идущая к провайдеру. После загрузки соответствующего драйвера, вы должны установить пакет rp-pppoe и запустить скрипт adsl-setup, который задаст вам все необходимые вопросы. Теперь вы можете подключаться и отключаться от интернета при помощи команд:<br />
<pre># /etc/rc.d/adsl start</pre><br />
и<br />
<pre># /etc/rc.d/adsl stop</pre><br />
соответственно. Настройка обычно легка и понятна, но на всякий случай можете почитать страницы man. Для автоматического подключения при загрузке, добавьте adsl в массив DAEMONS в /etc/rc.conf.<br />
<br />
==Система управления пакетами==<br />
===Pacman===<br />
pacman - это система управления пакетами, которая следит за всем программным обеспечением, установленной на вашу систему. Он имеет простую поддержку зависимостей и использует стандартный tar-gz архивный формат для всех пакетов. Некоторые общие задачи с соответствующими командами в длинной и короткой форме записи, объясняются ниже. Читайте man pacman, для того чтобы всегда правильно понимать опции pacman. Этот обзор только поверхностно объясняет текущие особенности pacman'а.<br />
Типичные задачи:<br />
# Добавление нового пакета из пакетного файла.<br />
# Обновление пакета из пакетного файла.<br />
# Удаление пакетов.<br />
# Обновление списка пакетов.<br />
# Обновление системы.<br />
# Добавление/Обновление пакета из репозиториев.<br />
# Вывод списка установленных пакетов.<br />
# Проверка того, установлен ли данный пакет.<br />
# Информация о данном пакете.<br />
# Список файлов, содержащихся в пакете.<br />
# К какому пакету принадлежит данный файл.<br />
<br />
====Добавление нового пакета из пакетного файла====<br />
<pre># pacman --add foo.pkg.tar.gz<br />
# pacman -A foo.pkg.tar.gz</pre><br />
<br />
Результатом будет установка пакета foo.pkg.tar.gz в вашу систему. Если в зависимостях есть какая-то ошибка , pacman возвращает ошибку и сообщает об ошибочных зависимостях, но не старается автоматически разрешить их. Смотри опцию --sync, если вам нужна данная функциональность.<br />
<br />
====Обновление пакета из пакетного файла====<br />
<pre># pacman --upgrade foo.pkg.tar.gz<br />
# pacman -U foo.pkg.tar.gz</pre><br />
<br />
Обновление пакета. Фактически представляет собой удаление старого и установку нового пакета.<br />
<br />
====Удаление пакетов====<br />
<pre># pacman --remove foo<br />
# pacman -R foo</pre><br />
<br />
Удаляются все файлы, относящиеся к пакету foo, кроме тех конфигурационных файлов, которые редактировались. При написании имени пакета к этой команде не надо указывать окончание .pkg.tar.gz.<br />
<br />
Для удаления всех без исключения пакетов, добавьте опцию --nosave.<br />
<br />
====Обновление списка пакетов====<br />
<pre># pacman --sync --refresh<br />
# pacman -Sy</pre><br />
<br />
Получение свежей версии списка пакетов из репозиториев, указанных в конфигурационном файле /etc/pacman.conf и разархивирование в область базы данных. Чтобы быть уверенным, что вы получили самые новые пакеты, используйте опцию --sysupgrade. В зависимости от ваших опций, указанных в файле pacman.conf, эта команда может требовать работающее интернет-соединение для доступа к FTP репозиториям. Эта опция немного похожа на apt-get update в Debian.<br />
<br />
====Обновление системы====<br />
<pre># pacman --sync --sysupgrade<br />
# pacman -Su</pre><br />
<br />
Обновление всех устаревших пакетов на вашей системе путем сравнения версии локального пакета с версиями пакетов из списка, который был скачен командой --refresh. Запускайте эту команду, если хотите поддерживать систему в актуальном состоянии. Кстати, эта команда не подразумевает обновление списка пакетов, поэтому правильнее комбинировать обе команды в одну:<br />
<pre># pacman --sync --refresh --sysupgrade<br />
# pacman -Syu</pre><br />
<br />
С этими опциями pacman автоматически получит текущий список пакетов, и сделает полное обновление системы к последним версиям пакетов с автомагически определенными зависимостями.<br />
<br />
====Добавление/Обновление пакета из репозиториев====<br />
<pre># pacman --sync foo<br />
# pacman -S foo</pre><br />
<br />
Получает и инсталлирует пакет foo со всеми требуемыми зависимостями. Перед использованием опции sync убедитесь, что вы обновили список пакетов перед попыткой инсталляции (добавьте --refresh или -y к опциям). В отличие от --add, --sync не делает различия между добавлением и обновлением пакета.<br />
<br />
В зависимости от pacman.conf может потребоваться работающее интернет-соединение. <br />
<br />
====Вывод списка установленных пакетов====<br />
<pre># pacman --query<br />
# pacman -Q</pre><br />
<br />
Показывает список всех установленных приложений в системе.<br />
<br />
====Проверка того, установлен ли данный пакет====<br />
<pre># pacman --query foo<br />
# pacman -Q foo</pre><br />
<br />
Вместо того чтобы применять команду grep ко всему установленному списку пакетов, проще пользоваться опцией --query к команде pacman. Если пакет foo инсталлирован, эта команда покажет его имя и версию, иначе ничего не покажет.<br />
<br />
====Информация о данном пакете====<br />
<pre># pacman --query --info foo<br />
# pacman -Qi foo</pre><br />
<br />
Показывает информацию об установленном пакете foo (его размер, дату инсталляции, дату сборки, зависимости, конфликты и т.д.). Если нужно показать информацию о пакете, который не установлен в системе, добавьте опцию --file или -p):<br />
<pre># pacman --query --info --file foo.pkg.tar.gz<br />
# pacman -Qip foo.pkg.tar.gz</pre><br />
<br />
====Список файлов, содержащихся в пакете====<br />
<pre># pacman --query --list foo<br />
# pacman -Ql foo</pre><br />
<br />
Показывает список всех файлов, относящихся к пакету foo.<br />
<br />
====К какому пакету принадлежит данный файл====<br />
<pre># pacman --query --owns /path/to/file<br />
# pacman -Qo /path/to/file</pre><br />
<br />
Этот запрос показывает имя и версию пакета, который содержит файл /path/to/file.<br />
<br />
===Доступ к репозиториям===<br />
Репозиторий - это сборник пакетов и мета-информации о них, который может находится в локальной директории или на внешнем FTP/HTTP сервере. Репозиторий current является репозиторием по-умолчанию системы Arch. У него всегда самые последние версии большинства ПО and stays fairly bleeding-edge.<br />
<br />
Большинство пользователей также подключают репозиторий extra, который содержит намного больше пакетов, и они не являются частью Arch. Чтобы подсоединить этот репозиторий, нужно раскомментировать соответствующие строки в /etc/pacman.conf.<br />
<br />
Можно также создавать, поддерживать в актуальном состоянии, использовать свой собственный репозиторий. За инструкциями обращайтесь к man-странице pacman.<br />
<br />
Если есть проблемы с интернетом, то устанавливайте с CD. Просто подключаете CD и устанавливаете пакеты, используя команду pacman -A packagename.pkg.tar.gz. Возможно также сделать локальный репозиторий для доступа к CD. Примонтируйте CD, например, в /mnt/cd, командой '''mount /mnt/cd''' (предполагается, что fstab правильно настроен), затем добавьте следующие строки в /etc/pacman.conf:<br />
<br />
<pre>[cd]<br />
Server = file:///mnt/cd/arch/pkg</pre><br />
<br />
После этого можете устанавливать соответствующие пакеты для поднятия интернет-соединения.<br />
<br />
==Система сборки Arch (ABS)==<br />
===Binary vs. Source===<br />
Как pacman отвечает за двоичный код, так и ABS отвечает за исходники: она помогает вам построить свои собственные пакеты из исходников, также позволяя вам перестраивать Arch Linux пакеты с вашими собственными пользовательскими настройками. Эта процедура обычно происходит так:<br />
# Синхронизируйте ваше дерево ABS с сервером (запустите abs как root).<br />
# Создайте новую директорию в /var/abs/local, имя которой будет совпадать с названием создаваемого пакета.<br />
# Скопируйте файл-пример PKGBUILD.proto из /var/abs в вашу только что созданную директорию, удалите окончание .proto, и исправьте его для нового пакета.<br />
# Запустите makepkg в рабочей директории с PKGBUILD файлом.<br />
# Инсталлируйте только что созданный пакет pacman'ом.<br />
# Пошлите пакет своим друзьям (или дайте его какому-нибудь продвинутому пользователю ArchLinux (Archer), чтобы он/она вставил/а в главное дерево ABS).<br />
<br />
===Синхронизация дерева ABS===<br />
Вы можете синхронизировать все PKGBUILD'ы в директорию /var/abs запустив скрипт abs с правами root. Он требует установленный пакет cvsup. Использование CVS позволяет иметь несколько версий ABS - это настраивается в /etc/abs/supfile.*.<br />
<br />
ABS умеет синхронизировать несколько репозиториев, список которых есть в /etc/abs/abs.conf. По умолчанию это current и extra.<br />
<br />
====Как собрать пакет?====<br />
<br />
Процесс сборки описан в man makepkg.<br />
<br />
====Как сделать новый пакет самому?====<br />
<br />
Читайте [[Arch_Packaging_Standards(Русский)]], если хотите создавать новые пакеты сами.<br />
<br />
==Частые вопросы==<br />
ЧаВо приведенные ниже относятся только к установке и загрузке свежеустановленной системы Arch Linux. Если у вас есть вопросы по поводу дальнейшего использования системных утилит, настройки X Window и пр., настройки оборудования, смотрите другие страницы Wiki. Если вы столкнулись с неописаной здесь проблемой, дайте знать автору этого документа.<br />
<br />
===Во время установки pacman ругается на неразрешенные зависимости пакета А, потому что не может найти пакет Б===<br />
<br />
Если это не глобальная поломка, то возможно вы неправильно смонтировали или не смонтировали установочный раздел. Это приводит к заполнению ramdisk'а и pacman выдает подобные ошибки.<br />
<br />
Убедитесь, что нажали DONE, а не CANCEL в меню Filesystem Mountpoints. Если вы используете Auto-Prepare такой ошибки быть не должно, и если она есть - сообщите о ней.<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 downloading them, then mount the install CD somewhere (eg, /mnt/cd) and add this line right below the [current] line in /etc/pacman.conf:<br />
<pre>Server = file:///mnt/cd</pre><br />
<br />
Replace /mnt/cd with the mountpoint you chose. Then use pacman --sync as you normally would - It will now check the /mnt/cd directory first 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 want to create and use multiple swap partitions. Create the partitions manually instead, and create as much swap partitions as your little heart desires. Go through the rest of the install, don't mind that you're only asked for one swap partition during the mount-point setting. Once you're through with the install and are about to edit your system configuration files, you can edit the fstab file and include a line for every swap device you created earlier. Simply copy the automatically generated swap line, and modify the referenced device according to your setup. The additional swaps will be activated after the bootup when swapon -a is being run by the initscripts.<br />
<br />
If, for any odd reason, you can not wait until after the installation with activating multiple swap partitions or files, you will have to open a shell on one of the virtual terminals and issue the swapon <device> for every swap drive or file you partitioned/readied before. Then continue as explained above with the install.<br />
<br />
In case you are honestly contemplating setting up multiple swap files or drives, you should keep in mind that a kernel that needs to swap is actually crying bitterly for more RAM, not more swap space. Please keep your penguin well fed. Thank you.<br />
<br />
===How do I reconfigure LILO from the rescue system?===<br />
As a first step you simply boot from the Arch Install CD or disks. If your partitions are intact and don't need checking, you should supply the root= kernel boot parameter as the instructions tell you. That will boot directly into your system, and you can skip all but the last step of actually reconfiguring and running lilo.<br />
<br />
If you cannot boot your old root directly, boot the CD as if you were going to start an installation. Once you're in a shell, you mount the root partition of your harddisk into the /mnt directory, for example like this:<br />
<pre># mount /dev/hda3 /mnt</pre><br />
<br />
Then you mount any other partitions to their respective mount points within that root of yours, for example a /boot partition:<br />
<pre># mount /dev/hda1 /mnt/boot</pre><br />
<br />
Now you need to mount a /dev tree in the /mnt area, where lilo will be able to find it:<br />
<pre># /mnt/bin/mount --bind /dev /mnt/dev</pre><br />
<br />
Once everything is mounted, make this /mnt directory your new root with the chroot /mnt command. This will start a new shell and drop you 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 anything that needs fixing. Simply type exit when you want to break out of this root again, back into the original file tree. You can now reboot and test your changes.<br />
<br />
===Не могу зайти на свою машину через ssh!===<br />
Отредактируйте /etc/hosts.deny. По умолчанию все входящие соединения запрещены.<br />
<br />
===How should I load modules during boot now?===<br />
<br />
If you want to load a module unconditionally without a specific device binding, add the name of the module to the MODULES array of your /etc/rc.conf. For on demand loading on device access, add it as usual with the alias command to your /etc/modprobe.conf (/etc/modules.conf for 2.4 kernels). To pass any options to a module you want to load through the MODULES array, only add the appropriate options line to the /etc/modprobe.conf.<br />
<br />
===Kernel refuses to boot because of lost interrupt===<br />
<br />
Kernel refuses to boot. It locks at:<br />
<pre>IRQ probe failed for hda<br />
hda lost interrupt</pre><br />
<br />
This error occurs for some HD controllers on kernel 2.6.x. A workaround is to pass the acpi=off option to the kernel at boot time.<br />
<br />
===I get access denied errors trying to play sound or read DVDs.===<br />
<br />
Add your user to the optical and audio groups.<br />
<pre># gpasswd -a johndoe optical<br />
# gpasswd -a johndoe audio</pre><br />
<br />
Logout, then login as your regular user (eg, johndoe) so the group changes can take effect.<br />
<br />
If you have a DVD drive, you may want to create a /dev/dvd symlink to your real DVD device.<br />
<br />
For example, if you use udev and your DVD drive is on /dev/hdc, you can do the following as root:<br />
<pre># cat >>/etc/udev/rules.d/00.rules <<EOF<br />
> KERNEL="hdc", NAME="hdc", SYMLINK="dvd"<br />
> EOF<br />
# /etc/start_udev<br />
# mount /dev/pts<br />
# mount /dev/shm</pre><br />
<br />
===When trying to install packages with pacman, I get this: error: xorg conflicts with xfree86.===<br />
<br />
This is a temporary problem as we make a full switch over to xorg. Currently, some packages still depend on xfree86 specifically, so pacman gets confused.<br />
<br />
You can fix this problem by installing xorg explicitly, then installing other packages afterwards.<br />
<br />
<pre># pacman -S xorg<br />
# pacman -S otherpkg1 otherpkg2 ...</pre></div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31560
Timezone (Русский)
2007-11-01T12:11:27Z
<p>Cucullus: </p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Русский]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное) или по местному (local time) времени.<br />
Как правило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно установливаются по местному времени.<br />
<br />
Установить режим машинных часов можно через переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>UTC</code>, то Linux переведёт часы с зимнего на летнее время (и обратно) вне зависимости от того работал компьютер в момент перехода на другое время или нет. (неплохо было бы перефразировать ;)<br />
<br />
'''ВАЖНО:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (и обратно), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботятся о переводе часов. В противном случае Вам придётся перевести часы вручную.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=TIMEZONE&diff=31531
TIMEZONE
2007-10-31T17:18:05Z
<p>Cucullus: traslation added</p>
<hr />
<div>[[Category: System administration (English)]]<br />
[[Category:Internationalization (English)]]<br />
[[Category:HOWTOs (English)]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_links_end}}<br />
== What is it ==<br />
<br />
The <code>TIMEZONE</code> variable is specified in the <code>/etc/rc.conf</code> file. It defines what timezone is the computer clock showing.<br />
<br />
== What can it be ==<br />
The complete list of possibilities can be shown using this command:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC vs. localtime ==<br />
The hardware clock can be set to UTC or to local time.<br />
Usually hardware clock on Linux machines is set to UTC time. If you use Linux with Windows on the same machine, then your clock is usually set to local time.<br />
<br />
Setting hardware clock mode is done via <code>HARDWARECLOCK</code> variable:<br />
HARDWARECLOCK="UTC"<br />
or<br />
HARDWARECLOCK="localtime"<br />
'''NOTE:''' As of current version of initscripts setting <code>HARDWARECLOCK</code> to any value other than <code>"UTC"</code> or just leaving it empty is the same as <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
<br />
'''NOTE:''' Linux will change to and from DST when the <code>HARDWARECLOCK</code> setting is set to <code>UTC</code>, regardless of whether Linux was running at the time DST is entered or left.<br />
<br />
'''IMPORTANT:''' When the <code>HARDWARECLOCK</code> setting is set to <code>localtime</code>, Linux will '''not''' adjust the time, operating under the assumption that your system may be a dual boot system at that time and that the other OS takes care of the DST switch. If that was not the case, the DST change needs to be made manually.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31530
Timezone (Русский)
2007-10-31T17:16:36Z
<p>Cucullus: /* UTC и localtime */</p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Internationalization (Русский)]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное) или по местному (local time) времени.<br />
Как правило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно установливаются по местному времени.<br />
<br />
Установить режим машинных часов можно через переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>UTC</code>, то Linux переведёт часы с зимнего на летнее время (и обратно) вне зависимости от того работал компьютер в момент перехода на другое время или нет. (неплохо было бы перефразировать ;)<br />
<br />
'''ВАЖНО:''' Если переменная <code>HARDWARECLOCK</code> установлена в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (и обратно), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботятся о переводе часов. В противном случае Вам придётся перевести часы вручную.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31529
Timezone (Русский)
2007-10-31T17:09:52Z
<p>Cucullus: /* UTC и localtime */</p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Internationalization (Русский)]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное) или по местному (local time) времени.<br />
Как правило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно установливаются по местному времени.<br />
<br />
Установить режим машинных часов можно через переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Linux will change to and from DST when the <code>HARDWARECLOCK</code> setting is set to <code>UTC</code>, regardless of whether Linux was running at the time DST is entered or left.<br />
<br />
'''ВАЖНО:''' Если <code>HARDWARECLOCK</code> установлено в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (и обратно), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботятся о переводе часов. В ином случае Вам придётся перевести часы вручную.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31528
Timezone (Русский)
2007-10-31T17:07:19Z
<p>Cucullus: /* UTC и localtime */</p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Internationalization (Русский)]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное) и по местному (local time) времени.<br />
Как привило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно установливаются по местному времени.<br />
<br />
Установить режим машинных часов можно чере переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Linux will change to and from DST when the <code>HARDWARECLOCK</code> setting is set to <code>UTC</code>, regardless of whether Linux was running at the time DST is entered or left.<br />
<br />
'''ВАЖНО:''' Если <code>HARDWARECLOCK</code> установлено в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (и обратно), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботятся о переводе часов. В ином случае Вам придётся перевести часы вручную.</div>
Cucullus
https://wiki.archlinux.org/index.php?title=Timezone_(%D0%A0%D1%83%D1%81%D1%81%D0%BA%D0%B8%D0%B9)&diff=31527
Timezone (Русский)
2007-10-31T17:04:58Z
<p>Cucullus: </p>
<hr />
<div>[[Category: Настройка системы]]<br />
[[Category: Internationalization (Русский)]]<br />
[[Category: Русские HowTo]]<br />
{{i18n_links_start}}<br />
{{i18n_entry|English|TIMEZONE}}<br />
{{i18n_entry|Nederlands|Tijdzone}}<br />
{{i18n_entry|Українська|Часовий пояс}}<br />
{{i18n_entry|Русский|Часовой пояс}}<br />
{{i18n_links_end}}<br />
== Что это такое ==<br />
Переменная <code>TIMEZONE</code> задаётся в файле <code>/etc/rc.conf</code>. Она определяет часовой пояс, которому соответствует время, показываемое машинными часами.<br />
<br />
== Какие могут быть варианты ==<br />
Полный список всех возможных вариантов можно увидеть выполнив:<br />
pacman -Ql glibc | grep zoneinfo | grep -v posix | grep -v right | grep -v .tab | grep -v /$ | sed "s@glibc /usr/share/zoneinfo/@ @"<br />
<br />
== UTC и localtime ==<br />
Машинные часы могут быть установлены по UTC (универсальное) и по местному (local time) времени.<br />
Как привило, часы на Linux-машинах устанавливаются в UTC. Если Вы используете Linux и Windows на одном компьютере, тогда часы обычно установливаются по местному времени.<br />
<br />
Установить режим машинных часов можно чере переменную <code>HARDWARECLOCK</code>:<br />
HARDWARECLOCK="UTC"<br />
или<br />
HARDWARECLOCK="localtime"<br />
'''ПРИМЕЧАНИЕ:''' Текущая версия загрузочных скриптов в случае отличия значения <code>HARDWARECLOCK</code> от <code>"UTC"</code> устанавливает <code>HARDWARECLOCK="localtime"</code>.<br />
<br />
'''ПРИМЕЧАНИЕ:''' Linux will change to and from DST when the <code>HARDWARECLOCK</code> setting is set to <code>UTC</code>, regardless of whether Linux was running at the time DST is entered or left.<br />
<br />
'''Важно:''' Если <code>HARDWARECLOCK</code> установлено в значение <code>localtime</code>, то Linux '''не будет''' переводить часы с зимнего на летнее время (и обратно), считая, что на Вашей машине установлена ещё одна (или несколько) ОС, которые сами позаботяться о переводе часов. В ином случве Вам придётся перевести часы вручную.</div>
Cucullus