yum update minor versions only

Jeroen De Meerleer asked:

On my server I am running Gitlab community edition for my development repositories and today I found a error that was caused by my yum update cronjob.

What happened is that an update from 7.x to 8.x was installed which requires a lot of extra actions to install successfully.

Therefore a zip download of the repository wasn’t available (a json file was returned with no files)

The question I wanna ask: Has the yum package an option to only update minor versions (e.g 7.1 to 7.2 but no 7.1 to 8.0)

Thanks in advance

My answer:


Yum doesn’t provide a way to follow a specific semantic version, but there is a way to lock a particular package version in place, using the yum versionlock plugin.

yum install yum-plugin-versionlock

This will allow locking a package to the currently installed version.

For example:

yum versionlock add gitlab*

To update the package, you will have to remove the lock first.

yum versionlock delete gitlab*

View the full question and answer on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.