LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Start X automatically when user logs in? (http://www.linuxquestions.org/questions/linux-newbie-8/start-x-automatically-when-user-logs-in-406145/)

Firewielder 01-21-2006 08:36 AM

Start X automatically when user logs in?
 
I am running Fedora 4, using a very minimal install, with FVWM as my window manager. I would like to eliminate gdm (gnome desktop manager) from my system and simply have have FVWM (and consequently, X) start every time I log in as a certain user. How can I accomplish this?

vaporizel 01-21-2006 08:50 AM

1. Go to console.
2. type "pico /etc/inittab" (if you have vi then replace pico -> vi)
3. Look the default runlevel in configuration, look the runlevel with meaning "X11 with xdm" or like it.
E.G (in that case, you must use 4):

# These are the default runlevels in Slackware:
# 0 = halt
# 1 = single user mode
# 2 = unused (but configured the same as runlevel 3)
# 3 = multiuser mode (default Slackware runlevel)
# 4 = X11 with KDM/GDM/XDM (session managers)
# 5 = unused (but configured the same as runlevel 3)
# 6 = reboot

3. replace default runlevel ("commented with #") with 4 (using as top before)
id:4:initdefault:

4. save you configuration

5. restart your computer.

Maybe this will help you.

acid_kewpie 01-21-2006 08:57 AM

how do you intend to log in without gdm?? if you mean a console login then gdm isn't used anyway, so is already got rid of. do you simply mean you want a user who logs in under a console to run startx automatically? i'd say run "tty" and if the response starts with "/dev/tty" then you know you're in a console, so start X if possible. so in that users .bashrc add:
Code:

[ $(tty | grep /dev/tty) ] && startx

Firewielder 01-21-2006 09:12 AM

Right, I want to be able to login from a console, without having any gdm/kdm/xdm/*dm, and have x and fvwm start when I log in as a certain user.

acid_kewpie 01-21-2006 10:00 AM

try my solution then, should do the trick.


All times are GMT -5. The time now is 10:41 AM.