2.2.1 linux软件管理: redhat 体系的软件管理 :yum(Yellow dog Updater,Modified)
yum常用命令
yum -y install ##安装
yum -y reinstall ##重新安装
yum -y remove ##卸载
yum search ##查询
yum repolist ##现在配置的源
yum update ##更新package
yum list "<regex>" ##列出安装包和未安装包
yum源地址
/etc/yum.repos.d/epel-testing.repo
/etc/yum.repos.d/CentOS-fasttrack.repo
/etc/yum.repos.d/docker-ce.repo
/etc/yum.repos.d/CentOS-Base.repo
/etc/yum.repos.d/elrepo.repo
/etc/yum.repos.d/epel.repo
/etc/yum.repos.d/CentOS-Debuginfo.repo
/etc/yum.repos.d/CentOS-Media.repo
/etc/yum.repos.d/CentOS-Vault.repo
yum 命令详解
check Check for problems in the rpmdb #检查rpmdb的问题
check-update Check for available package updates #检查可用的package更新
clean Remove cached data #移除缓存的data
deplist List a package's dependencies #list 包的依赖关系
distribution-synchronization Synchronize installed packages to the latest available versions
downgrade downgrade a package #降级一个package
erase Remove a package or packages from your system #从你的系统中移除一个package
groupinfo Display details about a package group #展示package组的细节
groupinstall Install the packages in a group on your system #在你的系统中安装package
grouplist List available package groups # 展示可用的package 组
groupremove Remove the packages in a group from your system #从你的系统中的一个组中移除package
help Display a helpful usage message
history Display, or use, the transaction history #展示或者使用事务历史
info Display details about a package or group of packages
install Install a package or packages on your system #在你的系统中安装package
list List a package or groups of packages #展示一个package或者package的group
load-transaction load a saved transaction from filename
makecache Generate the metadata cache #生成一个元数据缓存
provides Find what package provides the given value #查找提供指定value的package
reinstall reinstall a package #重新安装一个package
repolist Display the configured software repositories #显示configured software源
resolvedep Determine which package provides the given dependency
search Search package details for the given string #查询给定string的package的detail
shell Run an interactive yum shell #run 交互式的yum shell
update Update a package or packages on your system #update package on system
upgrade Update packages taking obsoletes into account
version Display a version for the machine and/or available repos. dispaly #机器或者源的version
Options:
-h, --help show this help message and exit
-t, --tolerant be tolerant of errors
-C, --cacheonly run entirely from system cache, don't update cache
-c [config file], --config=[config file]
config file location
-R [minutes], --randomwait=[minutes]
maximum command wait time
-d [debug level], --debuglevel=[debug level]
debugging output level
--showduplicates show duplicates, in repos, in list/search commands
-e [error level], --errorlevel=[error level]
error output level
--rpmverbosity=[debug level name]
debugging output level for rpm
-q, --quiet quiet operation
-v, --verbose verbose operation
-y, --assumeyes answer yes for all questions #所有的问题回复yes
--assumeno answer no for all questions
--version show Yum version and exit
--installroot=[path] set install root
--enablerepo=[repo] enable one or more repositories (wildcards allowed)
--disablerepo=[repo] disable one or more repositories (wildcards allowed)
-x [package], --exclude=[package]
exclude package(s) by name or glob
--disableexcludes=[repo]
disable exclude from main, for a repo or for
everything
--obsoletes enable obsoletes processing during updates
--noplugins disable Yum plugins
--nogpgcheck disable gpg signature checking
--disableplugin=[plugin]
disable plugins by name
--enableplugin=[plugin]
enable plugins by name
--skip-broken skip packages with depsolving problems
--color=COLOR control whether color is used
--releasever=RELEASEVER
set value of $releasever in yum config and repo files
--downloadonly don't update, just download
--downloaddir=DLDIR specifies an alternate directory to store packages
--setopt=SETOPTS set arbitrary config and repo options
Plugin Options: