Kamis, 22 Desember 2011

HOWTO: Get right to X with No Display Manager

GDM, KDM, LXDM, LightDM - so many display managers so little time! If your not sure what a "Display Manager" does on your Linux system, in short it is the piece of software that starts your graphical user interface and manages your user login.  I've been doing more and more work with ARM hardware of the late and most times with embedded devices there is little (or no) need for a display manager to be present. You want to get right to your desktop and just start using the system.

If you have a single user computer odds are you also have no need for a display manager to be cluttering your system. The solution is to simply have your desktop GUI of choice auto-start when the computer turns on. To do this we are going to use a simple, but effective, piece of software cleverly called "NoDM".

Before we begin, you first need to disable or uninstall any current display managers running on the system (look into your display manager documentation on doing this, it varies with each display manager).

Next you need to install NoDM. On a Debian/Apt based system it is as simple as running:

sudo apt-get install nodm

After your package manager works it's magic you need to edit at least two lines in the NoDM configuration file. Typically this file is located at /etc/default/nodm, to edit it open it as super user with your preferred text editor. For example:

sudo leafpad /etc/default/nodm 

The default configuration file should look something like this. The two lines we need to edit most are:

NODM_ENABLED=false

and

NODM_USER=root

The first line you simply need to change to read:

NODM_ENABLED=true

The second line you need to make equal to the username you want to be logged in with.

Finally you need to tell your system what type of session to start when X is spawned. For instance I prefer to use the Enlightenment desktop, so in my ~/.xsession file I add the following line:

enlightenment_start

To add this line to your .xsession file via the CLI simply run:

echo enlightenment_start > ~/.xsession

If you are using a desktop other than Enlightenment you will need to figure out what that desktop's start up command is. Have any questions feel free to drop a comment below and I'll do my best to help out.

Cheers,
~Jeff Hoogland

Tidak ada komentar:

Posting Komentar