Difference between revisions of "Operating Systems/Linux/Ubuntu/Ubuntu 16.04 LTS/Updates"
(→GUI) |
(Added CLI method of setting up automatic updates on Ubuntu) |
||
| Line 28: | Line 28: | ||
===CLI=== | ===CLI=== | ||
| + | (Not recommended if the GUI works) | ||
| − | + | 1. sudo apt install unattended-upgrades (this will most likely be preinstalled) | |
| + | |||
| + | 2. Ensure that it's configured correctly. run the command "sudo nano /etc/apt/apt.conf.d/50unattended-upgrades". Find the line that says "Unattended-Upgrade::Allowed-Origins", and look inside of its curly braces. Uncomment any lines including "${distro_codename}", but keep lines that end with "-proposed" or "-backports" commented. This will ensure that only security and recommended updates will be installed. | ||
| + | |||
| + | 3. sudo nano /etc/apt/apt.conf.d/20auto-upgrades. Set each line equal to "1" (with the quotation marks). This will tell it to update and upgrade each day. | ||
| + | |||
| + | 4. sudo systemctl enable unattended-upgrades && sudo systemctl start unattended-upgrades | ||
Revision as of 16:13, 19 November 2023
Why do we Need Updates
While some updates just deliver additional functionality or general bug fixes some updates patch critical security flaws; because of this it is always in the best interest of the user's security to have checks for updates ran constantly.
How to install Updates
GUI
- Search for
Software Updater - Follow the prompts that it gives you
- Alternatively, redownload
CLI
- sudo apt update
- This gets a list of what items can be updated
- sudo apt upgrade
- This updates based off the list from apt update
- reboot the system (optional)
While it's not required to use apt-fast, it's recommended as it can greatly decrease the amount of time when updating.
How to Check for Updates Automatically
Have updates installed without the need for manual action.
GUI
- Navigate to the
Updatessection in the settings app - Change "automatically check for updates" from
NevertoDaily
CLI
(Not recommended if the GUI works)
1. sudo apt install unattended-upgrades (this will most likely be preinstalled)
2. Ensure that it's configured correctly. run the command "sudo nano /etc/apt/apt.conf.d/50unattended-upgrades". Find the line that says "Unattended-Upgrade::Allowed-Origins", and look inside of its curly braces. Uncomment any lines including "${distro_codename}", but keep lines that end with "-proposed" or "-backports" commented. This will ensure that only security and recommended updates will be installed.
3. sudo nano /etc/apt/apt.conf.d/20auto-upgrades. Set each line equal to "1" (with the quotation marks). This will tell it to update and upgrade each day.
4. sudo systemctl enable unattended-upgrades && sudo systemctl start unattended-upgrades