Windows Server 2012 – Force Terminaluser to logoff

remote-desktop-servicesterminal-serverwindows-server-2012

We provide several Remote Desktop Services (RDS) and one of the connected user can't start any RDS anymore. How can I force logoff of that user?

What I already tried:

I tried logging in as domain admin on the Terminal Server the user is connected to and force the logoff of that user via GUI[1], which was unsuccessfull. My 2nd attempt was logging him off using the Console and the tsdiscon command which didn't work neither. I also tried doing logging him off using the LOGOFF [2] command and the PowerShell Commandlet Invoke-RDUserLogoff. None worked.

[1] With using the GUI I mean both a) using Server Manager > Remote Desktop Services > Collections > [MyCollection] > Connections Area > Right-click on affected user > Log off and b) Task Manager > Tab Users > Right-click on affected user > Sign off

[2] Force authenticated user immediate logoff (emergency case)

Best Answer

I'm not sure what you mean by "force the logoff of that user via GUI" so you might be referring to this, but I'll throw it out there anyway:

My GUI method is to open Task Manager on the server, go to the Users tab, then right click the user's session and choose Log Off.

If that fails to actually log off the session or their session isn't listed there, then you can try opening Computer Management on the server, go to Shared Folders, then Sessions. Sort by username, and then right click on each record for this user and clickClose Session`.

That should handle it. If it doesn't, then something is hung up/buggy that would require a reboot of the RDS server itself.