This chapter assumes that your system is already configured to run the X Window System®, and that you only need to reconfigure it to allow graphical login.
The fundamental thing that controls whether your computer boots to a
terminal prompt (console mode) or a graphical login prompt is the default
runlevel. The runlevel is set by the program /sbin/init under the control of the
configuration file /etc/inittab
. The default runlevels
used by different Unix-like systems (and different Linux® distributions) vary,
but if you look at /etc/inittab
the start of it should
be something like this:
# Default runlevel. The runlevels used by RHS are: # 0 - halt (Do NOT set initdefault to this) # 1 - Single user mode # 2 - Multiuser, without NFS # 3 - Full multiuser mode # 4 - unused # 5 - X11 # 6 - reboot (Do NOT set initdefault to this) id:3:initdefault:
All but the last line of this extract are comments. The comments show that runlevel 5 is used for X11 and that runlevel 3 is used for multi-user mode without X11 (console mode). The final line specifies that the default runlevel of the system is 3 (console mode). If your system currently uses graphical login (for example, using xdm) its default runlevel will match the runlevel specified for X11.
The runlevel with graphical login (xdm) for some common Linux® distributions is:
5 for Red Hat® 3.x and later, and for Mandrake™
4 for Slackware
3 for SuSE®. 4.x and 5.x
The first step in configuring your system is to ensure that you can start TDM from the command line. Once this is working, you can change your system configuration so that TDM starts automatically each time you reboot your system.
To test TDM, you must first bring your system to a runlevel that does not run xdm. To do so, issue a command like this:
/sbin/init 3
Instead of the number 3
you should specify the
appropriate runlevel for console mode on your system.
If your system uses Pluggable Authentication Modules
(PAM), which is normal with recent Linux® and Solaris™
systems, you should check that your PAM configuration permits
login through the service named tde
. If you previously used
xdm successfully, you should not need to make any
changes to your PAM configuration in order to use
TDM. /etc/pam.conf
or
/etc/pam.d/tde
. Information on configuring
PAM is beyond the scope of this handbook, but
PAM comes with comprehensive documentation (try looking in
/usr/share/doc/*pam*/html/
).
Now it's time for you to test TDM by issuing the following command:
tdm -nodaemon
If you get a TDM login dialog and you are able to log in, things are going well. The main thing that can go wrong here is that the run-time linker might not find the shared Qt™ or TDE libraries. If you have a binary distribution of the TDE libraries, make sure TDM is installed where the libraries believe TDE is installed and try setting some environment variables to point to your TDE and Qt™ libraries.
For example:
exportTDEDIR=
export/opt/tde
QTDIR=
export/usr/lib/qt2
PATH=
export$TDEDIR/bin:$QTDIR/bin:$PATH
LD_LIBRARY_PATH=
$TDEDIR/lib:$QTDIR/lib
If you are still unsuccessful, try starting xdm instead, to make sure that you are not suffering from a more serious X configuration problem.
When you are able to start TDM successfully, you can start to replace xdm by TDM. Again, this is distribution-dependent.
For Red Hat®, edit /etc/inittab
, look for this
line:
x:5:respawn:/usr/X11/bin/xdm -nodaemon
and replace with:
x:5:respawn:/opt/tde/bin/tdm
This tells init(8) to respawn TDM when the
system is in run level 5. Note that TDM does not need the
-nodaemon
option.
For Mandrake™, the X11 runlevel in
/etc/inittab
invokes the shell script
/etc/X11/prefdm
, which is set up to select from
amongst several display managers, including TDM. Make sure that all
the paths are correct for your installation.
For SuSE®, edit /sbin/init.d/xdm
to add a
first line:
. /etc/rc.config DISPLAYMANAGER=tdm export DISPLAYMANAGER
For FreeBSD, edit /etc/ttys
and find
the line like this:
ttyv8 "/usr/X11R6/bin/xdm -nodaemon" xterm off secure
and edit it to this:
ttyv8 "/usr/local/bin/tdm" xterm on secure
Most other distributions are a variation of one of these.
At this stage, you can test TDM again by bringing your system to the runlevel that should now run TDM. To do so, issue a command like this:
/sbin/init 5
Instead of the number 5
you should specify the
appropriate runlevel for running X11 on your system.
The final step is to edit the initdefault
entry in /etc/inittab
to specify the appropriate
runlevel for X11.
Before you make this change, ensure that you have a way
to reboot your system if a problem occurs. This might be a
“rescue” floppy-disk provided by your operating system
distribution or a specially-designed “rescue”
floppy-disk, such as tomsrtbt
. Ignore this advice
at your peril.
This usually involves changing the line:
id:3:initdefault:
to
id:5:initdefault:
When you reboot your system, you should end up with the graphical TDM login dialog.
If this step is unsuccessful the most likely problem is that the
environment used at boot time differs from the environment that you used for
testing at the command line. If you are trying to get two versions of TDE
to co-exist, be particularly careful that the settings you use for your
PATH
and LD_LIBRARY_PATH
environment variables
are consistent, and that the startup scripts are not over-riding them in
some way.
Would you like to comment or contribute an update to this page?
Send feedback to the TDE Development Team