Sep 26, 2016
I have had quite a bad experience trying to install my dearest Debian distro on my brand new Lenovo X1 (4th generation). After many failed attempts, and a couple of serious hesitations to switch to Linux Mint, it ended up being quite straight forward! So I thought I’d put it out here, and may be prevent someone from switching to Linux Mint (or other Debian derivative) out of anger or despair.
Important note: the following will describe how to install a Debian TESTING (not STABLE), currently Stretch (Jessie being the current stable).
0. Prepare the BIOS
You should follow the instructions available on the Debian wiki to prepare your machine’s BIOS:
1. Download Debian testing DVD
I chose to go with the DVD iso to make sure that all the desktop environments were available to install without the need for an Internet connection. This turned out to be not necessary, as the new Debian installer is able to download packages over wifi (after feeding it the proper non-free firmware).
After trying the stable netinstall, live-cd, etc. and ended with multiple fails.. I finally went with the weekly build, available here: http://cdimage.debian.org/cdimage/weekly-builds/
Note: the Debian live-CDs do not support UEFI boot, so there were simply unusable on my Lenovo (the Linux Mint live-cd worked flawlessly out of the box). Which was quite frustrating.
2. Prepare the install USB
I used unetbootin(1) to create the install USB. The Debian installer warns that some people encountered bugs when using unetbootin to prepare their install USB key; I did not encounter any.
Note: if using the laptop’s windows installation, you can use Rufus that does very well the job, and is available here: https://rufus.akeo.ie/
sudo apt-get install unetbootin unetbootin
Plug-in your USB, launch unetbootin, choose the ISO and detected USB, then start the build process. This should be quite straight forward, so I won’t be documenting it here. You’ll find more info available on the web.
Once unetbootin is done, keep the USB key plugged in, and add the Wifi firmware for it to be loaded during the installation process. You will need to create a directory named “firmware” at the root of the USB key, and drop the firmware package there.
You can find the proper package version here: https://packages.debian.org/search?keywords=firmware-iwlwifi
wget http://ftp.us.debian.org/debian/pool/non-free/f/firmware-nonfree/firmware-iwlwifi_20160824-1_all.deb mkdir /path/to/your/usbkey/firmware cp firmware-iwlwifi_20160824-1_all.deb /path/to/your/usbkey/firmware/
You can now safely unmount/unplug your USB.
3. Launch the installation
For some reason, Windows does not completely shutdown when asked to do so, preventing you from accessing the BIOS when restarting. You should hard reset your laptop by pressing long enough on the power button to force it to shutdown completely. After powering on the laptop, press F12 to launch the boot menu, and choose the USB medium.
The installation process is straight forward from there. The screen/wifi/etc. are all detected and work out of the box.
I chose the resize the Windows installation partition to keep there in case I needed it for some obscur reason (e.g. Canadian official paperwork uses very specific Adobe standards that are unfortunately not available on Linux..). I then encrypted my root and swap partitions. The installer is only able to automatically encrypt your whole drive. So in case you choose to keep the Windows installation, you will have to configure it manually. This is quite straight forward using the following tutorial: http://www.maridonkers.info/installing-debian-with-hard-disk-encryption-and-windows-dual-boot/. Don’t forget to create a separate, non-encrypted /boot partition for your system to be able to boot.
The next Debian release will be including some very nice feature with its new installer. Kudos to the Debian installer team who kept me from switching to another distro! ;)