Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Yum updates not respecting excludes, if excludes have wildcards. #437

Open
sharkannon opened this issue Jul 28, 2022 · 0 comments
Open

Yum updates not respecting excludes, if excludes have wildcards. #437

sharkannon opened this issue Jul 28, 2022 · 0 comments

Comments

@sharkannon
Copy link

It seems that according to the docs, the "Exclude" function on yum_updates should be the same as
yum update -x <package> or yum update --exclude <package>, however both those syntax support wildcards. When I try to use wildcards in our excludes, the excludes are ignored and the packages we're trying to exclude are updated. If I put in the specific package name, things are ignored as expected, however this is not always the best scenario, as some packages have version numbers (of dependency packages) embedded in their name, so a wildcard is required to properly exclude them.

Examples

Yum update (no excludes)

Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Resolving Dependencies
--> Running transaction check
---> Package google-cloud-sdk.x86_64 0:394.0.0-1 will be updated
---> Package google-cloud-sdk.x86_64 0:395.0.0-1 will be an update
--> Finished Dependency Resolution

Dependencies Resolved

==========================================================================================================================================================================================================================================
 Package                                                      Arch                                               Version                                               Repository                                                    Size
==========================================================================================================================================================================================================================================
Updating:
 google-cloud-sdk                                             x86_64                                             395.0.0-1                                             google-cloud-sdk                                             104 M

Transaction Summary
==========================================================================================================================================================================================================================================
Upgrade  1 Package

Yum update to exclude google-cloud-sdk

yum update -x google-*
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
No packages marked for update
yum update --exclude google-*
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
No packages marked for update

That's how it should work, but when I add google-* to the excludes in OSPatch Management, google-cloud-sdk gets updated.

Screen Shot 2022-07-28 at 11 20 39 AM

Output of log:

Running in dryrun mode, not updating 1 packages: ["google-cloud-sdk x86_64 395.0.0-1"]

The above output indicates that the package would be updated if it wasn't in dryrun.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant