Monday, 17 October 2016

Possible temporary solution for Windows 10 freezing after short idle

I actually cannot remember when this happened but my Windows 10 starts to freeze after I just left the computer for a very short time, probably less than 2 or 3 minutes.

Initially I thought it is my SSD where the windows is installed that has issue but sooner I noticed that as long as I keep using the computer then it does not freeze.

There are discussions, for example:

More reading reveals that this could only happen to users that are booting Windows from a SSD drive (still unsure) which is my case.

And a representative from Microsoft suggested the following:

To me they looks too complex and I like simple stuff so below is my temporary solution until Microsoft have a fix for it.

Copy the following code and save it in a batch file (e.g. anti-freeze.bat) on the booting SSD drive and when you think you are going to leave the computer for a while, just double click to bat file to preventing Windows from freezing.

@echo off

if "%1"=="done" goto start
start "" /min %0 done

echo Press Ctrl + C to quit...

cmd /c start notepad
timeout /T 5 /NOBREAK
taskkill /F /IM notepad.exe
timeout /T 5 /NOBREAK

goto start

What this does is it fires a windows command prompt, make itself minimized and then open/close notepad every 5 seconds. This works for me and I have left my PC on for the whole night and it is still alive.

Let me know if it works for you too! Have a nice day.