1.安装yum-downloadonly # yum install yum-downloadonly -y 2.下载到指定目录 # yum install rpm包 -y --downloadonly --downloaddir=(下载路径)