Using MsiInv to gather information about what is installed on a computer


As I was reading one of the posts on Quan To’s new blog, I noticed that someone posted a link to a tool named msiinv.exe on their tools page.  This tool (which stands for MSI Inventory) wraps some of the publicly documented MSI APIs to provide information about the state of all Windows Installer products, features and components that Windows Installer thinks are installed on your computer.  I say “thinks are installed” because there are some rare cases where the actual installation state of a given product can get out of sync with the information Windows Installer has stored in its internal data structures, which can cause confusion for setup packages.

I use this tool nearly every day as one of the first troubleshooting tools for setup problems because it allows me to get a baseline snapshot of what the current state is for a machine before I start trying to make changes to fix any problems a customer might be having.

Example usage of msiinv.exe

One of the common uses of msiinv.exe is if someone is trying to install one of the recent beta builds of VS 2005 or .NET Framework 2.0 and the setup UI states that you are not allowed to install because a previous beta version of <insert product name here> is on the machine and you must uninstall that first.  Sometimes after receiving this error message, a user will look in Add/Remove Programs and the product that setup is complaining about is nowhere to be found, or there is an Add/Remove Programs entry for that product but trying to remove it claims that the product is not on the computer and asks if you would like to remove the entry from the Add/Remove Programs list.

In these cases, you can use the following steps:

  1. Download msiinv.zip from the following location:

  2. Extract the contents of msiinv.zip to the folder c:\msiinv on your system
  3. Click on the Start menu, choose Run, type cmd and click OK
  4. Type this command:  c:\msiinv\msiinv.exe -p > c:\msiinv\msiinv_output.txt

    Note: This command must be run from a cmd prompt or it will not create a log file as expected.

These steps will create a text file named c:\msiinv\msiinv_output.txt with a list of each product that Windows Installer thinks is installed on the system.  Then you can open the text file in any text editor and search the list of products for the name of the product that setup told you to uninstall.  The output will look something like this (I am using an example from a machine that has .NET Framework 2.0 beta 2 installed):

Microsoft .NET Framework 2.0 Beta 2
 Product code: {7A1ADD0C-17F3-47B8-B033-A06E189C835D}
 Product state: (5) Installed.
 Package code: {856D48D2-6F94-466D-9732-534DB5854FB3}
 Version: 2.0.50215
<note: there is more info after this but I am omitting it because it isn’t useful to the rest of my example>

Now we have the Windows Installer product code and we can use that to uninstall the product by running msiexec /x <product code> (make sure that you include the curly braces in this command line).  If the product is actually installed on your system you will see a progress screen and uninstall will complete, and from there you should be able to re-run VS or .NET Framework setup and successfully install.

If Windows Installer thinks that the product is installed but it really isn’t, then running msiexec /x <product code> will give you an error stating that this command is only valid for installed products.  If this happens, you will need to perform an extra step to remove the data that causes Windows Installer to think this product is installed.  You can download the Windows Installer Cleanup Utility and install and run it on your machine to fix this.  In the list of applications that this tool displays, choose the one that matches the product name displayed when you first ran VS or .NET Framework setup and choose to remove it.  After this removal completes, you should be able to re-run VS or .NET Framework setup and successfully install.

Advanced usage of msiinv.exe

The msiinv.exe tool has several command line parameters that you can see by running it with the /? switch.  A couple of the more interesting options are the following:

  • msiinv.exe -v – This option will list all feature GUIDs and component GUIDs for each Windows Installer product that is installed on the machine.  This can be useful to see which products share components (which can help track down why running uninstall for one product leaves behind some files and/or registry).  If you have a lot of products installed on the machine, running with the verbose switch will take a long time.
  • msiinv.exe -x – This option will list Windows Installer components that are installed on the machine that do not have any products that hold reference counts on them anymore.  In most cases, this is caused by one or more setup being installed on the machine at some point in the past that violated the MSI component rules. (more info about component rules can be found here and here if you are interested)

<update date=”12/1/2008″> Updated the link to msiinv.zip because the old location was no longer available. </update>

<update date=”2/12/2009″> Updated command line for running msiinv.exe so it will work on Windows Vista and Windows Server 2008. </update>

<update date=”4/1/2009″> Removed broken link to msiinv.exe tool </update>

<update date=”10/11/2012″> Embedded new SkyDrive link to msiinv.exe tool </update>

 

Comments (80)

  1. balajik says:

    Hi Aaron, I am having trouble creating the users in the active directory that are required for the installation of Team Foundation Server! Can you please provide me with the step-by-step guide for installing Team Foundation Server! Thanks.

  2. Ian Thomas says:

    I notice the filedate on MSIInv.EXE is 2001.

    Does it inspect properties of the MSI database / installer that are current in the Windows Installer v3.1 ?

  3. astebner says:

    Hi Balajik – there is a lot of good information about Visual Studio Team System at http://lab.msdn.microsoft.com/teamsystem/. For example, I found this download location for a Team Foundation Server installation guide that might be useful to you – http://www.microsoft.com/downloads/details.aspx?FamilyId=E54BF6FF-026B-43A4-ADE4-A690388F310E&displaylang=en.

    Hope this helps!

  4. astebner says:

    Hi Ian – yes, even though the file has not been updated for a while, it still works with MSI databases that are using the Windows Installer 3.0/3.1 schemas because it uses public APIs to access the behind-the-scenes data, and those APIs are designed to be backwards compatible.

    Please let me know if you see any issues where it is not behaving as expected.

  5. balajik says:

    Hi Aaron – I already read the installation guide before posting here. I followed the steps in that guide. Like i said, i am having problems adding the Active Directory Domain user accounts needed for the installation. This installation is not as easy as VS 2005 or SQL 2005 or any other i’ve done before!

    Thanks for your help!

    Balaji K.

  6. astebner says:

    Hi Balaji,

    I’m sorry to say I don’t have any experience with the user account issue you’re running into. I would suggest looking around at issues on the Team System MSDN forums at http://forums.microsoft.com/msdn/default.aspx?ForumGroupID=5 and starting a new thread if you don’t see anything related to your problem already posted there. You can also use http://lab.msdn.microsoft.com/productfeedback/ to report bugs that you find while trying to install beta versions of the VS 2005 Team System.

    One thing to note here – the setup is definitely more complicated, because it includes configuring VS and SQL plus some other server-side components. Any feedback you have on streamlining and improving the process is definitely welcome!

  7. balajik says:

    Hi Aaron, Even i don’t have any experience with the ‘Domain Controller’ server role in Windows 2003 and these domain user accounts. As a result, i’m lost. Ok, I’ll try the MSDN forums and let you know if i was successful.

    Thanks again!

  8. I have heard from a few customers (inside and outside of Microsoft) who have had problems uninstalling…

  9. Gaurang says:

    Hi,

    I am trying to install sql server 2005 September 2005 ctp, but it is hanging at "Detecting Installed ISS". Can you please help regarding the same.

    I had VS.2005 beta 2 installed, but i though that might be because of this, and have uninstalled everything and trying to install sql server 2005, but no success. can you please help.

    my OS is : XP Prof. SP2

    Nortan Antivirus is installed.

    Thanks

    Gaurang

  10. astebner says:

    Hi Gaurang – can you please gather the SQL setup log files and send them to me at aaronste@microsoft.com so I can take a look and see if I can figure out what the problem is here? You can find the logs at %ProgramFiles%Microsoft SQL Server90Setup BootStrapLOGFiles*.*

  11. Timothy says:

    That method using "msiinv.exe" to locate installed products looks fantastic. That is the most useful tool I’ve seen for all these previous version Beta headaches. Printing the installed contents to a text file is a great obvious idea.

    I have personally used "msicuu.exe" to similar effect. It also has command switches found by using the "msicuu /?" syntax. Download: http://www.microsoft.com/downloads/details.aspx?FamilyID=49ae8576-9bb9-4126-9761-ba8011fabf38&displaylang=en&Hash=QQQCR9C

  12. Keni Pilf says:

    Thank you so much for you help. I was considering much more drastic action to get my true MSDN versions of SQL and VS installing.

  13. Syed Irtaza Ali says:

    I tried using msiexec /x {90032DD0-ABEE-4424-AC1E-B076BDD4E350}.

    But it just runs the remove process and the following text appears…"Please wait while Windows configures Microsoft SQL Server 2005 Beta 2". After that nothing happens and the window closes. When I run the msiinv.exe again, the product is still listed as installed.

    How do I remove this product? Awaiting your response.

  14. メモ: Visual Studio 2005 Express/SQL Server 2005 Express などのプレビュー版アンインストール手順

  15. Eyal Peleg says:

    The combination of msiinv.exe and msiexec /x did the trick for me (or at least so it seems).

    Thanks,

    Eyal

  16. Zoltan Kasnya says:

    WOW… Finally I’d been fighting this for 3 months now. Thanx… I was ready to grab a 20 pound magnet:) Works fine now

  17. James says:

    I cannot, for the life of me, get this exe to output anything. I see all the info while it’s running, and can pause it and look through the information, but it won’t output anything to a text file. I’ve tried running it through the command prompt and just plain opening it. I’ve put it in several different directories as well. It took about 4 run throughs just to create the output.txt file in the C: directory, but it is empty no matter how many times I run the program now. I’d really like to not have to pause the program, search through the listings, find what I’m looking for, and write down the product code with my hand on the mouse to have to do this… what’s the matter with me?

  18. astebner says:

    Hi James – You have to use the greater than sign ( > ) to redirect the output from the console window to a text file.  The following steps should allow you to do this:

    1.  Click on the Start menu, choose Run and type cmd

    2.  Type msiinv.exe > c:output_file.txt

    These steps should cause no text to be printed in the cmd window, but instead it should appear in the text file.  Hope this helps….

  19. Mike says:

    Duuuuuuude! You are the man…I am 3 hair-strands away from being bald trying to get the install to work. Thank you.

  20. Ormond says:

    Installing Visual Studio 2005 tells me that I need to uninstall SQL Server 2005 Express Edition (plus others) but msiinv doesn’t find it, and nor does the cleanup. (Yes, I had the beta installed and started an uninstall before cracking the shrink wrap on VS2005 and did it in the wrong order).

    How do I find these in order to uninstall?

  21. astebner says:

    Hi Ormond – If Visual Studio 2005 setup tells you that there is a beta version still installed, then you will need to take a look at the list of products at http://msdn.microsoft.com/vstudio/support/uninstall/default.aspx and compare the product names that need to be removed to the ones listed in your MsiInv output.  One or more of them will match, and those are the ones you need to remove.

  22. Ormond says:

    Thanks Aaron.  msiinv twice gives "Unexpected error: 1605 ()" but gives the output. MSDN Library for Visual Studio 2005 Beta 2 was first on the web site list and was there so I tried uninstalling that using Add/Remove Programs. This gives a "Fatal error during installation" and doesn’t remove it.

    msiexec /x with the product code and logging into a file also doesn’t remove it.

    Will a full reinstall of the beta and then a correct uninstall fix this?

  23. astebner says:

    Hi Ormond – You will likely need to use steps like the ones listed at http://blogs.msdn.com/astebner/archive/2005/11/03/488936.aspx in order to resolve this MSDN uninstall issue.  Can you try that out and see if it helps?

  24. Ormond says:

    Thank you – huge relief.  The smartmsizap finally did it.

  25. Gary Lutchansky says:

    I’m trying to remove the phantom Microsoft Visual Studio 2005 Team Suite. After running the VS 2005 troubleshooting tool, I get the following message:

    Error 1316. A network error occurred while attempting to read from the file: C:WINDOWSInstallvs_setup.msi.

    It probably fails because that file does not exist.

    I get the same error message using the msiexec /x <product code> method.

    Running the Windows Installer Cleanup Utility mentioned above (msicuu2.exe) prompts me with a few ‘Next >’s then tells me that the features I selected are currently being uninstalled … but it never gave me the opportunity to see or select. Maybe it did something useful. I move to the next step.

    Trying to install VC# Express brings me back to the original problem — I need to uninstall Team Suite.

    Any suggestions? Thanks!

  26. astebner says:

    Hi Gary – Can you please try the steps listed at http://blogs.msdn.com/astebner/archive/2005/10/30/487096.aspx to locate and manually remove Visual Studio Team Suite and see if that helps resolve this issue?

  27. Gary Lutchansky says:

    Bingo! The smartmsizap tool removed the lingering info! Thanks very much.

  28. The-Eagle says:

    I have the same problem as Syed Irtaza Ali

    I tried using msiexec /x {90032DD0-ABEE-4424-AC1E-B076BDD4E350}.

    But it just runs the remove process and the following text appears…"Please wait while Windows configures Microsoft SQL Server 2005 Beta 2". After that nothing happens and the window closes. When I run the msiinv.exe again, the product is still listed as installed.

    Please help I couldnt remove these Betas for many hours.

  29. astebner says:

    Hi The-Eagle – You will likely need to use some manual uninstall steps like the ones described at http://blogs.msdn.com/astebner/archive/2005/09/13/465401.aspx to try to resolve this.  Hope this helps!

  30. imranmp says:

    for some reason I cannot get it to produce a text file, i have tried c:msiinvmsiinv.exe -p> c:msiinv_output.txt; this pops up the cmd window for just a sec but no text file. also tried c:msiinvmsiinv.exe > c:msiinv_output.txt; which brings the cmd window and i can see all the output but it still doesnt produce a text file.

    thanks for your help.

  31. astebner says:

    Hi Imranmp – You need to make sure to follow the steps exactly as they are listed above in this blog post.  Specifically, you need to open a cmd prompt by clicking on the Start menu, choosing Run, typing cmd and clicking OK.  After the cmd prompt opens, you can run the c:msiinvmsiinv.exe -p > c:msiinv_output.txt command line and it should correctly create the output file.

    This command line will not work if you try to launch it directly from the Windows Start menu Run prompt.

  32. Si certains d’entre vous ont installé la beta du SP1 sur leur Team Foundation Server, vous aurez certainement

  33. rmg1 says:

    Hi all

    I’m trying to install the above program bit the installer says I have the following programs installed that I need to remove :-

    Microsoft SQL Server 2005 Express Edition

    Microsoft SQL Server 2005 Tools Express Edition

    Microsoft SQL Server Native Client

    I’ve run the Microsoft uninstaller to no effect and the msiinv pack above gives me the following :

    c:msiinvmsiinv.exe  2007419  17:46:36

    Windows Installer Clean Up

    Product code: {121634B0-2F4B-11D3-ADA3-00C04F52DD52}

    Product state: (5) Installed.

    Package code: {999BF813-45E5-11D3-ADB1-00C04F52DD52}

    Version: 3.00.00.0000

    AssignmentType: 0

    Publisher: Microsoft Corporation

    Language: 1033

    Installed from: C:Program FilesMSECACHEWICU3

       Package: msicuu.msi

    Local package: C:WINDOWSInstaller14de9a.msi

    Install date: 2007419

    0 patch packages.

    Windows XP Creativity Fun Packs – Windows Movie Maker 2

    Product code: {DA2D4D11-1811-4A24-B719-BF9F048C6106}

    Product state: (5) Installed.

    Package code: {67444CB4-541C-4088-B3DB-288E429073AF}

    Version: 1.00.0000

    AssignmentType: 0

    Publisher: Microsoft Corporation

    Language: 1033

       Package: Windows XP Creativity Fun Packs – Windows Movie Maker 2.msi

    About link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Help link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Help telephone: None

    Update link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Local package: C:WINDOWSInstaller2c8551.msi

    Install date: 2006622

    0 patch packages.

    Microsoft XML Parser

    Product code: {C7340571-7773-4A8C-9EBC-4E4243B38C76}

    Product state: (5) Installed.

    Package code: {5F0CFBF2-C96E-48D7-AFFE-ED254E7B455E}

    Version: 8.0.7820.0

    AssignmentType: 0

    Publisher: Microsoft Corporation

    Language: 0

       Package: msxml3.msi

    Local package: C:WINDOWSInstallercafb07.msi

    Install date: 200733

    0 patch packages.

    Macromedia Flash Player 8 Plugin

    Product code: {91057632-CA70-413C-B628-2D3CDBBB906B}

    Product state: (5) Installed.

    Package code: {1EEA9E65-83F2-4D21-8756-78D2F00C80C3}

    Version: 8.0.22.0

    AssignmentType: 0

    Publisher: Macromedia

    Language: 1033

    Suggested installation location: C:WINDOWSsystem32MacromedFlash

       Package: Install Flash Player 8 Plugin.msi

    Product Icon: %APPDATA%MicrosoftInstaller{91057632-CA70-413C-B628-2D3CDBBB906B}ARPPRODUCTICON.exe

    About link: http://www.macromedia.com

    Help link: http://www.macromedia.com/go/flashplayer_support/

    Local package: C:WINDOWSInstaller6a1e36.msi

    Install date: 2007123

    0 patch packages.

    Text-To-Speech-Runtime

    Product code: {7B3F0113-E63C-4D6D-AF19-111A3165CCA2}

    Product state: (5) Installed.

    Package code: {7B3F0113-E63C-4D6D-AF19-111A3165CCA2}

    Version: 1.0.0.0

    AssignmentType: 0

    Publisher: Magix Development GmbH

    Language: 0

       Package: ttsruntime.msi

    Local package: C:WINDOWSInstallercafb0d.msi

    Install date: 200733

    0 patch packages.

    Windows XP Creativity Fun Packs – Windows Movie Maker 2 – Audio

    Product code: {A6264FF6-C49D-4533-AF42-4875C38BB24C}

    Product state: (5) Installed.

    Package code: {85510E9B-3063-44CE-B24C-57485D437961}

    Version: 1.00.0000

    AssignmentType: 0

    Publisher: Microsoft Corporation

    Language: 1033

       Package: Windows XP Creativity Fun Packs – Windows Movie Maker 2 – Audio.msi

    About link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Help link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Help telephone: None

    Update link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Local package: C:WINDOWSInstaller2c84f7.msi

    Install date: 2006622

    0 patch packages.

    Windows XP Creativity Fun Packs – Windows Movie Maker 2 – Titles

    Product code: {3C26E039-BE18-4B5E-A723-45390C451819}

    Product state: (5) Installed.

    Package code: {F70ADEF8-8766-4008-85B1-8A2DC45108CD}

    Version: 1.00.0000

    AssignmentType: 0

    Publisher: Microsoft Corporation

    Language: 1033

       Package: Windows XP Creativity Fun Packs – Windows Movie Maker 2 – Titles.msi

    About link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Help link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Help telephone: None

    Update link: http://www.microsoft.com/windowsxp/experiences”>http://www.microsoft.com/windowsxp/experiences

    Local package: C:WINDOWSInstaller2c84f1.msi

    Install date: 2006622

    0 patch packages.

    Macromedia Flash Player 8

    Product code: {885A63EA-382B-4DD4-A755-14809B8557D6}

    Product state: (5) Installed.

    Package code: {F370C477-B10C-4D4E-A02F-2AB6024E0276}

    Version: 8.0.22.0

    AssignmentType: 0

    Publisher: Macromedia

    Language: 1033

    Suggested installation location: C:WINDOWSsystem32MacromedFlash

       Package: Install Flash Player 8 ActiveX.msi

    Product Icon: %APPDATA%MicrosoftInstaller{885A63EA-382B-4DD4-A755-14809B8557D6}ARPPRODUCTICON.exe

    About link: http://www.macromedia.com

    Help link: http://www.macromedia.com/go/flashplayer_support/

    Local package: C:WINDOWSInstaller6a1e31.msi

    Install date: 2007123

    0 patch packages.

    Adobe Common File Installer

    Product code: {8EDBA74D-0686-4C99-BFDD-F894678E5B39}

    Product state: (5) Installed.

    Package code: {8D808886-2E0E-433B-B750-D6F4153E668C}

    Version: 1.00.0000

    AssignmentType: 0

    Publisher: Adobe System Incorporated

    Language: 1033

    Suggested installation location: C:Program FilesCommon FilesAdobe

    Installed from: D:Adobe(R) Photoshop(R) CS2commonfilesinstaller

       Package: Adobe Common File Installer.msi

    About link: http://www.adobe.com

    Help link: http://www.adobe.com/help

    Help telephone: 1-555-555-4505

    Update link: http://www.adobe.com/updateinfo

    Local package: C:WINDOWSInstaller1017181.msi

    Install date: 20061022

    0 patch packages.

    neroxml

    Product code: {56C049BE-79E9-4502-BEA7-9754A3E60F9B}

    Product state: (5) Installed.

    Package code: {F15D643C-F940-4705-8493-D38D853F6D60}

    Version: 1.0.0

    AssignmentType: 0

    Publisher: Nero AG

    Language: 1033

    Installed from: C:DOCUME~1RichardLOCALS~1TempNeroDemo12550Redist

       Package: neroxml.msi

    Local package: C:WINDOWSInstaller45f34.msi

    Install date: 2007415

    0 patch packages.

    Adobe Bridge 1.0

    Product code: {B74D4E10-6884-0000-0000-000000000103}

    Product state: (5) Installed.

    Package code: {7DB98FBC-5EF5-4C4F-86D7-A03016CD44EA}

    Version: 001.000.003

    AssignmentType: 1

    Publisher: Adobe Systems

    Language: 1033

    Suggested installation location: C:Program FilesAdobeAdobe Bridge

    Installed from: C:DOCUME~1RichardLOCALS~1Temp

       Package: adb37B.tmp

    About link: http://www.adobe.com

    Help link: http://www.adobe.com/support/main.html

    Update link: http://www.adobe.com/support/downloads/main.html

    Local package: C:WINDOWSInstaller123f72e.msi

    Install date: 20061022

    0 patch packages.

    ABBYY FineReader 5.0 Sprint

    Product code: {D1696920-9794-4BBC-8A30-7A88763DE5A2}

    Product state: (5) Installed.

    Package code: {E1FC6DEF-A60D-44E1-863D-34332DC9B2C8}

    Version: 5.0.482.3421

    AssignmentType: 1

    Publisher: ABBYY Software House

    Language: 0

    Installed from: D:OCR

       Package: ABBYY FineReader 5.0 Sprint.msi

    About link: http://www.abbyy.com

    Help link: http://www.abbyy.com/support

    Help telephone: +7 (095) 234 44 00

    Update link: http://www.abbyy.com/support

    Transforms: C:WINDOWSInstaller{D1696920-9794-4BBC-8A30-7A88763DE5A2}1033.mst

    Local package: C:WINDOWSInstallercc81.msi

    Install date: 2005512

    0 patch packages.

    WebFldrs XP

    Product code: {350C97B0-3D7C-4EE8-BAA9-00BCB3D54227}

    Product state: (5) Installed.

    Package code: {350C97B0-3D7C-4EE8-BAA9-00BCB3D54227}

    Version: 9.50.7523

    AssignmentType: 1

    Publisher: Microsoft Corporation

    Language: 1033

    Installed from: C:WINDOWSsystem32

       Package: webfldrs.msi

    Help link: http://www.microsoft.com/windows

    Local package: C:WINDOWSInstallere6e9.msi

    Install date: 2005210

    0 patch packages.

    Macromedia Flash 8 Video Encoder

    Product code: {8BF2C401-02CE-424D-BC26-6C4F9FB446B6}

    Product state: (5) Installed.

    Package code: {687E7C9A-C6F9-4DC6-9332-702D7663041A}

    Version: 1.00.0000

    AssignmentType: 1

    Publisher: Macromedia

    Language: 1033

    Suggested installation location: C:Program FilesMacromediaFlash 8 Video Encoder

       Package: Macromedia Flash 8 Video Encoder.msi

    Product Icon: C:WINDOWSInstaller{8BF2C401-02CE-424D-BC26-6C4F9FB446B6}ARPPRODUCTICONFLV1.exe

    About link: http://www.Macromedia.com

    Help link: http://www.macromedia.com/go/flash/support

    Update link: http://www.macromedia.com/go/updates

    Local package: C:WINDOWSInstaller6a1e2c.msi

    Install date: 2007123

    0 patch packages.

    MSXML 4.0 SP2 (KB925672)

    Product code: {A9CF9052-F4A0-475D-A00F-A8388C62DD63}

    Product state: (5) Installed.

    Package code: {36918A3F-FDBD-4385-9AA4-EC9DDCB78615}

    Version: 4.20.9839.0

    AssignmentType: 1

    Publisher: Microsoft Corporation

    Language: 1033

       Package: msxml.msi

    Help link: http://support.microsoft.com/kb/925672

    Local package: c:WINDOWSInstaller2b2c1.msi

    Install date: 200734

    0 patch packages.

    Adobe Photoshop CS2

    Product code: {236BB7C4-4419-42FD-0409-1E257A25E34D}

    Product state: (5) Installed.

    Package code: {8976594A-2348-4F03-AB8C-89240D232E8F}

    Version: 9.0

    AssignmentType: 1

    Publisher: Adobe Systems, Inc.

    Language: 1033

    Suggested installation location: C:Program FilesAdobeAdobe Photoshop CS2

    Installed from: D:Adobe(R) Photoshop(R) CS2

       Package: Adobe Photoshop CS2.msi

    About link: http://www.adobe.com/photoshop

    Help link: http://www.adobe.com/support/main.html

    Help telephone: 1-555-555-4505

    Update link: http://www.adobe.com/photoshop

    Local package: C:WINDOWSInstaller1017177.msi

    Install date: 20061022

    0 patch packages.

    Macromedia Flash 8

    Product code: {2BD5C305-1B27-4D41-B690-7A61172D2FEB}

    Product state: (5) Installed.

    Package code: {C9A42B64-045E-4588-B898-587A4607FF55}

    Version: 8.00.0000

    AssignmentType: 1

    Publisher: Macromedia

    Language: 1033

    Suggested installation location: C:Program FilesMacromediaFlash 8

    Installed from: C:WINDOWSDownloaded InstallationsMacromedia Flash 8

       Package: Macromedia Flash 8.msi

    Product Icon: C:WINDOWSInstaller{2BD5C305-1B27-4D41-B690-7A61172D2FEB}ARPPRODUCTICONFL8.exe

    About link: http://www.macromedia.com

    Help link: http://www.macromedia.com/go/flash_support

    Update link: http://www.macromedia.com/go/updates

    Local package: C:WINDOWSInstaller6a1e3a.msi

    Install date: 2007123

    0 patch packages.

    MSXML 4.0 SP2 (KB927978)

    Product code: {37477865-A3F1-4772-AD43-AAFC6BCFF99F}

    Product state: (5) Installed.

    Package code: {2B27DCD9-53FA-4885-B6CD-698623819F4C}

    Version: 4.20.9841.0

    AssignmentType: 1

    Publisher: Microsoft Corporation

    Language: 1033

    Installed from: c:757d1eab3b2fd214e3454ea0328a

       Package: msxml.msi

    Help link: http://support.microsoft.com/kb/927978

    Local package: c:WINDOWSInstaller2b2c8.msi

    Install date: 200734

    0 patch packages.

    Macromedia Extension Manager

    Product code: {5546CDB5-2CE2-498B-B059-5B3BF81FC41F}

    Product state: (5) Installed.

    Package code: {7DC6AC23-4173-4456-881D-0C3178F87B77}

    Version: 1.7.240

    AssignmentType: 1

    Publisher: Macromedia, Inc.

    Language: 1033

    Suggested installation location: C:Program FilesMacromediaExtension Manager

       Package: Macromedia_Extension_Manager.msi

    About link: http://www.macromedia.com

    Help link: http://www.macromedia.com/go/dreamweaver/support

    Update link: http://www.macromedia.com/go/dreamweaver

    Local package: C:WINDOWSInstaller6a1e27.msi

    Install date: 2007123

    0 patch packages.

    Product code: {B10D2D36-B94C-4A28-9FAD-0606CA8E39C4}

    Product state: (5) Installed.

    Package code: {1C8F90EF-B7F0-48EF-B00B-49E98754CCA5}

    Version: 8.0.40607.16

    AssignmentType: 1

    Publisher: Microsoft

    Language: 1033

       Package: vjssetup.msi

    Local package: C:WINDOWSInstaller436451.msi

    Install date: 2006223

    0 patch packages.

    Adobe Acrobat 8 Professional – English, Français, Deutsch

    Product code: {AC76BA86-1033-F400-7760-000000000003}

    Product state: (5) Installed.

    Package code: {B6B3C39B-637C-465F-BC2B-087FC2EA901A}

    Version: 8.0.0

    AssignmentType: 1

    Publisher: Adobe Systems

    Language: 0

    Suggested installation location: C:Program FilesAdobeAcrobat 8.0

    Installed from: D:Adobe Acrobat 8 Professional

       Package: AcroPro.msi

    Product Icon: C:WINDOWSInstaller{AC76BA86-1033-F400-7760-000000000003}_SC_Acrobat.exe

    About link: http://www.adobe.com

    Help link: http://www.adobe.com/support/main.html

    Help telephone:  

    Update link: http://www.adobe.com/acrofamily/main.html

    Transforms: C:WINDOWSInstaller{AC76BA86-1033-F400-7760-000000000003}1033.mst

    Local package: C:WINDOWSInstaller2eb5d3c.msi

    Install date: 2006126

    0 patch packages.

    TuneUp Utilities 2006

    Product code: {868D7896-99D4-4513-BC62-2B3AD3E24926}

    Product state: (5) Installed.

    Package code: {8E227DFD-07AE-4C6C-BA54-25AA47D0D1F0}

    Version: 5.0.2331

    AssignmentType: 1

    Publisher: TuneUp Software

    Language: 0

    Installed from: C:Program FilesCommon FilesWise Installation Wizard

       Package: WIS868D789699D44513BC622B3AD3E24926_5_0_2331.MSI

    About link: http://www.tune-up.com

    Help link: http://www.tune-up.com

    Local package: C:WINDOWSInstaller71ff5b.msi

    Install date: 20061119

    0 patch packages.

    Alt-Tab Task Switcher Powertoy for Windows XP

    Product code: {A7050037-F0EA-4BAB-BCD5-FC05507D6147}

    Product state: (5) Installed.

    Package code: {CAF4680A-D280-4496-BA56-5A3B4C6C27C0}

    Version: 1.00.0001

    AssignmentType: 1

    Publisher: Microsoft Corporation

    Language: 1033

    Installed from: C:WINDOWSDownloaded Installations

       Package: Alt-Tab Task Switcher Powertoy for Windows XP.msi

    Product Icon: C:WINDOWSInstaller{A7050037-F0EA-4BAB-BCD5-FC05507D6147}ARPPRODUCTICON.exe

    About link: http://www.microsoft.com/windowsxp

    Help link: http://www.microsoft.com/directory

    Help telephone: (800) 426-9400

    Update link: http://www.microsoft.com/windowsxp

    Local package: C:WINDOWSInstaller37d33.msi

    Install date: 200668

    0 patch packages.

    Adobe Help Center 1.0

    Product code: {E9787678-1033-0000-8E67-000000000001}

    Product state: (5) Installed.

    Package code: {88757974-EAEE-4981-BF13-AF8DB3A90BC0}

    Version: 001.000.000

    AssignmentType: 1

    Publisher: Adobe Systems

    Language: 1033

    Suggested installation location: C:Program FilesAdobeAdobe Help Center

    Installed from: D:Adobe(R) Photoshop(R) CS2Help Center

       Package: Adobe Help Center 1.0.msi

    About link: http://www.adobe.com

    Help link: http://www.adobe.com

    Help telephone: 1-555-555-4505

    Update link: http://www.Adobe.com/updateinfo

    Local package: C:WINDOWSInstaller1017186.msi

    Install date: 20061022

    0 patch packages.

    J2SE Runtime Environment 5.0 Update 11

    Product code: {3248F0A8-6813-11D6-A77B-00B0D0150110}

    Product state: (5) Installed.

    Package code: {3248F0A6-6813-11D6-A77B-00B0D0150110}

    Version: 1.5.0.110

    AssignmentType: 1

    Publisher: Sun Microsystems, Inc.

    Language: 0

    Installed from: http://javadl.sun.com/webapps/download/GetFile/1.5.0_11-b03/windows-i586//

       Package: jre1.5.0_11-iftw.msi

    About link: http://java.com

    Help link: http://java.com

    Update link: http://java.sun.com

    Transforms: C:WINDOWSInstaller{3248F0A8-6813-11D6-A77B-00B0D0150110}sp1033.MST

    Local package: C:WINDOWSInstaller17692f.msi

    Install date: 2007219

    0 patch packages.

    Java(TM) SE Runtime Environment 6 Update 1

    Product code: {3248F0A8-6813-11D6-A77B-00B0D0160010}

    Product state: (5) Installed.

    Package code: {3248F0A6-6813-11D6-A77B-00B0D0160010}

    Version: 1.6.0.10

    AssignmentType: 1

    Publisher: Sun Microsystems, Inc.

    Language: 0

    Installed from: http://javadl.sun.com/webapps/download/GetFile/1.6.0_01-b06/windows-i586/

       Package: jre1.6.0_01-iftw.msi

    About link: http://java.com

    Help link: http://java.com

    Update link: http://java.sun.com

    Transforms: C:WINDOWSInstaller{3248F0A8-6813-11D6-A77B-00B0D0160010}sp1033.MST

    Local package: C:WINDOWSInstaller10c9f6d.msi

    Install date: 200749

    0 patch packages.

    Microsoft Office 2000 Premium

    Product code: {00000409-78E1-11D2-B60F-006097C998E7}

    Product state: (5) Installed.

    Package code: {95FB8B80-DF59-11D2-AFA2-00C04F5B3AEF}

    Version: 9.00.2720

    AssignmentType: 1

    Publisher: Microsoft Corporation

    Language: 1033

    Installed from: D:

       Package: DATA1.MSI

    Help link: http://www.microsoft.com/support

    Local package: C:WINDOWSInstaller2598fe.msi

    Install date: 2005512

    0 patch packages.

    Microsoft Office 2000 Disc 2

    Product code: {00040409-78E1-11D2-B60F-006097C998E7}

    Product state: (5) Installed.

    Package code: {6136B430-DF5B-11D2-BE45-00C04F6C8AD6}

    Version: 9.00.2720

    AssignmentType: 1

    Publisher: Microsoft Corporation

    Language: 1033

    Installed from: D:

       Package: DATA2.MSI

    Help link: http://www.microsoft.com/support

    Local package: C:WINDOWSInstaller2599c9.msi

    Install date: 2005512

    0 patch packages.

    Nero 7 Premium

    Product code: {43FFE159-3199-4188-A1CD-629166AD1033}

    Product state: (5) Installed.

    Package code: {2CB1BD8C-C76D-4FB6-BECB-12E45EA3B32A}

    Version: 7.02.6445

    AssignmentType: 1

    Publisher: Nero AG

    Language: 1033

    Suggested installation location: C:Program FilesNeroNero 7

    Installed from: C:DOCUME~1RichardLOCALS~1TempNeroDemo12550

       Package: Nero.msi

    Product Icon: C:WINDOWSInstaller{43FFE159-3199-4188-A1CD-629166AD1033}ARPPRODUCTICON.exe

    About link: http://www.nero.com/

    Help link: techsupport@nero.com retail-support@nero.com chinese-techsupport@nero.com

    Help telephone: xxxxxxxxxxxxxx

    Update link: techsupport@nero.com retail-support@nero.com chinese-techsupport@nero.com

    Transforms: C:WINDOWSInstaller{43FFE159-3199-4188-A1CD-629166AD1033}1033.mst

    Local package: C:WINDOWSInstaller45f40.msi

    Install date: 2007415

    0 patch packages.

    Windows Genuine Advantage v1.3.0254.0

    Product code: {63569CE9-FA00-469C-AF5C-E5D4D93ACF91}

    Product state: (5) Installed.

    Package code: {9606A54A-74F2-4CEE-BEF1-147C479507E6}

    Version: 1.3.0254.0

    AssignmentType: 1

    Publisher: Microsoft

    Language: 1033

       Package: LegitCheckControl.msi

    About link: http://www.microsoft.com/genuine/downloads/whyValidate.aspx/about

    Help link: http://www.microsoft.com/genuine/downloads/whyValidate.aspx/help

    Help telephone: 1-425.882.8080

    Update link: http://www.microsoft.com/genuine/downloads/whyValidate.aspx/update

    Local package: C:WINDOWSInstaller25c004.msi

    Install date: 2005927

    0 patch packages.

    Calculator Powertoy for Windows XP

    Product code: {B37C842A-B624-46B8-A727-654E72F1C91A}

    Product state: (5) Installed.

    Package code: {F678C174-C540-4EEC-8219-F802A8ECDB07}

    Version: 1.00.0001

    AssignmentType: 1

    Publisher: Microsoft Corporation

    Language: 1033

    Installed from: C:WINDOWSDownloaded Installations

       Package: Calculator Powertoy for Windows XP.msi

    Product Icon: C:WINDOWSInstaller{B37C842A-B624-46B8-A727-654E72F1C91A}ARPPRODUCTICON.exe

    About link: http://www.microsoft.com/windowsxp

    Help link: http://www.microsoft.com/directory

    Help telephone: (800) 426-9400

    Update link: http://www.microsoft.com/windowsxp

    Local package: C:WINDOWSInstaller2f334.msi

    Install date: 2006619

    0 patch packages.

    QuickTime

    Product code: {F07B861C-72B9-40A4-8B1A-AAED4C06A7E8}

    Product state: (5) Installed.

    Package code: {FDAD1103-F274-4D52-A4B4-047675BE8699}

    Version: 7.1.3.100

    AssignmentType: 1

    Publisher: Apple Computer, Inc.

    Language: 1033

    Suggested installation location: C:Program FilesQuickTime

       Package: QuickTime.msi

    Product Icon: C:WINDOWSInstaller{F07B861C-72B9-40A4-8B1A-AAED4C06A7E8}Installer.ico

    About link: http://www.apple.com

    Help link: http://www.apple.com/support/

    Help telephone: 1-800-275-2273

    Update link: http://www.apple.com/quicktime/

    Local package: C:WINDOWSInstallerc8c08.msi

    Install date: 20061112

    0 patch packages.

    Adobe Stock Photos 1.0

    Product code: {EE0D5DCD-2B97-4473-98DF-E93C0BD92F7A}

    Product state: (5) Installed.

    Package code: {A6DE94EB-270F-445A-8229-708FFB58444D}

    Version: 1.0.8

    AssignmentType: 1

    Publisher: Adobe Systems

    Language: 0

    Suggested installation location: C:Program FilesAdobeAdobe Stock Photos

    Installed from: C:DOCUME~1RichardLOCALS~1Temp

       Package: adb9.tmp

    About link: http://www.adobe.com

    Help link: http://www.adobe.com

    Help telephone: 1-555-555-4505

    Update link: http://www.adobe.com

    Local package: C:WINDOWSInstaller5326fe.msi

    Install date: 2006126

    0 patch packages.

    Product code: {B2A2C64F-AFA1-4BF0-9879-1071EF0C950C}

    Product state: (5) Installed.

    Package code: {A17B32A2-0013-44B4-A221-689725B9C84A}

    Version: 1.16.40607.16

    AssignmentType: 1

    Publisher: Microsoft

    Language: 1033

       Package: msdnexp.msi

    Local package: C:WINDOWSInstaller436456.msi

    Install date: 2006223

    0 patch packages.

    34 products installed.

    I can’t see anything that would stop me installing.

    Sorry this is such a long post – but any help would be appreciated.

  34. astebner says:

    Hi Rmg1 – I see 2 items in the msiinv list posted there that are beta products that will need to be removed:

    {B10D2D36-B94C-4A28-9FAD-0606CA8E39C4}

    {B2A2C64F-AFA1-4BF0-9879-1071EF0C950C}

    These are both from the VS 2005 beta 1.  The first is the J# Express Edition and the second is the MSDN Express Edition.

    Can you please try to remove these 2 products using steps 3-7 listed at http://blogs.msdn.com/astebner/archive/2005/10/30/487096.aspx and see if that resolves this issue?

  35. rmg1 says:

    Thanks Aaron

    I’m no longer going bald!!

    😉

  36. coker says:

    My uninstallation of Visual Studio Express C# has been suspended.  I began to uninstall but after after about 5 hours, it appeared that the uninstall wasn’t really working so I "ended" it.  Now, i can’t find any way to "resume" it.  I’ve tried just about everything I can think of.  When I try to use Add/Remove hardware, I get a message saying that the vs_setup.msi file can’t be opened.

    Also, according to the output produced by msiiv, C# and J# "aren’t installed"  However, they show up everywhere else (add/remove, program files, etc).

    Any ideas? I’m at a loss with this one…

    Thanks

  37. astebner says:

    Hi Coker – It sounds like the uninstall was mostly completed (since you do not see these products in the msiinv output), but it is not completely done because you still see them in Add/Remove Programs.  I think the cleanest solution would be to re-install these programs and then uninstall them again.  If that doesn’t help or you don’t want to go through that hassle, you can manually remove the files from Program Files and registry keys that are used to display the entries in Add/Remove Programs (they are located in a sub-key under HKEY_LOCAL_MACHINESoftwareMicrosoftWindowsCurrentVersionUninstall and you can search for them by the names of the products).

  38. Si certains d’entre vous ont installé la beta du SP1 sur leur Team Foundation Server, vous aurez certainement

  39. Si certains d&#39;entre vous ont installé la beta du SP1 sur leur Team Foundation Server, vous aurez

  40. rouxbox says:

    Thanks for the great post. I successfully removed my application. I cannot believe how easy if was to create a msi pack. Why am i finding it so hard to figure out how to create an uninstall so i dont how to go about this round about way. Any links or suggestions?

  41. astebner says:

    Hi Rouxbox – I’m not sure I understand your question.  An MSI supports installing, repairing and uninstalling.  You don’t have to create a separate package for uninstall – you should be able to use the same package that you use for install.  Can you please clarify the exact problem you’re running into related to uninstall so I can try to help better?

  42. Searcher54 says:

    Neat tool, thanks!  I recently tried to use the installer cleanup utility but it listed not one single program in the "installed products" list although I have tons of them, so I knew I had a problem somewhere.  I don’t seem to have any probs installing apps, tho, so I don’t know how hard I should pursue this – might break something – still, I sure prefer to have everything working as it should be.  So if you have any ideas about the following, I’d sure be grateful for any input.

    Running msiinv w/the -x arguement gives me:

    3064 components without an installed product.

    62 permanent components with a product currently installed.

    203 permanent components.

    273 shared components between currently installed applications.

    A lot of these were pre-installed programs, OEM, and I’ve found probs with uninstalling those in the past, but some of them are progs I installed, too, and I can’t figure why they’re ‘orphaned’…Running with -p won’t finish, gives me:

    Unexpected error: 1605 <>

    Assertion failed: ERROR_NO_MORE_ITEMS == uiEnumerateReturn, file msiinv.cpp, lin

    e 897

    This application has requested the Runtime to terminate it in an unusual way.

    Please contact the application’s support team for more information.

    Unfortunately, it seems that with xp sp2 there’s no easy way to reinstall Windows Installer, not that I’ve found so far, anyway.  I did try re-applying 3.1v2 but that didn’t do a thing.  What I’d really like is to have the Installer properly recognize all the progs it HAS installed – any ideas?  thanks 🙂

  43. astebner says:

    Hi Searcher54 – The -x argument is not the best one to use if you are trying to just get a list of installed programs.  It is only useful to get a list of orphaned Windows Installer components, which is an advanced technique usually only needed by the Microsoft product support teams.

    I’d suggest running with the -p flag to get a list of installed products.

    Also, I’m not sure exactly why you are trying to use the MsiInv tool to uninstall a product on your system.  I strongly suggest first trying to uninstall whatever product you are having trouble with using the entry in Add/Remove Programs before resorting to manually installing by using MsiInv.

    It doesn’t sound like you need to repair Windows Installer on your system.  Running Msiinv with the -p switch instead of -x should take care of the issue you’re referring to.  If you still think you need to repair Windows Installer, I’d suggest trying these steps:

    1.  Click on the Start menu, choose Run, type cmd and click OK

    2.  Run this command:  sfc /scannow

    3.  After it finishes (it can take a while), run this command:  msiexec /unregister

    4.  Run this command:  msiexec /regserver

    5.  Reboot

    That should allow you to repair Windows Installer if needed.

    Hopefully this helps.

  44. Searcher54 says:

    Thanks muchly for your reply,  astebner.  Guess I didn’t explain my purpose real well – I was trying to figure out why Windows Installer Cleanup Utility saw zip, nada, absolutely NO programs it had installed, when there should be lots of them.  That’s why I used the -x, as it seemed by your explanation of that switch that it might tell me something.  It did, but I’m not sure what! lol  I just know that something’s amiss or the Utility would give me selections in the box for "installed products".  It all started with Macrovision giving me IE errors then refusing to uninstall. (preparatory to a clean install)

    I did try running msiinv with the -p switch, but it would not finish, giving me the following error after listing only a few of my installed programs:

    "Unexpected error: 1605 <>

    Assertion failed: ERROR_NO_MORE_ITEMS == uiEnumerateReturn, file msiinv.cpp, line 897

    This application has requested the Runtime to terminate it in an unusual way.

    Please contact the application’s support team for more information."

    I’ll try the steps you suggested for the Windows Installer, and thanks again. Please let me know if you have any ideas about why the -p switch quits with an error, and/or why Cleanup Utility doesn’t show any programs at all.  

  45. astebner says:

    Hi Searcher54 – The error 1605 is a Windows Installer error code that means "This action is only valid for products that are currently installed."  Likely this means that one of the installed products on your system is in a bad/inconsistent state, and that is confusing msiinv and the WIndows Installer Cleanup Utility.  I’m not sure how to narrow down exactly what product is causing that error though.  It might help to use the -v (verbose) switch on msiinv.  If you want, you can run msiinv in verbose mode and zip and send me the log file so I can see if I can figure out anything about the root cause.  You can send the log file to Aaron.Stebner (at) microsoft (dot) com.

  46. I previously wrote about a log collection tool that will automatically gather and cab up Visual Studio

  47. I previously wrote about a log collection tool that will automatically gather and cab up Visual Studio

  48. Meta-Code says:

    Visual Studio 2008 – Install Problem Solved

  49. ASPInsiders says:

    This week with the RTM of VS2008 I made the move from the Beta 2 version of VS2008 to the RTM version.

  50. Since XNA Game Studio 2.0 shipped back in December, we’ve heard of a few installation issues from customers

  51. Since XNA Game Studio 2.0 shipped back in December, we&#39;ve heard of a few installation issues from

  52. dkwright says:

    Hi, do you know of an alternate source of msiinv.zip?  The website for it appears to be gone or down.

    Thank you!

  53. astebner says:

    Hi Dkwright – I’ve sent out mail to ask the owner of that site whether this is a temporary or permanent outage.  In the meantime, I’ve posted this file for download at the following alternate locations:

    http://astebner.sts.winisp.net/Tools/msiinv.zip

    http://cid-27e6a35d1a492af7.skydrive.live.com/self.aspx/Blog%7C_Tools/msiinv.zip

  54. dkwright says:

    Thank you.  I really appreciate it!

  55. mytechmail@sbcglobal.net says:

    I just tried running this on my laptop with Vista SP1 installed and I get "Unexpected Error: 1605 <>" repeated 3 times in the command prompt window and no output file. Any thoughts?

  56. astebner says:

    Hi Dasharp – I’ve seen these 1605 errors in the past on some systems.  They usually mean that there is some incorrect Windows Installer data somewhere in your registry.  However, I also looked at the code for this MsiInv tool and it should continue even after hitting errors like that and continue to list installed MSI-based products.  Are you sure it didn’t list anything in the log file?  Are you looking in the right location on your file system for the log file to be produced?

  57. mytechmail@sbcglobal.net says:

    I forgot to put the folder in output redirect. I found the file.

    Thanks.

  58. Boivin says:

    Hi,

    msiinv -x gives me many orphaned Components whose ProductCode is {00000000-0000-0000-0000-000000000000}.

    Those components seems to come from various appli:

    Component {89476830-4393-4DB3-8330-773401C4EE50} has no parent product (permanent)

    Product Code: {00000000-0000-0000-0000-000000000000}

    Permanent Product placeholder.

    Component path: C:Program FilesMEGAMEGA 2009Demonstration

    File or directory not found.

    Attributes:

    Component {A44402F0-AE37-45ED-9498-1094455D934B} has no parent product (permanent)

    Product Code: {00000000-0000-0000-0000-000000000000}

    Permanent Product placeholder.

    Component path: C:Program FilespalmOnePhotoDesktopuiDGUIimg_Dialogs_vw.ui

    File or directory not found.

    Attributes:

    How can I remove those orphaned Components?

    I haven’t dare to use MsiZapA.exe TW{00000000-0000-0000-000000000000}

    I fear it removes too many things.

    Any suggestions?

    Thanks in advance

  59. astebner says:

    Hi Boivin – Those orphaned components are from products that you had installed that had components that were marked as permanent (meaning they would not be removed during an uninstall).  My systems all have some components like that.  You should just leave them as is – if the product marked the components as permanent, they intended for them to be left behind on the system even after uninstalling the product.

  60. Boivin says:

    Hi Aaron.

    Thanks for your answer.

    For at least one soft (the one I’m concerned with), the orphaned component are not specified as ‘Permanent’ in the MSI (nor in the ISM as the package has been built with InstallShield 12).

    I’m afraid they remain because of a broken reference counter or something like that due to the way the MSI has been designed (unfortunately). Is there a way to remove them from the system? (without resinstalling the OS)

    I can’t find the Component ID in the registry.

  61. astebner says:

    Hi Boivin – Windows Installer components are stored in an obfuscated manner in the registry, and I wouldn’t recommend trying to manually modify any Windows Installer registry data because it is pretty easy to leave your system in an inconsistent state.  These component references aren’t going to hurt anything – the worst thing I think could happen here is that if you install some product in the future with that same component in it, it could cause the component reference count to be one too high.  That isn’t really going to affect anything, so overall it would probably be best to leave this as is and not try to manually fix it up.

  62. Julia says:

    Thank you for excellent article!

    It was very-very helpfull for me (I had a big problem with uninstalling Visual Studio 2010 ultimate trial)

  63. soyka says:

    Tried to upgrade SQL Express 2008 to 2008R2. For some reason the upgrade failed which left my server in a half way installed state. The above procedure helped me to get rid of both 2008 a 2008R2.

  64. badcop666 at hotmail dot com says:

    Hi Aaron, I am using msiinv.exe to monitor a build server farm (ccnet). I get different results when I run under two different domain logins.

    I'm wondering if the API is returning msi entries visible to the user?

    I will try to confirm this – however, would appreciate some guidance from the author.

    thx. Appreciate the excellent tool!

    Andy, NZ

  65. astebner says:

    Hi Badcop666 at hotmail dot com – I didn't create the MsiInv tool.  I got permission from the person who did to post it and write about it.  I have access to the source code too though, so I took a look and it is just calling standard Windows Installer APIs such as MsiEnumProducts (msdn.microsoft.com/…/aa370101.aspx) to determine what is installed on the computer.  If you have any per-user MSIs or components installed on a computer, then it is definitely possible for you to get different results when running this tool with different domain logins.

  66. Baxter Tocher says:

    Thank you *so* much for this. I've manage to uninstall the remnants of a program that's been annoying me for months. It had preventing me from reinstalling the software properly. Fabulous work!

  67. keith42 says:

    Hi Aaron,

    I tried the instructions above at the cmd prompt but I got this message

    "'C:msiinvmsiinv.exe-p' is not recognized as an internal or external command,operable program or batch file"

    I can run the c:msiinvmsiinv.exe no problem…I just cannot read that fast! What noob mistake am I making here? Thanks for all your help!

  68. astebner says:

    Hi keith42 – You need to put a space between msiinv.exe and -p. Can you please give that a try and let me know if it works for you?

  69. Shan says:

    Hello Aaron,

    I am trying to uninstall the PC Fix Speed and Optimize Your PC which are know to have some malware. I downloaded the file and followed the steps, but these two programs do not show up. I am at a loss. Do you have any suggestions?

  70. astebner says:

    Hi Shan – The instructions in this blog post only work for applications that use Windows Installer for their setup programs.  If you don't see this application in the list after running msiinv.exe, then it likely doesn't use Windows Installer, and you'll need to use some other means to uninstall it.  There might be an entry in the Programs and Features control panel that you can use to uninstall it, or there might be an uninstaller program in the same directory as the application itself.

  71. Alex says:

    So somehow my .NET Framework got updated to 4.5.2 during a windows update. While attempting to reinstall Visual Studio 2013 v3, it would simply error out claiming the 4.5.1 .NET Framework could not be installed.

    When checking the log, it gave no indication it's failure was due to a more recent .NET package. Searching a good load of articles on the microsoft website did nothing. Not only that, the FixIt #50123 which is supposed to help fix corrupted MSI packages didn't even mention I was running 3 different versions of .NET framework!

    After tracking down where on the Install CD this package was, I was able to manually run it and see a more detailed error log (I'm sure I could have done this via the VS setup, but it wasn't until reading the comments here that I got the idea). After using the steps you outlined, I quickly found that although the .NET framework wasn't listed in the installed apps, it was on the system, cloaked as a windows KB update.

    After removing it, again using your easy to follow instructions =D, I was able to finally, after two weeks of pain, reinstall my VStudio! I can not thank you enough!

  72. Adrian Arroyo says:

    The program I'm searching for didn't show up in the output. What do I do?

  73. astebner says:

    Hi Adrian Arroyo – That means that either the program isn't currently installed on your PC or the program doesn't use Windows Installer for its setup technology.  What is the exact program that you're searching for in your scenario?

  74. majkinetor says:

    Can we provide this tool via Chocolatey ?

    1. Hi majkinetor – I’m sorry, but I don’t have any plans to deliver this tool via other sites at this time. Are you having trouble downloading it from the link that I provided?

  75. Matthew Copeland says:

    When running this on Windows 10 (10.0.10586.0) 64 bit, I get two identical output lines.
    Unexpected error: 1605 ()

    Output file is created however, but my confidence is not high that the output was not changed in some meaningful way.

    Thanks,
    Matthew

    1. Hi Matthew Copeland – Error 1605 means that there is some data in your registry that the Windows Installer APIs don’t know how to process. The rest of the output from the msiinv.exe tool is still valid though, so you can continue using the output for your scenarios despite seeing those 1605 errors.

      1. Matthew Copeland says:

        Thanks Aaron!

        It would be interesting to know what registry entries were causing the problem. Is this an indication that the registry data does not match the data in the installer database?

        1. Hi Matthew Copeland – The registry entries are intentionally stored in an obfuscated format to discourage people from directly querying the registry and instead steering them towards the Windows Installer APIs. When I’ve seen that type of error in the past, it typically meant that there was an orphaned key that indicated that a patch was installed but the base product wasn’t actually installed or something similar to that. I haven’t seen this type of issue cause any harm other than for reporting tools like msiinv.exe that use Windows Installer APIs to mine data from the Windows Installer registry sub-key, so I don’t think you need to worry about it.