Jump to content

Welcome to MSFN Forum
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. This message will be removed once you have signed in.
Login to Account Create an Account


Photo

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

- - - - -

  • Please log in to reply
10 replies to this topic

#1
cumminbk

cumminbk

    Advanced Member

  • Member
  • PipPipPip
  • 412 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



How to remove advertisement from MSFN

#2
Bad Sector

Bad Sector

    Newbie

  • Member
  • 10 posts
  • OS:Windows 7 x64
  • Country: Country Flag
I deleted it manually, and I didn't encounter any problems afterwards...
so I think you can remove without any problem.

#3
CptMurphy

CptMurphy

    Just another techie

  • Member
  • PipPipPipPip
  • 534 posts
That folder is used if you ever want to uninstall the windows updates.
--- Signatures with a resolution greater then 300pix in width and 100pix in height will be removed ---
--- Please read the rules ---

#4
Shark007

Shark007

    Repackaging Specialist

  • Member
  • PipPipPipPipPipPipPipPipPip
  • 3,154 posts
A better option is to prevent its creation in the 1st place.
Using the proper switch during hotfix installation will stop it from being created.

use the switch /nobackup to prevent its creation.

shark

When posting about an issue in the codec thread,
please state what Operating System you use.


#5
cumminbk

cumminbk

    Advanced Member

  • Member
  • PipPipPip
  • 412 posts
@shark
yea when i do an unattended install i use /Q /O /N /Z on all my fixes yet i still have all my fixes showing up in this folder though.

#6
wesurveys

wesurveys
  • Member
  • 2 posts
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?

#7
hoak

hoak

    Member

  • Member
  • PipPip
  • 154 posts
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, 06 August 2009 - 10:22 AM.


#8
cluberti

cluberti

    Gustatus similis pullus

  • Supervisor
  • 11,252 posts
  • OS:Windows 8.1 x64
  • Country: Country Flag

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.
MCTS Windows Internals, MCITP Server 2008 EA, MCTS MDT/BDD, MCSE/MCSA Server 2003, Server 2012, Windows 8
--------------------
Please read the rules before posting!
Please consider donating to MSFN to keep it up and running!

#9
hoak

hoak

    Member

  • Member
  • PipPip
  • 154 posts
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?

:)

#10
cluberti

cluberti

    Gustatus similis pullus

  • Supervisor
  • 11,252 posts
  • OS:Windows 8.1 x64
  • Country: Country Flag

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.
MCTS Windows Internals, MCITP Server 2008 EA, MCTS MDT/BDD, MCSE/MCSA Server 2003, Server 2012, Windows 8
--------------------
Please read the rules before posting!
Please consider donating to MSFN to keep it up and running!

#11
Mr Snrub

Mr Snrub

    Former MSFT

  • Super Moderator
  • 775 posts
  • OS:Windows 8 x64
  • Country: Country Flag
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 ;)

My TechNet Blog
I have CDO. It's like OCD except the letters are in alphabetical order, as they should be.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users



How to remove advertisement from MSFN