[SOLVED] Remote Desktop Host Sleeps After Only Five Minutes

Status
Not open for further replies.
Aug 21, 2020
3
0
10
I host a computer that is used by a few people in a small organization. We use Windows Remote Desktop (RDP) to access the computer - even me and the computer is in my basement. RDP works fine and everyone is able to get access to the computer and do their work.

Last fall I figured out how to use network enabled Wake on Lan to remotely wake up a sleeping computer. Once I had educated my users on how to use Wake on Lan, I enabled sleep mode on the computer and set it for 30 minutes. Keeping the computer sleeping when not in use has several advantages and I intend to continue to keep it set up this way.

There is a problem, however. Despite the computer's sleep setting being set to 30 minutes, when there is a remote desktop connection, the computer goes to sleep after only 5 minutes of idle time. This is distacting as you can't leave your remote work for more than a moment or sleep knocks your connection down and you have to log back into the remote connection. I know that it is sleep that is knocking down the connection because when you try to log in again, you cannot do so until you run the Wake on Lan application to wake the computer back up. Then it lets you sign right in again. (I've also just gone into the basement and looked at the thing - it's asleep!)

I've tried extending the sleep time and set the display timer to never. This does not change things. When using RDP, the computer sleeps after 5 minutes of idle time. If you work locally, sleep is normal and the machine sleeps after 30 minutes.

I cannot find any settings in Windows that would allow me set timers differently than from the standard power settings. Why is this happening?

- - - Updated - - -

I just found this link Microsoft Support and gave it a shot. Initially it seemed to work and I stayed connected over ten minutes. Subsequently, I was logged in and while doing other work twice timed out at five minutes. So, this fix, at least with just the change I made, is not a solution.
 
Solution
On the hosted computer look in Reliabity History and Event Viewer for any error codes, warnings, or even informational events that correspond with the computer either going to sleep after 5 minutes or failing to re-awake at times you know that it should have woken up.

Reliability History is much more user friendly and has a time line format that can prove helpful

Event Viewer is much more cumbersome and make take some time to navigate about to find anything useful.

You can, in both tools, right click any given entry for more information, The results are likely to be vague or simply too broad to be useful.

Next take a detailed look at the power plans:

To delve deeper (if you are comfortable doing so) consider Powershell and...

Ralston18

Titan
Moderator
On the hosted computer look in Reliabity History and Event Viewer for any error codes, warnings, or even informational events that correspond with the computer either going to sleep after 5 minutes or failing to re-awake at times you know that it should have woken up.

Reliability History is much more user friendly and has a time line format that can prove helpful

Event Viewer is much more cumbersome and make take some time to navigate about to find anything useful.

You can, in both tools, right click any given entry for more information, The results are likely to be vague or simply too broad to be useful.

Next take a detailed look at the power plans:

To delve deeper (if you are comfortable doing so) consider Powershell and powercfg.

For example in Powershell run

Get-CimInstance -classname Win32_PowerPlan -Namespace "root\cimv2\power"

[You should be able to copy and paste the Get directly into Powershell.)

Another command:

powercfg /query

Results are cryptic overall but you may recognize somethings that you expect and also other things you do not.

Reference link for more information:

https://www.thewindowsclub.com/most-useful-commands-for-powercfg-command-line

The immediate intention is to not use either Powershell or powercfg to change anything. Just discover what may be there and how it is configured.

Something with a 5 minute sleep or power saving setting.
 
Solution
Aug 21, 2020
3
0
10
Ralson18 - great input in your repsonse. I'm not real comfortable with Powershell, but powercfg I'm fairly familiar with. (Have use lastwake command frequently.) I found the sleep diagnostics file and have opened it. I don't fully understand it but expect I will have a sleep event while I post this message and I will refresh the page to see if any event times match the current time. I note that nine users are listed. Are these the Windows users? If so, how do I tell them by name? I think I have five users set in the machine.
 
Aug 21, 2020
3
0
10
I also found this link Group Policy Settings and changed some of the settings in Remote Desktop Services. These have not had any impact, I still disconnect and the computer goes to sleep after 5 minutes of idle time in the remote connection.

If fact, none of the settings in the group policy remote desktop connection session seem to make any difference, whether related to sleep or reconnecting or other options. Is it possible that this whole section is somehow corrupted or disabled? How would you check or reload the service?
 
Last edited:
Status
Not open for further replies.

TRENDING THREADS