Debian – How to recreate /etc/cron.daily/apt

aptcron.dailydebianupgrade

On my Debian 6.0.8 system the /etc/cron.daily/apt file is missing. Therefore, unattended upgrades do not work.

How can I recreate/fix /etc/cron.daily/apt?

Best Answer

first find which package contains the missing file:

$ dpkg --search /etc/cron.daily/apt
apt: /etc/cron.daily/apt

which is that case is the package "apt", and then re-install it:

$ sudo apt-get -o Dpkg::Options::="--force-confmiss" --reinstall install apt

edit: added the option to force the miss conf