They offer different flash templates with latest features.
Login

Forgot password
Register
Back
Written by:
Alexio
Score: 20
votes: 22
Format: Article

 How to enable unattended software updates on Linux Mint


Installation of software updates are very important in every operating system. We can either configure the installation of package updates manually or automatically in Linux Mint. This tutorial explains you how to enable the installation of software package updates automatically in the Ubuntu-based editions of Linux Mint.

Open your terminal and run the update:

sudo apt-get update

Install the “unattended-upgrades” package:

sudo apt-get install unattended-upgrades

This is the package used to install the updated packages automatically.

The configuration files are located at /etc/apt/apt.conf.d

To configure the unattended-upgrades edit the /etc/apt/apt.conf.d/50unattended-upgrades file and make changes according to your need: 

// Automatically upgrade packages from these (origin, archive) pairs 

Unattended-Upgrade::Allowed-Origins { 

"${distro_id} ${distro_codename}-security"; 

// "${distro_id} ${distro_codename}-updates"; 

// "${distro_id} ${distro_codename}-proposed"; 

// "${distro_id} ${distro_codename}-backports"; 

}; 

Note : “ // “ is a comment line. So whatever follows by the comment line ( // ) cannot be evaluated.

To enable the updates simply remove the comment line ( // ).

If you dont want to install the software updates for certain packages, just add those package names in the Blacklist:

// List of packages to not update 

Unattended-Upgrade::Package-Blacklist { 

// "vim"; 

// "libc6"; 

// "libc6-dev"; 

// "libc6-i686"; 

}; 

The results of unattended-upgrades will be logged to /var/log/unattended-upgrades

To enable automatic updates, edit /etc/apt/apt.conf.d/10periodic and set the appropriate apt configuration options:

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

APT::Periodic::Download-Upgradeable-Packages "0"; 

APT::Periodic::AutocleanInterval "30"; 

APT::Periodic::Unattended-Upgrade "1"; 

The above configuration updates the package list, downloads, and installs available upgrades every day.

The local download archive is cleaned every thirty days.

Note : Here the number represents the days.


Tags: update automatic unattended
Created: 1 year ago.
Last edited: 1 year ago.
Reviewed: 1 year ago.
Read 0 times.

Comments
1 month ago

pulsatorius
I didn't have any etc/apt/apt.conf.d/10periodic so I created it. Was this the right move? Should it be included in the instructions?  
3 months ago

BenJetson
I got this working on my LM 17 system. Here's whats in my "/etc/apt/apt.conf.d/50unattended-upgrades" file:

http://paste.ubuntu.com/8218593/
 
7 months ago

drewkeller
I don't see a way to edit my comment. The format for allowed origins entry should be in the format "origin:suite" as shown in the _Release file (the way I posted it before got clobbered).  
7 months ago

drewkeller
For newer versions of Mint, you may need to change the allowed origins section. You can do a dry run, like this...

> sudo unattended-upgrade --dry-run
- Check the log in /var/log/unattended-upgrades/

To determine what origins you need, , look in /var/lib/apt/lists/. Files that end in "_Release" are candidates for sources. Add desired update sources in the format ":" as shown in the release file (open the file to see).

So you might have a section like this (Linux Mint 16 Petra)....

// Automatically upgrade packages from these (origin:archive) pairs
Unattended-Upgrade::Allowed-Origins {
"${distro_id}:${distro_codename}-security";
"${distro_id}:${distro_codename}-updates";
"linuxmint:petra"
"Ubuntu:saucy-security";
"Ubuntu:saucy-updates";
// "${distro_id}:${distro_codename}-proposed";
// "${distro_id}:${distro_codename}-backports";
};

Note that this doesn't care what level the update is.
 
1 year ago

Maya2013
....but this works well

Mint 13 / XFCE

Unattended-Upgrade::Allowed-Origins {
"${distro_id}:${distro_codename}";
"Ubuntu precise-security";

Result /var/log/unattended-upgrades
o=LinuxMint, a=Maya (get everything for maya)
o=Ubuntu, a=precise-security (only security updates)
 
1 year ago

windyweather
This doesn't work. After a couple of days I find the shield has an "i" in it and the updates were not installed. Something is left out for LM 14.

No Joy for automatic updates.
ww
 
1 year ago

windyweather
Minor issue I think.
I'm trying this on LM 14 and I don't find the 10periodic file.
Do I need to create that file?
Guess I'll create it with the contents you suggest.
ww
 
1 year ago

AshBaby
Thanks, very concise and clear.  
1 year ago

sujitnag
very impotent information  
1 year ago

Hammer459
Nice and clear tutorial  
1 year ago

telcnas
thanks for this nice info...... :)  

Other tutorials from Alexio