How to Install a Minimal Ubuntu 16.10 Desktop

UPDATE (15/02/2018) : Fantastic news for Ubuntu 18.04 is that this blog post will no longer be necessary. According to this article, Ubuntu 18.04 will have a ‘opt-in’ minimal desktop install option.

TL;DR: How to install the Ubuntu 16.10 desktop in a minimal manner that excludes all the bloatware that comes with Unity out-of-the-box.

UPDATE (29/10/2016) : I did everything below with KVM and was using Spice to connect to the VM. Unfortunately Ubuntu 16.10 appears to have an issue with the spice-vdagentd which you can see logged at and so copy / paste and window resizing won’t work at the moment.

I spent pretty much most of yesterday and today trying to figure out how to best install Ubuntu desktop in a minimal mode. I’m quite happy with the Unity window manager but I hate all the extra software that gets installed, especially when I’m working on a development virtual machine. I really don’t need LibreOffice or the music player etc.

So there are posts on AskUbuntu that suggest you install Ubuntu Server and then install the ubuntu-desktop package using the –no-install-recommends flag as shown in the command below.

sudo apt-get install --no-install-recommends ubuntu-desktop

Now I don’t know if I’m doing something wrong, but doing the above has ALWAYS resulted in a pretty much corrupted deployment of the Ubuntu desktop. By “corrupt” I mean the launcher refuses to launch/display applications and doing something like Alt+F2 just takes you to a search box. Unfortunately these same posts say very little beyond the flag and no one seems to complain about what I’m experiencing – maybe it’s just me ¯\_(ツ)_/¯  – but if you’re here then possibly not 😉

So after a lot of messing about with different package deployment scenarios, I finally came upon a solution that seems to result in a pretty minimal deployment AND the Ubuntu desktop is usable afterwards. It’s not perfect (for some reason the launcher refuses to be transparent) but it’s good enough that I can get a basic development environment setup.

The Steps

The trick that I’ve found (and it just seems stupid to me that I need to do this) is that I first install the display manager I’m wanting to use. In my circumstance I make use of LightDM so I deploy the lightdm package first straight after install Ubuntu Server and doing apt-get updates, like so.

sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade
sudo apt-get install lightdm

Once you have the display manager that you want deployed, you then deploy the window manager you’re wanting to use. In my case this is Unity so I then deploy the unity package manager with the following command.

sudo apt-get install unity

Now at this point I do a restart. What you’re going to find is that Ubuntu will boot to the login screen but if you attempt to login it’ll complain that it can’t start the session. Don’t panic, just press Ctrl+Alt+F1 to change into terminal mode. Login here and then deploy the ubuntu-desktop package at this point like so. (N.B. It’s super important to include the –no-install-recommends flag otherwise you’re going to get the bloatware and you’ve gone through all this for no reason.)

sudo apt-get install --no-install-recommends ubuntu-desktop

This is the bit I feel is stupid. Both the packages we deployed earlier (lightdm and unity) are actually deployed by this package as dependencies! I have no idea what’s going on here, but if I were to speculate on it, I would imagine that a recommended package is deployed that forces some kind of “refresh”. I say refresh for lack of a better term and I don’t have a deep understanding on the mechanics of the package deployment. As this “refresh” doesn’t happen as the recommended packages aren’t deployed, the rest of the package is deployed in a bad state – this is pure speculation of course.

Once the ubuntu-desktop package has deploy, do a reboot and you should have a working minimal Ubuntu desktop deployment. As I mentioned earlier, there are some things that don’t work straight away (like the launcher refuses to be transparent) but I imagine with a little tweaking it wouldn’t be too hard to fix these niggling issues. Also keep in mind as a result of using such a minimal install, you aren’t going to get apps like the Gnome terminal, software center etc. so if you want these you’ll need to apt-get install these manually.

At least now we don’t have to manually purge LibreOffice and it’s bloated compadres.


3 thoughts on “How to Install a Minimal Ubuntu 16.10 Desktop

  1. Thanks! I can confirm too that this one works!

    My use case: use ubuntu server 16.04 with minimal-virtual-machine profile in virtualbox. I’ve try and use other smaller DE, but still feels lags since no hardware acceleration… Only unity works

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s