/build/static/layout/Breadcrumb_cap_w.png

Uninstall a version of Java

The product un-install command is MsiExec.exe /X{26A24AE4-039D-4CA4-87B4-2F83217021FF}. I wrote a script:

Directory: $(KACE_SYS_DIR)
File: MsiExec.exe
Wait
Parameters: /X{26A24AE4-039D-4CA4-87B4-2F83217021FF}

The error is :

Running as: SYSTEM
Error creating process: C:\WINDOWS\System32\MsiExec.exe /X{26A24AE4-039D-4CA4-87B4-2F83217021FF} : (0) The operation completed successfully.
Error Code: 0
Status Code: 1605

 

Is that problem that on this computer that GUID doesn't exist?

Thanks

 


2 Comments   [ + ] Show comments
  • Have you tried using the built it scripting wizard under :

    Scripting > Configuration Policy > Uninstall wizard

    Especially with the GUID string, i find using this wizard gives me greater success. Yes if its not the right GUID it probably won't work. Hence with the wizard you can build them out quickly for all the different versions you want to remove. - nshah 11 years ago
  • Thanks. I will try that. - jfrasier 11 years ago

Answers (5)

Posted by: anonymous_9363 11 years ago
Red Belt
3

Roughly 0.5 seconds with Google will tell you that Windows Installer error 1605 is "This action is only valid for products that are currently installed."

Tricky to uninstall products which aren't installed. Add a test for installed status before attempting an uninstall.


Comments:
  • In the KACE inventory it showed that this computer did have that exact version. - jfrasier 11 years ago
Posted by: bkelly 11 years ago
Red Belt
2

If you can point to the MSI for the removal command instead of the GUID you may have better luck.

If you are going to pursue uninstall by GUID, note that the 32 bit and 64 bit installations have slightly different GUIDs. The one you have here is the 32 bit version, perhaps some of your systems have installed the 64bit?

26A24AE4-039D-4CA4-87B4-2F83217021FF


Comments:
  • Noticed that not only the change between 64 & 32, but also the specific version of Java:
    For example, version 1.7.0_21 (32-bit):
    {26A24AE4-039D-4CA4-87B4-2F83217021FF}

    version 1.7.0_25 (32-bit):
    {26A24AE4-039D-4CA4-87B4-2F83217025FF} - Joe_SCC 10 years ago
Posted by: SnowLyric 11 years ago
Second Degree Brown Belt
0

I'm not familiar with Kace but wondering if you need a /qn parameter.


Comments:
  • It did ask me if I wanted to uninstall, so yes having /qn would be a good idea. The problem was that it didn't uninstall. - jfrasier 11 years ago
  • u cn search for correct guid here HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall and give the exact vesrion of ur java application - appfreak 11 years ago
Posted by: terebent 11 years ago
Second Degree Brown Belt
0

The simple way to solve this is to add a condition to verify which version of Java is installed and execute the uninstall command for each version. As bkelly said, the product code for 64 bits Java is diferent than product code for 32 bits Java.

{26A24AE4-039D-4CA4-87B4-2F83217021FF} - Java x86

{26A24AE4-039D-4CA4-87B4-2F86417021FF} - Java x64.

Posted by: jegolf 11 years ago
Red Belt
0

...you do need to add /qn for a silent uninstall. Another option I use instead of a script is create a MI, check the box for uninstall, add the command line for the uninstall, and target it to the machines you want to uninstall the software from. You've now got a Manged UNinstall! 

I've noticed some of the uninstall strings seem to be incorrect and don't work as reported by our Kbox. I used a program that found the string more accurately - I can't remember what it was exactly but it was mentioned on ITNINJA...or if you Google for uninstall string finder something will turn up.


Comments:
  • Thanks. One reason I like scripts better than MI's is that I have control over when they happen. Maybe I really don't know enough about MIs to utilize them much. - jfrasier 11 years ago
  • Also with scripts I can add other steps like deleting an icon or something - jfrasier 11 years ago
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ