Upgrading a Laptop: a few notes

I recently replaced my 2013 Dell XPS 13 with a 2018 Dell XPS 13. This was a very smooth transition, but I thought it was worth publishing some notes on the process.  Yes, users of Real Operating Systems are probably laughing, and I wish Ubuntu had a migration tool as nice as Apple’s (assuming theirs still works).  But if you’re like me and choose to use a penguin-themed operating system, you might find these notes useful.

This isn’t meant to be a proper HOWTO, more of a list of notes to myself for the next time I do this.

Tips:

  • Migrating from machine to machine is much easier when they are both running the same OS.  In my case, I had Ubuntu 18.04 installed on both machines.
  • Don’t change your username.  Keep it simple!
  • Screen resolution and hard drive size were the same.  Again, minimizing change means your existing preferences will move over perfectly.

Process

  1. Do a basic installation on the new machine, just enough that it’s booting and your user exists.
  2. Make a backup of your home directory. You should use rsync for this. The instructions I followed include steps on how to do this.
  3. Export your package manager configuration, including the package sources and their keys.
  4. Generate a list of all of the packages that were installed on the old machine.
  5. Set up your new machine with the same packages sources and keys
  6. Tell the new machine to install the entire list of packages you saved.
  7. Reboot once
  8. Sync your user data to the new machine
  9. Reboot again
  10. Pray

I didn’t even need to migrate my /etc directory.  OK my printer config vanished, but that was easy enough to set up again.

To do all of those steps I followed these instructions.  There were some weird packages installed on the old machine that it couldn’t find, but none of them really seemed to make a difference.  The new machine was working as of the very first reboot, with the following one major issue, and a few minor issues.

Issues

Major Issue: Battery Drain During Sleep

YIKES.  This was not fun to discover. I quickly saw that my new Dell XPS 13 (9370) Laptop running Ubuntu 18.04 was draining battery while sleeping (suspended), at least 5% per hour.  It also felt warm even after having been “asleep” for hours.  It turns out this is a problem with the default sleep method being set wrong.  The default is set to “s2idle” when “deep” is the right answer.  See this AskUbuntu post for details about how to check for and fix this problem.

Touchpad

By default, the new touchpad uses two fingers to right click instead of the right side of the pad.  I decided to revert back to what I was used to be changing a setting:

gsettings set org.gnome.desktop.peripherals.touchpad click-method areas

Mouse Cursor

The mouse cursor has always been the bane of my existence.  I like the DMZ-Black cursor instead of the default white.  For some reason there are two places where the mouse cursor theme is set.  One is in GNOME settings, but the other is system-wide.  So I needed to use gnome-tweaks, and then also:

sudo update-alternatives --config x-cursor-theme

And then reboot.

Printer

Because I hadn’t copied my /etc directory I had to reinstall my printer software.

Conclusion

On the whole the migration was very uneventful.  I realize that I have a major advantage, being comfortable with Debian systems and apt commands and rsync, and not everyone can or wants to put up with this kind of procedure.  But for an operating system that is still lousy on the desktop, it actually works pretty nicely and is pleasant to use.  Here’s to another 5 years before I need to do this again!