| Win32_OperatingSystem | real LastBootUpTime (immune to Fast Startup) |
| quser enumeration | logs who was on before reboot |
| $SkipIfUserActive | optional defer if someone working |
| warning period | configurable 5-min warning for user |
Key insight: RMM agent can wake machine from sleep to run scheduled tasks. Combined with this script, machines that "never reboot" now reboot weekly - automatically, during off-hours, with no user action required.