On 01/31/2012 09:11 AM, Radek Vykydal wrote:
Port from F16. NM assumes this default but network service (initscripts) won't start the device without the BOOTPROTO value set. Resolves: rhbz#723404 --- gui.py | 2 -- loader/net.c | 2 ++ network.py | 5 ----- 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/gui.py b/gui.py index 409882b..0f89934 100755 --- a/gui.py +++ b/gui.py @@ -1020,8 +1020,6 @@ class InstallInterface(InstallInterfaceBase): # update ifcfg files for nm-c-e self.anaconda.id.network.setNMControlledDevices(nm_controlled_devices) - if not just_setup: - self.anaconda.id.network.presetDefaultConfiguration([install_device]) self.anaconda.id.network.writeIfcfgFiles() network.logIfcfgFiles(message="Dump before nm-c-e (can race " diff --git a/loader/net.c b/loader/net.c index fc4e271..d755eae 100644 --- a/loader/net.c +++ b/loader/net.c @@ -1236,6 +1236,8 @@ int writeDisabledIfcfgFile(char *device) { fprintf(fp, "HWADDR=%s\n", iface_mac2str(device)); fprintf(fp, "ONBOOT=no\n"); fprintf(fp, "NM_CONTROLLED=no\n"); + /* default for network service, NM assumes it */ + fprintf(fp, "BOOTPROTO=dhcp\n"); if (fclose(fp) == EOF) { return 3; diff --git a/network.py b/network.py index 15cf29c..8bdd096 100644 --- a/network.py +++ b/network.py @@ -462,11 +462,6 @@ class Network: else: device.set(('ONBOOT', 'yes')) - def presetDefaultConfiguration(self, devices=None): - for devname, device in self.netdevices.items(): - if not devices or devname in devices: - device.set(('BOOTPROTO', 'dhcp')) - def getOnbootControlledIfaces(self): ifaces = [] for iface, device in self.netdevices.items():
Ack. -- David Cantrell <dcantrell@xxxxxxxxxx> Supervisor, Installer Engineering Team Red Hat, Inc. | Westford, MA | EST5EDT _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list