View Single Post

   
  #3 (permalink)  
Old 02-21-2008, 08:47 AM
oldNbald
 
Posts: n/a
Default Re: Departing from GDM ... need a script.

Ben Measures scratched on the wall:

> Starting X on login isn't without caveats though.
>
> For example, only one user at a time can login since startx will
> output the error "Server is already active for display 0" for
> additional logins.


Hi ya Ben, When it comes to, "Server is already active for display 0",
there's not a problem - we always logoff and on as needed without any
xnest, etc.

Things didn't work out with the script.
Check out what I did in my /home to see if it's correct, please:

file: .bashrc

---begin---

#! /bin/bash
if ! pgrep -U $UID -f startx &> /dev/null; then
startx;
logout;
fi

---end----

Here's more info:

bash-2.05b$ ls -l .bas*
-rw------- 1 cmo users 375 Dec 13 20:34 .bash_history
-rwxr-xr-x 1 cmo users 83 Dec 13 20:05 .bashrc

What is your opinion?

Thanks for your assistance !
--
oNb
Another happy Linux user - # 276084.
Reject religion ! Embrace Jesus Christ.
Reply With Quote