Hello.
>xdm runs Xstartup on behalf of the user.
Hmm.. man page says: "After the user logs in, xdm runs the Xstartup script
as root.".
There is a $USER argument passed to this script, but the script itself runs
as root.

>. What does your Xstartup say?

exec /usr/bin/sessreg  -a -w /var/log/wtmp -u /var/run/utmp -x
/usr/lib64/X11/xdm/Xservers -l $DISPLAY -h "" $USER

I am pretty sure the problem is the following line in xdm-config:

DisplayManager*startup: /usr/lib64/X11/xdm/Xstartup
! The following three resources set up display :0 as the console.
DisplayManager._0.startup: /usr/lib64/X11/xdm/GiveConsole

GiveConsole is:
chown $USER /dev/console

So, sessreg is simply not called when xdm serves screen :0

I was able to fix it by copying sessreg line to the GiveConsole, but it
looks like a strange hack..
Ilya






On Sun, Oct 18, 2020 at 5:35 PM Chris Sorenson <cso...@isd.net> wrote:

> xdm runs Xstartup on behalf of the user. Or, at least it's supposed to.
> Xstartup should then call sessreg which should invoke wtmp and utmp.
> However, it's possible to bypass wtmp/utmp by passing "-w none" to
> sessreg, in which case "w" won't show the login. What does your Xstartup
> say?
>
>
> On 10/18/2020 07:00 AM, xorg-requ...@lists.x.org wrote:
> >
>
> >
> > Message: 1
> > Date: Sun, 18 Oct 2020 00:12:22 +0300
> > From: IL Ka <kazakevichi...@gmail.com>
> > To: xorg <xorg@lists.x.org>
> > Subject: xdm-config for :0 doesn't call Xstartup?
> > Message-ID:
> >       <CAHv=
> rm33zezeml9qkenphvkazh+upn+tdb7sbjjkl9qv8je...@mail.gmail.com>
> > Content-Type: text/plain; charset="utf-8"
> >
> > Hello.
> >
> > I found that xdm-config has the following lines
> > DisplayManager*startup: /usr/lib64/X11/xdm/Xstartup
> > DisplayManager._0.startup: /usr/lib64/X11/xdm/GiveConsole
> >
> > As I understand, that means GiveConsole is run instead of Xstartup,
> > so sessreg is not called, and I do not see my login in "w" output.
> >
> > I am sure this is how it worked for decades, so it could be that I
> > misunderstand something.
> >
> > Is it a bug?
> >
> > Ilya.
> >
>
_______________________________________________
xorg@lists.x.org: X.Org support
Archives: http://lists.freedesktop.org/archives/xorg
Info: https://lists.x.org/mailman/listinfo/xorg
Your subscription address: %(user_address)s

Reply via email to