Repository navigation
fix(al2023): disable update-motd timer - #2857
Merged
Merged
Conversation
mselim00
reviewed
Oct 15, 2026
mselim00
left a comment
Contributor
There was a problem hiding this comment.
independent of fixing the timeout/cleanup logic in the update-motd part, I agree a periodic update-motd invocation isn't necessary for these AMIs since they're largely intended to be treated as immutable. we do use it to advertise the NVIDIA EULA on NVIDIA AMIs though, so it's not something we want to totally mask
the service is enabled by default, so it would run at each boot independent of any timer, but the additional baked in-timer means it runs periodically regardless of boot cycles. disabling the timer means it'd only run once at boot, so the wasted space from a timeout is bounded, and timeouts aren't actually as likely as the issue would imply
…for the NVIDIA EULA notice Co-authored-by: Mazen Selim <100049111+mselim00@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue #, if available: Fixes #2856
Description of changes:
On AL2023 nodes,
update-motd.serviceruns at boot and every ~12h viaupdate-motd.timer. It executes/etc/update-motd.d/70-available-updates, which runstimeout 30s dnf updateinfounderCPUQuota=25%. Becausecleanup.shremoves/var/cache/dnfat build time, dnf has to rebuild its cache from scratch and is routinely killed by the timeout; when the kill lands mid-write it leaks a ~30 MB *.solvx.XXXXXX temp file in /var/cache/dnf. On long-lived nodes this accumulates to several GB and triggers kubeletDiskPressure(root cause in dnf tracked in amazonlinux/amazon-linux-2023#1142).This fix masks
update-motd.timerandupdate-motd.servicein the AL2023 template.By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Testing Done
systemctl mask update-motd.timer update-motd.service: both units reportmasked, the timer has no next trigger.See this guide for recommended testing for PRs. Some tests may not apply. Completing tests and providing additional validation steps are not required, but it is recommended and may reduce review time and time to merge.