diff -Nru libguestfs-1.32.2/debian/changelog libguestfs-1.32.2/debian/changelog --- libguestfs-1.32.2/debian/changelog 2016-03-13 21:14:50.000000000 +0000 +++ libguestfs-1.32.2/debian/changelog 2019-02-07 13:22:17.000000000 +0000 @@ -1,3 +1,10 @@ +libguestfs (1:1.32.2-4ubuntu2.1) xenial; urgency=medium + + * Fix missing /etc/fstab when enabling network (LP: #1632405) + * Fix build failure dh_install --fail-missing (LP: #1814939) + + -- Ioanna Alifieraki Thu, 07 Feb 2019 13:17:26 +0000 + libguestfs (1:1.32.2-4ubuntu2) xenial; urgency=medium * No-change rebuild for ruby2.3-only support. diff -Nru libguestfs-1.32.2/debian/patches/0001-appliance-touch-etc-fstab-when-enabling-the-network-.patch libguestfs-1.32.2/debian/patches/0001-appliance-touch-etc-fstab-when-enabling-the-network-.patch --- libguestfs-1.32.2/debian/patches/0001-appliance-touch-etc-fstab-when-enabling-the-network-.patch 1970-01-01 01:00:00.000000000 +0100 +++ libguestfs-1.32.2/debian/patches/0001-appliance-touch-etc-fstab-when-enabling-the-network-.patch 2019-02-07 13:14:41.000000000 +0000 @@ -0,0 +1,30 @@ +From: Pino Toscano +Date: Thu, 14 Jul 2016 14:09:18 +0200 +Subject: [PATCH] appliance: touch /etc/fstab when enabling the network + (RHBZ#1224795) + +Sadly, the dhclient-script shipped as part of isc-dhcp-client in Ubuntu +unconditionally reads from /etc/fstab without checking for its +existence. Since no package holds /etc/fstab, this file will not exist +in the appliance, cause dhclient to fail (actually keep looping calling +the failing dhclient-script) when the network is requested. + +As a workaround, touch /etc/fstab just before enabling the network: if +that file exists nothing changes, while an empty file will be available +in the other case, making at least dhclient-script in Ubuntu working. +--- + appliance/init | 1 + + 1 file changed, 1 insertion(+) + +Index: libguestfs-1.32.2/appliance/init +=================================================================== +--- libguestfs-1.32.2.orig/appliance/init ++++ libguestfs-1.32.2/appliance/init +@@ -109,6 +109,7 @@ ip link set dev lo up + + if test "$guestfs_network" = 1; then + iface=$(ls -I all -I default -I lo /proc/sys/net/ipv4/conf) ++ touch /etc/fstab # Workaround for Ubuntu. + if dhclient --version >/dev/null 2>&1; then + dhclient $iface + else diff -Nru libguestfs-1.32.2/debian/patches/series libguestfs-1.32.2/debian/patches/series --- libguestfs-1.32.2/debian/patches/series 2016-02-24 22:32:06.000000000 +0000 +++ libguestfs-1.32.2/debian/patches/series 2019-02-07 13:12:37.000000000 +0000 @@ -3,3 +3,4 @@ 0003-Do-not-use-DTB-for-armel.patch 0004-Generate-tarballs-for-supermin-appliance-using-repro.patch 0005-Run-gzip-inside-of-tar-zcf-with-n.patch +0001-appliance-touch-etc-fstab-when-enabling-the-network-.patch diff -Nru libguestfs-1.32.2/debian/rules libguestfs-1.32.2/debian/rules --- libguestfs-1.32.2/debian/rules 2016-03-13 16:04:12.000000000 +0000 +++ libguestfs-1.32.2/debian/rules 2019-02-07 13:17:19.000000000 +0000 @@ -119,7 +119,7 @@ erlang-depends -perlang-guestfs - dh_install -X.la -X.so.owner -Xbindtests -X/usr/lib/go/ -Xpackages.orig \ + dh_install -X.la -X.so.owner -Xbindtests -X/usr/lib/go/ -X/usr/lib/go- -Xpackages.orig \ --fail-missing # Add packages (except essential packages) from appliance packagelist