|
Solution
After trying many different methods that may work for you, such as running the commands
or
, the solution is:
Run
and the terminal will output all the directories and files of your current directory in ascending order so that you can see which files or directories are taking so much storage. The output will look like this:
Now you can see which files or directories are taking much space and delete them using
or
كود: rm -rf directory_name
. I did it and after running
again, I now had 88% — instead of 100% — of memory used from the
directory. Even though I had deleted many files and directories, it seemed strange to me that something was still occupying so much space. And here comes a powerful tool that solved my problems and of which I knew nothing before running into this issue.
NCDU
NCDU shows you which files and directories are taking the most space on the directory you run it — but it shows even the hidden files and directories that the other commands we used so far are unable to show. I did show you the other commands though because finding the big files and deleting them manually helped me to get some space — even if it was only a bit — so that I could install
by running the command
كود: sudo apt-get install ncdu
. Now, running the command
will show you what you need to find out — path being the directory you want to inspect, which on my case path was equal to
. You will see something like this:
Here we go! After I solved the issue, you can see that anaconda3 takes up the most space, but before solving the issue,
took about 4GiB of my memory — that is a lot. Also,
was a big part of the problem.
You now only need to remove the biggest files in these directories. I do not recommend removing all of the content inside them at once, but there are different opinions about it over the internet. But make some research so that you will not be doing something damageable for your computer. So, now, just run
and run
to find which applications’ caches are unnecessarily big. Then, run
where the filename will be the name of the file you want to remove. Also, if
is taking much space too, run
كود: rm -rf ~/.local/share/Trash
to remove all the trash that has been saved — if you don't care about them, of course. If the
file is also taking much space, run
.
After doing all of this and removing the anaconda files I had before and trying running its installer again, the installation succeed, and now I can use it without any problems.
Credits to this helpful article on NCDU that was a light for me:
|