Forum: X and Fluxbox
Topic: su -l
started by: erekose
Posted by erekose on Nov. 10 2007,07:16I logged to remote machine hosting DSL using putty, then issued "su -l <newuser>" and after supplying the correct password, I noticed that this will start a new windows manager on the remote machine.
It looks like the user profile was loaded to restart the X Manager on the remote machine ?
Posted by curaga on Nov. 10 2007,13:53In runlevel 5 it's default behavior to start a new X session. Boot into runlevel 2 if you want text mode only
Posted by erekose on Nov. 10 2007,15:39DSL has Debian blood in it. Debian does not make any distinction between runlevels 2 to 5.
* 0 - Halt
* 1 - Single
* 2 - Full multi-user with display manager (GUI)
* 3 - Full multi-user with display manager (GUI)
* 4 - Full multi-user with display manager (GUI)
* 5 - Full multi-user with display manager (GUI)
* 6 - Reboot
Anyway, it's just changing to another user using the su command and it should not be restarting the X session on the remote machine.
Posted by mikshaw on Nov. 10 2007,15:43
runlevel 2 = text mode as root
runlevel 3 (recently added) = text mode as dsl
If you want to boot into a desktop but prevent a new one from a remote connection, you'll probably need to modify /home/dsl/.bash_profile to remove startx. This would mean having to type "startx" in order to get a desktop initially. A more complicated alternative would be to check if the login is local or remote, and start x accordingly. I couldn't say how to do that, though.