No internet connectivity in Turris_OS LXC container

Hello everyone,

I started playing with my Turris Omnia and I am really struggling to have internet connectivity working when creating a LXC container with the download template set to Turris_OS stable

lxc-create -n test -t download
Distribution: Turris_OS
Release: stable
Architecture: armv7l

The DHCP client does not send a DHCP request as expected, and this issue could be related to this discussion:

But the fix suggested there works only for the Debian template

Moreover, even setting a fixed address in the container config does not work for me, the network configuration inside the container seems wrong:

root@test:~# ifconfig
br-lan Link encap:Ethernet HWaddr D8:58:D7:00:2B:B6
inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fd5e:6a7:4280::1/60 Scope:Global
inet6 addr: fe80::da58:d7ff:fe00:2bb6/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:11 errors:0 dropped:0 overruns:0 frame:0
TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:760 (760.0 B) TX bytes:1474 (1.4 KiB)

eth0 Link encap:Ethernet HWaddr D8:58:D7:00:2B:B6
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:34 errors:0 dropped:7 overruns:0 frame:0
TX packets:23 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:3074 (3.0 KiB) TX bytes:2418 (2.3 KiB)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)

Has anyone experienced this and knows what can be missing in the template configuration? I tried to search in the community documentation but found nothing related to that specific Turris_OS template

Thanks

It would not be a big issue if you have used static ipaddress to first confirm if the fault does not lie with the DHCP-server.

I today after starting to migrate to Ubuntu 18.04 from Ubuntu 16.04 with it replacing my old Samsung Evo 850 500 GB with a Samsung Evo 860 1 TB, also experienced not having the templates.

After much struggle, i experimented with using a hotspot on my phone and using that as WAN interface(Through wifi connection) for my Omnia router. Suddenly that did work and i quickly did the necessary steps to create it the LXC. In the LAN the gateway i used the ipadres that was given tot the Wifi adapter. Maybe you could try that.

If i now check the same page on the Omnia, i also have no longer the templates anymore. But in my case i did what i needed to do.

My problem is not about not having the templates, I am able to create the contatiner with Turris_OS distribution and everything works fine, however from inside the container I am not able to reach the outside internet.

One problem is for sure the DHCP client not sending the DHCP-REQUEST, but even if I set a static IP address from the config I am not able to ping anything outside

My suspects are some of the enabled daemons in /etc/rc.d from the distribution image messing up with the veth configuration, but for the moment I still haven’t found how to fix that

Can you post the output of

cat /etc/lxc/default.conf

this for example is how i configured my file.

root@K-Router:~# cat /etc/lxc/default.conf
lxc.network.type = veth
lxc.network.link = br-lan
lxc.network.flags = up
lxc.network.name = eth0
lxc.network.ipv4.address = 192.168.1.210/24
lxc.network.ipv4.gateway = 192.168.1.1
# Debian workaround
lxc.network.script.up = /usr/share/lxc/hooks/tx-off
lxc.tty = 4
lxc.pts = 1024
# Template to generate fixed MAC address
lxc.network.hwaddr = <REMOVED>

The only difference is that I didn’t put the “static ip” lines:

lxc.network.ipv4.address = 192.168.1.210/24
lxc.network.ipv4.gateway = 192.168.1.1

in the default configuration, but instead in the config file after the container is created, but the result should be the same.
Can you confirm me that for you (with this configuration and without any other changes) internet connectivity works from inside the container, created with template download and configuration set to Turris_OS, stable, armv7l?