Disable remote session timeout on Win Server 2012 R2

remote desktoptimeoutwindows-server-2012-r2

For botting purposes, I have to keep my Win Server 2012 R2 running without logging-off after I disconnect from Remote Session.

Found information about it here: http://technet.microsoft.com/en-us/library/cc754272.aspx but I just its for Win Server 2008 and doesn't seem to work on 2012 version.

Could you guys help me setting infinite timout?

EDIT: Tried this answer Changing the login timeout for Windows Remote Desktop Services but without results..

MORE DETAIL ABOUT WHAT I NEED: I connect to Amazon ECL Istance with "Remote Desktop Conection". I need to put remote server to keep running as if an user was normally remotely logged in, and prevent it from going to that log-out stand-by screen, usually blue coloured @ winserver2012, because i'm using macros that take screenshots of screen and find bitmap positions, do clicks, move mouse and stuff..

Best Answer

You need to configure the Computer Configuration's Remote Desktop Session Host policies:

  • launch the Global Policy Editor with typing gpedit.msc from the command-line and hit Enter.
  • In the left panel, navigate to Computer Configuration > Administrative Templates > Windows Components > Remote Desktop Services > Remote Desktop Session Host > Session Time Limits.
  • In the right panel, double-click the Set time limit for active but idle Remote Desktop Services sessions policy: in the modal window that will appear, activate it by switching the radio button from Not configured to Enabled, then set the desired amount of time in the drop-down list right below.

enter image description here

That's it: from now on, your remote users will also receive a pop-up warning 2 minutes before the session time expiration, so they'll have the chance to keep their session on (if they're still there): if they do nothing, they will be disconnected.

For additional info and other related policy settings, read here.