Evan
Evan

Reputation: 78

Failed Remove Anaconda Package (InvalidArchiveError)

I accidentally install tensorflow-gpu using conda install -c anaconda tensorflow-gpu in my base environment. When I try to remove that use the commands

conda clean -a
conda remove tensorflow-gpu

It return InvalidArchiveError

InvalidArchiveError('Error with archive C:\Users\Path\Anaconda3\pkgs\openssl-1.1.1g-he774522_0u1c8dqql\pkg-openssl-1.1.1g-he774522_0.tar.zst. You probably need to delete and re-download or re-create this file. Message from libarchive was:\n\nCould not unlink')

how to completely remove tensorflow-gpu package in my base conda environment?

Upvotes: 1

Views: 3604

Answers (2)

amine sachiro
amine sachiro

Reputation: 11

try: conda remove --force tensorflow-gpu

Upvotes: 0

user11530462
user11530462

Reputation:

Providing the solution here (Answer Section), even though it is present in the Comment Section for the benefit of the community.

This issue can be resolved in two methods

First Method: Remove openssl-1.1.1g-he774522_0.tar.zst and number of folders openssl-1.1.1g-he774522_0 containing also those .tar balls. After that please close the terminal which was running using openssl so if your python is running somewhere, try to close it down. Reopen and install openssl and everything will be back to normal

# install openssl from libarchive
conda install -c conda-forge libarchive

Second Method : Reinstall Anaconda

Upvotes: 1

Related Questions