Hacker News new | ask | show | jobs
by dharmon 1680 days ago
This is great! Thanks!

I am forced to use a Windows machine sometimes for work, and to me the unpardonable sin is that Windows seems to randomly reboot _without asking me_! I come to my office and all my open sessions are gone. How do you turn this off?! I try turning off the setting but it randomly turns itself back on.

Also, how do people set up a reasonable dev environment not built around Visual Studio? On my Mac I just use Terminal + MacVim (with my plugins), so I don't have particularly demanding needs. I tried WSL, but its just Linux side-by-side with Windows, not integrated with windows. If that's what I wanted I would just use Linux, but I need a command-line where I can still build Windows apps. Currently I use bash-for-git (so I can run `cmake --build ...`) but its so non-standard in lots of ways that it drives me a little nutty.

6 comments

> I am forced to use a Windows machine sometimes for work, and to me the unpardonable sin is that Windows seems to randomly reboot _without asking me_! I come to my office and all my open sessions are gone. How do you turn this off?!

That's the neat part, you don't! Windows loves to revert those settings after every major update, even if you dig into the registry and scheduler and change the settings at the source. It is one of my biggest gripes.

One of the best things Apple added to macOS a while back was the reopen all windows on startup. I don't even think twice about rebooting my Mac any more. Windows could sorely use the equivalent.

One way I dramatically reduce the amount of random reboots is I have a thing that looks like a USB flash drive but it has a few switches on the side - one of them, when activated, randomly moves the mouse every 1-5 minutes (there is also a hardware wheel knob that lets you customize the duration). It was meant to be a practical joke thing - slip it onto the back of a friends PC and drive them nuts, but it works great at tricking Windows to think the computer is being actively used. It doesn't stop all reboots caused by Windows updates, but it dramatically reduces them.

I also use it to keep my work PC awake when attending online meetings, or especially when I'm presenting. We have mandatory screen saver timeouts and for some reason I can't convince the IT overlords to tweak group policy to allow non-admins the ability to enable presentation mode. Oh well. At least they haven't resorted to only allowing whitelisted USB devices to run so my little joke USB fob still does its thing. I got it from Think Geek in their heyday but there are tons of similar devices on Amazon.

Tell your browser to reopen the tabs it had when it exits. Try looking into these settings as well: https://www.windowsdigitals.com/windows-10-reopen-applicatio...
I moved from Linux to Windows for less hassle with hardware and sleep. I stopped using windows because of the reboot issue (and hassle with sleep...laptops kept waking and burning out in my bag). I went to ridiculous lengths to avoid it rebooting when I had a bunch of VMs running doing long-running computations and it just kept biting me. Sometimes the VM disk would get corrupted from this.

Eventually I realized it hated me and wanted me to fail in life, or perhaps click on all the crappy games or whatever it insisted on installing from time to time.

I don't love everything about macOS, but it's the least bad option and to my mind and for my needs, it's not even close.

The idea to regularly update "Active Hours", so that Windows can never update, implemented as a simple script https://github.com/marcosbozzani/Win10ActiveHours still works for me to this day.
I used the debugger method[0] to control Windows Update. It redirects the call to the reboot scheduler that is called by Windows Update.

This has worked flawlessly for almost two years and multiple Windows feature updates.

0: https://lazyadmin.nl/it/how-to-stop-automatic-restart-win-10...

> Windows seems to randomly reboot _without asking me_! I come to my office and all my open sessions are gone.

You’re not safe from reboots even if you’re actively using the machine: https://www.youtube.com/watch?v=ReHafyiDTR0

Reboots should be configurable via Windows Update settings if these aren't taken over by a group policy. Last time I've dealt with random reboots turned out to be a hardware issue (bluescreen->autoreboot).