CentOS: yum Usage Details, centosyum details
The yum in CentOS is very powerful. You can use the yum installation software to know that the dependency is automatically resolved and the installation is not on duty.
The installation command is yum install ~, Yum queries the database to see if this software package exists. If yes, it checks its dependency conflicts. If no dependency conflict exists, download and install it. If yes, a prompt is displayed, you can determine whether to install dependencies or delete conflicting packages at the same time. The DELETE command is yum remove ~, Like the installation, yum also queries the database and provides a prompt to solve the dependency.
yum install ~
yum remove ~
Since yum has the installation and uninstallation functions, it naturally also has a query function. Using the yum query function, you can quickly obtain the software installation details of the system.
1. Use YUM to find the Software Package
Command: yum search ~
2. List all installable software packages
Command: yum list
3. list all updatable software packages
Command: yum list updates
4. list all installed software packages
Command: yum list installed
5. list all software packages installed but not in Yum Repository
Command: yum list extras
6. List the specified software packages
Command: yum list ~
7. Use YUM to obtain the software package information
Command: yum info ~
8. list information about all software packages
Command: yum info
9. list information of all updatable software packages
Command: yum info updates
10. list information about all installed software packages
Command: yum info installed
11. list information about all software packages installed but not in Yum Repository
Command: yum info extras
12. List the files provided by the Software Package
Command: yum provides ~
Generally, yum stores the downloaded software package and header in the cache. If we think they occupy disk space, we can use the yum clean command to clear them. More accurately, we use yum clean headers to clear the header and yum clean packages to clear the downloaded rpm package, yum clean all clear all.
1. command: yum clean packages 2. run the yum clean headers command in the/var/cache/yum directory to clear the headers. clear the old headers command in the cache directory (/var/cache/yum): yum clean oldheaders 4. clear the software packages in the cache directory (/var/cache/yum) and the old headers command: yum clean, yum clean all (= yum clean packages; yum clean oldheaders)
Yum commands:
Yum update upgrade system yum install ~ Install the specified Software Package yum update ~ Upgrade the specified Software Package yum remove ~ Uninstall the specified software yum grouplist to view the installed and available software groups in the system. If available, you can install yum grooupinstall ~ Install a yum grooupupdate ~ in the available software group displayed in the previous command ~ Update the software package yum grooupremove ~ of the specified software group ~ Uninstall the software package yum deplist ~ in the specified Software Group ~ Query the dependency yum list yum \ * of the specified software package to list all software packages starting with yum localinstall ~ Install the rpm package from the hard disk and use yum to solve the dependency