Changeset 262


Ignore:
Timestamp:
Dec 23, 2005, 5:25:52 PM (14 years ago)
Author:
bcornec
Message:

merge -r253:261 $SVN_M/branches/2.05

Location:
trunk
Files:
1 deleted
10 edited
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/mindi/README.pxe

    r236 r262  
    77
    88Add the following line to your default file:
    9 mondo
     9label mondo
    1010        kernel vmlinuz-mondo
    11         initrd initrd-mondo load_ramdisk=1 prompt_ramdisk=0 ramdisk_size=36864 rw root=/dev/ram iso_mode acpi=off apm=off devfs=nomount exec-shield=0 pxe [prefix="machine"] [ipconf=(ipadr:netmask:broadcast:gateway|dhcp)] [ping=#] ...
     11        append initrd=initrd-mondo load_ramdisk=1 prompt_ramdisk=0 ramdisk_size=36864 rw root=/dev/ram iso_mode acpi=off apm=off devfs=nomount exec-shield=0 pxe [prefix="machine"] [ipconf=(ipadr:netmask:broadcast:gateway|dhcp)] [ping=#] ...
    1212
    1313The initrd and kernel file come rom the first bootable media
  • trunk/mindi/mindi

    r244 r262  
    129129    if which awk &> /dev/null ; then
    130130    if ! which gawk &> /dev/null ; then
    131         LogIt "You have awk but not gawk. Please note that mindi works fine with a _sane_ awk binary. If your awk binary misbehaves then please contact your vendor or distribution's mailing list for technical support."
     131        LogIt "You have awk but not gawk.\nPlease note that mindi works fine with a _sane_ awk binary.\nIf your awk binary misbehaves then please contact your vendor\nor distribution's mailing list for technical support.\n"
    132132    fi
    133133    fi
     
    138138    FDISKLOG=/tmp/parted2fdisk.log
    139139    touch $FDISKLOG
    140 #    if [ "`cat /etc/issue.net 2> /dev/null | fgrep -i "debian"`" ] ; then
    141 #        LogIt "Warning - You are a Debian user. If mindi doesn't generate a good mountlist, it's because of a bug in YOUR awk binary. Don't tell me about it. Tell awk.deb's maintainer about it."
    142 #    fi
    143140    [ ! -e "$FDISK" ] && Die "Cannot find (s)fdisk"
    144141}
     
    235232        mappath=`find $KEYDIR/keymaps | grep "i[3-8]86" | grep "$locale[^r][^/]" | grep -vx " *#.*"`
    236233        if [ ! -e "$mappath" ] ; then
    237             LogIt "Cannot add $mappath: kbd map file not found"
     234            LogIt "Cannot add $mappath: kbd map file not found\n"
    238235            return
    239236        fi
     
    243240
    244241    mkdir -p $bigdir/etc
    245     cp --parents -pRdf $mappath $bigdir || LogIt "AKMF -- Could not copy $mappath to $bigdir"
     242    cp --parents -pRdf $mappath $bigdir || LogIt "AKMF -- Could not copy $mappath to $bigdir\n"
    246243    if [ "`echo $mappath | fgrep ".gz"`" ] ; then
    247244        included_list=`gzip -dc $mappath | fgrep -i include | sed s/'"'// | sed s/'"'// | cut -d' ' -f2`
     
    285282    if [ "`echo "$filename" | fgrep "lib/modules/" | grep "\.*o\.gz"`" != "" ] ; then
    286283    mv $scratchfile $scratchfile.gz
    287     gunzip -f $scratchfile || LogIt "Cannot gunzip $scratchfile.gz"
     284    gunzip -f $scratchfile || LogIt "Cannot gunzip $scratchfile.gz\n"
    288285    filename=`echo "$filename" | tr '.' '#' | sed s/#o#gz/#o/ | sed s/#ko#gz/#ko/ | tr '#' '.'`
    289286    fi
     
    309306    if [ $liloc ]; then
    310307        if ! [ `strings $liloc | grep "boot\.b"` ]; then
    311             LogIt "boot.b files built into lilo; I'll create a dummy."
     308            LogIt "boot.b files built into lilo; I'll create a dummy.\n"
    312309            > $copy_to
    313310            return 0
     
    315312    fi
    316313    if [ ! -f "$copy_from" ] ; then
    317         LogIt "OK, you don't have a /boot/boot.b file, which is odd because most _good_ Linux distributions come with one, even if it's only a softlink"
     314        LogIt "OK, you don't have a /boot/boot.b file, which is odd because\n most _good_ Linux distributions come with one, even if it's only a softlink"
    318315        copy_from=`cat /etc/lilo.conf | grep install= | grep "\.b" | cut -d'=' -f2`
    319316        if [ ! -f "$copy_from" ] ; then
    320             LogIt "Nor can I find it from your /etc/lilo.conf file. This is very odd."
     317            LogIt "Nor can I find it from your /etc/lilo.conf file. This is very odd.\n"
    321318            copy_from=`FindSensibleBootBFile`
    322             LogIt "I'm going to use '$copy_from'"
    323         fi
    324     fi
    325     cp -f $copy_from $copy_to || LogIt "CBBF -- warning -- cannot find your boot.b file. That's it, I quit... (j/k)"
     319            LogIt "I'm going to use '$copy_from'\n"
     320        fi
     321    fi
     322    cp -f $copy_from $copy_to || LogIt "CBBF -- warning -- cannot find your boot.b file. That's it, I quit... (j/k)\n"
    326323}
    327324
     
    346343                cp --parents -Rdf $incoming $outdir || Die "Cannot copy $incoming to $outdir - did you run out of disk space?"
    347344        if [ "`echo "$incoming" | grep "lib/modules/.*\..*o\.gz"`" != "" ] ; then
    348             gunzip -f $outdir/$incoming || LogIt "Cannot gunzip $outdir/$incoming"
     345            gunzip -f $outdir/$incoming || LogIt "Cannot gunzip $outdir/$incoming\n"
    349346        fi
    350347        [ -x "$outdir" ] && StripExecutable $outdir "-$filename-"
     
    391388    done
    392389    echo -e "$DONE"
    393     LogIt "$comment has been written."
     390    LogIt "$comment has been written.\n"
    394391}
    395392
     
    423420    while [ "$diskno" -le "$noof_disks" ] ; do
    424421    echo -en "#$diskno..."
    425     cp -f $tardir/$diskno.tar.gz $outdir || LogIt "[line 424] Cannot copy $tardir/$diskno.tar.gz to $outdir"
     422    cp -f $tardir/$diskno.tar.gz $outdir || LogIt "[line 424] Cannot copy $tardir/$diskno.tar.gz to $outdir\n"
    426423        CreateOneDataDiskImage $tardir/$diskno.tar.gz $outdir/mindi-data-$diskno.img $diskno $noof_disks
    427424        diskno=$(($diskno+1))
     
    494491    tar -cf - mindi.err | gzip -9 > mindi.err.$$.tgz
    495492    rm -Rf mindi.err /tmp/mountlist.txt.$$ mindilinux $FDISKLOG
    496     LogIt "Please e-mail a copy of /tmp/mindi.err.$$.tgz to the mailing list."
    497     LogIt "See http://www.mondorescue.org for more information."
    498     LogIt "WE CANNOT HELP unless you enclose that file."
     493    LogIt "Please e-mail a copy of /tmp/mindi.err.$$.tgz to the mailing list.\n"
     494    LogIt "See http://www.mondorescue.org for more information.\n"
     495    LogIt "WE CANNOT HELP unless you enclose that file.\n"
    499496    exit 1
    500497}
     
    544541FindAndAddUserKeyboardMappingFile() {
    545542    local r res mapfile mappath included_item included_list keyfile mp locale
    546     LogIt "Analyzing your keyboard's configuration."
     543    LogIt "Analyzing your keyboard's configuration.\n"
    547544    KEYDIR=/lib/kbd
    548545    [ ! -e "$KEYDIR" ] && KEYDIR=/usr/share/kbd     # Slackware
     
    550547    [ ! -e "$KEYDIR" ] && KEYDIR=/usr/share
    551548    if [ ! -e "$KEYDIR" ] ; then
    552     LogIt "Keyboard mapping directory not found. I shall use default map at boot-time."
     549    LogIt "Keyboard mapping directory not found. I shall use default map at boot-time.\n"
    553550    return 0
    554551    fi
     
    576573    keyfile=`find /etc -name rc.config | head -n1`
    577574    if [ "$keyfile" = "" ] || [ ! -e "$keyfile" ] ; then
    578         LogIt "Unknown config detected. Default keyboard map will be used."
     575        LogIt "Unknown config detected. Default keyboard map will be used.\n"
    579576        return
    580577    else
     
    583580    fi
    584581    if [ ! -e "$KEYDIR/keymaps" ] ; then
    585         LogIt "Keyboard mapping directory not found. Default keyboard map will be used."
     582        LogIt "Keyboard mapping directory not found. Default keyboard map will be used.\n"
    586583        return
    587584    fi
     
    601598    echo "mappath = $mappath" >> $LOGFILE
    602599    if [ ! -e "$mappath" ] || [ -d "$mappath" ] ; then
    603     LogIt "Keyboard mapping file not found. Default keyboard map will be used."
     600    LogIt "Keyboard mapping file not found. Default keyboard map will be used.\n"
    604601    return
    605602    fi
     
    618615
    619616FindHomeOfMindiAndMondo() {
    620 # nice patch from Martin Fürstenau
    621     for mh in /usr/lib /usr/opt /usr/share /usr/local /usr/local/share /usr/share/local /opt /opt/share /usr /ramdisk/usr/local/share /ramdisk/usr/share ; do
    622         if [ ! -L $mh ] ; then
    623            MH_PATH=$mh
    624            SYMLINK=0
    625            while [ $MH_PATH != "/" ] ; do
    626            MH_PATH=`dirname $MH_PATH`
    627                if [ -L $MH_PATH ] ; then
    628           SYMLINK=1
    629            fi
    630            done
    631 
    632            if [ $SYMLINK -ne 1 ] ; then
    633           if [ -d "$mh/mondo" ] && [ -e "$mh/mondo/restore-scripts" ] ; then
    634               [ "$MONDO_HOME" ] && Die "You have multiple instances of Mondo - one at $MONDO_HOME and one at $mh/mondo"
    635               MONDO_HOME=$mh/mondo
    636           fi
    637            fi
    638         fi
    639     done
    640 # end patch
    641 
    642617    [ "$MINDI_PREFIX" = "XXX" ] && Die "Mindi has not been installed correctly."
    643618    echo "MINDI_LIB = $MINDI_LIB" >> $LOGFILE
     
    645620    [ "$MINDI_CONF" = "YYY" ] && Die "Mindi has not been installed correctly."
    646621    echo "MINDI_CONF = $MINDI_CONF" >> $LOGFILE
    647     echo "MONDO_HOME = $MONDO_HOME" >> $LOGFILE
     622    echo "MONDO_LIB = $MONDO_LIB" >> $LOGFILE
    648623    mkdir -p $CACHE_LOC
    649624}
     
    669644    if which lilo.real > /dev/null 2> /dev/null ; then
    670645        LILO_EXE=lilo.real
    671         LogIt "lilo.real found; will be used instead of lilo (*grumble* *mutter*)"
     646        LogIt "lilo.real found; will be used instead of lilo (*grumble* *mutter*)\n"
    672647    else
    673648        LILO_EXE=lilo
     
    724699    fi
    725700    if [ ! -e "$1" ] ; then
    726     LogIt "Warning - cannot search specific path '$1'"
     701    LogIt "Warning - cannot search specific path '$1'\n"
    727702    return 1
    728703    fi
     
    864839    mkdir -p $bigdir/bin
    865840    if [ -e "$MONDO_TMP/post-nuke.tgz" ] ; then
    866         LogIt "\nIncorporating post-nuke tarball"
     841        LogIt "\nIncorporating post-nuke tarball\n"
    867842        old_pwd=`pwd`
    868843        cd $bigdir
    869         tar -zxf $MONDO_TMP/post-nuke.tgz || LogIt "Error occurred when untarring post-nuke tarball"
     844        tar -zxf $MONDO_TMP/post-nuke.tgz || LogIt "Error occurred when untarring post-nuke tarball\n"
    870845        cd $old_pwd
    871846    fi
     
    873848            LocateDeps $bigdir/usr/bin/mondo*restore >> $outfile.pre
    874849    else
    875         LogIt "Cannot find mondo*restore in mondo's tempdir, $MONDO_TMP"
    876         LogIt "I bet you've got a spare copy of Mondo or Mindi floating around on your system."
    877             LogIt "If Mindi was called by Mondo then send me a bug report. It not, type 'ps ax' to see which Mondo-related process is still running; then kill it. :-) Finally, run Mindi again."
     850        LogIt "Cannot find mondo*restore in mondo's tempdir, $MONDO_TMP\n"
     851        LogIt "I bet you've got a spare copy of Mondo or Mindi floating around on your system.\n"
     852            LogIt "If Mindi was called by Mondo then send me a bug report.\n It not, type 'ps ax' to see which Mondo-related process is still running;\n then kill it. :-)\n Finally, run Mindi again."
    878853            Die "Odd."
    879854        fi
    880         cp -f $MONDO_TMP/BOOTLOADER.* $bigdir 2> /dev/null || LogIt "\nMondo v1.2x defaults to LILO as the bootloader, BTW."
     855        cp -f $MONDO_TMP/BOOTLOADER.* $bigdir 2> /dev/null || LogIt "\nMondo v1.2x defaults to LILO as the bootloader, BTW.\n"
    881856    if [ -e "$MONDO_TMP/start-nfs" ] ; then
    882         LogIt "Incorporating NFS-related settings"
     857        LogIt "Incorporating NFS-related settings\n"
    883858        cp -f $MONDO_TMP/start-nfs $bigdir/sbin || Die "Cannot find start-nfs"
    884859        for r in NFS-SERVER-MOUNT NFS-SERVER-PATH NFS-DEV NFS-CLIENT-IPADDR NFS-SERVER-IPADDR ; do
     
    14401415        partition_format="compaq"
    14411416        elif [ ! "`fgrep device /etc/raidtab 2> /dev/null | grep -w $current_partition`" ] ; then
    1442         LogIt "Unable to find mountpoint of $current_partition - ignoring"
     1417        LogIt "Unable to find mountpoint of $current_partition - ignoring\n"
    14431418        continue
    14441419        fi
     
    15921567    fi
    15931568    if [ ! "$MONDO_TMP" ] ; then
    1594         LogIt "NB: Mindi's bootable CD always uses isolinux."
    1595         LogIt "For a bootable CD w/LILO, please use Mondo."
     1569        LogIt "NB: Mindi's bootable CD always uses isolinux.\n"
     1570        LogIt "For a bootable CD w/LILO, please use Mondo.\n"
    15961571    fi
    15971572    rm -Rf $TMP_ROOT/iso
     
    16071582    k=$TMP_ROOT/iso/isolinux
    16081583    if [ -e "$j" ] ; then
    1609         LogIt "Copying $j to $k"
     1584        LogIt "Copying $j to $k\n"
    16101585        cp -f $j $k || Die "Failed to copy $j to $k"
    16111586        cp -f $j $TMP_ROOT || Die "Failed to copy $j to $k"
     
    16311606        cp -f $TMP_ROOT/iso/isolinux/{isolinux.cfg,initrd.img,vmlinuz,isolinux.bin,message.txt} $MONDO_ROOT || Die "Cannot copy core files to ramdisk for boot disk. Did you run out of disk space?"
    16321607    fi
    1633     [ "$MONDO_HOME" ] && cp -f $MONDO_HOME/autorun .   
     1608    [ "$MONDO_LIB" ] && cp -f $MONDO_LIB/autorun .   
    16341609    if [ -d "/home/MondoCD" ] ; then
    16351610    cp -pRdu /home/MondoCD/* .
     
    17131688    cp -f $1 vmlinuz
    17141689    if [ "$?" -ne "0" ] ; then
    1715         LogIt "Failed to copy $1 to ramdisk"
     1690        LogIt "Failed to copy $1 to ramdisk\n"
    17161691        cd $old_pwd
    17171692        umount $mtpt
     
    19071882    LogIt "Please unload some of your modules and try again.\n"
    19081883    rm -f $TMP_ROOT/mtpt.$$
    1909     LogIt "Cannot incorporate mindi.rdz in bootdisk (kernel / modules too big?)"
     1884    LogIt "Cannot incorporate mindi.rdz in bootdisk (kernel / modules too big?)\n"
    19101885        retval=$(($retval+1))
    19111886    fi
     
    19451920    res=$(($res+$?))
    19461921    rm -f $imagefile
    1947     [ "$res" -ne "0" ] && LogIt "Warning - failed to create 1.44MB boot/root floppies"
     1922    [ "$res" -ne "0" ] && LogIt "Warning - failed to create 1.44MB boot/root floppies\n"
    19481923    rm -f $imagesdir/mindi-*.1440.img
    19491924    return $res
     
    20532028    LogIt "Please unload some of your modules and try again.\n"
    20542029    rm -f $TMP_ROOT/mtpt.$$
    2055     LogIt "Cannot incorporate mindi.rdz in bootdisk (kernel / modules too big?)"
     2030    LogIt "Cannot incorporate mindi.rdz in bootdisk (kernel / modules too big?)\n"
    20562031        retval=$(($retval+1))
    20572032    fi
     
    20832058        res=$(($res+$?))
    20842059        rm -f $imagefile
    2085         [ "$res" -ne "0" ] && LogIt "Warning - failed to create 1.44MB boot/root floppies"
     2060        [ "$res" -ne "0" ] && LogIt "Warning - failed to create 1.44MB boot/root floppies\n"
    20862061        return $res
    20872062    fi
     
    21852160    i=`cat $MONDO_TMP/BOOTLOADER.DEVICE 2> /dev/null`
    21862161    if [ "$i" ] ; then
    2187     LogIt "Backing up $i's MBR"
     2162    LogIt "Backing up $i's MBR\n"
    21882163    dd if=$i of=$bigdir/BOOTLOADER.MBR bs=446 count=1 >> $LOGFILE 2>> $LOGFILE
    21892164# < < E O F
     
    21932168    j=$i
    21942169    [ -h "$j" ] && j=`ResolveSoftlink $j`
    2195     LogIt "Creating /dev/boot_device ($j)"
     2170    LogIt "Creating /dev/boot_device ($j)\n"
    21962171    mkdir -p $bigdir/dev
    21972172    cp -pRdf $j $bigdir/dev/boot_device || Die "Unable to create /dev/boot_device on ramdisk"
     
    22082183    tar -zxf $MINDI_LIB/x11-tools.tgz 2>> $LOGFILE || LogIt "Warning - error occurred while unzipping x11-tools.tgz\n"
    22092184    fi
    2210     if [ -e "$MONDO_HOME/restore-scripts" ] ; then
    2211         cp -Rdf $MONDO_HOME/restore-scripts/* . 2>> $LOGFILE
    2212         [ "$?" -ne "0" ] && [ "`DidMondoCallMe`" ] && Die "Cannot find/install $MONDO_HOME/restore-scripts"
     2185    if [ -e "$MONDO_LIB/restore-scripts" ] ; then
     2186        cp -Rdf $MONDO_LIB/restore-scripts/* . 2>> $LOGFILE
     2187        [ "$?" -ne "0" ] && [ "`DidMondoCallMe`" ] && Die "Cannot find/install $MONDO_LIB/restore-scripts"
    22132188    fi
    22142189    [ -d "/lib/dev-state" ] && cp --parents -pRdf /lib/dev-state .
     
    25752550    else
    25762551        if [ "`strings $fname 2> /dev/null | fgrep "$kdate"`" = "" ] ; then
    2577             LogIt "Have you recompiled your kernel \"$fname\" w/o rebooting? Naughty but I'll allow it...\n"
     2552            LogIt "Have you recompiled your kernel \"$fname\" w/o rebooting?\n Naughty but I'll allow it...\n"
    25782553            duff_kernels="$fname $duff_kernels"
    25792554        else
     
    25872562    fi
    25882563    if [ ! "$possible_kernels" ] ; then
    2589         LogIt "No kernel matches exactly. Are there any duff kernels?"
     2564        LogIt "No kernel matches exactly. Are there any duff kernels?\n"
    25902565        possible_kernels="$duff_kernels"
    25912566        if [ ! "$possible_kernels" ] ; then
    2592             LogIt "Sorry, no duff kernels either"
     2567            LogIt "Sorry, no duff kernels either\n"
    25932568        else
    2594             LogIt "I bet you're running Debian or Gentoo, aren't you?"
    2595             LogIt "Your kernel doesn't have a sane builddate. Oh well..."
     2569            LogIt "I bet you're running Debian or Gentoo, aren't you?\n"
     2570            LogIt "Your kernel doesn't have a sane builddate. Oh well...\n"
    25962571        fi
    25972572    fi
     
    26142589            if echo $i | grep "`uname -r`" ; then
    26152590        LogIt "OK, I used my initiative and found that "
    2616                 LogIt "$i is probably your kernel. "
     2591                LogIt "$i is probably your kernel.\n "
    26172592        output="$i"
    26182593        return
     
    27862761        rm -f $mountpoint/bin/busybox.net
    27872762    fi
    2788     [ -e "$floppy_modules_path" ] || LogIt "path $floppy_modules_path does not exist. If you're not using a modular kernel then you're NUTS."
     2763    [ -e "$floppy_modules_path" ] || LogIt "path $floppy_modules_path does not exist.\n If you're not using a modular kernel then you're NUTS.\n"
    27892764    for i in $list_of_groovy_mods ; do
    27902765    floppy_modules="$floppy_modules `FindSpecificModuleInPath $floppy_modules_path $i`"
     
    27942769    [ "$YOUR_KERNEL_SUCKS" ] && i=$TMP_ROOT/$i
    27952770    echo "Adding $i ($s KB) to the rootfs" >> $LOGFILE
    2796     cp -df $i $mountpoint/ || LogIt "Unable to copy $i to $mountpoint"
     2771    cp -df $i $mountpoint/ || LogIt "Unable to copy $i to $mountpoint\n"
    27972772    [ "`echo "$i" | fgrep ".gz"`" ] && gunzip -f $mountpoint/`basename $i`
    27982773    done
     
    28662841    diskno=1
    28672842    while [ "$diskno" -le "$noof_disks" ] ; do
    2868         cd $minidir_root/$diskno || LogIt "Warning - cannot cd to $minidir_root/$diskno"
     2843        cd $minidir_root/$diskno || LogIt "Warning - cannot cd to $minidir_root/$diskno\n"
    28692844        tar -cf - . 2>> $LOGFILE | gzip -9 > $tardir/$diskno.tar.gz || Die "Can't tar/gzip disk#$diskno; please tell Hugo -exactly- what the errors where."
    28702845        diskno=$(($diskno+1))
     
    29412916
    29422917if [ -e "/etc/conf.modules" ] && [ ! -e "/etc/modules.conf" ] ; then
    2943     LogIt "Warning - Ancient distro detected." 1
     2918    LogIt "Warning - Ancient distro detected.\n" 1
    29442919    ln -sf /etc/conf.modules /etc/modules.conf
    29452920fi
     
    29752950    FindLiloBinary
    29762951fi
    2977 cat /proc/mounts | fgrep " $TMP_ROOT " | fgrep tmpfs > /dev/null 2> /dev/null && TMP_ROOT=/home && LogIt "Changing TMP_ROOT to $TMP_ROOT because you're using tmpfs for /tmp" ; # tmpfs doesn't like Mindi and /tmp, for some reason
     2952cat /proc/mounts | fgrep " $TMP_ROOT " | fgrep tmpfs > /dev/null 2> /dev/null && TMP_ROOT=/home && LogIt "Changing TMP_ROOT to $TMP_ROOT because you're using tmpfs for /tmp\n" ; # tmpfs doesn't like Mindi and /tmp, for some reason
    29782953rm -f /tmp/mindi_lo
    29792954trap "Aborted" SIGTERM
     
    30313006###
    30323007        kernelname=`echo $kernelpath | cut -d'-' -f2-`
    3033     LogIt "kernelname = $kernelname"
    3034     LogIt "kernelpath = $kernelpath"
     3008    LogIt "kernelname = $kernelname\n"
     3009    LogIt "kernelpath = $kernelpath\n"
    30353010        if [ ! -d "/lib/modules/$kernelname" ] && [ "$kernelpath" != "FAILSAFE" ]
    30363011        then
     
    30693044        [ "$USE_COMP" = "" ] && USE_COMP=yes
    30703045        [ "$NOT_BOOT" = "" ] && NOT_BOOT=no
    3071     [ "$TAPEDEV" ] && LogIt "This is a tape-based backup. Fine."
     3046    [ "$TAPEDEV" ] && LogIt "This is a tape-based backup. Fine.\n"
    30723047    [ "$kernelpath" = "" ] && kernelpath=`TryToFindKernelPath`
    30733048        kernelname=`echo $kernelpath | cut -d'-' -f2-`
     
    31173092mkdir -p $imagesdir
    31183093if [ ! "`DidMondoCallMe`" ] ; then
    3119     LogIt "Mindi Linux mini-distro generator v$MINDI_VERSION"
    3120     LogIt "Latest Mindi is available from http://mondorescue.berlios.de"
    3121     LogIt "BusyBox sources are available from http://www.busybox.net"
     3094    LogIt "Mindi Linux mini-distro generator v$MINDI_VERSION\n"
     3095    LogIt "Latest Mindi is available from http://mondorescue.berlios.de\n"
     3096    LogIt "BusyBox sources are available from http://www.busybox.net\n"
    31223097    LogIt "------------------------------------------------------------------------------"
    31233098else
     
    31383113echo "NOT_BOOT = '$NOT_BOOT'" >> $LOGFILE
    31393114if [ "$NOT_BOOT" != "" ] && [ "$NOT_BOOT" != "0" ] && [ "$NOT_BOOT" != "no" ] ; then
    3140     LogIt "Just creating mondo-restore.cfg and a small all.tar.gz for Mondo. Nothing else."
     3115    LogIt "Just creating mondo-restore.cfg and a small all.tar.gz for Mondo. Nothing else.\n"
    31413116    MakeMondoConfigFile $MONDO_TMP/mondo-restore.cfg
    31423117    MakeMountlist $MONDO_TMP/mountlist.txt
     
    31813156if [ "$YOUR_KERNEL_SUCKS" != "" ] || [ "$kernelpath" = "" ] || [ "$kernelpath" = "SUCKS" ] || [ "$kernelpath" = "FAILSAFE" ] ; then
    31823157    kernelpath=$MINDI_LIB/vmlinuz
    3183     LogIt "I shall include Mindi's failsafe kernel, not your kernel, in the boot disks."
    3184     LogIt "However, you are still running your kernel. If Mindi fails to create your"
    3185     LogIt "disks then it may still be a result of a problem with your kernel."
     3158    LogIt "I shall include Mindi's failsafe kernel, not your kernel, in the boot disks.\n"
     3159    LogIt "However, you are still running your kernel. If Mindi fails to create your\n"
     3160    LogIt "disks then it may still be a result of a problem with your kernel.\n"
    31863161    pwd=`pwd`
    31873162    cd $TMP_ROOT
     
    31913166fi
    31923167echo -e "Mindi's temp dir = $TMP_ROOT \nMindi's output dir=$imagesdir" >> $LOGFILE
    3193 [ "$(($RANDOM%64))" -eq "0" ] && LogIt "Dude, I've looked inside your computer and it's really dusty..."
     3168[ "$(($RANDOM%64))" -eq "0" ] && LogIt "Dude, I've looked inside your computer and it's really dusty...\n"
    31943169rm -f /tmp/mindi.err.*.tgz
    31953170
     
    32103185    else
    32113186        if ! PrepareBootDiskImage_LILO $imagesdir 1722 $kernelpath $ramdisk_size ; then
    3212         LogIt "Warning - failed to create 1.72MB boot image. Please reduce your kernel's size"
    3213         LogIt "if you want to make a 1.72MB floppy disk."
     3187        LogIt "Warning - failed to create 1.72MB boot image. Please reduce your kernel's size\n"
     3188        LogIt "if you want to make a 1.72MB floppy disk.\n"
    32143189        fi
    32153190        PrepareBootDiskImage_LILO $imagesdir 2880 $kernelpath $ramdisk_size || Die "Failed to create 2.88MB floppy disk image."
     
    32173192else
    32183193    if ! PrepareBootDiskImage_SYSLINUX $imagesdir 1722 $kernelpath $ramdisk_size ; then
    3219     LogIt "Warning - failed to create 1.72MB boot image. Please reduce your kernel's size"
    3220     LogIt "if you want to make a 1.72MB floppy disk."
     3194    LogIt "Warning - failed to create 1.72MB boot image. Please reduce your kernel's size\n"
     3195    LogIt "if you want to make a 1.72MB floppy disk.\n"
    32213196    fi
    32223197    if ! PrepareBootDiskImage_SYSLINUX $imagesdir 2880 $kernelpath $ramdisk_size ; then
    3223         LogIt "Warning - failed to create 2.88MB floppy disk image."
    3224         LogIt "Please reduce your kernel's size"
    3225         LogIt "if you want to make a 2.88MB floppy disk."
     3198        LogIt "Warning - failed to create 2.88MB floppy disk image.\n"
     3199        LogIt "Please reduce your kernel's size\n"
     3200        LogIt "if you want to make a 2.88MB floppy disk.\n"
    32263201    fi
    32273202    PrepareBootDiskImage_SYSLINUX $imagesdir 5760 $kernelpath $ramdisk_size || Die "Failed to create 5.76MB floppy disk image."
     
    32593234if [ "$imagesdir" != "/root/images/mindi" ] ; then
    32603235    for i in `find $imagesdir -maxdepth 1 -name "*.iso" -o -name "*.img"` ; do
    3261     cp -f $i /root/images/mindi || LogIt "[line 3260] Cannot copy $i to /root/images/mindi"
     3236    cp -f $i /root/images/mindi || LogIt "[line 3260] Cannot copy $i to /root/images/mindi\n"
    32623237    done
    32633238fi
     
    32653240# cleanup
    32663241rm -f /tmp/mountlist.txt.$$ $FDISKLOG /tmp/mindilinux
    3267 LogIt "$FRIENDLY_OUTSTRING"
     3242LogIt "$FRIENDLY_OUTSTRING\n"
    32683243ListUnsavedKernelModules
    32693244for mtpt in $FLOPPY_WAS_MOUNTED ; do
  • trunk/mindi/mindi.spec

    r250 r262  
    9393%defattr(644,root,root,755)
    9494%config(noreplace) %{_sysconfdir}/mindi/deplist.txt
    95 %doc CHANGES INSTALL COPYING README TODO README.ia64 README.pxe README.busybox
     95%doc ChangeLog INSTALL COPYING README TODO README.ia64 README.pxe README.busybox
    9696%{_mandir}
    9797%{_libdir}/mindi
  • trunk/mondo/ChangeLog

    r197 r262  
     1# $Id$
     2
    13MONDO CHANGES
    24
     
    79  needed + remove memory leaks)
    810
    9 v2.06 (xxx)
     11v2.06 (2005-12-23)
    1012- better error handling of failed commands/mindi (Andree Leidenfrost)
    1113- fix compiler warnings (Andree Leidenfrost)
     
    3032- remove sbminst (Bruno Cornec/Andree Leidenfrost)
    3133- use parted2fdisk everywhere (Bruno Cornec)
     34- exports MONDO_LIB (Bruno Cornec)
     35- RPM build for fedora core 4, sles9, redhat 7.3, rhel 3/4, mandriva 2006.0,
     36  mandrake 10.2 (Bruno Cornec/Gary Granger)
     37- interactive mode now asks for image size and prefix in NFS mode
     38  (Gallig Renaud/Bruno Cornec)
     39- iso-prefix should be read in iso mode even when -H not given (Stan Benoit)
     40- VERSION/RELEASE Tag added (Bruno Cornec)
     41- many code cleanup, small fixes, PXE/NFS code improvements
     42  (Sébastien Aperghis-Tramoni/Bruno Cornec)
    3243
    3344v2.05 (2005-11-19)
     
    464475""""""""""
    465476v1.40-6 (STABLE)
    466 - incorporated new config.guess, config.sub (H�tor Garc� �varez)
     477- incorporated new config.guess, config.sub (H�tor Garc� �varez)
    467478- updated manual to explain tmpfs needs to be in kernel (Mikael Hultgren)
    468479- don't let non-root users run mondoarchive
  • trunk/mondo/mondo/common/libmondo-archive-EXT.h

    r59 r262  
    4141                                          char *filelist, char *fname,
    4242                                          int setno);
     43extern void setenv_mondo_lib(void);
  • trunk/mondo/mondo/common/libmondo-archive.c

    r171 r262  
    37413741
    37423742/* @} - end of utilityGroup */
     3743
     3744void setenv_mondo_lib(void) {
     3745
     3746setenv("MONDO_LIB", MONDO_LIB, 1);
     3747}
  • trunk/mondo/mondo/common/libmondo-archive.h

    r59 r262  
    4242int archive_this_fileset_with_star(struct s_bkpinfo *bkpinfo,
    4343                                   char *filelist, char *fname, int setno);
     44void setenv_mondo_lib(void);
  • trunk/mondo/mondo/common/libmondo-devices.c

    r252 r262  
    16971697                   call_program_and_get_last_line_of_output(command));
    16981698            paranoid_free(command);
     1699
     1700            asprintf(&comment,
     1701                    "How much data (in Megabytes) will each media store?");
     1702            if (!popup_and_get_string("Size", comment, sz_size, 5)) {
     1703                log_to_screen("User has chosen not to backup the PC");
     1704                finish(1);
     1705            }
     1706            for (i = 0; i <= MAX_NOOF_MEDIA; i++) {
     1707                bkpinfo->media_size[i] = atoi(sz_size);
     1708            }
     1709            if (bkpinfo->media_size[0] <= 0) {
     1710                log_to_screen("User has chosen not to backup the PC");
     1711                finish(1);
     1712            }
     1713            paranoid_free(comment);
    16991714        }
    17001715        if (bkpinfo->disaster_recovery) {
  • trunk/mondo/mondo/mondoarchive/main.c

    r252 r262  
    172172    setenv("ARCH", get_architecture(), 1);
    173173
     174    /* Add MONDO_LIB environment variable for mindi */
     175    setenv_mondo_lib();
     176
    174177    unlink(MONDO_LOGFILE);
    175178
  • trunk/tools/rpm-env

    r238 r262  
    4646        export ddir="rhel"
    4747        export dver=`cat /etc/redhat-release | awk '{print $7}'`
     48    elif grep -q Fedora /etc/redhat-release ; then
     49        export ddir="fedora"
     50        export dver=`cat /etc/redhat-release | awk '{print $4}'`
     51        export suf="fc${dver}"
    4852    else
    4953        export ddir="redhat"
    50         export dver=`cat /etc/redhat-release | awk '{print $5}'`
    51         export suf="${dver}rh"
     54        export dver=`cat /etc/redhat-release | awk '{print $5}' | sed "s/\.//"`
     55        export suf="rh${dver}"
    5256    fi
    5357elif [ -e /etc/SuSE-release ]; then
Note: See TracChangeset for help on using the changeset viewer.