-
Notifications
You must be signed in to change notification settings - Fork 0
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
No internet inside container? #6
Comments
@tmpm697 Argh, my approgies, I've not documented about veth...
From my experience (sorry not to show you any sources), you must add rule I added above to README.md at 18bed45. Thanks for your reporting |
This is weird. I don't have iptables or nftables services running. How to setup that container will have static IP address? My setup:
I use archlinux latest with linux-lts, systemd-networkd to manage network for both host and container. I have [email protected] to start wifi profile and the profile in /etc/wpa_supplicant on host. I want build and start buildspawn with a specific ipadress but failed. Basically:
Create bridge network:
I build and start buildspawn container as default, the add static ip adress as in article:
Ip route on host:
Ip route on container:
I think there's something thing wrong with my setup, do you have same issue before? P/s I'll put code block when in desktop. Thanks. |
I see. I'll try to use bridge + nspawn + networkd later when I have time. |
I haven't tried bridge + nspawn + networkd yet, but found my mistaken (or forgot) point for using veth. Below's an example for iptables I used before (cf. https://wiki.archlinux.org/index.php/Simple_stateful_firewall) : Install this to /etc/iptables/iptables.rules
and below's for nftables I'm using now (cf. https://wiki.archlinux.org/index.php/Nftables#Simple_stateful_firewall): Install this to /etc/nftables.conf
|
I don't use iptables or nftables in my system. I have ve-xxxx on host and host0 in container but as the archwiki: "When you start the container, an IP address has to be assigned to both interfaces (on the host and in the container). If you use systemd-networkd on the host as well as in the container, this is done out-of-the-box" This is not true in my case, both use systemd-networkd but there's no ip under container. ve-xxx and host0 both in DOWN state. I use wifi profile with wpa-supplicant but I think it doesn't relate to this case. |
Ah, sorry, I misread your comment. I could maybe reproduce your issue (no IP address on
"networkctl" result
"ip address show" result
Both could do them. Here's
Maybe you couldn't treat veth by systemd-networkd properly. P.S. I use iwd to manage wifi profile instead of wpa_supplicant, I've used before. But when wpa_supplicant I haven't experience issue like you reported. |
ALL of my configs: ON HOST:
ON CONTAINER:
It's oposite of yours as my host0 is completely in down state and ve-* is in configuring state. I have no idea why it just don't work. |
How about And your log shows Also, any changes when you use kernel provided Updated: last line may not related for this issue because of https://wiki.archlinux.org/index.php/Linux_Containers#Privileged_containers_or_unprivileged_containers...:
|
on HOST:
vi
I use
|
Thank you. Your I don't have any answer / solution for you now... You might want to consider asking for your issue in ArchWiki or https://github.com/systemd/systemd/issues. |
Steps to produce:
on host I have ve-* interface, and inside container I have another interface without IP address, I would expect the non-lo interface should have and ip address assigned to it and I'll be able to ping google.com from container.
all setup are mostly default and I haven't changed anything.
I use archlinux latest lts-linux, systemd-networkd to manage my wifi connection via wpa_supplicant profile.
The text was updated successfully, but these errors were encountered: