今天我虚拟机提示我满了,,,打开磁盘分析器一看,yum的更新目录满了,本地虚拟跟生产环境的版本完全一致,所以我也不打算更新,找一下命令,得先安装yum-cron ,然后再禁止更新
[root@localhost ~]# vi /etc/yum
[root@localhost yum]# yum install yum-cron -y
[root@localhost yum]# ls
fssnap.d pluginconf.d protected.d vars version-groups.conf yum-cron.conf yum-cron-hourly.conf
[root@localhost yum]# vi yum-cron.conf
开启自动更新
[root@localhost ~]# systemctl start crond
[root@localhost ~]# yum -y install cronie
[root@localhost ~]# yum -y install yum-cron
[root@localhost ~]# systemctl start yum-cron
关闭自动更新
[root@localhost ~]# gedit /etc/yum/yum-cron.conf
update_messages = no
download_updates = no