diff options
author | Michael Janczyk | 2012-12-04 18:32:15 +0100 |
---|---|---|
committer | Michael Janczyk | 2012-12-04 18:32:15 +0100 |
commit | 77ff585ab48626ade2d312102ae98202bf8b8d98 (patch) | |
tree | 28511182974acfdcb2f47eb02756f0b180b6189e | |
parent | iPXE fixes (diff) | |
download | core-77ff585ab48626ade2d312102ae98202bf8b8d98.tar.gz core-77ff585ab48626ade2d312102ae98202bf8b8d98.tar.xz core-77ff585ab48626ade2d312102ae98202bf8b8d98.zip |
- respect blacklisting of modules when autoloading modules in hwautocfg '-b' (stage3).
- preinit.local enabled again for config/systemName/default, until now it was only possible for the default system in config/default. It make no sense for client specific configurations though.
-rw-r--r-- | src/boot-env/OpenSLX/MakeInitRamFS/Engine/SlxBoot.pm | 4 | ||||
-rwxr-xr-x | src/initramfs/scripts/bin/hwautocfg | 13 | ||||
-rwxr-xr-x | src/initramfs/scripts/init | 8 |
3 files changed, 15 insertions, 10 deletions
diff --git a/src/boot-env/OpenSLX/MakeInitRamFS/Engine/SlxBoot.pm b/src/boot-env/OpenSLX/MakeInitRamFS/Engine/SlxBoot.pm index a0c24edb..cc5cc409 100644 --- a/src/boot-env/OpenSLX/MakeInitRamFS/Engine/SlxBoot.pm +++ b/src/boot-env/OpenSLX/MakeInitRamFS/Engine/SlxBoot.pm @@ -235,9 +235,9 @@ sub _copyPreAndPostinitFiles foreach my $cfg ( 'default/initramfs/preinit.local', - "$self->{'system-name'}/initramfs/preinit.local", + "$self->{'system-name'}/default/initramfs/preinit.local", 'default/initramfs/postinit.local', - "$self->{'system-name'}/initramfs/postinit.local" + "$self->{'system-name'}/default/initramfs/postinit.local" ) { my $cfgPath = "$openslxConfig{'private-path'}/config/stage3/$cfg"; next if !-f $cfgPath; diff --git a/src/initramfs/scripts/bin/hwautocfg b/src/initramfs/scripts/bin/hwautocfg index 22323e84..482c9f9a 100755 --- a/src/initramfs/scripts/bin/hwautocfg +++ b/src/initramfs/scripts/bin/hwautocfg @@ -66,11 +66,12 @@ fi nwcardlist=$(echo ${slxconf_listnwmod}|sed "s/\ /|/g") # save results for later info and for Xen plugin when starting Xen VM hwinfo --netcard --usb-ctrl >/etc/hwinfo.netcard-usbctrl -grep modprobe /etc/hwinfo.netcard-usbctrl | grep -E "$nwcardlist|hcd" | \ - grep -v ehci | sed 's/.* Cmd: "//;s/"//' | sort -u >/etc/modprobe.base +grep modprobe /etc/hwinfo.netcard-usbctrl | grep -E "$nwcardlist|hcd" \ + | grep -v ehci | sed 's/.* Cmd: "//;s/"//;s/modprobe/modprobe -b ${MODPRV}/' \ + | sort -u >/etc/modprobe.base # virtio hack if [ $(grep -ic "virtio_pci" /etc/modprobe.base) -ge 1 ]; then - echo "modprobe virtio_net" >>/etc/modprobe.base + echo 'modprobe ${MODPRV} virtio_net' >>/etc/modprobe.base fi sh /etc/modprobe.base; mdev -s @@ -97,9 +98,9 @@ hwmain () { # check for rtc if not compiled directly into the kernel ( [ -e /proc/driver/rtc ] || modprobe ${MODPRV} rtc-cmos ) & waitfor /tmp/hwdataready 10000 -sed '/Driver Info #1/,/Config Status:/d' \ - /etc/hwinfo.data | grep modprobe | sed "s|.* Cmd: \"||;s|\"|$modloadbg|" \ - | sort -u >/etc/modprobe.pci +sed '/Driver Info #1/,/Config Status:/d' /etc/hwinfo.data | grep modprobe \ + | sed "s|.* Cmd: \"||;s|\"|$modloadbg|;s|modprobe|modprobe -b ${MODPRV}|" \ + | sort -u >/etc/modprobe.pci sh /etc/modprobe.pci mdev -s diff --git a/src/initramfs/scripts/init b/src/initramfs/scripts/init index 3f41d3c6..d1d7945b 100755 --- a/src/initramfs/scripts/init +++ b/src/initramfs/scripts/init @@ -121,8 +121,12 @@ runinithook '00-started' # run pre init script and user defined preinit.local, copied by mkdxsinitrd # from /var/lib/openslx/config/... in stage2 preinit -[ -x /bin/preinit.local ] && /bin/preinit.local - +[ -f /bin/preinit.local ] && { + [ $DEBUGLEVEL -gt 0 ] && \ + echo -n "Running script /bin/preinit.local ... " + chmod u+x /bin/preinit.local + /bin/preinit.local + [ $DEBUGLEVEL -gt 0 ] && echo "ok"; } # switch off the several configuration methods, will be switched on # according to kernel commandline settings |