[PATCH 1/5] dhclient now reads config files from /etc/dhcp

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Create /etc/dhcp in the initrd image and make sure loader writes
dhclient configuration files to /etc/dhcp.
---
 loader/net.c      |    4 ++--
 scripts/mk-images |    1 +
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/loader/net.c b/loader/net.c
index 1c35ac5..5b9593a 100644
--- a/loader/net.c
+++ b/loader/net.c
@@ -1123,7 +1123,7 @@ int writeDisabledNetInfo(void) {
 
     for (i = 0; devs[i]; i++) {
         /* remove dhclient-DEVICE.conf if we have it */
-        if (asprintf(&ofile, "/etc/dhclient-%s.conf", devs[i]->device) == -1) {
+        if (asprintf(&ofile, "/etc/dhcp/dhclient-%s.conf", devs[i]->device) == -1) {
             return 5;
         }
 
@@ -1219,7 +1219,7 @@ int writeEnabledNetInfo(iface_t *iface) {
         }
     }
 
-    if (asprintf(&ofile, "/etc/dhclient-%s.conf", iface->device) == -1) {
+    if (asprintf(&ofile, "/etc/dhcp/dhclient-%s.conf", iface->device) == -1) {
         return 17;
     }
 
diff --git a/scripts/mk-images b/scripts/mk-images
index da8796b..75ed578 100755
--- a/scripts/mk-images
+++ b/scripts/mk-images
@@ -555,6 +555,7 @@ makeinitrd() {
     mkdir -p $MBD_DIR/var/cache/hald
     mkdir -p $MBD_DIR/var/lib/dbus
     mkdir -p $MBD_DIR/var/lib/dhclient
+    mkdir -p $MBD_DIR/etc/dhcp
     mkdir -p $MBD_DIR/var/lock/rpm
     mkdir -p $MBD_DIR/var/run
     mkdir -p $MBD_DIR/var/run/dbus
-- 
1.6.3.3

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux