logo
Jiff Slater
🤔 About
✍️ Contact
📚Knowledge
30 Jul 2021
These articles have been archived. You may find them useful but I am no longer offering support for them. Check out my latest articles on plkt.io.
Arch Linux on Dell M6800
29 August 2015

I have not upgraded my computer systems for a while and have been using a combination of Windows 7 and Mac OS X as my main OSes. Recently, I had the opportunity to purchase a Dell M6800. Below is a walkthrough of how I got Arch Linux configured on this monster of a machine.

Summary

Pros
– Blazing fast machine, faster than a top-of-the-line Macbook Pro (mid-2015) Retina model tested at the Apple Store on loading webpages (tested NYT, The Verge, BBC, and Engadget).

Cons
– Too large to conveniently lug around
– Heavy

Applications Used: Mutt (email), Firefox (web browsing), rxvt-unicode (terminal), dwm (window manager), irssi (irc)

Partitioning

This computer was configured with two hard discs: a 512GB SSD and a 512GB HDD. The first was used as the boot drive. It has been a long time since I configured a hardware (not VM) Linux machine from scratch and spent several hours selecting the optimal partition layout to set me up for the next 5 years. I wanted a partition layout that was easy to reconfigure, hard to configure improperly, and encryptable.

Before even considering the layout, I had to choose which partition table format I would go for. In the past, I would opt for the Master Boot Record (MBR) format which gave me interoperability with Windows. Now, with Windows 8 and beyond requiring UEFI support for Windows 8 certified PCs, there is no real reason to stick with MBR. For this machine, I selected the GUID partition table (GPT).

With that in mind, I considered the following scenarios:

(1) Simple scheme using GPT
In the past, due to the requirement of dual-booting for university, I had opted for a MBR configuration. I considered for this machine the following layout.

Partition 0: EFI boot, 256MB
Partition 1: Windows, 256GB
Partition 2: /boot, 256MB
Partition 3: / (root), 64GB
Partition 4: /home, remainder of space

Benefits of this layout was that it was simple. Drawbacks: could not easily modify in the future without copying data to an external disc and copying back. Also, it would be a waste of space if I did not use Windows.

Furthermore, with /home and / separated, I would have to set up encryption twice so I could make mistakes that would render encryption useless or open up attack opportunities.

(2) Linux Unified Key Setup upon Logical Volume Management (LUKS upon LVM)
This setup would give me all the flexibility of LVM with the added benefit of encryption. This means, I could extend a logical volume within Linux across multiple drives in the event my SSD ran out of space or, say, I wanted to implement a RAID configuration. Unfortunately, again, this would require multiple partitions and key configurations which would be cumbersome to manage.

(3) LVM upon LUKS
This setup would prohibit me from doing the above in (2), namely, spreading out partitions across physical media. However, it would be the easiest to configure and would give me encryption across my entire drive. Because I had an SSD, I was not too concerned about any r/w performance penalty that I would likely encounter having all these abstractions in place. Here is the partition scheme I opted for, using the GPT.

Partition 0: EFI system, 256MB
Partition 1: Linux boot, 256MB
Partition 2: Linux LVM, remainder of space, encrypted

You will notice that a Windows partition isn’t included here. Because I am using LVM, I can create space for it if I do decide to install Windows upon a separate partition.

I configured the above with the following commands (after booting into the Arch Linux setup disc).

Using GDisk, performed as root

#> gdisk /dev/sda #configure my SSD
(gdisk)> o # create a new GPT
(gdisk)> n # create the EFI partition
(gdisk)> [enter] # default partition number
(gdisk)> [enter] # default sector
(gdisk)> +256M # make the partition size 256MB
(gdisk)> ef00 # make the filesystem type EFI
(gdisk)> n # create the boot partition
(gdisk)> [enter] # default partition number
(gdisk)> [enter] # default sector
(gdisk)> +256M # make the partition size 256MB
(gdisk)> 8300 # make the filesystem type Linux FS
(gdisk)> n # create the LVM partition
(gdisk)> [enter] # default partition number
(gdisk)> [enter] # default sector
(gdisk)> [enter] # up to last sector
(gdisk)> 8e00 # Linux LVM filesystem type
(gdisk)> w # write changes to disc

Using LVM, performed as root

#> lvmdiskscan # list available disks found by lvm
/dev/sda1 [ 256.00MiB]
/dev/sda2 [ 256.00MiB]
/dev/sda3 [ 465.26MiB]
0 disks
3 partitions
0 LVM physical volumes
#> pvcreate /dev/sda3
#> vgcreate root /dev/sda3
#> lvcreate -L 32GB vg0 -n root
#> lvcreate -L 8GB vg0 -n tmp
#> lvcreate -L 8GB vg0 -n swap
#> lvcreate -L 64GB vg0 -n home

Create the file systems
In the past, I would have went for ext4, but wanted to really make sure I was taking advantage of my SSD (despite the performance penalty from LVM and encryption), so I went with XFS.

#> mkfs.xfs /dev/vg0/root
#> mkfs.xfs /dev/vg0/home
#> mkfs.xfs /dev/vg0/tmp

So, now I have achieved my initial scenario. The Arch Linux Installation guide shows how to mount the file system and install packages as appropriate.

Other Callouts on the Dell M6800

– At times, I encountered some rather scary looking write errors (likely due to the write scheduler being used). I prevented further occurences by adding libata.force=noncq to my GRUB_CMDLINE_LINUX_DEFAULT in /etc/default/grub and regenerating the configuration.
– I did not remember to install wpa_supplicant to connect to WiFi so I had to procure an Ethernet cable to download it before configuring netcfg to connect to my home network.
– Audio was enabled on Firefox by installing its optional dependencies (use pacman -Qi firefox to list them) and installing pulseaudio and pulseaudio-alsa. Remember to turn off the suspend-on-idle module to prevent pops when playing videos.
– The included Nvidia graphics card is meant for an Optimus configuration, so use the Intel supplied graphics card as the default. You can use bumblebee to offload 3D rendering applications to the Nvidia graphics card.
– Not Dell specific but I needed to remember to update my resolv.conf when connecting to OpenVPN servers. This fixed my DNS resolution issues.

lspci

00:00.0 Host bridge: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor DRAM Controller (rev 06)
00:01.0 PCI bridge: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor PCI Express x16 Controller (rev 06)
00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06)
00:03.0 Audio device: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor HD Audio Controller (rev 06)
00:14.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI (rev 04)
00:16.0 Communication controller: Intel Corporation 8 Series/C220 Series Chipset Family MEI Controller #1 (rev 04)
00:19.0 Ethernet controller: Intel Corporation Ethernet Connection I217-LM (rev 04)
00:1a.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #2 (rev 04)
00:1b.0 Audio device: Intel Corporation 8 Series/C220 Series Chipset High Definition Audio Controller (rev 04)
00:1c.0 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #1 (rev d4)
00:1c.2 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #3 (rev d4)
00:1c.3 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #4 (rev d4)
00:1c.4 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #5 (rev d4)
00:1c.6 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #7 (rev d4)
00:1c.7 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #8 (rev d4)
00:1d.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #1 (rev 04)
00:1f.0 ISA bridge: Intel Corporation QM87 Express LPC Controller (rev 04)
00:1f.2 SATA controller: Intel Corporation 8 Series/C220 Series Chipset Family 6-port SATA Controller 1 [AHCI mode] (rev 04)
00:1f.3 SMBus: Intel Corporation 8 Series/C220 Series Chipset Family SMBus Controller (rev 04)
01:00.0 VGA compatible controller: NVIDIA Corporation GK104GLM [Quadro K3100M] (rev a1)
03:00.0 Network controller: Intel Corporation Wireless 7260 (rev bb)
11:00.0 SD Host controller: O2 Micro, Inc. SD/MMC Card Reader Controller (rev 01)

uname -a

Linux london 4.1.5-1-ARCH #1 SMP PREEMPT Tue Aug 11 15:41:14 CEST 2015 x86_64 GNU/Linux