Difference between revisions of "Display manager"

From ArchWiki
Jump to: navigation, search
(Logging in as root)
Line 175: Line 175:
 
===GDM===
 
===GDM===
 
====Logging in as root====
 
====Logging in as root====
It's not advised to login as root but if you still want to login as root user you can edit /etc/gdm/custom.conf. To do this open /etc/gdm/custom.conf and find the line:
+
It's not advised to login as root but if you still want to login as root user you can edit /etc/gdm/custom.conf. To do this open /etc/gdm/custom.conf with your favorite editor and find the line:
 
  [security]
 
  [security]
 
After that line add:
 
After that line add:
 
  AllowRoot=true
 
  AllowRoot=true
You should now be able to login as root.
+
Now save the changes and restart X. In the case of gdm that can be done with "gdm-restart" on a console. Once done you should now be able to login as root.
  
 
==See Also==
 
==See Also==

Revision as of 15:02, 27 August 2009

Template:I18n links start Template:I18n entry Template:I18n entry Template:I18n entry Template:I18n entry Template:I18n entry Template:I18n entry Template:I18n entry Template:I18n entry Template:I18n entry Template:I18n links end

Definition and Explanation

A login manager is a graphical interface screen that is displayed at the end of the boot process, and in place of displaying the command prompt.

There are various types of these, just as there are various types of windows managers and desktop managers. It is that which loads up after the boot menu and boot process, and before the window manager loads.

There is a certain amount of customization and themeability available with these managers.

A listing of login managers follows below.

Install the package

Choose and install a preferred Display Manager.

Note: It is best practice, but not required, to choose the Display Manager that corresponds to your Desktop Environment. Typically SLiM is preferred if there is not a corresponding Desktop Environment.

XDM: X Display Manager

# pacman -Sy xorg-xdm

GDM: Gnome Display Manager

# pacman -Sy gdm

KDM: KDE Display Manager

# pacman -Sy kdebase kdebase-workspace

SLiM: Simple Log-in Manager

# pacman -Sy slim

Entrance: Enlightenment Display Manager

# pacman -Sy entrance-svn

(Note: entrance-svn is in the [community] repository)

Configure loading the Display Manager

You have two easy methods to make the system load the display manager:

  1. Inittab Method
    The Display Manager will load automatically after start-up and will respawn in the event of a crash.
  2. Daemon Method
    The Display Manager will load automatically during the start-up as a daemon.
    (Currently only works with Entrance, GDM, KDM and SLiM)

The inittab method is recommended for various reasons, one being that it will allow you to boot directly into framebuffer mode from GRUB. This is an advantage should the graphics driver crash in X, for example, you would not be forced to fix your system from a live cd or through other needlessly complex means.

With the inittab method all you would have to do is to press 'e' for edit at the GRUB prompt and just add the number of the run-level you prefer, such as:

3

to the end of the 'kernel' line to boot directly into framebuffer mode in order to fix your system/X (This is also described more thoroughly & descriptive below.)

Both methods are equally easy.

Inittab Method (recommended)

The run-levels are:

  0    Halt
  1(S)	Single-user
  2    Not used
  3    Multi-user (default)
  4    Not used
  5    X11
  6    Reboot

Modify default run-level

Edit /etc/inittab and find the line that looks like this:

id:3:initdefault:

Modify the '3' to '5' for X11:

id:5:initdefault:

The next time you reboot, the 'X Display Manager' should run. For other display managers see below:

Modify default Display Manager

Edit /etc/inittab and find the line that looks like similar to this one (near the end):

x:5:respawn:/usr/bin/xdm -nodaemon

Modify it so it points to the Display Manager of your choice:

GDM:

x:5:respawn:/usr/sbin/gdm -nodaemon

KDM:

x:5:respawn:/usr/bin/kdm -nodaemon

SLiM:

x:5:respawn:/usr/bin/slim >& /dev/null

Entrance:

x:5:respawn:/usr/sbin/entranced -nodaemon &> /dev/null

The next time you reboot, the Display Manager of your choice should run.

Daemon Method

You simply need to add the daemon name to your daemons array in '/etc/rc.conf'.

Near the end of the file you will see a line that looks similar to the following:

DAEMONS=(syslogd klogd !pcmcia network netfs crond) # this is the daemons array

Append the daemon name for the Display Manager of your choice (entranced, gdm, kdm or slim):

Example

DAEMONS=(syslogd klogd !pcmcia network netfs crond entranced)


The next time you reboot, the Display Manager should run. In the event that it doesn't, make sure that you typed in the name correctly, also make sure that the manager you selected is installed. It also helps to make sure that startx is not stopping with errors.

Note: If you use this method and your display manager hangs while loading, or X doesn't recognize any input device, you will need to boot into single user mode (run-level 1) using the examples above and remove the display manager daemon from rc.conf.

Troubleshooting

If GDM starts up properly on boot, but fails after repeated attempts on logout, try adding this line to the daemon section of /etc/gdm/custom.conf:

GdmXserverTimeout=60

Switching run-levels

Command Prompt

If you want to test out the display manager without rebooting, or you want to change the X configuration and that pesky Display Manager keeps respawning.

Use this command:

/sbin/telinit <run-level>

To switch to run-level 3 (Multi-User):

/sbin/telinit 3

To switch to run-level 5 (X11):

/sbin/telinit 5

By switching you can avoid restarting the system during your testing.

GRUB

You can add a menu item in GRUB to allow you to boot with or without X11,

In /boot/grub/menu.lst find the first kernel entry you have, the default is '# (0) Arch Linux'

# (0) Arch Linux
title  Arch Linux
root   (hd0,0)
kernel /vmlinuz26 root=/dev/sda3 ro
initrd /kernel26.img

You can duplicate it and modify both like so:

# (0) Arch Linux Multi-user
title  Arch Linux Multi-user
root   (hd0,0)
kernel /vmlinuz26 root=/dev/sda3 ro 3
initrd /kernel26.img
# (0) Arch Linux X11
title  Arch Linux X11
root   (hd0,0)
kernel /vmlinuz26 root=/dev/sda3 ro 5
initrd /kernel26.img

The run-level was appended to the end so the kernel knows what run-level to start with.

LILO

You can start-up with the run-level of your choice by just selecting or typing in the kernel name and then appending the desired run-level in the lilo boot screen.

Like so:

 : Arch 5

GDM

Logging in as root

It's not advised to login as root but if you still want to login as root user you can edit /etc/gdm/custom.conf. To do this open /etc/gdm/custom.conf with your favorite editor and find the line:

[security]

After that line add:

AllowRoot=true

Now save the changes and restart X. In the case of gdm that can be done with "gdm-restart" on a console. Once done you should now be able to login as root.

See Also