我意外删除了 /etc/apt/apt.conf.d/20auto-upgrades

我意外删除了 /etc/apt/apt.conf.d/20auto-upgrades

我删除了这个文件/etc/apt/apt.conf.d/20auto-upgrades。我以为它是一个交换文件。我该怎么办?重新安装 unattended-upgrades apt 不起作用。

/usr/sbin/dpkg-reconfigure: unattended-upgrades is broken or not fully installed root@****:/var/log/unattended-upgrades#

答案1

尝试这个:

打开终端,

Ctrl++AltT

运行:

sudo -i
nano /etc/apt/apt.conf.d/20auto-upgrades

在打开的文件中粘贴以下行:

APT::Periodic::Update-Package-Lists "1";
APT::Periodic::Unattended-Upgrade "1";

Ctrl+O

保存存档

Ctrl+X

关闭纳米

相关内容