2

How do I automatically start Ubuntu Update Manager on a particular time of the day and make it download updates ?

Similarly, do I automatically update installed softwares (Ubuntu Software Center) on a particular time of the day and make downloads?

5
+50

You can either set apt-get to update and upgrade in cron.daily or you could simply use cron-apt. There is also an unattended-upgrades package but I haven't used it.

Unless there is a reason that you only want to work with the Ubuntu Update-Manager/Software-Center, although I can't see why.

It's an issue that has been answered in various locations, so here are some references:

  • What is the command to start the Update Manager and to tell to install? What is the command to start the automatic update in software center installed software? – Optimight Jul 2 '12 at 10:54
  • I am trying to use 'Schedule tasks' downloaded from Ubuntu 12.04 LTS Software Center. – Optimight Jul 2 '12 at 10:57
  • @gladiator2345 I appreciate Astyanax's answer. But I was looking for specific instructions like I have put in my answer today. After following the answer by Astyanax,which was very helpful to find the solution, but I struggled to get the actual solution. – Optimight Jul 6 '12 at 23:54
0

You might want to take a look at unattended upgrades. While that doesn't say anything about when they will take place, another good howto can be found here which works without additional software, and to me looks more like a direct answer to your question. Though you might want to substitute the cron-part from "daily" to something more precise. You might heck this Cron Howto for details on how to handle that.

0

Install cron-apt:

sudo apt-get install cron-apt

Edit config-file:

sudo gedit /etc/cron.d/cron-apt

comment the line: (put '#' in front of it)

0 0 * * * root test -x /usr/sbin/cron-apt && /usr/sbin/cron-apt

Add these lines to the end of the file:

Every day (midnight)

0 0 * * * root test -x /usr/sbin/cron-apt && /usr/sbin/cron-apt

Save the file.

For more information see: https://help.ubuntu.com/community/CronHowto

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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