PXE netboot install of Ubuntu Desktop results in unconfigured network interface

Bug #1750597 reported by David Coronel
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
debian-installer (Ubuntu)
Won't Fix
Undecided
Unassigned

Bug Description

When doing a PXE netboot of Ubuntu Desktop over NFS, the installer adds the following lines for each network interface to /etc/network/interfaces (I think this is to keep the root fs available during the live session):

  auto ens3
  iface ens3 inet manual

I was able to reproduce the issue with both Xenial and Bionic. There's something specific about Ubuntu Desktop that's not an issue with Ubuntu Server. I believe it's because of ubiquity and casper being used for Desktop vs debian installer in Server.

The workaround is to edit /etc/network/interfaces and remove the lines relating to your network interfaces after rebooting at the end of the installation. The only two non-comment lines left when you’re finished should be:

auto lo
iface lo inet loopback

One can preseed a late_command which overwrites the /etc/network/interfaces with only a loopback device to automate this workaround.

There is an 8 year old bug #388060 related to this issue that mentions the following:

```
These lines are added by casper in a script called 23networking. Here are a few relevant lines from the script:

if [ -z "${NETBOOT}" ]; then method="dhcp"; else method="manual"; fi
if [ "$method" != dhcp ] || [ ! -x /root/usr/sbin/NetworkManager ]; then
# ...
cat >> "$IFFILE" <<EOF
auto $i
iface $i inet $method

EOF
fi

So, this at least enables the live cd environment to be loaded over NFS. However, the problem is that this later gets propagated to the installed environment if ubiquity is called. This is done by the install.py script and here are the relevant lines from the script:

for path in ('/etc/network/interfaces', '/etc/resolv.conf'):
if os.path.exists(path):
shutil.copy2(path, os.path.join(self.target, path[1:]))
```

I'm attaching a screenshot of the issue after the livecd netboot PXE installation (netboot-pxe-issue.png) and another screenshot of the same instance but after the workaround to remove the lines in /e/n/i (netboot-pxe-issue-after-workaround.png).

Additional information:

1) The release of Ubuntu you are using via 'lsb_release -rd'

Ubuntu 16.04.3 LTS
Ubuntu Bionic Beaver (development branch)

2) The version of the package you are using, via 'apt-cache policy pkgname'

Ubuntu 16.04.3 LTS:
casper 1.376.2
ubiquity 2.21.63.4

Ubuntu Bionic Beaver (development branch)
casper 1.388
ubiquity 18.04.1

3) What you expected to happen
Network interfaces should be configured by Network Manager after the final reboot at the end of the installation. There shouldn't be 'manual' lines in /etc/network/interfaces at the end of the installation.

4) What happened instead
Network interfaces are not configured by Network Manager after the final reboot at the end of the installation. There are 'manual' lines in /etc/network/interfaces at the end of the installation and because of that there is no network interface configured after the reboot.

Revision history for this message
David Coronel (davecore) wrote :
Revision history for this message
David Coronel (davecore) wrote :
affects: casper (Ubuntu) → debian-installer (Ubuntu)
Revision history for this message
David Coronel (davecore) wrote :

Netbooting Ubuntu Desktop is not a supported installation method for Ubuntu. The only supported way to install Ubuntu via netboot is with the Netboot images of Ubuntu[1]. More information in the Ubuntu documentation[2].

[1] http://cdimage.ubuntu.com/netboot/
[2] https://help.ubuntu.com/community/Installation/Netboot

Changed in debian-installer (Ubuntu):
status: New → Won't Fix
Revision history for this message
Ye Tian (flymaxty) wrote :

I had same issue when I was trying to install ubuntu-desktop(16.04 & 18.04) with pxe.

netboot-installer need online repo(like http://archive.ubuntu.com/ubuntu) to do install, but it is inefficient when network is not good(network policy problem or low bandwidth network).

If Netbooting Ubuntu Desktop over nfs is not supported, is there any way can do batch install or automatic installation offline?

Or is there any way to do cleanup with /etc/network/interfaces after nfs-base installation?

Thank you!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.