-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Error with symlinked /etc/resolv.conf #12461
Comments
Can you provide the output of |
Here it is:
|
Ok that looks good, can you show |
/etc/resolvconf/run/resolv.conf is a regular file. Actually I was copying it to /etc/resolv.conf with cp when testing. |
But maybe |
Yes, /etc/resolvconf/run is a symlink to /run/resolvconf |
If you symlink I see the problem, I will try to fix it later this week. |
Thanks! With direct symlink you suggested it works. |
We need to follow all symlinks in the /etc/resolv.conf path. Currently we would only check the last file but it is possible that any directory before that is also a link. Unfortunately this code is very hard to maintain and not well tested. I will try to come up with a unit test when I have more time. I think we could utilize some for of chroot for this. For now we are stucked with the default setup in the fedora/ubunutu test VMs. [NO NEW TESTS NEEDED] Fixes containers#12461 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
When container is run on debian unstable (bookworm) on which /etc/resolv.conf is a symlink to /etc/resolvconf/run/resolv.conf, container startup fails.
Steps to reproduce the issue:
podman network create tstnet
podman pod create --name tst --hostname tst --network tstnet --publish 1521:1521
podman run --pod tst --name dummy alpine
Describe the results you received:
When container is run, the following error appears:
Describe the results you expected:
Container should start up without errors
Additional information you deem important (e.g. issue happens only occasionally):
If I replace an /etc/resolv.conf symlink by regular file, no error occurs.
Output of
podman version
:Output of
podman info --debug
:Package info (e.g. output of
rpm -q podman
orapt list podman
):Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide? (https://github.com/containers/podman/blob/master/troubleshooting.md)
Yes
Additional environment details (AWS, VirtualBox, physical, etc.):
The text was updated successfully, but these errors were encountered: