Changeset 1922 in MondoRescue for branches/2.2.6/mindi
- Timestamp:
- Apr 17, 2008, 12:32:36 PM (16 years ago)
- Location:
- branches/2.2.6/mindi
- Files:
-
- 2 deleted
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.2.6/mindi/deplist.txt
r1902 r1922 25 25 26 26 #-------------------------------- ESSENTIAL ----------------------------------- 27 fstab raidtab modules.conf conf.modules mondorestore modules.conf.local 27 fstab raidtab 28 /usr/sbin/mondorestore 28 29 /etc/mdadm/mdadm.conf /etc/mdadm.conf 29 30 /sbin/ldconfig … … 33 34 bzip2 bunzip2 lzop 34 35 ctrlaltdel 35 # Do not remove as they need to be aligned with the kernel 36 insmod lsmod 36 # Everything needed to handle modules correctly 37 insmod lsmod /sbin/modprobe 38 /etc/modprobe.d /etc/modprobe.conf /etc/modules.conf /etc/conf.modules /etc/modules.conf.local 39 37 40 hosts host.conf resolv.conf hosts.allow hosts.deny nsswitch.conf 38 41 klogd sysklogd … … 59 62 # gdb valgrind /usr/lib/valgrind 60 63 61 #----------------- For all you LVM users out there, much love -----------------62 LVMFILES:63 lvmiopversion lvchange lvcreate lvdisplay lvextend lvmchange lvmcreate_initrd lvmdiskscan lvmsadc lvmsar lvreduce lvremove lvrename lvscan pvchange pvcreate pvdata pvdisplay pvmove pvscan vgcfgbackup vgcfgrestore vgchange vgck vgcreate vgdisplay vgexport vgextend vgimport vgmerge vgmknodes vgreduce vgremove vgrename vgscan vgsplit liblvm lvm lvm-10 /etc/lvm/lvm.conf64 #------------------------------------------------------------------------------65 64 # 66 65 # Proliant extended support if available … … 68 67 conrep cpqacuxe hponcfg 69 68 lshw 69 #----------------- For all you LVM users out there, much love ----------------- 70 LVMFILES: 71 lvmiopversion lvchange lvcreate lvdisplay lvextend lvmchange lvmcreate_initrd lvmdiskscan lvmsadc lvmsar lvreduce lvremove lvrename lvscan pvchange pvcreate pvdata pvdisplay pvmove pvscan vgcfgbackup vgcfgrestore vgchange vgck vgcreate vgdisplay vgexport vgextend vgimport vgmerge vgmknodes vgreduce vgremove vgrename vgscan vgsplit liblvm lvm lvm-10 /etc/lvm/lvm.conf 72 #------------------------------------------------------------------------------ -
branches/2.2.6/mindi/mindi
r1919 r1922 1069 1069 1070 1070 1071 MakeModuleLoadingScript() {1072 local module fname params modpath kver outerloop i modpaths kver searchpath list_to_echo j1073 tmpmodprobe_flag=$11074 outfile=$21075 > $outfile || Die "Cannot create empty $outfile"1076 echo -en "#\041/bin/sh\n\n" >> $outfile1077 echo "echo -en \"Loading your modules...\"" >> $outfile1078 if [ "$YOUR_KERNEL_SUCKS" ] ; then1079 kver=$FAILSAFE_KVER1080 cd $MINDI_TMP1081 searchpath=lib/modules/$kver1082 else1083 ###1084 ### Sq-Modification ... Use kernelname for module search path if specified1085 ###1086 #kver=`uname -r`1087 if [ "${kernelname}" != "" ]1088 then1089 kver=${kernelname}1090 else1091 kver=`uname -r`1092 fi1093 ###1094 ### Sq-Modification end1095 ###1096 searchpath=/lib/modules/$kver1097 fi1098 1099 echo -en "for outerloop in 1 2 3 4 5 ; do\necho -en \".\"\n" >> $outfile1100 list_to_echo="$MODULES"1101 # Remove unwanted modules from list1102 for i in $DENY_MODS; do1103 list_to_echo=`echo ${list_to_echo} | tr ' ' '\n' | grep -Ev "^${i}$" | tr '\n' ' '`1104 EXTRA_MODS=`echo ${EXTRA_MODS} | tr ' ' '\n' | grep -Ev "^${i}$" | tr '\n' ' '`1105 done1106 1107 # Make temporary modprobe.conf file if we are told so1108 if [ "$tmpmodprobe_flag" = "Y" ] ; then1109 infile="$MINDI_TMP/modprobe.conf.mindi"1110 find /etc/modprobe.d -maxdepth 1 -name "*" -xtype f -print0 | xargs -0 cat > $infile1111 else1112 infile="/etc/modules.conf"1113 fi1114 1115 for module in $list_to_echo $EXTRA_MODS ; do1116 params=`sed -n "s/^options \\+$module \\+//p" $infile`1117 modpaths=`FindSpecificModuleInPath $searchpath $module`1118 for i in $modpaths ; do1119 echo "MyInsmod $i $params > /dev/null 2> /dev/null" \1120 | tr '.' '#' \1121 | sed s/#o#gz/#o/ \1122 | sed s/#o#gz/#o/ \1123 | sed s/#ko#gz/#ko/ \1124 | sed s/#ko#gz/#ko/ \1125 | tr '#' '.' >> $outfile1126 echo -en "$i added to module list.\n" >> $LOGFILE1127 done1128 done1129 echo -en "done\n" >> $outfile1130 echo "echo \"Done.\"" >> $outfile1131 chmod +x $outfile1132 cd /1133 # Remove temporary modprobe.conf file if we have created one1134 if [ "$tmpmodprobe_flag" = "Y" ] ; then1135 rm -f $infile1136 fi1137 }1138 1139 1140 1071 MakeMountlist() { 1141 1072 local scratchdir mountlist all_partitions current_partition \ … … 2555 2486 cd $old_pwd 2556 2487 echo -en "..." 2557 MakeModuleLoadingScript $TMPMODPROBE_FLAG $mountpoint/sbin/insert-all-my-modules2558 echo -en "..."2559 2488 old_pwd=`pwd` 2560 2489 if [ "$YOUR_KERNEL_SUCKS" ] ; then … … 2722 2651 echo "-----------------------------" >> $LOGFILE 2723 2652 2724 if [ -e "/etc/conf.modules" ] && [ ! -e "/etc/modules.conf" ] ; then2725 LogIt "WARNING - Ancient distro detected." 12726 ln -sf /etc/conf.modules /etc/modules.conf2727 fi2728 2653 [ -e "/sbin/mkdosfs" ] && [ ! -e "/sbin/mkfs.vfat" ] && ln -sf /sbin/mkdosfs /sbin/mkfs.vfat 2729 2654 … … 2760 2685 2761 2686 [ "`uname -r | grep "2.4.[0-6]" | grep -v "2.4.[0-9][0-9]"`" != "" ] && echo "WARNING! Your kernel may have buggy loopfs code. Consider upgrading to 2.4.7" 2762 # If we have a 2.6 kernel, the system uses module-init-tools which means that we2763 # may have the modprobe configuration spread out across multiple files in2764 # directory /etc/modprobe.d. If this is the case we concatenate these files into2765 # a temporary file for further processing. Otherwise we continue in the standard2766 # way. Note further that in case /etc/modprobe.d exists, we use it and ignore2767 # /etc/modprobe.conf which is exactly what module-init-tools does. The temporary2768 # modprobe.conf file is created in MakeModuleLoadingScript. AL041128.2769 if [ -d "/etc/modprobe.d" ] && [ "`uname -r | cut -c1-3`" = "2.6" ] ; then2770 TMPMODPROBE_FLAG="Y"2771 else2772 TMPMODPROBE_FLAG="N"2773 [ -e "/etc/modprobe.conf" ] && [ ! -e "/etc/modules.conf" ] && ln -sf /etc/modprobe.conf /etc/modules.conf2774 [ ! -e "/etc/modules.conf" ] && Die "/etc/modules.conf not found; you may have to create a softlink from /etc/conf.modules to /etc/modules.conf; of course, all good distros use modules.conf anyway..."2775 fi2776 2687 2777 2688 # Update the PATH variable if incomplete -
branches/2.2.6/mindi/rootfs/sbin/init
r1910 r1922 79 79 openvt 7 /bin/sh /sbin/wait-for-petris 80 80 openvt 8 /usr/bin/tail -f $LOGFILE 81 # May avoid shell error messages 82 chmod 666 /dev/tty* /dev/console 81 83 } 82 84 … … 162 164 fi 163 165 echo "Activating a potential USB Storage device" 164 if [ -f usb-storage.ko ] || [ -f usb-storage.ko.gz ]; then 165 if [ -e "/tmp/USE-UDEV" ] ; then 166 modprobe -q usb-storage 167 else 168 insmod usb-storage.ko* 169 fi 170 fi 166 modprobe -q usb-storage 171 167 for i in 1 2 3 4 5 6 7 8 9 10 ; do 172 168 sleep 1 … … 199 195 HowMuchFreeSpaceOnRamdisk() { 200 196 df -m -P | grep /dev/ram | head -n1 | tr -s '\t' ' ' | cut -d' ' -f4 201 }202 203 204 205 InsertEssentialModules() {206 # Load the VIA IDE module first thing if it exists (requires ide-core).207 # This is to ensure that DMA is working for VIA chipsets with 2.6 kernels.208 for module in /ide-core.ko* /via82cxxx.ko*; do209 [ -f "$module" ] && MyInsmod $module > /dev/null 2> /dev/null210 done211 # Then load the remaining modules in normal (i.e. arbitrary) order.212 for j in 1 2 3 4 5 ; do213 for i in `ls /*.*o* 2> /dev/null` ; do214 [ -f "$i" ] && MyInsmod $i > /dev/null 2> /dev/null215 done216 done217 197 } 218 198 … … 314 294 fi 315 295 create_dev_makedev 316 # May avoid shell error messages317 chmod 644 /dev/tty*318 296 if [ -x /sbin/udevsettle ]; then 319 297 /sbin/udevsettle … … 389 367 return 390 368 fi 391 if [ -e "/tmp/USE-UDEV" ] ; then 392 if [ -f uhcd_hci.ko ] || [ -f uhcd_hci.ko.gz ]; then 393 modprobe -q uhcd_hci 394 fi 395 if [ -f usbhid.ko ] || [ -f usbhid.ko.gz ]; then 396 modprobe -q usbhid 397 fi 398 else 399 if [ -f uhcd_hci.ko ]; then 400 insmod uhcd_hci.ko 401 fi 402 if [ -f usbhid.ko ]; then 403 insmod usbcore.ko 404 insmod usbhid.ko 405 fi 406 fi 369 modprobe -q uhcd_hci 370 modprobe -q usbhid 407 371 } 408 372 … … 413 377 LogIt "Scanning LVM's..." 1 414 378 if which lvm ; then 415 MyInsmoddm-mod416 MyInsmoddm_mod379 modprobe -q dm-mod 380 modprobe -q dm_mod 417 381 lvm vgscan --mknodes 418 382 else … … 566 530 ModprobeAllModules() { 567 531 568 for m in `find /lib/modules -name '* .ko*'`; do532 for m in `find /lib/modules -name '*\.ko*' -o -name '*\.o*'`; do 569 533 j=`basename $m | sed 's/\.ko.*$//'` 534 j=`basename $m | sed 's/\.o.*$//'` 570 535 echo "$DENY_MODS" | grep -q "$j " 571 536 if [ $? -eq 0 ]; then … … 584 549 PKLVL=`cut -f1 /proc/sys/kernel/printk` 585 550 echo 0 > /proc/sys/kernel/printk 586 if [ ! -e "/tmp/USE-UDEV" ] ; then 587 echo "Inserting modules ..." 588 insert-all-my-modules >> $LOGFILE 2>> $LOGFILE 589 for i in $FORCE_MODS; do 590 MyInsmod $i 591 done 592 else 593 ModprobeAllModules 594 fi 551 ModprobeAllModules 595 552 echo $PKLVL > /proc/sys/kernel/printk 596 553 } … … 654 611 PKLVL=`cut -f1 /proc/sys/kernel/printk` 655 612 echo 0 > /proc/sys/kernel/printk 656 if [ ! -e "/tmp/USE-UDEV" ] ; then 657 InsertEssentialModules 658 else 659 ModprobeAllModules 660 fi 613 ModprobeAllModules 661 614 echo $PKLVL > /proc/sys/kernel/printk 662 615
Note:
See TracChangeset
for help on using the changeset viewer.