+5 votes
232 views
Install Ubuntu Server security updates

in Linux / Unix by (551k points)
reopened | 232 views

1 Answer

+3 votes
Best answer

1. How to install security updates on Ubuntu Server
2. How to update a single package on Ubuntu Server
3. How to update Ubuntu system globally
4. How to automatically install the latest security updates on Ubuntu Server

Updates play an essential role in any operating system, but when we talk about exclusive systems for servers , such as Ubuntu Server, this task becomes vital since these teams are in charge of maintaining interaction in the company and it is for this reason, developers frequently release security updates to preserve both the security and the availability of the information hosted on the server..

 

 

TechnoWikis will explain to you how we can update our Ubuntu Server at the security level and thus have the certainty that both the services and the information will be protected.

 


1. How to install security updates on Ubuntu Server


If the update-notifier-common package has been installed on our server, the Ubuntu Server will generate an alert associated with the updates that are pending using the motd (message of the day) function directly in the console.

 

In this case we can analyze if there are new updates with the command:

 sudo apt update 
image

 


2. How to update a single package on Ubuntu Server

 

Step 1

Ubuntu Server gives us the possibility to verify and update a single package but not all those installed in the system, in this case it is required to use the "install" command like this:
 sudo apt install "package" 
image

 

Step 2

This is responsible for installing the package in its latest available version or updating it if we have an old version, in case there is no more recent update we will see this:

 

image

 


3. How to update Ubuntu system globally


This is a mechanism that checks for and installs available updates.

 

Step 1

First, we must look for updates with the following command:
 sudo apt list –upgradable 
image

 

Step 2

To apply these updates we execute the following:
 sudo apt-get dist-upgrade 
image

 

There we must enter the letter "S" to confirm the download and installation of these updates..

 


4. How to automatically install the latest security updates on Ubuntu Server

 

Step 1

We have the possibility of making use of the unattended update package "unattended-upgrades" which is responsible for analyzing and applying the updates as they are available, to install it we execute the following:
 sudo apt install unattended-upgrades 
image

 

Step 2

Once installed we will apply the automatic updates with the following order:
 sudo dpkg-reconfigure unattended-upgrades 
We will see that the following is displayed. We click on "Yes" to confirm the automatic task.

 

 

image

 

 

Updates can restart Ubuntu Server services affecting the critical operation of the company, so we must be careful with these types of updates.

 

Step 3

You can run unattended updates manually with the following command:
 sudo unattended-upgrade 
image

 

Step 4

We can add the -d parameter in order to enable debugging mode:
 sudo unattended-upgrade -d 
Security updates are important to maintain optimal server performance and with TechnoWikis you have learned to configure them either manually or automatically in Ubuntu Server.

 


by (3.5m points)

Related questions

+3 votes
1 answer
asked Apr 27, 2020 in Linux / Unix by backtothefuture (551k points) | 420 views
+5 votes
1 answer
+4 votes
1 answer
asked Oct 14, 2019 in Linux / Unix by backtothefuture (551k points) | 234 views
+3 votes
1 answer
+4 votes
1 answer
asked Sep 29, 2020 in Linux / Unix by backtothefuture (551k points) | 1.4k views
Sponsored articles cost $40 per post. You can contact us via Feedback
10,634 questions
10,766 answers
510 comments
3 users