LDM does not warn when a user is already logged in

Bug #67366 reported by Jonathan Carter
16
Affects Status Importance Assigned to Milestone
LTSP5
Fix Released
Undecided
Unassigned
Baltix
Invalid
Undecided
Unassigned
ltsp (Ubuntu)
Fix Released
Medium
Scott Balneaves
Intrepid
Fix Released
Medium
Scott Balneaves

Bug Description

When a user logs in from LDM, it does not warn that the user is already logged in on the server or another terminal.

Warning a user about this is quite important, as logging in multiple times aren't supported with many desktop environments and applications.

Note: the original reporter indicated the bug was in package 'ldm'; however, that package was not published in Baltix.

Tags: ltsp
description: updated
Revision history for this message
towsonu2003 (towsonu2003) wrote :

closing the Baltix part, assuming that the problem isn't occuring in Baltix

Oliver Grawert (ogra)
Changed in ltsp:
assignee: nobody → ogra
importance: Undecided → Wishlist
status: Unconfirmed → Confirmed
Revision history for this message
Ian Jackson (ijackson) wrote :

Using an edubuntu server install made from the feisty i386 edubuntu dvd 20070418, I absentmindedly logged in twice - once on a thin client and once on the server.

The result was that on the server I was no longer able to log out at all. Even logging out on the client and C-A-Backspace-killing the X server, and logging in again, produced a session where [Door icon] / Logout would hang.

Since the consequences are so serious and there is absolutely no reason for the user to expect this not to work, I think this bug is much worse than Wishlist and I have increased the priority.

Changed in ltsp:
importance: Wishlist → Medium
Revision history for this message
Scott Balneaves (sbalneav) wrote :

I'll handle this as part of the LDM rewrite

Changed in ltsp:
assignee: ogra → sbalneav
status: Confirmed → In Progress
Revision history for this message
MohanMandava (mssmandv) wrote :

I am seeing this problem too. Is there a workaround until the fix (apart from a re-install) ? Or is Ctrl-Alt-Backspace the only way out ?

Thanks,
-Mohan.

Revision history for this message
Scott Balneaves (sbalneav) wrote :

Did some initial work on this. Looks like as part of the new rc subsystem within ldm, we can do a pgrep for session information, If found, then we can use something like zenity to pop up a warning. I'll look at getting something into bzr this weekend.

Revision history for this message
Oliver Grawert (ogra) wrote :

lets do that properly and have a separate feedback gui app for the differen feedbacks we can have if the greeter is gone ... not zenity :)
if you got something for the backend let me know, i'll look into hacking up a basic gui :)

Revision history for this message
Francis Giraldeau (francis-giraldeau) wrote :

One important thing to support multiple hosts : multiple sessions must be avoided over the whole cluster. A kind of global variable is needed for that. A lock file can be used in the home directory for that, that contains Xsession PID and the server on which the session is started. Assuming that each user has it's own ssh key, then it will be able to kill it's previous session to start a new one.

Comments?

Revision history for this message
Scott Balneaves (sbalneav) wrote :

A clustered approach is too much to get in for this round. We'll handle the simple "same server" case for now, and spec this out next time.
Lots of possible issues on this one: what if the file's created, but the lock information becomes stale due to improper logout. Where do we
put it? Should we just arbitrarily destroy another valid session that may have an open OpenOffice document with a term paper that's got
6 hours work in it with no save, etc etc etc.

We really have 2 separate issues here:

1) Site policy. Some sites may find it desirable, even necessary, to have multiple logins. Others may wish to support a strict "one user one login" rule. We should put some thought to coming up with a solution that allows both.

2) Current technical limitations. The REAL problem here is that Gnome and KDE freak out when multiple logins occur on the same account, due to their assumption that the single workstation paradigm is what's prevalently out there. However, the reality on the ground is that a LARGE number of Gnome/KDE desktops are delivered in a thin client manner, with exactly the problems we're running into. The REAL solution to this problem will be to open a dialogue with the desktops, and figure out what needs to be done to allow multiple simultaneous logins to be workable, perhaps with a warning (i.e. "You have another desktop session open, this will be a read-only desktop in which you will not be allowed to make desktop changes"). Then, the only problem we'll have to worry about will be solving #1.

Revision history for this message
Oliver Grawert (ogra) wrote :

i dont think we should differ from gdm behavior here ... afaik it automatically warns the user about an existing session with a dialog that has a button saying "log me in anyway" and afaik its configurable by the admin if the dialog is shown ... (i have to look, i may be wrong here)

Revision history for this message
Roland Ronquist (roland-ronquist) wrote :

Oliver is perfectly right about the gdm, due to my present problems with using ldm I am very much up to date on how to setup gdm 8-)

Best,
r.r.

Revision history for this message
Avinash.Rao (avinash-aol) wrote :

I am using Ubuntu Studio + LTSP 5.0 and i am facing the same problem. The server doesnot warn the user that he/she has already logged in on another machine.

This creates a problem when the user open the same file, make changes and save the file, which is already open on another machine.

Hope this is fixed.
Avinash

Revision history for this message
GideonRomm (gideon) wrote :

The attached file can be used in:

/opt/ltsp/i386/usr/lib/ldm/rc.d/S15-userLoginCheck

with lts.conf param:

LDM_LIMIT_ONE_SESSION = True

Revision history for this message
Jordan Erickson (lns) wrote : Re: [Bug 67366] Re: LDM does not warn when a user is already logged in

Gadi,

Wow, great work =) I don't understand a lot of your script but it looks
to me like this script will also kill stale procs (I.E. not procs in
another active user session) - is that true? If so, it might be worth
mentioning that this would replace the unofficial package
"gnome-watchdog", which does a much similar thing.

Cheers,
Jordan

GideonRomm wrote:
> The attached file can be used in:
>
> /opt/ltsp/i386/usr/lib/ldm/rc.d/S15-userLoginCheck
>
> with lts.conf param:
>
> LDM_LIMIT_ONE_SESSION = True
>
>
> ** Attachment added: "rc.d file to achieve limiting one session per server"
> http://launchpadlibrarian.net/17939928/S15userLoginCheck.20080924
>
>

Revision history for this message
Oliver Grawert (ogra) wrote :

included in intrepid

Changed in ltsp:
status: In Progress → Fix Released
Revision history for this message
Avinash.Rao (avinash-aol) wrote :

Hi GideonRomm,

I did create the S15-userLoginCheck under /opt/ltsp/i386/usr/lib/ldm/rc.d and copied the contents of your attachment. I also found another file under this directory called S01-setup-xauth.

I also added the LDM_LIMIT_ONE_SESSION = True in lts.conf file. I restarted the dhcp3-server service. But, i guess its not working. The lts.conf file is under the /opt/ltsp/i386/usr/share/doc/ltsp-client-core/examples/lts.conf.

Am i doing anything wrong?

Thanks
Avinash

Revision history for this message
GideonRomm (gideon) wrote :

If you are using Ubuntu, the lts.conf file should be in: /var/lib/tftpboot/ltsp/i386/lts.conf
If it is not there, create it in the format:

[default]
LDM_LIMIT_ONE_SESSION = True

Also, if using Ubuntu, after adding the S15-userLoginCheck, you should run: sudo ltsp-update-image --arch=i386

-Gideon

Revision history for this message
Avinash.Rao (avinash-aol) wrote :

Thank you for your quick response.

Yes, I am using Ubuntu, I will make the changes you have suggested and get
back!

Warm Regards,
Avinash

On Tue, Nov 4, 2008 at 5:17 PM, GideonRomm
<email address hidden>wrote:

> If you are using Ubuntu, the lts.conf file should be in:
> /var/lib/tftpboot/ltsp/i386/lts.conf
> If it is not there, create it in the format:
>
> [default]
> LDM_LIMIT_ONE_SESSION = True
>
>
> Also, if using Ubuntu, after adding the S15-userLoginCheck, you should run:
> sudo ltsp-update-image --arch=i386
>
> -Gideon
>
> --
> LDM does not warn when a user is already logged in
> https://bugs.launchpad.net/bugs/67366
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in Linux Terminal Server Project: New
> Status in "ltsp" source package in Ubuntu: Fix Released
> Status in ltsp in Ubuntu Intrepid: Fix Released
> Status in Baltix GNU/Linux: Invalid
>
> Bug description:
> When a user logs in from LDM, it does not warn that the user is already
> logged in on the server or another terminal.
>
> Warning a user about this is quite important, as logging in multiple times
> aren't supported with many desktop environments and applications.
>
>
>
> Note: the original reporter indicated the bug was in package 'ldm';
> however, that package was not published in Baltix.
>

Revision history for this message
Stéphane Graber (stgraber) wrote :

This bug has been fixed with the S15-userLoginCheck ldm rc.d script included in the upstream code and in Jaunty. Marking the bug as fix released upstream (it's already marked as fixed for ubuntu).

Changed in ltsp:
status: New → Fix Released
Revision history for this message
Lucas (swmxavier) wrote :

Hi.

I am using ubuntu 9.04 server. But there is not a directory called rc.d in ldm.

I need create it?

Help.

Thx.

Revision history for this message
GideonRomm (gideon) wrote :

Lucas,

You don't need to do anything. Simply set:

LDM_LIMIT_ONE_SESSION = True

in your lts.conf file.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.