Archlinux hard disk installation, archlinux Hard Disk
Use a USB flash drive to install arch to the hard disk
I. preparations:
1) download the arch image and sig files and put them in the same folder. Https://www.archlinux.org/download/
In a linux Non-arch environment, the verification code is as follows:
# Gpg -- verify./archlinux-2012.10.06-dual.iso.sig
An error is returned:
Gpg: Signature made Sat 06 Oct 2012 03:28:53 pm ist using RSA key ID 9741E8AC
Gpg: Can't check signature: public key not found
# Gpg -- no-default-keyring -- keyring vendors. gpg -- keyserver pgp.mit.edu -- recv-key 9741E8AC
# Gpg -- verify -- verbose -- keyring vendors. gpg./archlinux-2012.10.06-dual.iso.sig
See the following information
Gpg: assuming signed data in './archlinux-2012.10.06-dual.iso'
Gpg: Signature made Sat 06 Oct 2012 03:28:53 pm ist using RSA key ID 9741E8AC
Gpg: using PGP trust model
Gpg: Good signature from "Pierre Schmitz"
Gpg: WARNING: This key is not certified with a trusted signature!
Gpg: There is no indication that the signature belongs to the owner.
Primary key fingerprint: 4AA4 767B BC9C 4B1D 18AE 28B7 7F2D 434B 9741 E8AC
Gpg: binary signature, digest algorithm SHA1
2) Prepare a 1 Gu disk for the boot disk.
# Dd bs = 4 M if =/path/to/archlinux. iso of =/dev/Sdx& Sync
Use lsblk to find the USB flash disk and make sure it is not mounted.
After the Boot disk is ready, set the bios to start from the USB flash drive and restart to Boot Archlinux (i686). I am a 32-bit
Ii. Start Installation
1) set the keyboard layout
# Loadkeys us
2) when accessing the network, my network card is broadcom and uses a dynamic IP address.
# No port found in ip link
# Modprobe-r tg3
# Modprobe broadcom
# Modprobe tg3
# Ip link
# Ip link setInterfacenameUp
# Ping-c 3 www.baidu.com
3) Hard Disk partitioning. I use the fdisk tool, which is actually very simple.
Create three primary partitions, one extended partition, and then two logical partitions from the extended partition.
For details, refer to wiki.
4) format the partitions and mount them separately.
# Mkfs. ext4/dev/sdaX
If you divide a swap area, do not forget to format and enable it.
# Mkfs. ext4/dev/sda1
# Mkswap/dev/sda2
# Swapon/dev/sda2
# Mkfs. ext4/dev/sda3
# Mkfs. ext4/dev/sda5
# Mkfs. ext4/dev/sda6
Mount each partition. Mount each partition according to your personal plan. My partitions
/Dev/sda1 200 M/boot
/Dev/sda2 500 M swqp
/Dev/sda3 20G/
/Dev/sda5 12G/var
/Dev/sda6 265G/home
Mount
# Mount/dev/sda3/mnt
# Mkdir/mnt/boot
# Mount/dev/sda1/mnt/boot
# Mkdir/mnt/var
# Mount/dev/sda5/mnt/var
# Mkdir/mnt/home
# Mount/dev/sda6/mnt/home
5) vi/etc/pacman. d/hosts list
Server = http://mirrors.ustc.edu.cn/archlinux/$repo/ OS /$arch
You can use other sources. Make sure to force Refresh after modification.
# Pacman-Syy
6) Installation
# Pacbench/mnt base-devel
7) generate fstab
# Genfstab-U-p/mnt>/mnt/etc/fstab
8) switch to new system
# Arch-chroot/mnt/bin/bash
9) nano/etc/locale. gen
Uncomment
En. US.UTF-8 UTF-8
En. CN.UTF-8 UTF-8
En. TW.UTF-8 UTF-8
# Locale-gen
10)
# Ln-s/usr/share/zoneinfo/Asia/Shanghai/etc/localtime
11)
# Hwclock -- systohc -- utc
12)
# EchoMyhostname>/Etc/hostname
And/etc/hosts
Add the same host name:
## /etc/hosts: static lookup table for host names##<ip-address>myhostname::1localhost.localdomainlocalhost# End of file
13) configure the network once and for all
# Systemctl enable dhcpcd @Interfacename. Service
14) set the Root password
# Passwd
15)
# pacman -S grub# grub-install --target=i386-pc --recheck /dev/sda
# grub-mkconfig -o /boot/grub/grub.cfg
#exit
#reboot
The End
Note: The above information source https://wiki.archlinux.org
Archlinux Installation
I installed the hard drive on xp for your reference:
1. Draw out a hard disk space for installing Archlinux, and change the volume labels of Each Xp partition to English.
2. Download Grub4Dos (download.gna.org/grub4dos/grub4dos-0.4.4.zip) and decompress grldr from grub4dos to C: \ of XP :\. Download the archlinux-2009.08-core-i686.iso and place it in C: \. decompress the VMLINUZ26 and ARCHISO_PATA.IMG files under the BOOT directory in the image file to C :\.
3. Modify the boot. ini file of XP, remove the read-only attribute, and add the following at the end of boot. ini:
C: \ grldr = "Grub"
4. restart the computer, select Grub, enter the Grub boot program, press the C key to enter the Grub console, and enter:
Root (hd0, 0)
Kernel/VMLINUZ26
Initrd/ARCHISO_PATA.IMG
Boot
5. After the kernel is started, the system prompts that the installer cannot be found in/dev/archiso and a console appears. In this case, you can create a link to direct archiso to the installer:
Mkdir/win
Mount-r-t ntfs/dev/sda1/win
Modprobe loop
Losetup/dev/loop6/win/archlinux-2009.08-core-i686.iso
Ln-s/dev/loop6/dev/archiso
Press Ctrl + D to continue.
6. Log On with the root user and enter:
/Arch/setup
Start installation as prompted. The installation process uses the text mode, which is extremely fast and superb.
For details, see Arch's wiki: Installation Guide for beginners.
Windows 7 uses EasyBCD hard drive to install linux (Arch). An error occurred while selecting ARCH on the Arch startup interface.
Incomplete images,
The iso file may not be found. Is it case sensitive?
In addition, you 'd better find a corresponding version based on the tutorial. I feel that I can directly use iso, which may have high memory requirements.