Subject: RE: Starting X from /etc/rc.local
To: netbsd-users <netbsd-users@netbsd.org>
From: John A. Maier <johnam@kemper.org>
List: netbsd-users
Date: 01/13/2000 12:58:00
Solution:

1) Compile the kernel for a pc console.
2) add:
/usr/X11R6/bin/X<server> -query <xdmserver>
to your rc.local
3) in /etc/ttys turn on your console
console "/usr/libexec/getty Pc"         pc3     on secure
(otherwise you'll have no way of shutting down!)

I had a gut feeling that the PCVT stuff wasn't happy with having a X   
server started from a non-login terminal.

I like most of you have become spoiled by pcvt's ability to Ctrl+Alt+Fn   
to other virtural consoles. Remember to Ctrl+Alt+BackSpace out of X so   
you can get a local login prompt to shutdown nicely.

For those who don't understand what I an trying to accomplish...
I am starting X with the -query switch.  This allows X to query a xdm   
server and get a xdm login prompt.  Efectivly I have turned a fleet of   
486-80Mhz with 8-12Megs of RAM into X terminals!!!

Just incase your currious, other switchs are:
 -broadcast  # this sends out a broadcast request for a xdm server and   
coneects to the first one that responds.  This is a stupid mode to use if   
you have several xdm server on you net (see -indirect).

 -query <host> # connects to a specific xdm server and displays a login   
screen.

 -indirect <host> #  request a chooser from a xdm server.  If you have   
several xdm servers on you net, it will display a list of all of them.   
 You can then select the one to connect to, which will give you a xdm   
login box for that machine.

John A. Maier
Kemper Military School and College
Director of MIS
Voice: 660-882-5623
Fax: 660-882-3778
Email: johnam@kemper.org
Web: www.kemper.org


> -----Original Message-----
> From: John A. Maier
> Sent: Thursday, January 13, 2000 11:58 AM
> To: netbsd-users; netbsd-help; John A. Maier
> Subject: Starting X from /etc/rc.local
>
>
>
> I tried starting X from rc.local with the command:
> /usr/X11R6/bin/XF86_S3 -query johnam &
>
> For the most part it works, but after I login, odd keyboard
> stuff starts
> happening.
>
> I open an xterm and it starts scrolling as if the Enter key
> is stuck.  I
> hit some keys and it stops.  But then other characters will
> spontainiously start printing.
>
> Three PC and keyboards later it still happened!
>
> I disable this startup in rc.local and just invoked it from a
> termial
> prompt and it works flawlessly!!!
>
> My first guess is it has something to do with X starting,
> PCVT and no
> control terminal.
> (I have tried with both pcvt and wscons)
>
> I would love to still start X from rc.local and avoid having
> to login
> from the terminal, any ideas?
>
> John A. Maier
> Kemper Military School and College
> Director of MIS
> Voice: 660-882-5623
> Fax: 660-882-3778
> Email: johnam@kemper.org
> Web: www.kemper.org
>