Install hangs on Ubuntu 18.04 in WSL 1709
Using Ubuntu 18.04 on WSL on 1709 Go thru the prelim steps on install page.
Install hangs here: Preparing to unpack .../azure-cli_2.0.33-1~xenial_all.deb ... Unpacking azure-cli (2.0.33-1~xenial) over (2.0.33-1~xenial) ...
Stuck there - have to ctrl+z to exit.
If I try to remove: $ sudo apt-get remove -y azure-cli E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem. $ sudo dpkg --configure -a
$ sudo apt-get remove -y azure-cli Reading package lists... Done Building dependency tree Reading state information... Done The following packages will be REMOVED: azure-cli 0 upgraded, 0 newly installed, 1 to remove and 148 not upgraded. 1 not fully installed or removed. After this operation, 0 B of additional disk space will be used.
dpkg: error processing package azure-cli (--remove): package is in a very bad inconsistent state; you should reinstall it before attempting a removal Errors were encountered while processing: azure-cli E: Sub-process /usr/bin/dpkg returned an error code (1)
Unable to do any other apt work at this point as it will try to reinstall azure-cli and hang again.
It would be nice to have more output during install.
Similar issue here. I had to do the following just to get apt working again:
sudo mv /var/lib/dpkg/info/azure-cli.* /tmp/
sudo dpkg --remove --force-remove-reinstreq azure-cli
sudo apt-get remove azure-cli
sudo dpkg --configure -a
I then installed it using the following:
sudo apt-get update && sudo apt-get install -y libssl-dev libffi-dev python-dev build-essential
curl -L https://aka.ms/InstallAzureCli | bash
The last command there took probably 10 minutes to install. In particular it seemed to hang at "uninstalling wheel-0.31.1" for quite a while.
Closing due to inactivity.