18

This is the opposite of this question. Basically I've been using Ubuntu for a while but decided to give KDE a shot so I went through the process of getting the latest KDE installed. I'm very impressed with KDE and the Kwin window manager seems like a better WM than Compiz which is what I was using for Gnome (sure that's an oppinion).

This was an Ubuntu Jaunty install. So how do I go about removing the Gnome desktop? Is there an automated way similar to what my previous question covered?

UPDATE: Should there be any packages I should NOT remove in the process?

codeLes
  • 1,832
  • 5
  • 23
  • 34
  • 2
    The answer is essentially the same as your previous question. You just need to find the equivalent meta-package. It's probably `gnome` or `gnome-desktop-environment`. – Telemachus Aug 24 '09 at 14:05
  • 3
    Even if that is the case, I think it is well worth having both of the two as stand-alone questions on Super User. – Jonik Aug 24 '09 at 14:32

5 Answers5

19

Ubuntu has a built-in tool for changing the type of system you are running.

$ sudo tasksel

This tool lets you check the box next to the type of system you want (Kubuntu, Xubuntu, Ubuntu, Ubuntu Server) and then confirm to have the tool re-configure your system, removing and adding packages as needed.

Majik
  • 252
  • 2
  • 2
9

The purge command is a good start. In addition, you probably want to remove all the dependent libraries that were installed only to get Gnome. You can do that via autoremove in apt-get or, if you use aptitude, it should happen automatically.

Note that the purge command has an oddity: it purges items you remove explicitly, but only removes any automatically removed dependent packages. (That is, if you enter aptitude purge foo-bar and fizzbuzz gets automatically removed at the same time, foo-bar is purged but fizzbuzz is only removed.) So a good way to recursively purge is this:

aptitude purge foo-bar && aptitude purge ~c

The ~c search in aptitude finds any packages that were removed but not purged in the first removal.

One final note, if you haven't been using aptitude, always check its output the first time you try to run it. Don't simply say "Yes" to whatever it wants to do. Depending on what package manager you've been using, you may find that aptitude thinks some things should be autoremoved, but you prefer to keep them.

Telemachus
  • 6,845
  • 1
  • 27
  • 33
  • I take it the Ubuntu Software Centre doesn't purge? – BloodyIron May 01 '12 at 13:53
  • @BloodyIron To be honest, I'm not sure. I don't think the Ubuntu Software Centre existed the last time I used Ubuntu. I'm more comfortable with the command-line tools (and Debian), but there may be a GUI or Ubuntu-specific way to do it as well. – Telemachus May 01 '12 at 14:01
  • well, I'm a fan of the CLI too, but I like the idea of a GUI front end not lacking in features (such as purge). Having such shortcomings in a GUI app/frontend just limits a user who doesn't want to use CLI, why not put it in? I'm curious as I don't know either. – BloodyIron May 01 '12 at 14:16
8

I think the simplest way to do this is to remove ubuntu-desktop and install kubuntu-desktop.

sudo apt-get install kubuntu-desktop
sudo apt-get --purge remove ubuntu-desktop

You can also just uninstall gnome-desktop-environment instead of ubuntu-desktop.

  • 1
    Is there *any* difference between uninstalling gnome-desktop-environment and ubuntu-desktop? – Jonik Aug 24 '09 at 14:23
  • 4
    @Jonik: I use Debian not Ubuntu, so I can't test it. But in general, you can find out by simply entering `aptitude -s purge thing1` and then `aptitude -s purge thing2`. The `-s` flag is for *simulate*, and it allows you to check things safely (and as a regular user - no need to become root first or use `sudo`). – Telemachus Aug 24 '09 at 14:27
  • 3
    @Jonik: Afaik, ubuntu-desktop includes gnome and some gnome apps. http://www.psychocats.net/ubuntu/whichbuntu. You can also check the package dependencies using `apt-cache showpkg package_name`. –  Aug 24 '09 at 14:45
  • 1
    That won't work. In the standard Ubuntu install, *everything* is marked as manually installed, so when you `sudo aptitude purge ubuntu-desktop`, only the meta-package is removed; all of GNOME remains installed. – Mechanical snail Oct 05 '11 at 23:51
3

Well, you cant totally remove Gnome because, many common programs on Ubuntu (read Firefox) use Gnome Libraries.

lprsd
  • 2,755
  • 6
  • 36
  • 45
2

I'm not 100% but I'm fairly sure the equivalent meta package is gnome-desktop

That's right... I removed gnome by this:

sudo apt-get remove gnome-*
slhck
  • 223,558
  • 70
  • 607
  • 592
paatos
  • 21
  • 1