![apt install vs apt get install apt install vs apt get install](https://i1.wp.com/itsfoss.com/wp-content/uploads/2016/08/Using-apt-get-commands-linux-11.jpg)
The apt-get clean command is generally used to clear disk space as needed, generally as part of regularly scheduled maintenance. You should only have these afterwards: $ sudo ls -lR /var/cache/apt/archivesĭrwx- 2 _apt root 4096 Nov 12 07:24 partial
![apt install vs apt get install apt install vs apt get install](https://www.codegrepper.com/codeimages/apt:-command-not-found.png)
var/cache/apt/archives/postfix_3.4.5-1ubuntu1_b You might have a number of files in the directory prior to running the clean operation: /var/cache/apt/archives/db5.3-util_5.3.28+dfsg1-0.6ubuntu1_b The only files it leaves in /var/cache/apt/archives are the lock file and the partial subdirectory. The directories it cleans out are /var/cache/apt/archives/ and /var/cache/apt/archives/partial/. The apt-get clean command clears the local repository of retrieved package files that are left in /var/cache. These commands clean up after apt-get's installation operations and remove files that are still on your system but are no longer needed – often because the application that required them is no longer installed.
![apt install vs apt get install apt install vs apt get install](https://techsmagic.com/wp-content/uploads/2021/11/1-47.png)
On the other hand, how often do you use apt-get clean, apt-get autoclean or apt-get autoremove?
Apt install vs apt get install update#
Packages are updated fairly frequently and commands like apt-get update and apt-get upgrade make the process quite easy. If you don’t need Python 2.Running apt-get commands on a Debian-based system is routine.
![apt install vs apt get install apt install vs apt get install](https://itsfoss.com/wp-content/uploads/2016/08/Using-apt-get-commands-linux-07.jpg)
Note: Make sure you already have enabled the universe repo given in Step 2 of this article and have Python 2 on your system. Now, if you are also interested in Pip 2 then here are the commands to follow. To select, just enter the number given corresponding to each version path under the Selection column and hit the Enter key. You will get something like the below screenshot with the choice to set one at the priority. In the future, if you want to set Python 3 as default or first version in the priority list, simply update the alternatives list, using this command: sudo update-alternatives -config python Now, check the default version: python -V Sudo update-alternatives -install /usr/bin/python python /usr/bin/python3 2 Sudo update-alternatives -install /usr/bin/python python /usr/bin/python2 1 Thus, we change the priority and set Python2 at the top so that it could call by applications as the default version. However, by default, the system will give priority to Python3, and that’s when we run python command it will give an error: Command 'python' not found, did you mean:Ĭommand 'python' from deb python-is-python3 You will see both python 2.7 and 3 on your Ubuntu 20.04 Linux. See all available Python version on the systemĪs we know Ubuntu 20.04 comes out of the box with Python 3 thus, let’s check what are the available versions of Python are on our system. To view the current version of Python on your system run: python2 -VĤ. Once done with the above command, its time to install Python 2.7 version on Ubuntu Linux, for that, follow this syntax: sudo apt install python2-minimal It is quite possible that your system would already have the Universe repository, still run the below command to add or confirm it.
Apt install vs apt get install how to#
Open a command terminalĪlthough everybody is familiar with how to run the command terminal, however, those who don’t know can use the shortcut key combination i.e Ctrl+Alt+T. Install Python 2.7 on Ubuntu 20.04 LTS Linux and make it default 1. See all available Python version on the system