Since it caused me some grievance in finding out the hard way I thought sharing so it may prevent such for others
both, netctl
and dhcpcd
, appear to be dependent on udev
to provide/predict ifname(s) for the respective service to bind to and that is not working well inside the container, perhaps udev
being restricted. Starting either service kept on throwing (unspecified) dependency errors.
Curioulsy dhcpcd@ifname.service
does not work but invoking dhcpcd ifname
from the cli does…
another issue with netctl
is that it does not profile an iface that is already set and up otherwise (e.g. passed through veth from lxc). That however can be worked around with ForceConnect=yes
in the respective netctl profile in the container.
dhclient
on the other hand is working with no such qualms, and so is networkd
, latter though may have a bug in its dhcp client 3.0.1 - DHCP error: could not get routes: No data available (container)? and been the reason of going through this excercise.