“『YUM COMMAND CHEAT SHEET』”的版本间差异
无编辑摘要  | 
				无编辑摘要  | 
				||
| 第50行: | 第50行: | ||
Get info on available security updates<br/>  | Get info on available security updates<br/>  | ||
|-  | |-  | ||
|   | | grouplist  | ||
|    | | ''List names of installed and available package groups''  | ||
|-  | |-  | ||
|   | | groupinfo  | ||
|    | | ''Display description and contents of a package group''  | ||
'''yum groupinfo “Web Server”'''<br/>  | |||
See packages in Web Server group<br/>  | |||
|-  | |-  | ||
|   | | check-update  | ||
|    | | ''Query repositories for available package updates''  | ||
|-  | |-  | ||
! colspan="2"| INSTALL, REMOVE AND UPGRADE PACKAGES WITH YUM  | ! colspan="2"| INSTALL, REMOVE AND UPGRADE PACKAGES WITH YUM  | ||
|-  | |-  | ||
|    | | install  | ||
|    | | ''Install a package from a repository to your system''  | ||
'''yum install vsftpd'''<br/>  | |||
Install the vsftpd package<br/>  | |||
|-  | |-  | ||
|    | | update  | ||
|    | | ''Update one or all packages on your system''  | ||
'''yum update'''<br/>  | |||
Update all packages with available updates<br/>  | |||
'''yum update httpd'''<br/>  | |||
Update the httpd package (if available)<br/>  | |||
'''yum update --security'''<br/>  | |||
Apply security-related package updates<br/>  | |||
|-  | |||
| update-to  | |||
| ''Update one or all packages to a particular version''  | |||
|-  | |||
| upgrade  | |||
| ''Update packages taking obsoletes into account''  | |||
|-  | |||
| localinstall  | |||
| ''Install a package from a local file, http, or ftp''  | |||
'''yum localinstall abc-1-1.i686.rpm'''<br/>  | |||
Install abc package from local directory<br/>  | |||
'''yum localinstall http://myrepo/abc-1-1.i686.rpm'''<br/>  | |||
Install abc from FTP site<br/>  | |||
|-  | |||
| downgrade  | |||
| ''Downgrade a package to an earlier version''  | |||
'''yum downgrade abc'''<br/>  | |||
Downgrade the abc package to an earlier version<br/>  | |||
|-  | |||
| reinstall  | |||
| ''Reinstall the current version of a package''  | |||
'''yum reinstall util-linux'''<br/>  | |||
Reinstall util-linux (to replace any deleted files)<br/>  | |||
|-  | |||
| swap  | |||
| ''Remove one package and install another''  | |||
'''yum swap ftp lftp'''<br/>  | |||
Remove ftp package and install lftp package<br/>  | |||
|-  | |||
| erase  | |||
| ''Erase a package (and possibly dependencies) from your system''  | |||
'''yum remove vsftpd'''<br/>  | |||
Remove the vsftpd package and dependencies<br/>  | |||
|-  | |||
| remove  | |||
| ''Same as erase''  | |||
|-  | |||
| autoremove  | |||
| ''Same as erase, plus removes additional unneeded packages *''  | |||
'''yum autoremove httpd'''<br/>  | |||
Remove httpd and other unneeded packages<br/>  | |||
|-  | |||
| groupinstall  | |||
| ''Install all packages in the selected group''  | |||
yum groupinstall “Web server”<br/>  | |||
Install Web Server packages<br/>  | |||
|-  | |-  | ||
! colspan="2"| TROUBLESHOOT AND MAINTAIN YUM  | ! colspan="2"| TROUBLESHOOT AND MAINTAIN YUM  | ||
2020年10月15日 (四) 23:40的版本
Download YUM COMMAND CHEAT SHEET for Red Hat Enterprise Linux
| SUBCOMMAND | DESCRIPTIONS AND TASKS | 
|---|---|
| YUM QUERIES | |
| help | Display yum commands and options
 yum help  | 
| list | List package names from repositories
 yum list available  | 
| info | Display information about a package
 yum info vsftpd  | 
| deplist | Display dependencies for a package
 yum deplist nfs-utils  | 
| provides | Find packages that provide the queried file
 yum provides “*bin/top”  | 
| search | Search package names and descriptions for a term
 yum search samba  | 
| updateinfo | Get information about available package updates
 yum updateinfo security  | 
| grouplist | List names of installed and available package groups | 
| groupinfo | Display description and contents of a package group
 yum groupinfo “Web Server”  | 
| check-update | Query repositories for available package updates | 
| INSTALL, REMOVE AND UPGRADE PACKAGES WITH YUM | |
| install | Install a package from a repository to your system
 yum install vsftpd  | 
| update | Update one or all packages on your system
 yum update  | 
| update-to | Update one or all packages to a particular version | 
| upgrade | Update packages taking obsoletes into account | 
| localinstall | Install a package from a local file, http, or ftp
 yum localinstall abc-1-1.i686.rpm  | 
| downgrade | Downgrade a package to an earlier version
 yum downgrade abc  | 
| reinstall | Reinstall the current version of a package
 yum reinstall util-linux  | 
| swap | Remove one package and install another
 yum swap ftp lftp  | 
| erase | Erase a package (and possibly dependencies) from your system
 yum remove vsftpd  | 
| remove | Same as erase | 
| autoremove | Same as erase, plus removes additional unneeded packages *
 yum autoremove httpd  | 
| groupinstall | Install all packages in the selected group
 yum groupinstall “Web server”  | 
| TROUBLESHOOT AND MAINTAIN YUM | |
| MANAGE YUM REPOSITORIES | |
| MANAGE LANGUAGE PACKAGES WITH YUM | |
| POPULAR OPTIONS FOR DIFFERENT YUM COMMANDS ** | |
| MORE YUM-RELATED COMMANDS (install the yum-utils package) | |