Jump to content

[Question] - $hf_mig$ folders - remove them?


cumminbk

Recommended Posts

should $hf_mig$ folders be removed? i have heard some people say yes others say no. If a user does not plan on reinstalling, repair installing, or uninstalling any hotfixes or service packs can this folder be safely removed. I see CCleaner now has an option to remove this folder.

your thoughts?

Title Edited - Please follow the forum rules from now on

-- Martin L

Link to comment
Share on other sites


  • 3 years later...

I have an oldish laptop running with XP Professional with only 2GB of memory which is virtually full (only ~350MB of space left). The PC is now becoming very sluggish so I am therefore trying to free up some space. I note that there are ~350MB of update files in the C:\WINDOWS\$hf_mig$ directory. I have looked at the comments debating the issue of whether or not it is OK to remove the contents of the $hf_mig$ folder but they seem to date back to 2005 and there does not seem to be a concensus one way or the other. Have there been any further developments since that time?

Link to comment
Share on other sites

  • 1 month later...

I'd be interested in a definitive answer -- I've read somwhere that this directory and it's subdirectories is used to resolve 'updates of updates' i.e. prevents older versions of files from replacing newer versions:

When a security update, critical update, update, update rollup, driver, or feature pack installs GDR version files, the hotfix files are also copied to the %windir%\$hf_mig$ folder. This supports migration to the appropriate files if you later install a hotfix or service pack that includes earlier versions of these files. For example, consider the following scenario:

1. You apply a security update that installs a GDR version of File.dll with a version number of 5.2.3790.1000 and copies a hotfix version of File.dll with a version number of 5.2.3790.1000 to the %windir%\$hf_mig$ folder.

2. You apply a hotfix that includes a hotfix version of File.dll with a version number of 5.2.3790.0000.

In this scenario the hotfix installation in step 2 installs the hotfix version of File.dll (version number 5.2.3790.1000) from the %windir%\$hf_mig$ folder instead of the hotfix version of File.dll (version number 5.2.3790.0000) from the hotfix package.

...but can't find an authoritative source...

:unsure:

Edited by hoak
Link to comment
Share on other sites

I'd be interested in a definitive answer -- I've read somwhere that this directory and it's subdirectories is used to resolve 'updates of updates', but can't find an authoritative source...

:unsure:

It's not documented publicly, but indeed the $hf_mig$ folder is used for uninstall of updates, and there *may* be an update out there that uses the folder to determine which binary to install, but that is not what the folder is for, and I've never personally come across one that uses the folder for anything more than uninstallation file backup. With the advent of using update.exe for XP+ updates or the servicing engine .msu's for Vista+, this should not really even be possible anymore as the update itself contains it's branching and versioning information, so unless you're running NT4 or 2000 this should be 100% safe to delete. Also, any time you install a service pack and you choose to clean up the uninstall files (Vista/Win7) or chose to install it with the switch to not save backup files (XP/2003/previous), you can safely remove the $hf_mig$ folder after installing the service pack successfully, as you can never use those files for hotfix uninstall of anything prior to the SP anyway.

If you're paranoid you can always move it's contents to another location, but the only thing I would suggest is to make sure you never delete that folder itself, only it's contents. You should be very safe in doing so.

Link to comment
Share on other sites

Thank you so much cluberti; that sounds as authoratative an answer as we'll ever get! I'm curious though, why you'd suggest /$hf_mig$ might be harmful as virtually ever Microsoft tool, applet, installer I've used recreates any essential directories?

:)

Link to comment
Share on other sites

Thank you so much cluberti; that sounds as authoratative an answer as we'll ever get! I'm curious though, why you'd suggest /$hf_mig$ might be harmful as virtually ever Microsoft tool, applet, installer I've used recreates any essential directories?

:)

It's more of a "just in case" rather than anything else, nothing more. Again, I've never personally seen any issues with it, but it's a "just in case" so that you don't run the risk of problems later. You're free to do what you want with your system, but I'd recommend leaving it as there's no harm in doing so, and there's at least that .001% chance of problems if you do remove it.

Link to comment
Share on other sites

I agree with cluberti that removing the folder (immediately) after the installation of a service pack is safe - however it contains the various branches of the hotfixes that may need migrating as part of the service pack installation, so shouldn't be deleted beforehand.

The absence of the folder might not block a service pack being installed, but it would mean that you run the risk of regressing some dual mode hotfixes (i.e. applicable for your current SP level and the one you are service packing up to).

We also had a few cases recently where a customer had deleted that folder and it was preventing a COM+ hotfix installation on W2K3 due to a previous QFE version from another hotfix package being missing from $hg_mig$.

All in all a low risk, but so is the disk space gained by deleting it ;)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...