Ever have issues because of a pending reboot?

I’ve ran into this problem myself many times in the past, and usually rebooting the Windows device will correct the problem.  But turns out I recently ran into this where, after multiple reboots, I kept getting a message about a pending restart was needed.  So upon further investigation, I found a very useful tip that will help you out in any of these situations, without rebooting.

NOTE:  There are other reasons as well that your device may need restarted before installing a program or whatever.  This post is referring specifically to Pending File Renames.

First, you want to confirm that your particular issue has to do with Pending File Renames.  You can do this in 2 ways:

  • Run the following from a command line: reg query “\\machinename\hklm\System\CurrentControlSet\Control\Session Manager” /v PendingFileRenameOperations.  You will receive either an ERROR message, which means you do not have any pending file renames, or you will receive a list of the pending renames.
  • Open regedit, and navigate to HKLM\System\CurrentControlSet\Control\Session Manager, and look for the key PendingFileRenameOperations.  If it does not exist, then you have no pending operations.  Otherwise, note the items listed.

DISCLAIMER:  Never make any changes to the registry without backing up.  If you don’t know how to backup the registry, you need to stop reading and move along (these aren’t the droids you are looking for).

Once you have your list of items, you need to review these and determine what program they are in reference too.  You will need to make a judgment call, based on the program affected, if you need to proceed or not.  Bear in mind, that what you do following this could cause severe problems with your machine and/or the program affected.  These operations could be actual file renames, or they could be deletions due to an uninstall.

Now that you have made your decision, you can perform the operations yourself if you feel comfortable doing so, then remove the entire PendingFileRenameOperations key.  Again, make sure you have a backup of the entire Session Manager branch that you can restore if need be.  Once you remove the PendingFileRenameOperations key, you should be able to perform your original task without getting a message.

Another alternative is to backup the PendingFileRenameOperations key, perform your task, then restore the key.  If you try this, you will want to make sure that the pending operations do not have anything to do with your original task.  Also, the task that you are performing could write additional data to the PendingFileRenameOperations, which you would need to merge with the items you backed up.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s