On Tuesday 28 July 2015 15:21:37 Cédric Bosdonnat wrote:
dhcpcd requires an interface name as parameter to work. We are now
getting it from /proc/sys/net/ipv4/conf/ folder children.
---
appliance/init | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/appliance/init b/appliance/init
index cca62e7..ef18959 100755
--- a/appliance/init
+++ b/appliance/init
@@ -111,7 +111,8 @@ if test "$guestfs_network" = 1; then
if dhclient --version >/dev/null 2>&1; then
dhclient
else
- dhcpcd
+ iface=$(ls -I all -I default -I lo /proc/sys/net/ipv4/conf)
+ dhcpcd $iface
I'm noticing the same issue (not requesting for any interface) also on
a current Debian/testing system, which uses isc-dchp (dhclient).
I'd say that might be better to just extend this also to dhclient, so
passing the network interface to whichever dhcp client is used on the
appliance. At least, this seems to not break things on Debian/testing
and Fedora/21 (both using dhclient).
--
Pino Toscano