Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Assume I need to write a cron job to automate the installation of security update daily, which command I should use for better reliability?

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

You don't need a cron job to install security update. unattended-upgrade do it for you, automatically. From its description in pkg on Ubuntu 12.04

 This package can download and install security upgrades automatically
 and unattended, taking care to only install packages from the
 configured APT source, and checking for dpkg prompts about
 configuration file changes.

you just need install it, then

dpkg-reconfigure unattended-upgrades 

then, choose "YES" and let it do its jobs.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.