aws-cli
aws-cli copied to clipboard
Unable to uninstall AWSCLI version 2.24.24 on Windows 11
Describe the issue
I installed AWSCLI version 2.24.24 on Windows through .MSI installer and cannot uninstall it through Control Panel to perform a clean install of the new version. The Windows Installer said that the feature I am trying to use is on a network resource that is unavailable. Installation by downloading the version 2.24.24 (AWSCLIV2-2.24.24.msi) or the latest version (AWSCLIV2.msi) from the website does not help because the same issue of uninstalling the existing version occurs.
Additional Information/Context
No response
CLI version used
2.24.24
Environment details (OS name and version, etc.)
Windows 11 Version 23H2
Hi @songkomkrit,
Sorry to hear you're having an issue uninstalling the AWS CLI v2. I'm not sure what could be the issue here - can you provide more details on how you installed the AWS CLI v2 initially? Was the MSI you downloaded saved and run from a networked drive?
If you download a new version of the AWS CLI to a local drive, can you perform the installation?
Alternatively, you could try to download this same version to a local drive, and use that to uninstall the AWS CLI. You can download the 2.24.24 MSI from this link:
https://awscli.amazonaws.com/AWSCLIV2-2.24.24.msi
Or, follow the instructions here:
https://docs.aws.amazon.com/cli/latest/userguide/getting-started-version.html
First of all, I appreciate your response. I usually download an AWS CLI using the link https://awscli.amazonaws.com/AWSCLIV2.msi and have nothing to do with a networked drive. I forgot to let you know that I can successfully, but forcefully, uninstall that version by using Program Install and Uninstall troubleshooter provided by Microsoft at https://support.microsoft.com/en-us/topic/fix-problems-that-block-programs-from-being-installed-or-removed-cca7d1b6-65a9-3d98-426b-e9f927e1eb4d. Currently, my AWS CLI version is up-to-date, and I have no problem with uninstalling its previous version.
Thanks for the details!
I haven't been able to reproduce the issue - when using a Windows Amazon EC2 instance, I am able to install and uninstall that version (and any version I tried) with no issue.
I'll leave this issue open for the time being should another user encounter a similar situation and we can see if we can identify any commonalities.
I confirm I have the same behavior when using winget.
PS C:\Users\admin> winget uninstall --id Amazon.AWSCLI
Found AWS Command Line Interface v2 [Amazon.AWSCLI]
Starting package uninstall...
Uninstall failed with exit code: 1612
I tried to uninstall the AWS CLI and it's failing with the following error:
The problem is fixed after downloading the installer with the same version and placing it in the Temp path.
After I installed again the AWS-CLI, winget removed the installer from the Temp path. I think this is the bug.
OS info: Windows 11 Enterprise 24H2