$hf_mig$ folder

i accidentally delete windows $hf_mig$ folder (hotfix uninstallers) with CCleaner and now i read that it is not safe to delete that folder? is that so? :o i have windows XP SP2.

i accidentally delete windows $hf_mig$ folder (hotfix uninstallers) with CCleaner and now i read that it is not safe to delete that folder? is that so? :o i have windows XP SP2.

Hi CeeCee,

Read these threads. They should answer any questions that you have. Post back if you do have more questions. Where did you read that it is not safe to delete that folder?

CCleaner Readme 1

CCleaner Readme 2

CCleaner Readme 3

:)

CeeCee is right. DO NOT DELETE the folder $hf_mig$ or anything in it. This is a serious mistake in CCleaner (which is otherwise an awesome program that I use, expect for the Hotfix Cleaner).

Here's the Microsoft page - http://support.microsoft.com/kb/824994

and the relevant excerpt -

----------

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.

----------

By deleting anything in this folder, you can be installing older versions of files if they happen to be packaged with a certain hotfix, possibly un-fixing a bug or security vulnerability.

However, it is safe to delete any folders starting with

%windir%\$xpsp1hfm$\ (only if you have XP SP2 installed)

%windir%\$NtUninstallQ...$\

%windir%\$NtUninstallKB...$\

There are the true "Backups" for the hotifxes.

Here is a safe way to delete Hotfix Backups in the meantime - http://winhlp.com/WxServicePackUninstallUninstall.htm

Sorry if I sound urgent here, but this can be a serious bug and "break" future hotfix installations.

This is a serious mistake in CCleaner (which is otherwise an awesome program that I use, expect for the Hotfix Cleaner).

CCleaner cleans the hotfix "uninstallers". If you don't want to uninstall your hotfixes then you don't need the uninstallers.

That's my point. The files in the $hf_mig$ folder are not the uninstallers. Windows uses them for more than that - as a file version comparison when installing newly released hotfixes. The uninstall files are in the %windir%\$NTUninstall* folders.

Read my whole post, the explanation is in there as well as the Microsoft link.

Deleting files out of the $hf_mig$ folder will break future (future being the operative word here) hotfix installations.

I'm not trying to give you a hard time, please understand. I really like this program.

I'm just trying to save people from problems in the future, as this is not the correct way to go about removing hotfix uninstallers.

CCleaner cleans the hotfix "uninstallers". If you don't want to uninstall your hotfixes then you don't need the uninstallers.

Not wise to remove the uninstallers. Unless you absolutely need to which I don't think anyone can go to that stage.

There is a possibility you may break any future packs that will come available.

"If the version installed is from the branch with fewer cumulative changes (in this example, it would be the GDR branch), the package installer caches the more cumulative versions (in this example, the QFE version) in %WINDIR%\$hf_mig$\KB######\. If a hotfix for one of those files is installed later, the package installer will ?migrate? the previously updated files to the QFE versions in order to maintain consistency.

In addition, versions for a higher service pack level (if such versions exist) are also cached so that the software updates can be reapplied when the computer is updated to the next service pack. After the service pack installation, the package installer checks the cache directory at %WINDIR%\$hf_mig$\KB######\ to determine whether there are any software updates to be migrated to the new service pack level. If there are, the package installer installs these software updates from the cache. This method does not use the Xpsp1hfm.exe file that is used in dual-mode packages described previously. Instead, this functionality is built into the package installer itself." (MS Corp)

My understanding is that "%WINDIR%\$hf_mig$\KB######" is the cache folder, not a hotfix uninstaller. CCleaner should not touch this folder.

As for removing the uninstallers...sometimes hotfixes will mess up your computer, and you do need to uninstall them. It is a good idea to test your hotfixes before removing the uninstaller. I'm not clear why removing the uninstaller would break future updates. Microsoft tells you how to remove uninstallers safely.

This is very interesting. Any feedback is appreciated. :)

Some interesting points...

I'll have a look into the $hf_mig$ folder specs.

:)

Some interesting points...

I'll have a look into the $hf_mig$ folder specs.

:)

I was just getting ready to PM you. :)

Can you please post the Uninstaller folders that CCleaner cleans? CCleaner should not touch the $hf_mig$ folder.

Read Me

Read Me

Read Me

Thank you,

K

Some interesting points...

I'll have a look into the $hf_mig$ folder specs.

:)

Does the CCleaner option "Hotfix Uninstallers" clean the $hf_mig$ folder?

I suppose I should have mentioned it in the first post, but when I hit the Analyze button to see what CCleaner will delete, it lists all the KB###### folders inside my $hf_mig$ folder. As we mentioned, it should not touch these.

I noticed this in particular because I have already removed the %windir%\$NTUninstall* folders from my computer (the uninstall folders).

As far as removing the uninstallers (%windir%\$NTUninstall* folders) breaking future updates as GreenWhite mentions, this is not the case.

These folders as safe to delete, as MS says also. It is the $hf_mig$ folder that is in question.

I suppose I should have mentioned it in the first post, but when I hit the Analyze button to see what CCleaner will delete, it lists all the KB###### folders inside my $hf_mig$ folder. As we mentioned, it should not touch these.

I noticed this in particular because I have already removed the %windir%\$NTUninstall* folders from my computer (the uninstall folders).

As far as removing the uninstallers (%windir%\$NTUninstall* folders) breaking future updates as GreenWhite mentions, this is not the case.

These folders as safe to delete, as MS says also. It is the $hf_mig$ folder that is in question.

Nice catch! I just ran a search on my computer, and I don't have the $hf_mig$ folder - hmmmm.

@MrG: Get back to us soon please. ;)

What OS are you running? The $hf_mig$ folder is specific to WinXP SP2 and Windows Server 2003.

Previous to SP2 the folder is called %windir%\$xpsp1hfm$\ I believe.

It is the $hf_mig$ folder that is in question.

Yes, most definitely. Especially since the $hf_mig$ folder isn't an uninstaller, but the cache folder.

"...the package installer installs these software updates from the cache."

"As far as removing the uninstallers (%windir%\$NTUninstall* folders) breaking future updates as GreenWhite mentions, this is not the case."

Yes indeed. I made a mistake.

What OS are you running? The $hf_mig$ folder is specific to WinXP SP2 and Windows Server 2003.

Previous to SP2 the folder is called %windir%\$xpsp1hfm$\ I believe.

I'm running WinXP Pro SP2. That folder isn't anywhere on my computer. I'm going to fix that later on today.

Thanks to everyone in this thread for the heads-up about the $hf_mig$ folder! Like at least two or three have mentioned, I found this folder missing, but luckily had a backup dating from before the most recent update of CCleaner and could recover it as of early February. Only the most recent set of patches is missing.

I found this folder missing, but luckily had a backup dating from before the most recent update of CCleaner and could recover it as of early February.

Thanks for that info. I was wondering what type of crap I was going to have to go through to restore that folder, until I read your post and remembered that I too have a backup that I saved using Microsoft Backup.

Thanks to everyone in this thread for the heads-up about the $hf_mig$ folder! Like at least two or three have mentioned, I found this folder missing, but luckily had a backup dating from before the most recent update of CCleaner and could recover it as of early February. Only the most recent set of patches is missing.

You can easily reinstall these missing patches manually, then your $hf_mig$ folder will contain all.

A good reminder how important backups are!

You can easily reinstall these missing patches manually, then your $hf_mig$ folder will contain all.

A good reminder how important backups are!

I wouldn't say easily; downloading 50 or so patches and a 200+ MB Service Pack and installing all of them is at least a 4 hour process for most users, maybe more.

Lets just hope this problem gets resolved quickly!

Some people intentionally remove that folder. (From another forum)

"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." (Franklin)

"If I remember correctly $hf_mig$ folder is recreated when any new hotfixes are installed." (Franklin)

"As I understand it, if you install an update, then later install another update that contains an earlier version of a file that's in the previous update, then you need it to migrate the later version of the file instead of installing the earlier version. Why this would ever come up I don't know, but it's Windows, it doesn't have to make sense." (Greenknight)

I don't know how to confirm whether or not that folder gets re-installed with a hotfix. If someone knows how to confirm this, please hit us up.

I'm also interested in whether or not the cache can be rebuilt if the folder does get re-created.

I would like to add one more thing. :P

Even though this folder may not be as serious as we think, it's still not a hotfix uninstaller folder. Therefore, it shouldn't be cleaned by the hotfix uninstaller option.