Changeset 1315 in MondoRescue for branches/2.2.2/mindi


Ignore:
Timestamp:
Apr 16, 2007, 4:13:59 PM (17 years ago)
Author:
Bruno Cornec
Message:

Log files are now consistent: mondoarchive.log for mondoarchive (containing also mindi.log) and mondorestore.log for mondorestore (copied from /tmp (ram) to /var/log (disk) at the end of the restore)
One include has been created for each bianry containing only that declaration ofr the moment, but which will be extended to include all local definitions (ps_* e.g.)
Doc updated accordingly
LOGFILE in restore process is now passed in the environment and not duplicated anymore
LogIt is not redifined either
LOGFILE should be put in environment by mondoarchive for mindi's usage but that's a step left for later.

Location:
branches/2.2.2/mindi
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.2/mindi/ChangeLog

    r1311 r1315  
    33MINDI CHANGES
    44
    5 1.2.2 (2007-04-15)
     51.2.2 (2007-04-16)
     6- Mindi log file is now added to mondoarchive log file to ease debug (Bruno Cornec)
    67- Suppress losetup usage in start-nfs (unreliable and doesn't work with QEMU (Bruno Cornec)
    78- Fix a bug where losetup is called with only one parameter (#140) (Bruno Cornec)
  • branches/2.2.2/mindi/mindi

    r1311 r1315  
    430430    echo "Mindi $MINDI_VERSION is exiting" >> $LOGFILE
    431431    echo "End date : `date`" >> $LOGFILE
     432    if [ "`DidMondoCallMe`" ] ; then
     433        cat $LOGFILE >> /var/log/mondoarchive.log
     434    fi
    432435
    433436    sync
     
    452455    fi
    453456
    454     # Creates a tar file containing all required files
    455     for i in /etc/fstab /etc/lilo.conf /etc/raidtab $LOGFILE /var/log/mondo-archive.log ; do
    456         [ -e "$i" ] && cp -f $i $MINDI_TMP 2>> $LOGFILE
    457     done
    458     rm -f $TMPDIR/mindi.err.*.tgz
    459     tar -cf - $MINDI_TMP | gzip -9 > $TMPDIR/mindi.err.$$.tgz
    460     LogIt "Please e-mail a copy of $TMPDIR/mindi.err.$$.tgz to the mailing list."
     457    LogIt "Please e-mail a copy of $LOGFILE to the mailing list."
    461458    LogIt "See http://www.mondorescue.org for more information."
    462459    LogIt "WE CANNOT HELP unless you enclose that file.\n"
     
    13561353                current_partition=$actual_dev
    13571354            else
    1358                 Die "Your system uses a UUID partition ($current_partition), but you lack the tool to support it.\nPlease replace labels with their correct devices in /etc/fstab or install findfs|blkid|vol_id"
     1355                Die "Your system uses a UUID partition ($current_partition), but you lack the tool to support it.\nPlease replace labels with their correct devices in $MY_FSTAB or install findfs|blkid|vol_id"
    13591356            fi
    13601357        else
     
    28922889mount >> $LOGFILE
    28932890echo "-------------" >> $LOGFILE
     2891if [ -e /etc/raidtab ]; then
     2892    echo "-------------" >> $LOGFILE
     2893    echo "/etc/raidtab content:" >> $LOGFILE
     2894    echo "-------------" >> $LOGFILE
     2895    cat /etc/raidtab >> $LOGFILE
     2896fi
     2897echo "-------------" >> $LOGFILE
    28942898echo "lsmod result:" >> $LOGFILE
    28952899echo "-------------" >> $LOGFILE
     
    30313035    LogIt "------------------------------------------------------------------------------"
    30323036else
    3033     echo "You are using Mindi-Linux v$MINDI_VERSION to make boot+data disks" >> /var/log/mondo-archive.log
     3037    echo "You are using Mindi-Linux v$MINDI_VERSION to make boot+data disks" >> $LOGFILE
    30343038fi
    30353039if [ -f $MINDI_LIB/rootfs/bin/busybox ]; then
  • branches/2.2.2/mindi/rootfs/sbin/LogIt

    r746 r1315  
    1111currdate=""
    1212
    13 LOGFILE=/tmp/mondo-restore.log
     13if [ _"$LOGFILE" = _"" ]; then
     14    echo "LOGFILE was undefined. Using /tmp/mondorestore2.log"
     15    LOGFILE="/tmp/mondorestore2.log"
     16fi
     17
    1418if [ ! -e "$LOGFILE" ] ; then
    1519    echo "...first line..." > $LOGFILE
  • branches/2.2.2/mindi/rootfs/sbin/init

    r1273 r1315  
    367367        mount_cmd="mount /dev/shm -t tmpfs -o size=$size" ; # was 34m until 04/2003
    368368        LogIt "Trying '$mount_cmd'"
    369     $mount_cmd /tmp/tmpfs 2>> /$LOGFILE
     369    $mount_cmd /tmp/tmpfs 2>> $LOGFILE
    370370    res=$?
    371371    [ "$res" -eq "0" ] && break
     
    434434MINDI_REV=RRR
    435435trap CaughtSoftReset SIGTERM
    436 LOGFILE=/tmp/mondo-restore.log
     436LOGFILE=/tmp/mondorestore.log
    437437PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/mondo:/usr/games
    438438GROOVY=/tmp/groovy-stuff
    439439USER=root
    440 export PATH GROOVY USER
     440export PATH GROOVY USER LOGFILE
    441441
    442442echo "Welcome to init (from mindi ${MINDI_VER}-r${MINDI_REV}"
  • branches/2.2.2/mindi/rootfs/sbin/install-additional-tools

    r866 r1315  
    4343    biggiefsize=`cat $stub.size`
    4444    rm -f $stub.name $stub.size
    45 #    echo -e -n "\rRecombining #$biggienumber ($biggiefname)        \r"
    4645    > /tmp/out.dat
    4746    sliceno=0
     
    5251        slicefile="$slicefile"$sliceno
    5352        [ ! -e "$slicefile" ] && break
    54 #   echo "biggienumber=$biggienumber slicefile=$slicefile" >> /tmp/mondo-restore.log
    5553        cat $slicefile >> /tmp/out.dat
    5654        rm -f $slicefile
    5755        sliceno=$(($sliceno+1))
    5856        done
    59 #    echo "$sliceno slices"
    6057
    61     echo "$biggiefname ($biggiefsize KB) restored. $sliceno slices." >> /tmp/mondo-restore.log
    62 
    63 #    cat $stub.[0-9]* > /tmp/out.dat
    64 #    rm -f $stub.*               ; # .[0-9]* for the slices, plus .name & .size
    65 
     58    echo "$biggiefname ($biggiefsize KB) restored. $sliceno slices." >> $LOGFILE
    6659
    6760    mkdir -p $biggiefname
  • branches/2.2.2/mindi/rootfs/sbin/post-init

    r739 r1315  
    5757fi
    5858
    59 cat /tmp/mountlist.txt >> /tmp/mondo-restore.log
     59cat /tmp/mountlist.txt >> $LOGFILE
    6060
    6161iso=`grep iso /proc/cmdline`
Note: See TracChangeset for help on using the changeset viewer.