This is the process I used for installing Arch Linux on my new Dell Precision 7530 laptop. MASSIVE thanks to jantman as this is mostly copied from his gist in the first link below.
- precision5530_install.md (mostly copied from here)
- Dell XPS 15 - ArchWiki
- Laptop/Dell - ArchWiki
This system is dual-booted with win10 on the 1st drive and arch on the 2nd. First attempted to get arch to run on the raid Intel RST controller, however it looks like the kernel won't support it. With the 4k screen, it's easier to get going after booting from the flash drive by making the font bigger with pacman -Sy terminus-font && setfont ter-v32n
. Finally, make sure to SSH in so you have a log of what happened and can copy and paste stuff.
- Plug in power, wired Ethernet. DO NOT PLUG IN Arch installation USB stick.
Attach an external monitor (see last step for details) - Power on the system. At the Dell splash screen, hold down the F12 key until you get to the one-time boot menu.
- Other Options -> Change Boot Mode Settings
- Change boot mode to: 2) UEFI Boot Mode, Secure Boot OFF. Proceed and apply the changes.
- System will reboot. At the Dell splash screen, press F12.
- Other Options -> BIOS Setup
- System Configuration -> SATA Operation - set to "AHCI" (not RAID / Intel Rapid Restore)
- Exit. System will reboot.
- Other Options -> Change Boot Mode Settings
- System will reboot. At the Dell splash screen, press F12.
- Other Options -> BIOS Setup
- Maintenance -> Data Wipe. Check "Wipe on Next Boot". Verify that USB stick is NOT plugged in, click OK and then No to not cancel.
- Click Exit. The laptop will reboot. You'll get a Dell logo with a progress bar and then a data wipe prompt. Select "Continue" and then "Erase", and you'll eventually get a success message.
- Other Options -> BIOS Setup
- Plug in the Arch Installer USB stick and press Enter to reboot.
- At the Dell splash screen, hold down the F12 key until you get to the one-time boot menu. Do not select the "USB Storage Device" option - this will boot in BIOS mode. Select one of the first two UEFI Boot options (they both seemed to give the same thing for me).
- Select "Arch Linux archiso x86_64 UEFI CD". You should eventually boot to a
root@archiso ~ #
prompt. - We'll now wipe the disk (
nvme0
) according to dm-crypt wipe on an empty disk or partition:cryptsetup open --type plain -d /dev/urandom /dev/nvme1n1 to_be_wiped
lsblk
and verifyto_be_wiped
exists- do the wipe:
dd if=/dev/zero of=/dev/mapper/to_be_wiped bs=1M status=progress
- on my 477GB disk, this took about 14 minutes cryptsetup close to_be_wiped
- If you want the convenience of running the installation remotely over SSH, follow Install from SSH - ArchWiki:
- Ensure the machine is on your network (
ip addr
). - Ensure that
PermitRootLogin yes
is present and uncommented in/etc/ssh/sshd_config
- Set a temporary root password:
passwd
- Start the SSH daemon:
systemctl start sshd
- Ensure the machine is on your network (
- Follow the initial steps of the Arch Installation Guide prior to partitioning: set the keyboard layout if needed, verify UEFI boot with
ls /sys/firmware/efi/efivars
, connect to your LAN, and set the system clock. (Note: verifying UEFI is important; the first time I did this, I inadvertantly booted into legacy/BIOS mode.) - We'll now set up LVM on LUKS and partition the disks (this setup was chosen for the ease of suspend):
cgdisk /dev/nvme1n1
- Create a 550M partition of type
EF00
(EFI System
) calledESP
(this will become the EFI System Partition,/dev/nvme1n1p1
) - Create a 300M partition of type 8300 called
BOOT
(this will become/dev/nvme1n1p2
) - Use the rest of the disk (476GB for me) for a partition of type 8300 called
SYSTEM
(this will become/dev/nvme1n1p3
) - Write to disk and quit
- Create a 550M partition of type
- Create the LUKS container for the system:
cryptsetup luksFormat --type luks2 /dev/nvme1n1p3
- Open the container:
cryptsetup open /dev/nvme1n1p3 cryptlvm
- Create the physical volume:
pvcreate /dev/mapper/cryptlvm
- Create the volume group:
vgcreate LUKSvol /dev/mapper/cryptlvm
- Because I'm old-school, create a swap volume twice the size of the RAM (32G):
lvcreate -L 32G LUKSvol -n swap
- Because I'm lazy and this is a laptop (don't hate me), use the rest of the disk for a single root partition:
lvcreate -l 100%FREE LUKSvol -n root
- Setup the filesystems:
mkswap /dev/LUKSvol/swap && mkfs.ext4 /dev/LUKSvol/root
- Mount the partitions:
mount /dev/LUKSvol/root /mnt; swapon /dev/LUKSvol/swap
- Create the ESP filesystem on the ESP partition:
mkfs.fat -F32 /dev/nvme1n1p1
(if that isn't installed,pacman -S dosfstools
) and mount it:mkdir /mnt/efi && mount /dev/nvme1n1p1 /mnt/efi
- Create the boot filesystem on the BOOT partition:
mkfs.ext4 /dev/nvme1n1p2
- Create the boot directory and mount the partition:
mkdir /mnt/boot && mount /dev/nvme1n1p2 /mnt/boot
- We're done with this for now, but we'll come back to finish it later.
- Back in the Installation Guide, pick up at the Installation process:
- Edit
/etc/pacman.d/mirrorlist
as desired. - Install the base packages:
pacstrap /mnt base
- Continue on with the Configure System steps:
genfstab -U /mnt >> /mnt/etc/fstab
and check the resulting file- chroot into the system:
arch-chroot /mnt
- Set the time zone, i.e.
ln -sf /usr/share/zoneinfo/Region/City /etc/localtime
and runhwclock --systohc
- Edit
/etc/locale.gen
as needed, runlocale-gen
, and create/etc/locale.conf
- Create
/etc/hostname
and set/etc/hosts
entries accordingly. - Install intel microcode:
pacman -S intel-ucode
- Configure mkinitcpio per the dm-crypt instructions: edit the
HOOKS
line to match what's given in those instructions (order matters A LOT). Also ensure that afterlvm2
you addresume
. If you're usingen_US.UTF-8
you can leave outkeymap
andconsolefont
. The final line should read:HOOKS=(base udev autodetect keyboard modconf block encrypt lvm2 resume filesystems keyboard fsck)
. For the Precision 5530 laptop, also setMODULES=(intel_agp i915)
. Save the file and then runmkinitcpio -p linux
. - Run
passwd
to create the root password. - Install the GRUB bootloader:
pacman -S grub efibootmgr
- Ensure the ESP is mounted at
/efi
- Install GRUB:
grub-install --target=x86_64-efi --efi-directory=/efi --bootloader-id=GRUB
- Edit
/etc/default/grub
- In the kernel parameters, set
resume=/dev/LUKSvol/swap
- In the kernel parameters, set
cryptdevice=UUID=device-UUID:cryptlvm root=/dev/LUKSvol/root
(replacingdevice-UUID
with the UUID of the device, i.e. the/dev/disk/by-uuid
symlink that points to/dev/nvme1n1p3
) - If you're like me, you'll want to remove the default
quiet
* To work around some video issues, addnomodeset
. - The final line should read:
GRUB_CMDLINE_LINUX_DEFAULT="resume=/dev/LUKSvol/swap cryptdevice=UUID=[UUID]:cryptlvm root=/dev/LUKSvol/root nomodeset"
- In the kernel parameters, set
- Run
grub-mkconfig -o /boot/grub/grub.cfg
to generate the new GRUB configuration
- The installation should be complete.
exit
thenumount -R /mnt
andreboot
.
16. Press F12 at the Dell splash screen.
* Other Options -> BIOS Setup
* Settings -> General -> Boot Sequence
* Click "Add Boot Option"
* Boot Option Name: "GRUB"
* Leave File System List as-is
* File Name: click "..." to browse, browse to ``\EFI\GRUB\grubx64.efi``
* OK
* Click the "GRUB" entry in the boxes at the top right, and move it to be the first option (using the arrow buttons).
17. "Apply" then "Exit". System will reboot.
- If all went well, you should get a GRUB menu and then the beginning of Arch boot. You'll be prompted for the LUKS passphrase; enter it and you should boot into Arch.
* If you have video issues, like me, and the screen goes black before or after entering your LUKS passphrase, reboot. At the GRUB prompt press "e" and appendnomodeset
to thelinux
line. This will work as a temporary fix until video is set up properly. - Connect to your network and get DHCP (
systemctl start dhcpcd@INTERFACE-NAME
).
20. Continue on with the Puppetized installation process per [Arch Linux in README.md](https://github.com/jantman/workstation-bootstrap/blob/master/README.md#arch-linux):
1. Do a full update: ``pacman -Syu``
2. ``pacman -S base-devel puppet git lsb-release ruby`` - when prompted, install the whole base-devel group
3. ``gem install --no-user-install r10k``
4. If you're using a private GitHub repo for customization, generate SSH keys for root and add them as deploy keys on the repo.
5. As root, in ``/root``: ``git clone https://github.com/jantman/workstation-bootstrap.git && cd workstation-bootstrap``
6. ``./bin/run_r10k_puppet.sh | tee /root/puppet.$(date +%s)`` - run puppet and capture the output.
21. Install some packages for the graphics: ``pacman -S linux-headers xf86-video-intel nvidia-dkms nvidia-settings xorg-xrandr tlp``
22. Until [freedesktop.org bug 109959 – REGRESSION: black screen with linux 5.0 when starting X](https://bugs.freedesktop.org/show_bug.cgi?id=109959) is fixed and released, 5.x kernels will fail to detect the laptop screen (eDP). To fix this, apply the kernel patch listed in that bug or install ``linux-precision5530-headers`` and ``linux-precision5530`` from [my Arch repo](http://archrepo.jasonantman.com/current/index.html) ([source repo](https://github.com/jantman/arch-pkgbuilds/tree/master/linux-precision5530)). Once this bug is fixed in the Arch kernel, you can switch back to that and also switch from ``nvidia-dkms`` to ``nvidia`` (the DKMS driver is required for the custom kernel).