Thursday, May 6, 2010

Switching from Metacity to Xfwm4 in GDM

GDM is pretty bulletproof, and is a great way to manage your display and provide autologin services for your desktop. Unfortunately GDM loads Metacity, and unless your running Gnome it can be a hit to your memory cache. For those of us using Xfce4, its not the most efficient way to handle resources.

The Xubuntu developers put together a gdm theme that will load xfwm4 instead of Metacity. To take advantage of this little boost in preformance, install the following package:

sudo apt-get install xubuntu-gdm-theme

Unfortunately for us running a lean version of Ubuntu or Xubuntu, the theme needs a little help beyond just installing the theme:

sudo rm -f /usr/share/gdm/autostart/LoginWindow/metacity.desktop

When GDM gets an update, you may have to remove that file again. I haven't played with it enough to figure out how to disable it permanently, if anyone has any suggestions, I would appreciate it! Just post them in the comments section.

Wednesday, May 5, 2010

Lean Xubuntu

I have to admit, I love Xubuntu. They have a really nice community behind it, the developers are super friendly, and the with the last few releases the artwork is superb. Plus, I've used Xubuntu off and on since 7.10, but over the last few releases its gotten a tad bloated. For machines with less than 256 megs or ram, its not the best solution in the world.

So I looked into a way to make Xubuntu leaner than the default install. If I have the resources, I don't mind running the default Xubuntu and Firefox, but on my Compaq Presario 700 (K6-500 with 256 Megs Ram) neither would work well.

However hope isn't lost. If you want a Lean Xubuntu, you just have to follow a few easy steps. First, I used the alternate installer, Xubuntu or Ubuntu works, either way. I did a "Command Line Only Install" (selected at boot time under the F4 "Modes" menu). Once the install was finished, reboot, and you have the familiar "server-like" install of Ubuntu/Xubuntu. Once I logged in, I executed the following apt command:

apt-get -y install xorg gdm xfce4 xubuntu-restricted-extras xubuntu-wallpapers xubuntu-plymouth-theme xubuntu-icon-theme xubuntu-gdm-theme xubuntu-docs xubuntu-default-settings xubuntu-artwork xfce4-goodies chromium-browser network-manager-gnome

Reboot your computer, and you will see the beautiful Xubuntu graphics and themes. Once you log in, you will have to use appfinder to change the empty browser launcher in the top panel to Chromium.

And thats it! A Lean Xubuntu install. I did some memory tests, and this method doesn't use any more RAM than the Ubuntu + Xfce4. Install only what applications you need from the command line, and enjoy the Xubuntu-Lite!

Monday, May 3, 2010

Ubuntu Lucid 10.04

Ubuntu Lucid came out on the 29th, and with it the first "final" release of Lubuntu. Today I'll be comparing three systems memory usage head to head. The first system is Ubuntu and XFCE4, the second system Xubuntu, and the third system Lubuntu. I'll be displaying the results of the "free" command just after boot and logged into the desktop, using only the used memory to determine the desktops memory footprint. The only command executed is the terminal, no other applications prior to the test. All systems use GDM to log into the desktop.

The three systems used in testing are:

UbuntuCli+Xfce4 = Sempron 1500+ with 1G of Ram
Xubuntu = VirtualBox OSE + Guest Additions with 512 Megs of Ram
Lubuntu = VirtualBox OSE + Guest Additions with 512 Megs of Ram

The first two use GDM for login, while Lubuntu uses their own LXDM.

First up, my favorite system, "Command Line Only" Ubuntu plus XFCE4. This install has a special place in my heart, as I only install just the applications I need and want, usually in a trail and error sort of way. I do so love running apt commands! Free reported 221 megs used with 112 megs in buffers, for a total of 109 megs of used RAM. Not bad! However using this system is most definately not for the faint of heart, you will be debugging a lot of things that Xubuntu or Lubuntu take care of for you in the background, and in Lucid I haven't gotten automounting taken care of. Oddly enough it was working in Karmic, but something changed that I haven't quite figured out, and may never pursue. I don't mind executing mount commands, Xfce4 has a nice device mounter panel applet that I'm using now and have enjoyed so far.

Next up, the venerable Xubuntu. I started with Ubuntu with version 7.04, and when 7.10 came out I was in love with Xubuntu and Xfce4. I had used Xfce before in the past, but by the time I was used to Ubuntu, I was pretty much dedicated to the mouse (the Xfce mascot)! I've always loved Xubuntu, but for the last two or three releases have caught a lot of flack due to the system becoming more and more bloated. In fact its said that while Xubuntu feels faster, in reality after using it for some time it winds up with close to the same memory usage as Ubuntu with no desktop effects turned on. At any rate, the results of Free showed 258 megs with 95 megs in buffers, for a total of 163 megs of RAM. So there is 50 megs in there somewhere. My guess is in providing things like automounting and other services I simply don't have installed in my UbuntuCli+Xfce4 systems.

Finally, we have Lubuntu, the new kid on the block. With Ubuntu 10.04 Lubuntu is getting close to becoming an official project of the Ubuntu family of distributions, along with Ubuntu, Xubuntu, Kubuntu, and the other few official projects, check the http://www.ubuntu.com website for the others, they seem to change with every release. The Lubuntu project has released what they hope will be the final product for Lucid Lynx. Its still technically "beta," but its a very stable beta and useful for everyday use. The results of free showed 158 megs used with 56 megs in buffers giving us just 102 megs of used memory! The system seems every bit as polished as Xubuntu, and in my opinion quite beautiful. I'm still an Xfce4 user, but if I had an older system with 256 megs of RAM or less, I would most likely put Lubuntu on it. My only complaint about the system was the file manager, when something was automounted it didn't show up on the desktop like it does on Xubuntu, something that might put some people off. Not a big deal for me, and no where near a deal breaker.

So in summary, here is the used ram after subtracting buffers:

UbuntuCli+Xfce4 = 109 megs used
Xubuntu = 163 megs used
Lubuntu = 102 megs used

Very interesting results indeed. Although I was skeptical at times for the Lubuntu project, they seem to be providing a valuable service to the community that may not be able to do an advanced task like Command Line Ubuntu and install just what they need. I could immagine that would be like the frontier days, and not everyone can handle that although they would learn a lot. I guess its my debian background that makes UbuntuCli such an attractive project for me!

So there you have it, three Lean Ubuntu choices for your systems. If you have the RAM available, the choice between Lubuntu and Xubuntu becomes a matter of taste. Personally, I prefer Xfce4, so would lean a bit towards Xubuntu myself if I wasn't already doing the Command Line installs for fun already. What can I say, I love to tweak things.

Thats it for now!

UPDATE: Seems that the automounting problem was the result of Lucid's removal of Hald, which thunar-volman depends on. Thanks to mr_pouit on irc.ubuntu.com in the #xubuntu channel, I found this bug:

https://bugs.launchpad.net/ubuntu/+source/policykit-1/+bug/546992

To make a long story short, put the following in /etc/rc.local just above exit 0:

/usr/sbin/hald

Reboot, and your all set! Now stuff will automount and show up on the desktop like it did under older versions of Ubuntu! Easy peasy. Thanks Xubuntu Team!