How to automaticly upgrade security patches?

Asked by Ralph Ulrich

Before ubuntu-9.04
I made this "/etc/rc.local" to get automaticly security patches
-----------
#!/bin/sh -e
apt-get update && aptitude -y safe-upgrade
exit 0
-----------

But having nowadays this does not update the package lists.
What is the new official way to auto security upgrade without any user with sudo/root credentials present (I don't want my mom to get admin rights)?

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Steven Danna (ssd7) said :
#1

This functionality is actually present in the software-sources tool and
shouldn't require any custom scripts. Try the following:

1) Open System->Administration->Software Sources
2) Goto the "Updates" tab
3) In the "Automatic Updates" section ensure that "Check for updates" is
checked and set to daily.
4) In that same section, ensure "Install security updates without
confirmation" is toggled.

I hope this helps.

Revision history for this message
Ralph Ulrich (eulenreich) said :
#2

But the user (my mom) using the machine does not have sudo permissions ?

Revision history for this message
Steven Danna (ssd7) said :
#3

That is a system-wide setting, so once the administrator sets it up, it
should just work in the background as far as I know. There is a daily cron
job that will be run as root that reads the setting set by that program, so
it will install all security updates in the background silently and check
for updates every day without your mom's intervention at all. In fact, as
long as the machine is on, even if she isn't logged in, this should work.

Can you help with this problem?

Provide an answer of your own, or ask Ralph Ulrich for more information if necessary.

To post a message you must log in.