Start X on login

From Gentoo Wiki
Jump to:navigation Jump to:search
This page has been nominated for deletion.

The given reason is: Duplicate topic where this one is not fleshed out, nothing links here, and parts are outdated

If you disagree with its deletion, do not remove this notice; discuss your objections on the associated discussion page.

Administrators, please remember to check if anything links here and the page history before deleting.

This notice should remain for a minimum of 1 month after it was placed on the page. If discussion is still ongoing it should remain until a consensus is reached, at which time the page may be deleted or this notice may be removed. (However, if the page has only been edited by the user who nominated it for deletion and/or is in the nominator's user space, then a speedy deletion may be called for.)

This seems to be a duplicate of earlier X without Display Manager .

This guide shows how you can start X after logging in to terminal. Its lightweight alternative to display managers. When combined with Automatic_login_to_virtual_console a system can be configured to automatically boot directly into X.


To automatically start X, add the following to your ~/.bash_profile.

FILE ~/.bash_profile
if [[ -z $DISPLAY ]] && [[ $(tty) = /dev/tty1 ]]; then exec startx; fi


To automatically start KDE, add the following to your ~/.bash_profile.

FILE ~/.bash_profile
if [[ -z $DISPLAY ]] && [[ $(tty) = /dev/tty1 ]]; then exec startx /usr/bin/startkde; fi

Ensure the user has permission to execute the .bash_profile script.

user $chmod u+x ~/.bash_profile

Now when you log in to the first terminal bash executes startx automatically.