Still not messing around with
Secure Boot as there were way too many other fires to fight...
Ultimately after my first experiment I decided to ditch "Linux Mint 17 Qiana KDE Edition" because it would invariably freeze on me - most of the time before login and I don't think it was ever stable enough to let me get to a clean shutdown (even going straight to it after login). I didn't even try one of the Ubuntu flavors as they have too much in common with Mint and I figured that they would suffer the exact same problem. I figured with these "everything but the kitchen sink" cookie cutter distros I had no chance in hell as a neophyte to figure out what the problem with my particular hardware was. So I really only had one choice - to "Build Your Own Beast" with
Arch Linux - hopefully carefully building up my configuration I would be able to catch the culprit and take corrective action on the spot. It had nothing to do with the fact that
pacman is Arch's package manager.
For the impatient: The approach worked - apparently my laptop's Intel HD Graphics 4600/NVIDIA Quadro K2100M (2GB GDDR5 VRAM)
Hybrid Graphics hardware was at the core of the problem.
I can't over-emphasize the importance of having a backup solution like
macrium reflect around and making liberal backups of known good states of your partitions before making your "next big move". While in many cases (but still not all) it is possible to "hack yourself" back to a bootable system - it is just so much easier as a neophyte to simply blast yourself back to your last known good state when all of a sudden everything goes down the toilet. Creating backup images to an external USB3 drive from Windows 10 is pretty quick (and the same can be said for the restore).
I was also fortunate enough to get two handfuls of inexpensive 8GB Lexar USB2 flash drives during the current "back to shool" frenzy. They are a lot faster and more convenient than optical media drives for the various boot media required (installion, recovery, repair, etc.). Being paranoid I stuck to USB2 flash drives and always used them in a USB2 (not USB3 (SS)) port (under certain circumstances USB2 in USB3 would not boot). I used
USBWriter on Windows 10 to prepare an
Arch 4.1.6 installer
USB drive and a GParted Live USB with the
gparted-live-0.23.0-1-i586 ISO.
Replaced the Toshiba MQ01ACF050 500GB with a Samsung 850 Pro MZ-7KE512BW in the laptop and switched to "UEFI-only" in the BIOS. Booted the GParted Live USB and created an EXT4 partition consuming the latter half of the SSD in order to deny it to Windows 10. Then used the flash drive prepared by the
Windows 10 media creation tool to install Windows 10 on the first half of the SSD.
Aside: I already upgraded the laptop previously via Windows Update from Windows 7 to Windows 10 on the Toshiba HDD. Strangely enough
ProduKey wasn't able to recover the new Windows 10 product key - all I could get was the OEM (Windows 8.1) product key that resides in the BIOS - which of course doesn't work for a Windows 10 installation. Presumably the "Windows Update" upgrade registered my laptop's hardware profile with MS. So when I performed a clean install of Windows 10 the installation let me repeatedly "skip" the product code entry - but eventually my clean install activated successfully (still with no product key to be found with ProduKey).
Once Windows 10 was done there were 4 new partitons on the SSD:
- 450 MiB Recovery (NTFS)
- 100 MiB EFI System Partition (FAT32)
- 16 MiB Microsoft Reserved (MSR) Partition (unknown)
- 200+ GiB system (NTFS)
Windows 10 also elected to create a 128 MiB MSR at the beginning of my secondary HDD (Western Digital WD10SPCX).
Now Windows 10 was only using 25% of the EFI System partition - so it is possibly OK "as is" - but that partition will be mounted as the linux /boot partition and the
Arch Beginner's Guide recommends 512 MiB for the EFI System Partition. GParted can't deal with the MSR partition and refused to resize the EFI System partition even when there was space. So:
Using
AOMEI Partition Assistant I shrunk/moved the System partition further to the end, moved the 16 MiB MSR further to the end and expanded the EFI System Partition to 512 MiB.
Before starting the Arch Linux install I prepared the target partitions with
GParted:
- Deleted the EXT4 partition at the end of the SSD to make room.
- Created a partiton for '/' (i.e. root).
- Created a partition for '/var'.
- Used the remaining space for a partition for '/home'.
- Created a 32 GiB swap space at the end of my secondary HDD space. Given that I'm running with 32 GB of RAM I'm not too concerned about the swap space being on a slow 5400 rpm drive. I don't expect that it will ever get used - it is simply there of the "compatibility reasons" (whatever...).
- ... and remember the existing EFI system partition will become your '/boot' partition.
There are no hard and fast rules about the partition sizes and some people simply use a single partition for '/', '/var', and '/home'. I have resized these partitions multiple times because I like some "head room" (partially for dealing with future bad clusters) - but most of my allocations are probably insane overkill. The current installation - Arch Linux (1 user set up) + Gnome 3.16 (& extras)+ Chromium + Sublime Text 2:
- /boot: 512 MiB / 57 MiB used
- /: 64 GiB / 147 MiB used (GParted shows 2.4 GiB used - but I blame that on the other mounted partitions).
- /var: 32 GiB / 1.8 GiB used
- /home: 142 GiB / 2.5 GiB used
Once all the partitions were prepared I simply followed the relevant sections of the
Arch Beginners Guide to finish the basic installation - I ended up using
systemd-boot as the boot loader.
And guess what - the kernel would still freak out 2 out of 3 boot ups even with this minimal configuration. At least occasionally I had a boot that would let me fix some stuff. At this point I found out about Intel/AMD
microcode (actually I should have paid closer attention to the
Beginner's Guide). Microcode is loaded into the CPU to address hardware bugs. Typically this is done by the BIOS but linux has it's own mechanism for updating (volatile) microcode so that the newest microcode can be loaded even before the hardware BIOS is updated. In my case it turned out that my recently updated BIOS already loaded the most recent Intel microcode update for my
Intel Core i7-4900MQ.
But then I noticed that the kernel module
nouveau would often complain just before the kernel would launch into a tyrade. Nouveau is the open source module for NVIDIA graphics - not to be confused with the proprietary
NVIDIA module. Once I
blacklisted the nouveau module, the kernel tyrades stopped - the problem seemed to be addressed - for now.
I went ahead and installed the
NVIDIA module. Sailing was still smooth - time to install Gnome 3.16 - which borked the configuration. Arch would only boot into an infinite
Gnome 3.16 "Oh no! Something has gone wrong" cycle. Using the Arch Live USB drive I had to disable the
Gnome Display Manager to regain control over the boot process.
I consulted an
alternate guide that made it clear that all wasn't well. For some reason I stumbled onto
bumblebee which seemed to address my particular hardware situation. After installing bumblebee, X11 started to work and Gnome was happy. After that installing Chromium (and gSoftware [pacman -S gnome-software]) was a snap.