lib/tmpfiles.d: symlink networks, protocols, rpc and services into /etc - #44
Merged
dongsupark merged 1 commit intoAug 7, 2026
Merged
Conversation
glibc resolves these through the usrfiles NSS module, so nothing in /etc is needed for getprotobyname() and friends to work. Anything that reads the paths directly still breaks though: statically linked binaries open /etc/protocols themselves, and a hostPath volume of type File keeps kubelet from starting the pod at all when the file is missing, which is what azure-npm hits on Flatcar. Link them from /usr/share/baselayout the same way /etc/nsswitch.conf already is. tmpfiles leaves an existing path alone, so a copy the user put there keeps winning. Fixes flatcar/Flatcar#1852 Signed-off-by: Satwik Sai Prakash Sahoo <sahoospsatwik@gmail.com>
satwiksps
force-pushed
the
fix-missing-nss-files
branch
from
August 6, 2026 01:28
d888f8a to
a84fe9f
Compare
2 tasks
Member
|
Thanks, created a PR flatcar/scripts#4190, running CI. |
dongsupark
added a commit
to flatcar/scripts
that referenced
this pull request
Aug 7, 2026
Pulls in flatcar/baselayout#44. Signed-off-by: Dongsu Park <dongsu@dpark.io>
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.
/etc/protocols,/etc/services,/etc/rpcand/etc/networksare not on disk in flatcar. Glibc finds them under/usr/share/baselayout/through theusrfilesNSS module wired up innsswitch.conf, sogetprotobyname()and friends work fine and nothing looks broken.Anything that opens those paths directly does break though. Statically linked binaries and go programs parse
/etc/protocolsthemselves, and kubernetes workloads that mount the file as ahostPathwithtype: Filedo not even start, because kubelet requires the path to exist on the host, this is what azure-npm runs into.So this PR adds four
Llines tobaselayout-etc.confpointing back at the copies in/usr/share/baselayout/, exactly how/etc/nsswitch.confand/etc/issueare already handled.Lleaves an existing path alone, so anyone who put their own file in/etckeeps it.