yumdownloader
yum 源安装非常方便解决依赖包问题,但是有时当你只需要下载安装包和依赖包时就用到了 yumdownloader,该命令是在yum-untils组件中
yum install yum-utils
例如:yumdownloader nfs-utils --destdir /tmp/nfs-utils --resolve
--destdir 指定下载目录
--resolve 同时下载相关的rpm依赖包

例如
[root@test tmp]# yumdownloader nfs-utils --destdir /tmp/nfs/ --resolve

Loaded plugins: product-id
No Match for argument downloaded_rpms
--> Running transaction check
---> Package nfs-utils.x86_64 1:1.2.3-78.el6_10.1 will be installed
--> Processing Dependency: libtirpc >= 0.2.1-11 for package: 1:nfs-utils-1.2.3-78.el6_10.1.x86_64
--> Processing Dependency: python-argparse for package: 1:nfs-utils-1.2.3-78.el6_10.1.x86_64
--> Running transaction check
---> Package libtirpc.x86_64 0:0.2.1-6.el6_4 will be updated
---> Package libtirpc.x86_64 0:0.2.1-15.el6 will be an update
---> Package python-argparse.noarch 0:1.2.1-2.1.el6 will be installed
--> Finished Dependency Resolution
nfs-utils-1.2.3-78.el6_10.1.x86_64.rpm | 337 kB 00:00
libtirpc-0.2.1-15.el6.x86_64.rpm | 82 kB 00:00
python-argparse-1.2.1-2.1.el6.noarch.rpm | 48 kB 00:00
[root@test tmp]# cd nfs/
[root@test nfs]# ls
libtirpc-0.2.1-15.el6.x86_64.rpm nfs-utils-1.2.3-78.el6_10.1.x86_64.rpm python-argparse-1.2.1-2.1.el6.noarch.rpm