Changeset 1939 in MondoRescue for branches/stable/mindi


Ignore:
Timestamp:
May 17, 2008, 1:29:54 AM (16 years ago)
Author:
Bruno Cornec
Message:

svn merge -r 1923:1938 $SVN_M/branches/2.2.6

Location:
branches/stable/mindi
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • branches/stable/mindi/README.pxe

    r1302 r1939  
    2121server is the ip addr of the NFS server
    2222mountpoint is the mount point on the NFS server to use (should be in /etc/exports of the NFS server)
     23The [] mean this parameter is optional
     24The () mean that you have a choice with the '|' meaning 'or'
    2325
    2426The initrd and kernel file come from the first bootable media
  • branches/stable/mindi/deplist.txt

    r1924 r1939  
    3030fdisk hdparm parted uname
    3131loadkeys
    32 mount
    33 devfsd burnBX burnK6 burnK7 burnMMX burnP5 burnP6 lucifer tiobench tiotest bonnie++ mprime ide-smart
     32# These lines require absolute paths now !
     33/bin/mount
     34/sbin/mount.nfs /sbin/mount.nfs4
     35/sbin/mount.fuse
     36/sbin/mount.cifs /sbin/mount.cifs3
     37/sbin/mount.smb /sbin/mount.smb3
     38/sbin/mount.smbfs /sbin/mount.smbfs3
    3439# helps for debugging
    3540/usr/bin/ldd
    3641/usr/bin/strace
     42
     43#
     44devfsd burnBX burnK6 burnK7 burnMMX burnP5 burnP6 lucifer tiobench tiotest bonnie++ mprime ide-smart
    3745
    3846# For udev
  • branches/stable/mindi/distributions/conf/mindi.conf.dist

    r1924 r1939  
    9393#
    9494mindi_scsi_mods="3w-xxxx 3w_xxxx 3w-9xxx 3w_9xxx 53c7,8xx a100u2w a320raid aacraid adpahci advansys aha152x aha1542 aha1740 aic79xx aic79xx_mod aic7xxx aic7xxx_mod aic7xxx_old AM53C974 atp870u BusLogic cciss cpqfc dmx3191d dpt_i2o dtc eata eata_dma eata_pio fdomain gdth g_NCR5380 i2o_block i2o_core ide-scsi ieee1394 imm in2000 initio ips iscsi isp megaraid megaraid_mm megaraid_mbox megaraid_sas mptbase mptscsih mptsas mptspi mptfc mptscsi mptctl NCR53c406a ncr53c8xx nsp32 pas16 pci2000 pci2220i pcmcia ppa psi240i qla1280 qla2200 qla2300 qla2xxx qla2xxx_conf qlogicfas qlogicfc qlogicisp raw1394 scsi_debug scsi_mod scsi_transport_sas scsi_transport_spi sd_mod seagate sg sim710 sr_mod sym53c416 sym53c8xx sym53c8xx_2 t128 tmscsim u14-34f ultrastor wd7000 vmhgfs"
    95 mindi_ide_mods="ide ide-generic ide-detect ide-mod ide-disk ide-cd ide_cd ide-cs ide-core ide_core edd paride ata_generic ata_piix libata via82cxxx generic nvidia ahci sata_nv cmd64x pata_amd pata_marvell pata_serverworks"
    96 mindi_usb_mods="usb-storage usb-ohci usb-uhci usbcore usb_storage input hid uhci_hcd ehci_hcd uhci-hcd ehci-hcd ohci-hcd ohci_hcd usbkbd usbhid keybdev mousedev libusual"
     95mindi_ide_mods="ide ide-generic ide-detect ide-mod ide-disk ide_disk ide-cd ide_cd ide-cs ide-core ide_core edd paride ata_generic ata_piix libata via82cxxx generic nvidia ahci sata_nv cmd64x pata_amd pata_marvell pata_serverworks"
     96# Replace with that line for HP OCMP e.g.
     97#DENY_MODS="MPS_Driver_Mapper mps octtldrv tscttl streams kqemu"
     98mindi_usb_mods="usb-storage usb-ohci usb-uhci usbcore usb_storage input hid uhci_hcd ehci_hcd uhci-hcd ehci-hcd ohci-hcd ohci_hcd usbkbd usbhid keybdev mousedev libusual scsi_mod"
    9799mindi_pcmcia_mods="pcmcia_core ds yenta_socket"
    98 mindi_cdrom_mods="cdrom isocd isofs inflate_fs nls_iso8859-1 nls_cp437 nls_utf8 sg sr_mod zlib_inflate"
     100mindi_cdrom_mods="cdrom isocd isofs inflate_fs nls_iso8859-1 nls_base nls_cp437 nls_utf8 sg sr_mod zlib_inflate iso9660"
    99101mindi_tape_mods="ht st osst ide-tape ide_tape"
    100102mindi_net_mods="sunrpc nfs nfs_acl lockd fscache loop mii 3c59x e100 bcm5700 bnx2 e1000 eepro100 ne2k-pci tg3 pcnet32 8139cp 8139too 8390 forcedeth vmxnet vmnet"
  • branches/stable/mindi/mindi

    r1924 r1939  
    108108
    109109BOOT_MEDIA_MESSAGE="$mindi_boot_msg"
    110 
    111110FDISK=$MINDI_SBIN/parted2fdisk
    112111
     
    172171
    173172    mkdir -p $bigdir/etc
    174     #cp --parents -pRdf $mappath $bigdir 2>> $LOGFILE || LogIt "AKMF -- Could not copy $mappath to $bigdir"
    175173    tar cf - $mappath 2>> /dev/null | (cd $bigdir ; tar xf -) || LogIt "AKMF -- Could not copy $mappath to $bigdir"
    176174    if [ "`echo $mappath | grep -F ".gz"`" ] ; then
     
    282280                BIGNO=$(($BIGNO+1))
    283281            else
    284                 #cp --parents -Rdf $incoming $outdir 2> /dev/null || Die "Cannot copy $incoming to $outdir - did you run out of disk space?"
    285282                tar cf - $incoming 2> /dev/null | (cd $outdir ; tar xf -) || Die "Cannot copy $incoming to $outdir - did you run out of disk space?"
    286283   
     
    299296        incoming=`ReadLine`
    300297    done
    301 }
    302 
    303 
    304 CopyImageToDisk() {
    305     local image dev procno res comment
    306     image=$1
    307     dev=$2
    308     comment=$3
    309     [ ! -f "$image" ] && [ ! -b "$image" ] && Die "Image $image does not exist. Did you run out of disk space?"
    310     Prompt "About to write $comment. Please press ENTER."
    311     echo -en "Formatting disk..."
    312     if which fdformat > /dev/null ; then
    313         fdformat -n $dev > /dev/null 2> /dev/null || Die "Cannot format $dev - is your Linux distro broken?"
    314     elif which superformat > /dev/null ; then
    315         superformat $dev > /dev/null 2> /dev/null || Die "Cannot format $dev - is your Linux distro broken?"
    316     else
    317         Die "Please install either fdformat or superformat."
    318     fi
    319     echo -en "\nWriting $comment"
    320     if echo $image | grep "mindi-[r|b]oot\.1440" &> /dev/null ; then
    321         cat $image > $dev &
    322     else
    323         dd if=$image of=$dev &> /dev/null &
    324     fi
    325     procno=$!
    326     ps $procno > /dev/null 2> /dev/null
    327     while [ "$?" -eq "0" ] ; do
    328         sleep 3
    329         echo -en "."
    330         ps $procno > /dev/null 2> /dev/null
    331     done
    332     echo -e "$DONE"
    333     LogIt "$comment has been written."
    334298}
    335299
     
    14391403    MakeSyslinuxMessageFile $MINDI_TMP/iso/isolinux/message.txt
    14401404    cp $kernelpath $MINDI_TMP/iso/isolinux/vmlinuz 2>> $LOGFILE || Die "Cannot copy vmlinuz ($kernelpath) to mindi tmp ($MINDI_TMP/iso/isolinux/vmlinuz). Did you run out of disk space?"
    1441     cp $MINDI_TMP/mindi.rdz $MINDI_TMP/iso/isolinux/initrd.img 2>> $LOGFILE
     1405    cp $MINDI_TMP/mindi.rdz $MINDI_TMP/iso/isolinux/initrd.img 2>> $LOGFILE || Die "Cannot copy mindi.rdz ($MINDI_TMP/mindi.rdz) to $MINDI_TMP/iso/isolinux/initrd.img. Did you run out of disk space?"
    14421406    if [ _"$MONDO_SHARE" != _"" ]; then
    1443         cp $kernelpath $MONDO_ROOT/vmlinuz 2>> $LOGFILE || Die "Cannot copy vmlinuz ($kernelpath) to mondo root ($MONDO_ROOT/vmlinuz). Did you run out of disk space?"/dev/null
    1444         cp $MINDI_TMP/mindi.rdz $MONDO_ROOT/initrd.img 2>> $LOGFILE || Die "Cannot copy mindi.rdz ($MINDI_TMP/mindi.rdz) to mondo root ($MONDO_ROOT/vmlinuz). Did you run out of disk space?"
    1445 
     1407        cp $kernelpath $MONDO_ROOT/vmlinuz 2>> $LOGFILE || Die "Cannot copy vmlinuz ($kernelpath) to mondo root ($MONDO_ROOT/vmlinuz). Did you run out of disk space?"
     1408        cp $MINDI_TMP/mindi.rdz $MONDO_ROOT/initrd.img 2>> $LOGFILE || Die "Cannot copy mindi.rdz ($MINDI_TMP/mindi.rdz) to $MONDO_ROOT/initrd.img. Did you run out of disk space?"
    14461409    fi
    14471410    [ -e "$iso_cfg_file" ] || Die "FIXME - unable to find $iso_cfg_file - this should never occur"
     
    19601923        cd $MINDI_TMP
    19611924        for i in `ListKernelModulePaths | HackPathsToFailsafe` ; do
    1962             #cp --parents -pRdf ./$i $bigdir 2>> $LOGFILE || Die "PDDI can't cp $i->$bigdir"
    19631925            tar cf - ./$i 2>> $LOGFILE | (cd $bigdir ; tar xf -) || Die "PDDI can't copy $i->$bigdir"
    19641926            if [ "`du -sk $i | cut -f1`" -lt "$(($CHOPSIZE*2))" ] ; then
    1965                 #cp --parents -pRdf $i $bigdir 2>> $LOGFILE
    19661927                tar cf - $i 2>> $LOGFILE | (cd $bigdir ; tar xf -)
    19671928            else
     
    19751936            for k in $j ; do
    19761937                if [ "`du -sk $k | cut -f1`" -lt "$CHOPSIZE" ] ; then
    1977                     #cp --parents -pRdf $k $bigdir 2>> $LOGFILE
    19781938                    tar cf - $k 2>> $LOGFILE | (cd $bigdir ; tar xf -)
    19791939                else
     
    23522312        s=`which $w 2> /dev/null`
    23532313        if [ -e "$s" ] ; then
    2354             #cp --parents -af $s . 2>> $LOGFILE
    23552314            tar cf - $s 2> /dev/null | tar xf -
    23562315        fi
     
    23622321    file $MINDI_LIB/rootfs/bin/busybox 2>&1 | grep -q "dynamically"
    23632322    if [ $? -eq 0 ]; then
    2364         # We want to use the real mount
    2365         rm -f bin/mount
    2366         LocateDeps $MINDI_LIB/rootfs/bin/busybox /bin/mount > $MINDI_TMP/busy.lis
    2367         #cp --parents -Rdf `sort -u $MINDI_TMP/busy.lis` .
    2368         tar cf - /bin/mount `sort -u $MINDI_TMP/busy.lis` 2> /dev/null | tar xf -
     2323        # We want to use the real mount and all the supported variants (nfs, cifs, ...)
     2324        rm -f bin/mount $MINDI_TMP/busy.lis
     2325        mountlis=`grep mount $DEPLIST_FILE`
     2326        for f in $MINDI_LIB/rootfs/bin/busybox $mountlis ; do
     2327            if [ -f $f ]; then
     2328                LocateDeps $f >> $MINDI_TMP/busy.lis
     2329            fi
     2330        done
     2331        tar cf - $mountlis `sort -u $MINDI_TMP/busy.lis` 2> /dev/null | tar xf -
    23692332        rm -f $MINDI_TMP/busy.lis
    23702333    fi
     
    23762339        echo "udev device manager found" > $mountpoint/tmp/USE-UDEV
    23772340        LogIt "udev device manager found"
    2378         #cp --parents -Rdf /etc/udev . 2> /dev/null
    23792341        tar cf - /etc/udev 2> /dev/null | tar xf -
    23802342        # This avoids NIC remapping if on another machine at restore time on Debian at least
    23812343        rm -f ./etc/udev/rules.d/z25_persistent-net.rules
    2382         #cp --parents -Rdf /lib/udev /lib64/udev . 2> /dev/null
    23832344        tar cf - /lib*/udev 2> /dev/null | tar xf -
    23842345        if [ -x /sbin/udevd ]; then
     
    24072368                fi
    24082369            done
    2409             #cp --parents -Rdf $lis `sort -u $MINDI_TMP/udev.lis` .
    24102370            tar cf - $lis `sort -u $MINDI_TMP/udev.lis` 2> /dev/null | tar xf -
    24112371            rm -f $MINDI_TMP/udev.lis
     
    24262386            lis=`grep -Ev '^#' $MINDI_CACHE/tools.files`
    24272387            LocateDeps $lis > $MINDI_TMP/tools.lis
    2428             #cp --parents -Rdf $lis `sort -u $MINDI_TMP/tools.lis` .
    24292388            tar cf - $lis `sort -u $MINDI_TMP/tools.lis` 2> /dev/null | tar xf -
    24302389        fi
     
    24462405    fi
    24472406
    2448     #cp --parents -Rdf /dev/fd0*[1,2][4,7,8]* . 2> /dev/null
    24492407    tar cf - /dev/fd0*[1,2][4,7,8]* 2> /dev/null | tar xf -
    24502408
     
    24892447        [ "$YOUR_KERNEL_SUCKS" ] && i=$MINDI_TMP/$i
    24902448        echo "Adding $i ($s KB) to the rootfs" >> $LOGFILE
    2491         #cp --parents -Rpdf $i $mountpoint 2>/dev/null || LogIt "Unable to copy $i to $mountpoint"
    24922449        tar cf - $i 2>/dev/null | (cd $mountpoint ; tar xf -) || LogIt "Unable to copy $i to $mountpoint"
    24932450        # Uncompress modules if not using udev and native modprobe
     
    25012458
    25022459    # Also copy modules.dep in case of udev so that normal modprobe works
    2503     #cp --parents -Rpdf /$needed_modules_path/modules.dep $mountpoint 2>/dev/null || LogIt "Unable to copy modules.dep to $mountpoint"
    25042460    tar cf - /$needed_modules_path/modules.dep 2>/dev/null | (cd $mountpoint ; tar xf -) || LogIt "Unable to copy modules.dep to $mountpoint"
    25052461
     
    25502506        ln -sf sbin/init init
    25512507        # create cpio image file and unmount loop filesystem
    2552         find . -print | cpio -o -H newc | gzip -9 > $old_pwd/$rdz_fname 2> /dev/null
     2508        find . -print | cpio -o -H newc | gzip -9 > $rdz_fname 2> /dev/null
    25532509        cd $old_pwd
    25542510        umount $mountpoint || Die "Cannot unmount $tempfile"
  • branches/stable/mindi/rootfs/sbin/init

    r1924 r1939  
    531531
    532532    for m in `find /lib/modules -name '*\.ko*' -o -name '*\.o*'`; do
    533         j=`basename $m | sed 's/\.ko.*$//'`
    534         j=`basename $m | sed 's/\.o.*$//'`
     533        k=`basename $m | sed 's/\.ko.*$//'`
     534        j=`basename $k | sed 's/\.o.*$//'`
    535535        echo "$DENY_MODS" | grep -q "$j "
    536536        if [ $? -eq 0 ]; then
  • branches/stable/mindi/rootfs/sbin/start-nfs

    r1842 r1939  
    6868    # Finally mounts the NFS share
    6969    LogIt "Mounting NFS share ($nfsmount) on /tmp/isodir..."
     70    touch /etc/mtab
    7071    mount -t nfs -o nolock $nfsmount /tmp/isodir
    7172   
    7273    LogIt "Mounting NFS image ${imgname}-1.iso in $dirimg on /mnt/cdrom in loopback"
    73     mount -o ro -t iso9660 /tmp/isodir/$dirimg/${imgname}-1.iso /mnt/cdrom
     74    mount -o ro,loop -t iso9660 /tmp/isodir/$dirimg/${imgname}-1.iso /mnt/cdrom
    7475fi
Note: See TracChangeset for help on using the changeset viewer.