Changeset 1341 in MondoRescue
- Timestamp:
- Apr 25, 2007, 12:27:26 AM (18 years ago)
- Location:
- branches/stable/mondo/src/restore-scripts/mondo
- Files:
-
- 1 deleted
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/stable/mondo/src/restore-scripts/mondo/Makefile.am
r424 r1341 1 1 restoremondodir = $(pkgdatadir)/restore-scripts/mondo 2 restoremondo_SCRIPTS = ISO ask-me-a-question compare- me compare-subroutine-me \2 restoremondo_SCRIPTS = ISO ask-me-a-question compare-subroutine-me \ 3 3 edit-mountlist grub-MR hack-fstab hack-grub hack-lilo hack-elilo \ 4 4 ide-opt ide-opt-off label-partitions-as-necessary \ -
branches/stable/mondo/src/restore-scripts/mondo/grub-MR
r567 r1341 1 1 #!/bin/sh 2 3 2 # 3 # $Id$ 4 # 4 5 # grub-MR ------ a rudimentary replacement for grub-install 5 6 # 6 7 # 7 #8 # 2005/11/259 # - try_grub_hack : do not return success when grub wrote 'Error '10 #11 # 2004/06/2812 # - added support for /dev/md0==GRUB13 #14 # 2004/06/2715 # - re-enable the call to grub-install and the 'echo' thing as a backup16 # - hacked the hack :) to improve MDK9.2 support17 # - added try_grub_hack()18 #19 # 2004/06/1420 # - just use grub-install.patched; nothing else21 #22 # 2004/05/0523 # - try EVERYTHING - grub-install, grub --batch, etc.24 #25 # 2004/04/1826 # - try grub --batch < /etc/grub.conf first27 # - if it fails, grub-install.patched instead28 # - if _that_ fails, fail.29 #30 # 2004/04/1531 # - added grub-install.patched to the mix32 #33 # 2004/04/0134 # - use grub-install if there's an NTFS partition on the disk35 #36 # 2004/03/3137 # - disabled direct call to grub38 #39 # 2004/03/2840 # - call grub directly if possible41 #42 # 2004/03/2643 # - find stage 1 if possible; more stable, reliable call to grub44 #45 # 2003/08/2446 # - fixed line 26 (Christian)47 #48 # 2002/11/1849 # - first incarnation50 51 52 LOGFILE=/var/log/mondo-archive.log53 54 8 55 9 Die() { -
branches/stable/mondo/src/restore-scripts/mondo/hack-lilo
r567 r1341 1 1 #!/bin/sh 2 3 4 LogIt() { 5 echo "$1" >> /tmp/mondo-restore.log 6 } 7 2 # 3 # $Id$ 4 # 8 5 9 6 -
branches/stable/mondo/src/restore-scripts/mondo/label-partitions-as-necessary
r1297 r1341 7 7 8 8 read_partition_line() { 9 local tmplabel mountpt command format9 local label mountpt command format 10 10 11 if [ "`echo "$1" | grep -E 'LABEL='`" != "" ] ; then 11 label=`echo "$1" | awk '{print $1}' | cut -d'=' -f2` 12 format=`echo "$1" | awk '{print $3}'` 13 14 if [ "`echo "$1" | grep -E 'LABEL='`" != "" ] ; then 12 15 opttun="-L" 13 elif [ "`echo "$1" | grep -E 'UUID='`" != "" ] ; then 16 mountpt=`awk '{print $1,$5}' $mountlist | grep " $label$" | awk '{print $1}'` 17 elif [ "`echo "$1" | grep -E 'UUID='`" != "" ] ; then 14 18 opttun="-U" 19 mountpt=`awk '{print $1,$6}' $mountlist | grep " $label$" | awk '{print $1}'` 15 20 else 16 21 # Nothing to do 17 22 return 18 23 fi 19 24 20 tmp=`echo "$1" | tr -s ' ' '\t' | cut -f1`21 label=`echo "$tmp" | cut -d'=' -f2`22 format=`echo "$1" | tr -s ' ' '\t' | cut -f3`23 mountpt=`grep -w " $label" $mountlist | cut -d' ' -f1`24 25 if [ ! "$mountpt" ] ; then 25 LogIt "Not labeling anything as $label because $mountptis not a mountpoint"26 LogIt "Not labeling anything as ($label) because ($mountpt) is not a mountpoint" 26 27 elif [ ! "$label" ] ; then 27 LogIt "Not labeling $mountpt as anything because $labelis not a label"28 LogIt "Not labeling ($mountpt) as anything because ($label) is not a label" 28 29 else 29 30 if [ "$format" = "ext2" ] || [ "$format" = "ext3" ] ; then -
branches/stable/mondo/src/restore-scripts/mondo/make-me-bootable
r911 r1341 1 1 #!/bin/sh 2 3 4 LOGFILE=/tmp/mondo-restore.log5 6 2 7 3 -
branches/stable/mondo/src/restore-scripts/mondo/raw-MR
r567 r1341 7 7 LogIt "Restoring MBR..." 2 8 8 if uname -a | grep -q FreeBSD; then 9 echo -e 'y\ny' | /mnt/RESTORING/sbin/fdisk -b /BOOTLOADER.MBR -B $1 >/dev/null 2>> /tmp/mondo-restore.log9 echo -e 'y\ny' | /mnt/RESTORING/sbin/fdisk -b /BOOTLOADER.MBR -B $1 >/dev/null 2>> $LOGFILE 10 10 else 11 dd if=/BOOTLOADER.MBR of=$1 bs=446 count=1 2>> /tmp/mondo-restore.log11 dd if=/BOOTLOADER.MBR of=$1 bs=446 count=1 2>> $LOGFILE 12 12 fi 13 13 exit $? -
branches/stable/mondo/src/restore-scripts/mondo/stabgrub-me
r1001 r1341 1 1 #!/bin/sh 2 2 # 3 # stabgrub-me 4 # 5 # 04/08/2003 6 # - cleaned up backup func a bit 7 # 8 # 9 # 10 # forked from stablilo-me on 2002/11/20 3 # $Id$ 11 4 # 12 5 ##################################################################### 13 6 14 15 LOGFILE=/tmp/mondo-restore.log16 7 17 8 QuitIfNotFound() { -
branches/stable/mondo/src/restore-scripts/mondo/stabraw-me
r567 r1341 1 1 #!/bin/sh 2 2 # 3 # stabraw-me 4 # 5 # forked from stablilo-me on 2002/11/21 3 # $Id$ 6 4 # 7 5 ##################################################################### 8 6 9 10 LOGFILE=/tmp/mondo-restore.log11 7 12 8 QuitIfNotFound() { … … 16 12 fi 17 13 } 18 19 20 21 22 14 23 15 LocateOldFstab() {
Note:
See TracChangeset
for help on using the changeset viewer.