Re: xdm, was Re: Accepting external sendmail on 2.0.2

From: Igor Sobrado (igor_at_string1.ciencias.uniovi.es)
Date: 07/18/05


Date: 18 Jul 2005 19:15:13 +0200

Frederick Bruckman <fredb@immanent.net> wrote:
>
> I think you shouldn't run an X server and a getty on the same
> virtual console. On i386, you enable virtual consoles by setting
> "wscons=YES" in "/etc/rc.conf". The X server will start on vt05
> by default, if its configured, but occasionally the X server wins
> the race with wscons and starts on the wrong virtual console, so
> its better to add "vt05" to the "Xservers" start up file. As in:
>
> tail -2 /etc/X11/xdm/Xservers
>
> #:0 local /usr/X11R6/bin/X vt05 -nolisten tcp
> :0 local /usr/X11R6/bin/X vt05
>
> I guess it's not the default, because it wouldn't work on ports
> that don't have virtual consoles.

Hi Frederick.

Agreed, I think that running an X server and a getty on the same
virtual console is a very bad decision and must be avoided if
possible. I think that defaults in NetBSD fix the problem you
are describing (a race with wscons) now. I do not know the exact
symptoms of the problem you are describing, but it looks different
from the problem I have. Sorry, I probably did a very bad
description of the problem in my previous post.

As it is a small text file, I will dump the contents of the
Xservers file provided by default in NetBSD 2.0.2:

-------------------------------
$ cat /usr/X11R6/lib/X11/xdm/Xservers
# $Xorg: Xserv.ws.cpp,v 1.3 2000/08/17 19:54:17 cpqbld Exp $
#
# Xservers file, workstation prototype
#
# This file should contain an entry to start the server on the
# local display; if you have more than one display (not screen),
# you can add entries to the list (one per line). If you also
# have some X terminals connected which do not support XDMCP,
# you can add them here as well. Each X terminal line should
# look like:
# XTerminalName:0 foreign
#
:0 local /usr/X11R6/bin/X vt05 -nolisten tcp
-------------------------------

(the only uncommented line has vt05 in the default file, no need
to write a modified version of this file in /etc/X11). From your
post, I understand that the race condition occurs only when the
X server starts too fast and uses one of the (yet) unassigned
virtual consoles that will be requested by wscons as soon as
it starts. Well, I do no think that it will happen now, as the
console to be used (vt05) is in the xdm's Xservers configuration file.
I read some threads about a race condition with console in xdm,
I suppose that the problem you are describing is that one.
Fortunately, it looks fixed in a way that works on all supported
platforms now (don't know if Xservers is different in NetBSD/i386).

The problem, though, is that both the text console (ttyE0, but
labeled "console") and the xconsole automatically started by
xdm are in some way "incompatible".

To be exact, all works fine until someones tries to login in the
text console. When someone goes to the text console and tries
to login to the system the next message appears in the small
console window started by xdm:

-------------------------------
Console log for altair.v6.local
s
NetBSD/i386 (altair.v6.local) (console)
 
login: Jul 18 18:38:55 altair init: getty repeating too quickly on port /dev/console, sleeping
-------------------------------

(the "s" in the second line is the first character in my login name)
and the text console "hangs". After a given amount of time
(usually 5 or 10 minutes) the text console can be used to log into
the system (at least when X has been started and there is not an
xconsole running, not sure if that process has been killed or died).

I tried changing the ":0 local /usr/X11R6/bin/X vt05 -nolisten tcp"
line in the configuration file to ":0 local /usr/X11R6/bin/X vt05"
but I guess that removing "-nolisten tcp" is not the fix I want. :-)))

In other words, the only workaround I know is using an empty Xsetup_0
file to start xdm without an xconsole on the lower-right corner of
the screen.

Cheers,
Igor.



Relevant Pages

  • Re: Switching virtual terminals
    ... CTRL+ALT+Fn works but from a text console Alt-Fn does nothing. ... It's remains at the same tty I was at when I issued the ... so, 'from an x session to a text console, aka, virtual console, ... FWIW my ~6-year-old Packard Bell laptop has the same problem. ...
    (Fedora)
  • Re: Switching virtual terminals
    ... works but from a text console Alt-Fn does nothing. ... at the same tty I was at when I issued the CTRL+ALT+Fn from X. ... so, 'from an x session to a text console, aka, virtual console, ... ..the Sin of Ignorance, ...
    (Fedora)
  • Re: Switching virtual terminals
    ... works but from a text console Alt-Fn does nothing. ... at the same tty I was at when I issued the CTRL+ALT+Fn from X. ... so, 'from an x session to a text console, aka, virtual console, ... This keyboard has ALT keys on both sides of the space bar. ...
    (Fedora)
  • Re: Switching virtual terminals
    ... works but from a text console Alt-Fn does nothing. ... the same tty I was at when I issued the CTRL+ALT+Fn from X. ... so, 'from an x session to a text console, aka, virtual console, ... Machine is about a 7 year old Dell with a 110 key PC keyboard. ...
    (Fedora)
  • RE: Allow custom group access to Power User server console?
    ... Another alternative would be if there is a simple console (similar to ... Allow custom group access to Power User server console? ... Power Users server management console without putting them in the Power ...
    (microsoft.public.windows.server.sbs)