查看“『YUM COMMAND CHEAT SHEET』”的源代码
←
『YUM COMMAND CHEAT SHEET』
跳到导航
跳到搜索
因为以下原因,您没有权限编辑本页:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
[[category:Linux]] Download [https://access.redhat.com/sites/default/files/attachments/rh_yum_cheatsheet_1214_jcs_print-1.pdf YUM COMMAND CHEAT SHEET for Red Hat Enterprise Linux] {| class="wikitable" ! SUBCOMMAND !! DESCRIPTIONS AND TASKS |- ! colspan="2"| YUM QUERIES |- | help | ''Display yum commands and options'' '''yum help'''<br/> Show yum subcommands and options<br/> |- | list | ''List package names from repositories'' '''yum list available'''<br/> List all available packages<br/> '''yum list installed'''<br/> List all installed packages<br/> '''yum list all'''<br/> List installed and available packages<br/> '''yum list kernel'''<br/> List installed and available kernel packages<br/> |- | info | ''Display information about a package'' '''yum info vsftpd'''<br/> List info about vsftpd package<br/> |- | deplist | ''Display dependencies for a package'' '''yum deplist nfs-utils'''<br/> List dependencies and packages providing them<br/> |- | provides | ''Find packages that provide the queried file'' '''yum provides “*bin/top”'''<br/> Show package that contains top command<br/> '''yum provides “*/README.top”'''<br/> Show package containing README.top file<br/> |- | search | ''Search package names and descriptions for a term'' '''yum search samba'''<br/> Find packages with samba in name or description<br/> |- | updateinfo | ''Get information about available package updates'' '''yum updateinfo security'''<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 |- | 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 |- | check | ''Check the local RPM database for problems (runs for a long time)'' |- | history | ''View and use yum transactions'' '''yum history list'''<br/> List all yum install, update and erase actions<br/> '''yum history info 3'''<br/> Show details of yum transaction 3<br/> '''yum history undo 3'''<br/> Undo the yum action from transaction 3<br/> '''yum history redo 3'''<br/> Redo the undone yum action from transaction 3<br/> |- | clean | ''Clear out cached package data'' '''yum clean packages'''<br/> Delete packages saved in cache<br/> '''yum clean all'''<br/> Clean out all packages and meta data from cache<br/> |- | fssnapshot | ''List LVM stapshots (helps roll back after package updates)'' |- | fs | ''Act on filesystem (prevent doc or language file install on minimal systems)'' '''yum fs filters'''<br/> List enabled filesystem filters<br/> '''yum fs documentation'''<br/> Filters all docs from being installed (careful!)<br/> |- ! colspan="2"| MANAGE YUM REPOSITORIES |- | repolist | ''Display enabled software repositories'' |- | repoinfo | ''Display information about enabled yum repositories *'' '''yum repoinfo rhel-7-server-rpms'''<br/> See info on rhel-7-server-rpms repo<br/> |- | repo-pkgs | ''Work with packages in a particular repository *'' '''yum repo-pkgs my-rpms list'''<br/> List packages from my-rpms repo<br/> '''yum repo-pkgs my-rpms install'''<br/> Install all packages from my-rpms repo<br/> '''yum repo-pkgs my-rpms remove'''<br/> Remove all packages from my-rpms repo<br/> |- | makecache | ''Download yum repository data to cache'' |- ! colspan="2"| MANAGE LANGUAGE PACKAGES WITH YUM |- | langavailable | ''List all available languages *'' |- | langinfo | ''List packages available for a language *'' '''yum langinfo es'''<br/> List packages associated with Spanish language<br/> |- | langinstall | ''Install packages associated with a particular language *'' '''yum langinstall es'''<br/> Install packages associated with Spanish language<br/> |- | langlist | ''List languages that are installed *'' |- | langremove | ''Remove installed language packs for a language *'' '''yum langremove es'''<br/> Remove packages associated with Spanish language<br/> |- ! colspan="2"| POPULAR OPTIONS FOR DIFFERENT YUM COMMANDS ** |- | -y | ''Assume yes if prompted'' |- | --assumeno | ''Assume no if prompted'' |- | -q | ''Produce no output'' |- | -v | ''Produce extra debugging output'' |- | --noplugins | ''Run command without loading any yum plugins'' |- | --disableplugin= | ''Disable a particular plugin for single command'' '''yum --disableplugin=langpacks info vsftpd'''<br/> |- | --enableplugin= | ''Enable a plugin that is installed, but currently disabled'' '''yum --enableplugin=ps ps'''<br/> Show packages tied to running processes<br/> |- | --enablerepo= | ''Enable currently disabled repo for a single command (wildcards okay)'' '''yum install docker \ --enablerepo=rhel-7-server-extras-rpm'''<br/> |- | --disablerepo= | ''Disable currently enabled repo for a single command (wildcards okay)'' '''yum list available --disablerepo=epel'''<br/> |- | --downloadonly | ''Download to /var/cache/yum/arch/prod/repo/packages/, but don’t install'' '''yum install --downloadonly vsftpd'''<br/> Download vsftpd package to cache<br/> |- | --filter-???= | Replace ??? with vendors, rpm-groups, arches, and others to filter output |- | --changelog | Display changelog information of package |- ! colspan="2"| MORE YUM-RELATED COMMANDS (install the yum-utils package) |- | | |- | | |}
返回至“
『YUM COMMAND CHEAT SHEET』
”。
导航菜单
个人工具
登录
命名空间
页面
讨论
大陆简体
已展开
已折叠
查看
阅读
查看源代码
查看历史
更多
已展开
已折叠
搜索
导航
首页
最近更改
随机页面
MediaWiki帮助
笔记
服务器
数据库
后端
前端
工具
《To do list》
日常
阅读
电影
摄影
其他
Software
Windows
WIKIOE
所有分类
所有页面
侧边栏
站点日志
工具
链入页面
相关更改
特殊页面
页面信息