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

Disable motd #1910

Closed
wants to merge 1 commit into from
Closed

Conversation

stijndehaes
Copy link

Disabling motd results in a faster boot of the
AMI.

Issue #, if available: #1751

Description of changes:

By disabling motd the AMI is able to boot up faster. The difference is about 20s. Analysis was done using systemd-analyze:

Before change:
Startup finished in 698ms (kernel) + 7.574s (initrd) + 1min 2.208s (userspace) = 1min 10.481s graphical.target reached after 1min 2.146s in userspace.

After change:
Startup finished in 454ms (kernel) + 3.842s (initrd) + 38.513s (userspace) = 42.810s graphical.target reached after 38.055s in userspace.

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: Launching a custom AMI made from one of the release AMI's

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.

Disabling motd results in a faster boot of the
AMI.
@stewartsmith
Copy link

Is this observable with the stock AL2023 images? We did make sure the update-motd service didn't block the OS launching.

@cartermckinnon
Copy link
Member

cartermckinnon commented Aug 5, 2024

This service doesn't block any of the important services (nodeadm-run, containerd, kubelet), so I don't see much benefit in disabling it. The "update is available" message written by /etc/update-motd.d/70-available-updates is helpful, IMO.

Time to graphical.target isn't the right metric here, I think, we care about kubelet starting, the Node becoming Ready in the API, etc.

@cartermckinnon
Copy link
Member

Let me know if you disagree @stijndehaes

@stijndehaes
Copy link
Author

@cartermckinnon fair enough :)
I do notice kubelet launching 3s faster without motd, but that is probably within margin of error.
I would like to improve the hot code path, I am leaving on a 10 days of vacation tomorrow, but after that I would love to improve nodeadm-config and nodeadm-run.
nodeadm-config uses kubelet making it slow, and nodeadm-run uses containerd making it slow.
Is there a better place than github issues to discuss solution designs? :)

@ndbaker1
Copy link
Member

ndbaker1 commented Aug 8, 2024

appreciate the attention here, i also think it would benefit from a bit of caching and/or parallelism here so i might take a stab at it when i have time

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

Successfully merging this pull request may close these issues.

4 participants