Module to detect Windows OS pending reboots.
CHECK PENDING – When a table is Loaded with ENFORCE NO option, then the table is left in CHECK PENDING status. It means that the LOAD utility did not perform constraint checking. – The check pending status will appear when Referential Integrity(RI) violation between data in parent table with child table. Check the HKLM Software Microsoft Server manager registry key. What's the value of CurrentRebootAttempts? If this is greater than 0, that means something that Server Manager did requires a reboot. You should check the Server Manager console and ensure that there's nothing outstanding in there that would require a reboot. You can use it both for checking if a full reboot is required because of kernel or core libraries updates (using the -r option), or what services need to be restarted (using the -s option). Needs-restarting -r returns 0 if reboot is not needed, and 1 if it is, so it is perfect to use in a script.
Some of these (like httpd) check a file to decide whether to do the restart (allowing for you to disable the behavior if desired). That said, if an rpm doesn't auto-restart its daemon, you need to do it manually to take advantage of the updated binary. Processes spawned from other simple executables (like bash) will also need to be shutdown. Windows created a registry subkey RebootRequired under HKLMSOFTWAREMicrosoftWindowsCurrentVersionWindowsUpdateAuto Update to detect this pending state. So, for easy job, I wrote the little batch script (for windows XP & Server 2003) and powershell script (for Windows Vista & Server 2008 or later) to detect this key.
Minimum PowerShell version
3.0
Installation Options
Copy and Paste the following command to install this package using PowerShellGet More Info
You can deploy this package directly to Azure Automation. Note that deploying packages with dependencies will deploy all the dependencies to Azure Automation. Learn More
Manually download the .nupkg file to your system's default download location. Note that the file won't be unpacked, and won't include any dependencies. Learn More
Author(s)
Brian Wilhite
Copyright
(c) 2018 Brian Wilhite. All rights reserved.
Package Details
Owners
Tags
Functions
Dependencies
This module has no dependencies.
FileList
- PendingReboot.nuspec
Version History
Checking For Pending Restart Stuck Windows 10
Version | Downloads | Last updated |
---|---|---|
0.9.0.6 (current version) | 7,189,421 | 8/22/2018 |
0.9.0.0 | 56 | 8/21/2018 |