(1)挂载光盘
# mount /dev/cdrom /mnt
(2)删除/etc/yum.repos.d目录下所有的repo文件
# cp -r /etc/yum.repos.d /etc/yum.repos.d_bak
# rm -rf /etc/yum.repos.d/*
(3)创建新文件dvd.repo
# vim /etc/repos.d/dvd.repo
[dvd]
name=install dvd
baseurl=file:///mnt
enabled=1
gpgcheck=0
(4)刷新repos生成缓存
# yum makecache
(5)使用yum命令测试安装所需的包
# yum install -y tftp