Changeset 1830 in MondoRescue for branches/2.2.5/mindi/rootfs/sbin/init


Ignore:
Timestamp:
Dec 2, 2007, 12:24:17 AM (16 years ago)
Author:
Bruno Cornec
Message:
  • start-nfs should NOT do exit => kernel panix as init exits

-some other fixes for init on denymods

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.5/mindi/rootfs/sbin/init

    r1829 r1830  
    157157HandleCDROMorFloppies() {
    158158    # Just in case we have an iLO ensure we will map it correctly
    159     grep -q "usb-storage " $DENY_MODS
     159    echo "$DENY_MODS" | grep -q "usb-storage "
    160160    if [ $? -eq 0 ]; then
    161161        return
     
    393393# Prepare minimal USB env in case we have USB kbd such as with iLO
    394394[ -d /proc/bus/usb ] && ! grep -q /proc/bus/usb /proc/mounts && mount -t usbfs none /proc/bus/usb
    395 grep -Eq 'uhcd_hci |usbhid |usbcore ' $DENY_MODS
     395echo "$DENY_MODS" | grep -Eq 'uhcd_hci |usbhid |usbcore '
    396396if [ $? -eq 0 ]; then
    397397    return
     
    576576    for m in `find /lib/modules -name '*.ko*'`; do
    577577        j=`basename $m | sed 's/\.ko.*$//'`
    578         grep -q '$j ' $DENY_MODS
     578        echo "$DENY_MODS" | grep -q "$j "
    579579        if [ $? -eq 0 ]; then
     580            echo "Denying $j..."
    580581            continue
    581582        fi
     
    594595        echo "Inserting modules ..."
    595596        insert-all-my-modules >> $LOGFILE 2>> $LOGFILE
    596         for i in $FORCE_MODS do;
     597        for i in $FORCE_MODS; do
    597598            MyInsmod $i
    598599        done
     
    631632if [ "`grep -i denymods /proc/cmdline`" ]; then
    632633    export DENY_MODS="`cat /proc/cmdline | sed 's~.*denymods=\"\(.*\)\".*~\1~'` mondonone"
     634else
     635    export DENY_MODS=" "
    633636fi
    634637
    635638if [ "`grep -i forcemods /proc/cmdline`" ]; then
    636639    export FORCE_MODS="`cat /proc/cmdline | sed 's~.*forcemods=\"\(.*\)\".*~\1~'` mondonone"
     640else
     641    export FORCE_MODS=" "
    637642fi
    638643
Note: See TracChangeset for help on using the changeset viewer.