timedatectl set-ntp trueTo check the service status, use
timedatectl status
timedatectl set-timezone America/Los_Angeles
To manually set timezone
- If you don't know which one is near you issue this command
timedatectl list-timezones
- Or you know your location then type this command to find your location
timedatectl list-timezones | grep <name>
cfdiskfdisk -lfor checking list disk
For home and base system
mkfs.ext4 /dev/sdX1For swap partition
mkswap /dev/sdX2 For root partition
mount /dev/sdX1 /mnt For home partition
mount /dev/sdX2 /mnt/homeFor EFI Scheme, make sure directory
/boot/efiis created then mount it
mount /dev/sdX3 /mnt/boot/efivim /etc/pacman.d/mirrorlistsudo pacman-mirrors -gchoose your closet mirrors
pacstrap /mnt base base-devel linux linux-firmware ntfs-3g sudo vim grub os-prober netctl dialog wpa_supplicant dhcpcd pppGenerate an fstab file use -U
genfstab -U /mnt >> /mnt/etc/fstabEnable user in the wheel group to have sudo access by uncommenting this line # %wheel ALL=(ALL) ALL
ln -s /usr/bin/vim /usr/bin/vi
Change root into the new system
arch-chroot /mntSet the time zone*
ln -sf /usr/share/zoneinfo/America/Los_Angeles /etc/localtimeRun hwclock to generate /etc/localtime
hwclock --systohcUncomment en_US-UTF-8 YTF-8 in /etc/locale.gen, and generate them with:
locale-genCreate the locale.conf file, and set the LANG variable accordingly:
/etc/locale.conf
LANG=en_US.UTF-8
Create the hostname file:
/etc/hostname
myhostname
Add matching entries to hosts(5):
/etc/hosts
127.0.0.1 localhost
::1 localhost
127.0.1.1 myhostname.localdomain myhostnamemkinitcpio -PSet the root password:
passwduseradd -m johnusermod -aG wheel,audio,video,optical,power,storage johnFor MBR Scheme
grub-install --target=i386-pc /dev/sdXFor EFI Scheme
grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUBIf you are planning to install Arch Linix on an external disk then put the --removable flag to the grub command on top
grub-mkconfig -o /boot/grub/grub.cfgBecause Grub will automatically detect Windows partition when generating grub config when using MBR, EFI need to make sure that grub is intalled inside the Windows boot partition
sudo systemctl start netctlnetctl enable profilesudo systemctl enable [email protected]To enable at boot
sudo systemctl start [email protected]sudo pacman -Sy archlinux-keyring && sudo pacman -Syu