10/8/2019 Msi Silent Uninstall Command Line
From a command prompt run msiexec /x ProductCode This should uninstall your application. More Info: 1. Using the original MSI. If you have access to the original MSI used for the installation, you can simply right click it in Windows Explorer and select Uninstall. As stated above you can do the same by command line: msiexec /x filename.msi /q. Using the full installer from the command line will implicitly enable silent mode. To learn more, see the /S option in this command-line options document about full installer configurations. Silent installation is enabled by the /S option. How to Uninstall Silently. To uninstall Firefox for Enterprise silently you have to uninstall from the. If you have access to the original MSI used for the installation, you can simply right click it in Windows Explorer and select Uninstall. You can also uninstall via command line as explained in section 3. Using the old ARP Applet OR new Windows 8/10 Settings Interface.
To perform the uninstall, which AFAIK should be silent (it has been in my experience, but try it before you bet the farm on that. Silence may depend on how your installer/uninstaller was built). See here for more: WMIC: the best command line tool you've never used (overview of WMIC with lots of cool commands described).
Active4 months ago
msiexec is command prompt software that installs an MSI program. But I have found that you can install an MSI file from the command line by just typing in the name of the MSI file on the command line.
But in order to uninstall the MSI file, it seems you have to call the
msiexec program and give it a /x or /uninstall .
How can I uninstall an MSI from the command line without using the Stein Åsmul
msiexec routine?
25.6k1515 gold badges6161 silver badges129129 bronze badges
xarzuxarzu
3,5363131 gold badges9191 silver badges131131 bronze badges
7 Answers
Short answer: you can't. Use MSIEXEC /x
Long answer: When you run the MSI file directly at the command line, all that's happening is that it runs MSIEXEC for you. This association is stored in the registry. You can see a list of associations by (in Windows Explorer) going to Tools / Folder Options / File Types.
For example, you can run a .DOC file from the command line, and WordPad or WinWord will open it for you.
If you look in the registry under Roger LipscombeRoger Lipscombe
HKEY_CLASSES_ROOT.msi , you'll see that .MSI files are associated with the ProgID 'Msi.Package'. If you look in HKEY_CLASSES_ROOTMsi.PackageshellOpencommand , you'll see the command line that Windows actually uses when you 'run' a .MSI file.
58.5k4444 gold badges199199 silver badges322322 bronze badges
There are many ways to uninstall an MSI package. This is intended as a 'reference'.
In summary you can uninstall via: msiexec.exe, ARP, WMI, PowerShell, Deployment Systems such as SCCM, VBScript / COM Automation, DTF, or via hidden Windows cache folder, and a few other options presented below.
The first few paragraphs provide important MSI tidbits, then there are 14 sections with different ways to uninstall an MSI file. Puh.
'Babble, Babble - Over':Sections 1, 2 and 3 are the normal uninstall approaches (and hence recommended).
Personally I use option 3 or 5 from section 3 (both options with logging, but option 5 runs silently as well). If you are very busy, skip all the babble and go for one of these - it will get the job done.
If you have problems uninstalling altogether and are looking for an alternative to the deprecated
If you think MSI and Windows Installer is more trouble than it's worth, you might want to read about the corporate benefits of using MSI files.
Installscript MSI setups generally come wrapped in a setup.exe file. To read more about the parameters to use for uninstalling such setups please see these links: setup.exe pdf reference sheet, Setup.exe and Update.exe Command-Line Parameters.
Some MSI files are installed as part of bundles via mechanism such as Burn (WiX Toolkit) or InstallShield Suite projects. This can make uninstall slightly different from what is seen below. Nagin season 2 latest episode. Here is an example for InstallShield Suite projects.
Be aware that running uninstall silently or interactively can cause different results (!). For a rather lengthy description of why this is the case, please read this post: Uninstall from Control Panel is different from Remove from .msi
If you are unexpectedly asked for the original installation media when trying to uninstall, please read this answer: Why does MSI require the original .msi file to proceed with an uninstall? and perhaps also section 12 below for some important technical details.
If you got CCleaner or similar cleanup tools installed, perhaps jump to section 11.
If uninstall is failing entirely (not possible to run), see sections 12 & 13 below for a potential way to 'undo' the installation using system restore and / or cleanup tools.
1.
|
Install / Uninstall | Command Line Option | Silent Mode |
MSI – Installation | msiexec /i “<msi file name with path>” [TRANSFORMS=”<mst file name with path>”] | msiexec /i “<msi file name with path>” [TRANSFORMS=”<mst file name with path>”] /qn |
MSI – UnInstallation | msiexec /x <ProductGUID> | msiexec /x <ProductGUID> /qn |
MSP – Installation | Command line with Progress dialog: msiexec /p “<msp file name with path>” /qb |
msiexec /p “<msp file name with path>” /qn |
Command line with UI: msiexec /p “<msp file name with path>” REINSTALLMODE=oums REINSTALL=ALL |
||
MSP – Uninstallation | Command line with Progress dialog: Msiexec /package <ProductGUID> MSIPATCHREMOVE=<PatchGUID> /qb |
msiexec /I <ProductGUID> MSIPATCHREMOVE=<PatchGUID> /qn |
Note:
|
Bhuvana’s Thought on Msigeek.com:
I came across MSIgeek blog through linkedin groups. Good to see lots of articles and FAQs on MSI at one stop. Some of the articles definitely helps to give a better insight into the concepts. So felt like contributing some article, which would help people like us, the Packaging specialists.
I came across MSIgeek blog through linkedin groups. Good to see lots of articles and FAQs on MSI at one stop. Some of the articles definitely helps to give a better insight into the concepts. So felt like contributing some article, which would help people like us, the Packaging specialists.
If you want to get in touch, her LinkedIn Profile is – Here. (PS: Do mention in the LinkedIn request that, you read her article on msigeek. We do not want to give her un-necessary Spams ? )
Comments are closed.
Author
Write something about yourself. No need to be fancy, just an overview.