VMware Horizon Community
RTVNoord
Enthusiast
Enthusiast

Log Off After Disconnect not working

Hi there,

We run Horizon 8.3.0 with several different Desktop Pools. Within these desktop pools we have set the "Log Off After Disconnect" at 90 minutes. 
Pool-settings.png

This setting is not set in the VMware Horizon Agent GPO, but only within the Pools

This "Log off after disconnect" setting is to make sure our lazy users who just hit the X instead of logging off 😤, still will be (forced) logged off. But.. this disconnect setting per desktop pool does not seem to work. As you can see in the image below, users are disconnected for many hours but not logged off.Horizon-disconnected-users.png

Finally, after the famous 10 hours (..the default setting for timeout is 10 hours) these users will finally be logged off.

But as you can understand, that's not what we want. We want disconnected users to be logged off after 90 minutes, as set in the desktop pool. What's the bug overhere? And, how can we fix this so users are logged off after the set 90 minutes?

Any ideas / help would be great 👍

Regards,

Pascal

0 Kudos
9 Replies
ganeshteja55
Contributor
Contributor

Facing same issue, pls suggest

0 Kudos
rpeb1723
Contributor
Contributor

Maybe check the global settings section and make sure it isn't set to never?  Also, I'm pretty sure every user on that list was disconnected for less than 90 minutes except for the last one.  The time on the right side isnt how long they have been offline, it is how long their session lasted before they disconnected.  So if they were connected for 4 hours and then disconnected the time on the right under the "Last session" heading will be 4 hours and the time under the duration heading will be 4 hours plus however long the session stays available after they disconnected

0 Kudos
jzumwalt
Enthusiast
Enthusiast

Did you make any progress on this? We are having the same issue. 

0 Kudos
RTVNoord
Enthusiast
Enthusiast

Sorry for the late response. 

First of all, the error is not in Horizon. It is the wrong way we read the disconnect status. It is by design and cannot be modified.
Once you know it, it's simple.

An explanation:

When a user is disconnected, the time the user is actually disconnected is the difference in time between the column: duration and last session. So you have to calculate yourself. And yes, this is very crooked.

In the example below (see also the image), you can clearly see what I mean:
Start Time: 2 hours 53 minutes
Last Session: 2 hours 5 minutes
This makes the total time that the user is actually disconnected: 48 minutes (Start Time - Last Session = Actual disconnect time)


In our environment I see, exactly after 1 hour, that the user is logged out.


Hope that makes it a bit more clear.

 

 

CEDCHelp
Contributor
Contributor

@RTVNoord  Seems you didn't have issues at all like the other people, and your system was logging off disconnected sessions as it should.

 

 

In my case, the log off should happen within 1 minute and it doesn't, and disconnected sessions can stay longer than 2 months as recorded over the summer when we didn't need any. Now we must clear the sessions daily or the students can't even access the remote computer lab as its full of disconnected sessions, meaning you can't connect to that PC unless you're the same person with the disconnect session.

 

 

We are looking at making a GP that will force computers to reboot at midnight to clear them, but this isn't the correct fix. 

 

has anyone found a fix for VM ? I checked logs, and I can see the log when someone disconnected correctly as:

 

log:
2023-09-25T05:22:29.090-06:00 INFO (11DC-1330) <4912> [wsnm_desktop] Session DISCONNECTED: sessionId=4, user DOMAIN\user, client=CYRUS, connectionId=83ee4b6c_c691_41ae_b2e8_6d2f6860f527, userDn=cn=s-1-5-21-3931225680-1871015619-2963001510-2180139,cn=foreignsecurityprincipals,dc=vdi,dc=vmware,dc=int
2023-09-25T08:46:33.735-06:00 INFO (11DC-1330) <4912> [wsnm_desktop] Delay JMS ENDED notification until fully logged out for sessionId=4 (timeout = 1800 seconds)
2023-09-25T08:46:34.745-06:00 INFO (11DC-1218) <TimerService> [wsnm_desktop] Session ENDED: sessionId=4 (delayed logoff)

debug:
2023-09-25T08:46:34.745-06:00 INFO (11DC-1218) <TimerService> [wsnm_desktop] Session ENDED: sessionId=4 (delayed logoff)
2023-09-25T08:46:34.745-06:00 DEBUG (11DC-1218) <TimerService> [wsnm_desktop] Publish SESSION ENDED
2023-09-25T08:46:34.746-06:00 DEBUG (66A0-3684) <Thread-3075> [ComponentResponse] Message is ENDED

 

but 98% don't disconnect and don't have that line about "delayed logoff". 

0 Kudos
CEDCHelp
Contributor
Contributor

@RTVNoord  did not work. still have a ton of stuck disconnected sessions not logging off. suggestions?

0 Kudos
RTVNoord
Enthusiast
Enthusiast

This is a bit of education for your users. They don't log out correctly and thats why you get all this disconnected sessions.
Horizon cannot do anything for you in this. The only thing you can do, is set the log off after disconnect time very short.
Instruct your users to log off in Windows correctly is the only way to avoid this

0 Kudos
OperationFUBAR
Contributor
Contributor

This is an old thread, but for those that stumble across it like I did looking for an answer (in my case this is Ubuntu VM's) please review the following KB from VMware:

 

https://kb.vmware.com/s/article/2151503 

0 Kudos
Virtual_Leo
Contributor
Contributor

I have acomplished this by using the "Idle Time Until Disconnect (VDI)" GP

In our scenario we want our users sessions to shutdown after 5 hours of inactivity, above GP is set to 30 minutes and then in the Desktop Pool in Horizon i set Log Off After Disconnect to 270 minutes

0 Kudos