At first, only .tar.gz was in the GNU/linuxsystem. Users must compile each program they want to use. After the appearance of Debian, it was considered necessary to add a computer system to manage software packages installed on computers. This system is called dpkg. The named 'package' appears on GNU/Linux for the first time. Soon afterwards, red hats began to build their own package management system 'rp '.
The creators of GNU/Linux soon fell into a new dilemma. They want to install software packages in a fast, practical, and efficient way. These software packages can automatically process dependencies between each other and maintain their configuration files during the upgrade process. Debian once again acts as a pioneer. She pioneered APT (Advanced Packaging Tool ). This tool is then transplanted to the Red Hat system by Conectiva for managing rpm packages. We can also see her figure in other releases.
"At the same time, apt is a complete and advanced software package management program. Using it allows you to find the software package you want, easily and accurately, the installation and uninstallation are simple. It also updates all your software to the latest status and can be used to upgrade ubuntu ."
"Apt is a software that requires commands, but now there are also a lot of graphical software, such as Synaptic, Kynaptic and Adept ."
Command
Sudo is required for all the commands to be introduced below! Replace "packagename" and "string" with the program you want to install or find.
* Apt-get update -- run this command after modifying/etc/apt/sources. list or/etc/apt/preferences. In addition, you need to regularly run this command to ensure that your package list is up-to-date.
* Apt-get install packagename -- install a new software package (see aptitude below)
* Apt-get remove packagename -- uninstall an installed software package (keep the configuration file)
* Apt-get-purge remove packagename -- uninstall an installed software package (delete the configuration file)
* Dpkg-force-all-purge packagename some software is hard to uninstall and can be used if it blocks other software applications, but it is a little risky.
* Apt-get autoclean apt will back up installed or unloaded software on the hard disk. If you need space, you can run this command to delete the software you have deleted.
* The apt-get clean command will also delete the backup of the installed software, but this will not affect the use of the software.
* Apt-get upgrade -- update all installed software packages
* Apt-get dist-upgrade -- upgrade the system to the new version.
* Apt-cache search string -- search for strings in the package list
* Dpkg-l package-name-pattern -- lists all software packages that match the pattern. If you do not know the full name of the software package, you can use "* package-name-pattern *".
* Aptitude -- view the installed or available software packages in detail. Similar to apt-get, aptitude can be called through the command line, but is limited to some commands-the most common commands are installation and uninstallation. Because aptitude knows more information than apt-get, it is more suitable for installation and uninstallation.
* Apt-cache showpkg pkgs -- displays the package information.
* Apt-cache dumpavail -- print the list of available software packages.
* Apt-cache show pkgs -- displays Software Package records, similar to dpkg-print-avail.
* Apt-cache pkgnames -- print the names of all packages in the package list.
* Dpkg-S file -- the package to which the file belongs.
* Dpkg-L package -- list all files in the software package.
* Apt-file search filename -- find a software package containing a specific file (not necessarily installed). The file names of these files contain the specified string. Apt-file is an independent software package. You must first install apt-get install and then run apt-file update. If apt-file search filename outputs too much content, you can try to use apt-file search filename | grep-w filename (only show the names of the complete words in the specified string) or similar methods, such: apt-file search filename | grep/bin/(only files in folders such as/bin or/usr/bin are displayed. If you are looking for a specific execution file, this is helpful ).
* Apt-get autoclean -- run this command regularly to clear the. deb files of uninstalled software packages. In this way, you can release a large amount of disk space. If your requirements are urgent, you can use apt-get clean to release more space. This command will delete the. deb file that has installed the software package. In most cases, you will not use these. debs files. Therefore, if you feel overwhelmed by insufficient disk space, this method may be worth a try.
Typical applications
- I am a racing enthusiast and want to play a racing game. Which racing games are available?
- Apt-cache search racing game
- There are a lot of results. Check whether