ArchLinux Installation Tutorials

Source: Internet
Author: User
Tags get ip locale arch linux

First, prepare 1. Download image

Download the latest ISO image file here, use PowerISO or DD to burn to USB flash drive

$ dd bs=4M if=/path/to/archlinux.iso of=/dev/sdx && sync
2. Booting from USB stick

Boot after startup, you may need to close secure boot in the BIOS
Confirm whether the boot mode is EFI

# ls /sys/firmwre/efi/efivars
II. installation 1. Connection network (WLAN) interface activation: IP
    • Use rfkill list to see if the WLAN is locked and unlocked if it is locked rfkill unblock .
    • Using the ip link interface name to view the WLAN, similar to WLP9S0, use the
    • Activating the WLAN interface, using the ip link set <wlan> up activation interface, after activation, ip link you can see that the status of the WLAN interface is displayed as similar
Wireless connection: IW
    • Use iw dev <wlan> scan | less to view the scanned access point
    • Using the iw <wlan> connect connection reference wiki
设接入点SSID为<SSID>无加密:# iw dev <wlan> connect <SSID>WEP加密使用十六进制或 ASCII 密码(格式是自动识别出来的,因为 WEP 密码长度是固定的):# iw dev <wlan> connect <SSID> key 0:<KEY>使用十六进制或 ASCII 密码,第三个是默认 (从0计数,共四个)# iw dev wlan0 connect your_essid key d:2:your_keyWPA/WPA2加密WPA/WPA2# wpa_supplicant -i <wlan> -c <(wpa_passphrase <SSID> <KEY>)
Get IP:DHCP
# dhcpcd <wlan>
2. Partition: Gdisk, MKFS set up partition

Use gdisk /dev/sdx the option to select the specified hard disk for partitioning, the following are the commands commonly used in Gdisk:

    • ? Print the available commands
    • P Print Partition Table
    • o New GPT partition table
    • N New Partition
    • D Delete Partition
    • Q Do not change the partition table and exit directly
    • W will change the actual write to the hard disk

It is generally necessary to create at least the new/located partition (type code 8300), and you can mount the home or var directory to a separate partition. If necessary, you can also create a swap partition (type Code 8200), and if it is a blank hard disk, you also need to build the EFI partition (type code EF00)

formatting partitions
# mkfs.vfat -F32 /dev/sda1# mkfs.ext4 /dev/sda2 # mkswap /dev/sda3 # swapon /dev/sda3
Mount Partition: Mount
# mount /dev/sda2 /mnt # mkdir -p /mnt/home /mnt/boot/efi # mount /dev/sda1 /mnt/boot/efi
3. Install the base system selection software source

Edit /etc/pacman.d/mirrorlist , add the source used. Such as

Server=https://ipv6.mirrors.ustc.edu.cn/archlinux/$repo/os/$arch

and then refresh

# pacman -Sy
Basic system
# pacstrap /mnt base base-devel
Generate Fstab
# genfstab -pU /mnt >> /mnt/etc/fstab
4. Configure Chroot to the new system
# arch-chroot /mnt /bin/bash
Language regions

Edit /etc/locale.gen , remove a few lines of comments

en_US.UTF-8 UTF-8 zh_CN.GB18030 GB18030 zh_CN.GBK GBK zh_CN.UTF-8 UTF-8 zh_CN GB2312

And then run

# locale-gen

Last edited/etc/locale.conf

LANG=en.UTF-8
Terminal font (optional)

Edit /etc/vconsole.conf :

KEYMAP=usFONT=Lat2-Terminus16
Time

Connect the /etc/localtime Soft link to the /usr/share/zoneinfo/Zone/SubZone . Where Zone and Subzone replace the time zone, for example:

# ln -s /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
Host name (optional)
# echo myhostname > /etc/hostname
Set Root password, add user

In addition to setting the Root password, add an account for the Administrators group to do the usual use:

# passwd# useradd -G wheel user# passwd user# chfn user# mkdir -m 700 /home/user# chown user:user /home/user
Installing and configuring Bootloader
# pacman -S grub os-prober efibootmgr# grub-install --target=x86_64-efi --bootloader-id=Arch --recheck# grub-mkconfig -o /boot/grub/grub.cfg
X Window Manager and some drive X window manager
#  pacman -S xorg-server xorg-xinit
Universal Graphics Driver
# pacman -S xf86-video-vesa

Drivers that support hardware acceleration can automatically prompt you to install when X is installed, just select the correct type of video card and do not need to be installed explicitly.

Sound card driver
# pacman -S alsa-utils
Input device driver

Input device drivers are installed automatically when X is installed, and generally do not require an explicit installation. However, laptops or touch screen users need to install Synaptics:

# pacman -S xf86-input-synaptics
Virtual machines

If you are installing in VMware, install some drivers specifically for the virtual machine:

# pacman -S xf86-input-vmmouse xf86-video-vmware svga-dri

Install VMware Tools, select "Install VMware Tools" in VMware, and then:

# pacman -S linux-headers# for x in {0..6}; do mkdir -pv /etc/init.d/rc$x.d; done# mount /dev/cdrom /mnt# cd /root# tar zxf /mnt/VMwareTools*.tar.gz# cd vmware-tools-distrib# ./vmware-install.pl

Follow the instructions, if the final error, generally do not worry, after restarting VMware Tools to correctly start.

Install fonts

Install some commonly used Chinese and English fonts:

# pacman -S ttf-dejavu wqy-zenhei wqy-microhei
Installing the Desktop Environment (Deepin)
# pacman -S deepin deepin-extra

Configuring the LIGHTDM Login Manager

# vi /etc/lightdm/lightdm.conf

Found it

#greeter-session=example-gtk-gnome

Remove the comment and change to:

greeter-session=lightdm-deepin-greeter

Start the LIGHTDM service

# systemctl enable lightdm.servicce

Restart can

5. Two note If these steps do not have NetworkManager installed, you cannot connect to the network after rebooting into the Deepin.
# pacman -S networkmanager# systemctl enable NetworkManager.service
Nouveau does not support GTX1060 and GTX1070 and requires the installation of Nvidia graphics cards
# pacman -S nvidia

If necessary, you can add Nouveau to blacklist

# echo blacklist nouveau >> /etc/modprobe.d/blacklist.conf# mkinitcpio -p linux
Third, SSD optimization

See next article, optimized use of SSDs under Linux

Reference:

    • Arch Linux Installation Guidelines
    • Arch Linux Installation Deepin desktop environment
    • Arch Linux wiki-wireless Network configuration

ArchLinux Installation Tutorials

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.