How To Update CentOS 7.0/7.1/7.2/7.3/7.4 to CentOS 7.5

1

CentOS has released its major release of CentOS 7.5 on 10 May 2018, a month later the release of RHEL 7.5. Since from the day of release, you might be looking for upgrading the current version to latest CentOS release.

This post is mainly focusing on upgrading the previous version of CentOS 7.x to the latest version (Centos 7.5 at the time writing). Before going to update, let’s take a look at the main changes in the latest version.

Major changes

  1. CentOS can report bugs directly to bugs.centos.org via new abrt release.
  2. OpenSSL now compiled with OpenSSL instead of NSS
  3. Supports High Availability clusters of virtual machines (VMs) on Amazon Web Services and Microsoft Azure

See CentOS 7.5 release note for more information.

Before performing the OS upgrade, it is recommended to take a backup of important files to secure location.

Update CentOS 7.0/7.1/7.2/7.3/7.4 to CentOS 7.5

Check the current version of your release.

cat /etc/redhat-release

Output:

CentOS Linux release 7.4.1708 (Core)

From the above, you can see that my machine is running CentOS 7.4.

Now, let’s look at what are the updates available for your system.

yum check-update

Output:

The following are the updates available for my machine.

Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
 * base: centos.excellmedia.net
 * extras: centos.excellmedia.net
 * updates: centos.excellmedia.net

NetworkManager.x86_64                                          1:1.10.2-16.el7_5                                updates
NetworkManager-adsl.x86_64                                     1:1.10.2-16.el7_5                                updates
NetworkManager-bluetooth.x86_64                                1:1.10.2-16.el7_5                                updates
NetworkManager-glib.x86_64                                     1:1.10.2-16.el7_5                                updates
NetworkManager-libnm.x86_64                                    1:1.10.2-16.el7_5                                updates
NetworkManager-ppp.x86_64                                      1:1.10.2-16.el7_5                                updates
NetworkManager-team.x86_64                                     1:1.10.2-16.el7_5                                updates
NetworkManager-tui.x86_64                                      1:1.10.2-16.el7_5                                updates
NetworkManager-wifi.x86_64                                     1:1.10.2-16.el7_5                                updates
NetworkManager-wwan.x86_64                                     1:1.10.2-16.el7_5                                updates
acl.x86_64                                                     2.2.51-14.el7                                    base
alsa-lib.x86_64                                                1.1.4.1-2.el7                                    base

.     .     .
.     .     .

tuned.noarch                                                   2.9.0-1.el7                                      base
tzdata.noarch                                                  2018e-3.el7                                      updates
util-linux.x86_64                                              2.23.2-52.el7                                    base
vim-minimal.x86_64                                             2:7.4.160-4.el7                                  base
virt-what.x86_64                                               1.18-4.el7                                       base
wpa_supplicant.x86_64                                          1:2.6-9.el7                                      base
xfsprogs.x86_64                                                4.5.0-15.el7                                     base
xorg-x11-drv-wacom.x86_64                                      0.34.2-5.el7                                     updates
yum.noarch                                                     3.4.3-158.el7.centos                             base
yum-plugin-fastestmirror.noarch                                1.1.31-46.el7_5                                  updates
yum-utils.noarch                                               1.1.31-46.el7_5                                  updates
Obsoleting Packages
grub2.x86_64                                                   1:2.02-0.65.el7.centos.2                         base
    grub2.x86_64                                               1:2.02-0.64.el7.centos                           @anaconda
grub2-tools.x86_64                                             1:2.02-0.65.el7.centos.2                         base
    grub2-tools.x86_64                                         1:2.02-0.64.el7.centos                           @anaconda
grub2-tools-extra.x86_64                                       1:2.02-0.65.el7.centos.2                         base
    grub2-tools.x86_64                                         1:2.02-0.64.el7.centos                           @anaconda
grub2-tools-minimal.x86_64                                     1:2.02-0.65.el7.centos.2                         base
    grub2-tools.x86_64                                         1:2.02-0.64.el7.centos                           @anaconda

If you are satisfied with the updates, let’s issue the following command to install the same.

yum update

You will get the package details along with the download size, and you need to press Y and Enter to begin the update.

 tar                                          x86_64        2:1.26-34.el7                           base           845 k
 targetcli                                    noarch        2.1.fb46-6.el7_5                        updates         67 k
 teamd                                        x86_64        1.27-4.el7                              base           112 k
 tuned                                        noarch        2.9.0-1.el7                             base           244 k
 tzdata                                       noarch        2018e-3.el7                             updates        482 k
 util-linux                                   x86_64        2.23.2-52.el7                           base           2.0 M
 vim-minimal                                  x86_64        2:7.4.160-4.el7                         base           437 k
 virt-what                                    x86_64        1.18-4.el7                              base            29 k
 wpa_supplicant                               x86_64        1:2.6-9.el7                             base           1.2 M
 xfsprogs                                     x86_64        4.5.0-15.el7                            base           896 k
 xorg-x11-drv-wacom                           x86_64        0.34.2-5.el7                            updates        306 k
 yum                                          noarch        3.4.3-158.el7.centos                    base           1.2 M
 yum-plugin-fastestmirror                     noarch        1.1.31-46.el7_5                         updates         33 k
 yum-utils                                    noarch        1.1.31-46.el7_5                         updates        120 k

Transaction Summary
=========================================================================================================================
Install    4 Packages
Upgrade  200 Packages

Total download size: 267 M
Is this ok [y/d/N]: y <-- Press Y

Downloading packages:
No Presto metadata available for base
updates/7/x86_64/prestodelta                                                                      | 409 kB  00:00:04
Delta RPMs reduced 74 M of updates to 15 M (80% saved)
(1/204): NetworkManager-glib-1.10.2-14.el7_5_1.10.2-16.el7_5.x86_64.drpm                          | 157 kB  00:00:00
(2/204): NetworkManager-libnm-1.10.2-14.el7_5_1.10.2-16.el7_5.x86_64.drpm                         | 156 kB  00:00:00
(3/204): centos-release-7-4.1708.el7.centos_7-5.1804.1.el7.centos.x86_64.drpm                     |  13 kB  00:00:00
(4/204): ca-certificates-2017.2.14-71.el7_2018.2.22-70.0.el7_5.noarch.drpm                        |  49 kB  00:00:00
(5/204): dhclient-4.2.5-58.el7.centos_4.2.5-68.el7.centos.1.x86_64.drpm                           | 135 kB  00:00:00
(6/204): dhcp-common-4.2.5-58.el7.centos_4.2.5-68.el7.centos.1.x86_64.drpm                        |  80 kB  00:00:00
(7/204): dhcp-libs-4.2.5-58.el7.centos_4.2.5-68.el7.centos.1.x86_64.drpm                          |  92 kB  00:00:00
(8/204): e2fsprogs-libs-1.42.9-10.el7_1.42.9-12.el7_5.x86_64.drpm                                 |  40 kB  00:00:00

Once the packages are downloaded, the installer will automatically start installing it. You may need to accept the GPG signing key if it prompts.

  util-linux.x86_64 0:2.23.2-52.el7
  vim-minimal.x86_64 2:7.4.160-4.el7
  virt-what.x86_64 0:1.18-4.el7
  wpa_supplicant.x86_64 1:2.6-9.el7
  xfsprogs.x86_64 0:4.5.0-15.el7
  xorg-x11-drv-wacom.x86_64 0:0.34.2-5.el7
  yum.noarch 0:3.4.3-158.el7.centos
  yum-plugin-fastestmirror.noarch 0:1.1.31-46.el7_5
  yum-utils.noarch 0:1.1.31-46.el7_5

Replaced:
  grub2.x86_64 1:2.02-0.64.el7.centos                      grub2-tools.x86_64 1:2.02-0.64.el7.centos

Complete!

Once the packages are installed, you can go ahead and reboot your machine

reboot
If the system doesn’t boot with the new kernel, then consider booting to old kernel and then reinstall the newly installed kernel.

READ: How to boot with an old kernel version in CentOS 7 / RHEL7

Now, verify the CentOS version.

cat /etc/redhat-release

Output:

CentOS Linux release 7.5.1804 (Core)

That’s All.

Further Reading

You might also like

How To Update CentOS 7.0/7.1/7.2/7.3/7.4 to CentOS 7.5

1