Issues with pasta network stack, special setting and join an existing podman network #23597
Replies: 5 comments 1 reply
-
There are network modes (e.g. pasta,slirp4netns,bridge...) and "custom/user-defined" networks ( In order to use network connect/disconnect you must a container with custom networks (aka bridge mode). Given you are using pasta (rootless default since v5) network connect/disconnect will not work. It is a either or situation. If you want to use custom network as rootless it used a setup as shown there: #22943 (comment) |
Beta Was this translation helpful? Give feedback.
-
Cross-posted with https://www.reddit.com/r/podman/comments/1epjdlu/how_can_i_specify_a_network_name_to_join_together/ (no links added on either side...). |
Beta Was this translation helpful? Give feedback.
-
Thanks for the reply. I think what I would like to achieve is rather simple. Thanks for the diagram @Luap99 but I think it's really beyond my competences at the moment. I simply can't fully digest it. What are the steps I have to take to achieve what I'm trying to achieve? |
Beta Was this translation helpful? Give feedback.
-
Ok, this is what I did:
This are the config that I was passing in the quadlet file. I created a network with Now, as I'm going down to the rabbit hole, if I do
Shouldn't the gateway be 10.0.2.2 as specified in the Also, if I inspect the container:
I don't see any tap0 interface as specified in the mentioned config file. Why is that? Why the container IP doesn't match the pasta option given range and why the interface has a different name? Can someone please ELI5 to me, I'm really trying hard to learn these things! :) Is what I did good/acceptable or am I missing something else? |
Beta Was this translation helpful? Give feedback.
-
Thank you very much both @Luap99 and @sbrivio-rh for your help and extra documentation/links. Learned a lot while troubleshooting this! I'm rather confused at the moment... |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to have this container to work with a VPN connection (WireGuard).
Container has been working fine with podman <5, so with slirp4netns. Now that I migrated to podman version 5.1.2, I'm having some issues with this container and the new pasta network stack.
This is what I see in the container logs when it starts without successfully connecting to the VPN (VPN endpoint and port have been masked with 123.123.123.123 and 1234:
As you can see both IPV4 and IPV6 ping are failing. Container starts, it's marked as healthy but I can't even connect to its web UI.
Reading the documentation, I passed the following settings into my quadlet file:
Network=pasta:-I,tap0,--ipv4-only,-a,10.0.2.0,-n,24,-g,10.0.2.2,--dns-forward,10.0.2.3,--no-ndp,--no-dhcpv6,--no-dhcp
With these settings, I can have the container to work, it connects to the VPN successfully (and the connection is way faster than with slirp4netns btw...).
These are the logs:
With the settings above I can connect to the container WEB UI and everything works as expcted.
Now the issue is, I have to connect this container to an existing network and it seems I can't. I tried with --netns but no luck.
Maybe I passed the wrong option for --netns, I'm not sure.
How can I have that container to work with the VPN, pasta network stack and connect it to an existing network called my_network?
Beta Was this translation helpful? Give feedback.
All reactions