Arch Linux Installation LEGACY - LeandroTheDev/arch_linux GitHub Wiki

Connect to the internet

  • iwctl
  • device list
  • station wlan0 scan

This will show the intenets in your area.

  • station wlan0 get-networks
  • station wlan0 connect "INTERNET NAME"

Test internet connectivity

  • ping google.com

Update time date

  • timedatectl set-ntp true
  • timedatectl status

Partitions

Creating the partition lsblk will show the hard disks connected Select the one you want install arch

The "?" is the disk you want to install arch

  • fdisk /dev/sd?
  • o

Creating Linux

  • n
  • default
  • default
  • default

Save

  • w

Active linux on the partition

  • mkfs.ext4 /dev/sd?1
  • mount /dev/sda1 /mnt

Installing Arch Linux

  • pacman -Sy archlinux-keyring
  • pacstrap /mnt base-devel base linux linux-firmware vim

Installing System Detection boot

  • genfstab -U /mnt >> /mnt/etc/fstab
  • arch-chroot /mnt

Creating Swap

  • fallocate -l 4GB /swapfile
  • chmod 600 /swapfile
  • mkswap /swapfile
  • swapon /swapfile
  • vim /etc/fstab
  • /swapfile none swap defaults 0 0 // add new line

Changing timezone

  • ln -sf /usr/share/zoneinfo/AMERICA/Sao_Paulo /etc/localtime
  • hwclock --systohc

Language

  • vim /etc/locale.gen
  • en_US.UTF-8 -> remove the #

Install the language

  • locale-gen

Naming the machine

  • vim /etc/hostname

Configuring localhost

  • vim /etc/hosts
  • 127.0.0.1 localhost
  • ::1 localhost
  • 127.0.1.1 machinename.localdomain machinename

Change root password

  • passwd

Create user

  • useradd -m username

Create user password

  • passwd username

Give access to user

  • usermod -aG wheel username

Download sudo for admin actions

  • pacman -S sudo

Edit visudo to grant previleges to users

  • visudo

Remove the #

  • #%wheel ALL=(ALL) ALL

Download the detectors of S.O

  • pacman -S grub dosfstools os-prober mtools ntfs-3g

Script for updating grub

  • vim /usr/sbin/update-grub
  • // add
  • #!/bin/sh
  • set -e
  • exec grub-mkconfig -o /boot/grub/grub.cfg "$@"

Run script

  • grub-install /dev/sda

Update settings

  • chown root:root /usr/sbin/update-grub
  • chmod 755 /usr/sbin/update-grub
  • update-grub

Install a network manager to use internet

  • pacman -S networkmanager
  • systemctl enable NetworkManager

Finishing installing

  • exit
  • umount /mnt -l
  • reboot

Configuring Arch Linux

Connect to the internet

  • sudo nmcli device wifi connect "INTRNETNAME" password "password"

Active some Librarys for pacman

  • sudo vim /etc/pacman.conf
  • #[multilib]
  • #Include = /etc/pacman blablablabla

Remove the #

Drivers

For old processor for monitor and processors if needed

  • lspci -v | grep -A1 -e VGA -e 3D

For Intel Users

  • sudo pacman -Sy xf86-video-intel mesa lib32-mesa

For Nvidia Users

  • sudo pacman -Sy nvidia nvidia-utils lib32-nvidia-utils

Nvidia official site // If you use a desktop install desktop first and Steam for max compatibility

  • Nvidia
  • sudo pacman -S linux-headers
  • sudo vim /etc/modprobe.d/nouveau.conf
  • //add
  • blacklist nouveau
  • sudo mkinitcpio -p linux
  • reboot
  • chmod +x NVIDIA-DRIVER...
  • sudo ./NVIDIA-DRIVER...

Finish

  • Have Fun