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

ns.GetNS - unknown FS magic on "/run/snap.docker/netns/{container_id}": 1021994 #1110

Open
jocado opened this issue Oct 23, 2024 · 0 comments

Comments

@jocado
Copy link

jocado commented Oct 23, 2024

Hi,

This isn't necessarily a bug as such, but I'm trying to get a bit more info on the failing mechanism to see if there is any way I can at least work around it, or even better perhaps contribute a fix somewhere.

When using CNI plugins with Nomad, and docker running from a snap, it results in the following error pattern when creating the container via Nomad:

failed to setup alloc: pre-run hook "network" failed: failed to configure networking for alloc: failed to configure network: plugin type="bridge1" failed (add): failed to open netns "/run/snap.docker/netns/db65a7df22ec": unknown FS magic on "/run/snap.docker/netns/db65a7df22ec": 1021994

The bridge1 plugin referred to here is identical to the referenced in the workaround here: hashicorp/nomad#11085

#!/bin/bash
CNI_IFNAME=eth1
exec /opt/cni/bin/ipvlan

I've tried this with both CNI plugin bundle versions 1.3.0 and 1.6.0

Nomad [ which is also running from a snap ], works fine for standard docker operations.

I have tried running the nomad process with the snap confinement disabled [ apparmor and seccomp ], but get the same error. I'm wondering if there is some kind of mount namespace issue going on, but it's not clear because the contents of /run/snap.docker/netns/ is isn't itself in a separate mount namespace.

Is anyone able to tell me where I should start looking ? What is the likely cause of unknown FS magic ?

It seems like there is some kind of mount info somewhere which can't be access from nomad,. Just not sure where.

Thanks very much!

Cheers,
Just

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