You are not logged in.
~$ startx
Goodbye!
Offline
Here you go: wiki linky
I made it long
as I lacked the time to make it short...
Offline
Thanks,
I use KDE, that of this must be in "/etc/rc.conf":
# This would load KDM on startup
DAEMONS=(syslogd klogd !pcmcia network netfs crond kdm)
# This would load GDM on startup
DAEMONS=(syslogd klogd !pcmcia network netfs crond gdm)
# This would load XDM on startup
DAEMONS=(syslogd klogd !pcmcia network netfs crond xdm)
Goodbye!
Offline
or you can edit your /etc/inittab file like this
#
# /etc/inittab
#
# Runlevels:
# 0 Halt
# 1(S) Single-user
# 2 Not used
# 3 Multi-user
# 4 Not used
# 5 X11
# 6 Reboot
id:5:initdefault:
rc::sysinit:/etc/rc.sysinit
rs:S1:wait:/etc/rc.single
rm:2345:wait:/etc/rc.multi
rh:06:wait:/etc/rc.shutdown
su:S:wait:/sbin/sulogin -p
c1:2345:respawn:/sbin/agetty 38400 vc/1 linux
c2:2345:respawn:/sbin/agetty 38400 vc/2 linux
c3:2345:respawn:/sbin/agetty 38400 vc/3 linux
c4:2345:respawn:/sbin/agetty 38400 vc/4 linux
c5:2345:respawn:/sbin/agetty 38400 vc/5 linux
c6:2345:respawn:/sbin/agetty 38400 vc/6 linux
ca::ctrlaltdel:/sbin/shutdown -t3 -r now
x:5:respawn:/opt/kde/bin/kdm -nodaemon
# End of file
notice the id:5:initdefault: and x:5:respawn:/opt/kde/bin/kdm -nodaemon lines. this will launch kdm when you boot up too.
im not sure which way is better or faster, but i do it this way.
Offline
Thanks, thanks, thanks!
Goodbye!
Offline
im not sure which way is better or faster, but i do it this way.
At least with GDM there are shown errors at shutdown if the inittab method isn't used (GDM can't be killed by the initscripts at shutdown since AFAIK GDM kills itself when starting the shutdown)
Offline
I don't need any login manager. I have written this piece of code at the end of ~/.zshrc (~/.bashrc might also work when using bash) and if I log into first terminal console, X starts automatically.
# Start X if not already started and you are in first console
if [ "`tty`" = "/dev/vc/1" ]; then
startx
fi
Maybe somebody finds this useful too.
Offline
You could also check if $DISPLAY is set, and if it's not, startx. This would work in all consoles. Another enhancement would be:
if [ -z "$DISPLAY" ]; then
n=5
echo "Starting X11 in $n seconds..."
sleep $n
startx
fi
So you still have some seconds to decide whether you want to start X or not.
I used it myself some time ago. I prefer that to using a graphical login manager.
Offline
Thanks, thanks.
Goodbye!
Offline