Yum is a background program used to manage rpm packages. it is written in python and can easily solve rpm dependencies. After the yum server is created, the yum client can obtain the software package through http and ftp, and directly manage and update all the rpm packages, even including kernel updates, using convenient commands. It can also be understood as an apt management tool in the Hongqi environment. 1. list package files list all the rpm packages that can be installed or updated in the resource library # List specific
Yum is a background program used to manage rpm packages. it is written in python and can easily solve rpm dependencies. After the yum server is created, the yum client can obtain the software package through http and ftp, and directly manage and update all the rpm packages, even including kernel updates, using convenient commands. It can also be understood as an apt management tool in the Hongqi environment.
I. list package files
List all rpm packages that can be installed or updated in the Resource Library
# Yum list
List specific rpm packages that can be installed, updated, and installed in the Resource Library
# Yum list perl // list the packages named perl
# Yum list perl * // list packages starting with perl
List all updates to the rpm package in the Resource Library
# Yum list updates
List all installed rpm packages
# Yum list installed
List rpm packages installed but not included in the Resource Library
# Yum list extras
Note: extras is the name of the resource list defined in repos. d.
II. list resource information
Lists information about all rpm packages that can be installed or updated in the resource library.
# Yum info
Lists the specific information of rpm packages that can be installed or updated and installed in the resource library.
# Yum info perl // list perl package information
# Yum info perl * // list information of all packages starting with perl
Lists information about all the rpm packages that can be updated in the resource library.
# Yum info updates
Lists information about all installed rpm packages.
# Yum info installed
Lists the installed rpm packages that are not included in the resource library.
# Yum info extras
III. search
Search for rpm packages matching specific characters
# Yum search perl // search for the package name and package description
Search for rpm packages with specific file names
# Yum provides realplay
IV. management package
Install the rpm Package
# Yum install perl // install the perl package
# Yum install perl * // install a package starting with perl
Delete an rpm package, including packages that depend on the package
# Yum remove perl * // All perl-* packages are deleted.
5. Update
Check the updatable rpm Package
# Yum check-update
Update all rpm packages
# Yum update
Update the specified rpm package, such as updating the kernel and kernel source
# Yum update kernel-source
For large-scale version upgrades, unlike yum update, the old obsolete package is also upgraded.
# Yum upgrade
6. clear cache
Clear temporary rpm Package files
# Yum clean packages
Clear temporary rpm header files
# Yum clearn headers
Clear the existing rpm header file
# Yum clean oldheaders
Clear existing rpm header files and package files
# Yum clearn
Or
# Yum clearn all
VII. others
Install Livna.org rpms GPG key
# Rpm -- import http://rpm.livna.org/RPM-LIVNA-GPG-KEY
Check GPG Key
# Rpm-qa gpg-pubkey *
Show Key Information
# Rpm-qi gpg-pubkey-a109b1ec-3f6e28d5
Delete Key
# Rpm e gpg-pubkey-a109b1ec-3f6e28d5