Changeset 275 in MondoRescue for branches/2.06/mondo
- Timestamp:
- Jan 3, 2006, 4:59:29 PM (18 years ago)
- Location:
- branches/2.06/mondo/mondo
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.06/mondo/mondo/common/libmondo-devices.c
r273 r275 2434 2434 strcpy(exclude_these_devices, 2435 2435 call_program_and_get_last_line_of_output 2436 (" cat /etc/fstab | tr -s '\t' ' '| grep -E '( (coda|ncpfs|nfs|smbfs|cifs) )' | cut -d' ' -f1 | tr -s '\n' ' ' | awk '{print $0;}'"));2436 ("tr -s '\t' ' ' < /etc/fstab | grep -E '( (coda|ncpfs|nfs|smbfs|cifs) )' | cut -d' ' -f1 | tr -s '\n' ' ' | awk '{print $0;}'")); 2437 2437 sprintf(result_sz, "%s %s", exclude_these_directories, 2438 2438 exclude_these_devices); … … 2464 2464 strcpy(exclude_these_devices, 2465 2465 call_program_and_get_last_line_of_output 2466 (" cat /etc/fstab | tr -s '\t' ' '| grep -E '( (coda|ncpfs|nfs|smbfs|cifs) )' | cut -d' ' -f1 | tr -s '\n' ' ' | awk '{print $0;}'"));2466 ("tr -s '\t' ' ' < /etc/fstab | grep -E '( (coda|ncpfs|nfs|smbfs|cifs) )' | cut -d' ' -f1 | tr -s '\n' ' ' | awk '{print $0;}'")); 2467 2467 sprintf(result_sz, "%s", exclude_these_directories); 2468 2468 paranoid_free(exclude_these_devices); -
branches/2.06/mondo/mondo/common/libmondo-filelist.c
r273 r275 616 616 // sort_file(filelist); // FIXME - filelist chopper sorts, so this isn't necessary 617 617 sprintf(command, 618 " cat %s | getfacl --all-effective -P -2>> %s | gzip -c1 > %s 2>> %s",618 "getfacl --all-effective -P %s 2>> %s | gzip -c1 > %s 2>> %s", 619 619 filelist, MONDO_LOGFILE, facl_fname, MONDO_LOGFILE); 620 620 iamhere(command); -
branches/2.06/mondo/mondo/common/libmondo-tools.c
r273 r275 336 336 file=$i/.directory; if [ -f \"$file\" ] ; then mv -f $file $file.old ; \ 337 337 awk '{if (index($0, \"rootimagesmindi\")) { while (length($0)>2) { getline;} ; } \ 338 else { print $0;};}' $file.old > $file ; fi ; done");338 else { print $0;};}' $file.old > $file ; fi ; done"); 339 339 run_program_and_log_output(tmp, 5); 340 340 paranoid_free(tmp); -
branches/2.06/mondo/mondo/mondo-makefilelist
r273 r275 1 1 #!/bin/sh 2 # 3 # $Id$ 4 2 5 # 3 6 # mondo-makefilelist … … 82 85 res=`grep -v "Permission denied" $TMP/find.log` 83 86 if [ "$res" != "" ] ; then 84 cat $TMP/find.log 85 cat $TMP/find.log >> $LOGFILE 87 cat $TMP/find.log | tee -a $LOGFILE 86 88 fi 87 89 # include various directory _paths_ (not contents of dirs: that comes later) … … 105 107 106 108 # Patch from Andy Glass - 03/03/2002 107 for i in ` cat /etc/fstab | tr -s '\t' ' '| cut -d' ' -f2 | grep -v '-'` ; do109 for i in `tr -s '\t' ' ' < /etc/fstab | cut -d' ' -f2 | grep -v '-'` ; do 108 110 # End patch 109 # for i in `cat /etc/fstab | tr -s '\t' ' ' | cut -d' ' -f2` ; do110 111 grep -vx "$i/lost+found" $output | grep -vx $i"lost+found" > $output.MID 111 112 sync … … 113 114 done 114 115 # exclude .journal files (ext3) 115 for i in ` cat /etc/fstab | tr -s '\t' ' '| grep "ext3" | cut -d' ' -f2` ; do116 for i in `tr -s '\t' ' ' < /etc/fstab | grep "ext3" | cut -d' ' -f2` ; do 116 117 grep -vx "$i/\.journal" $output | grep -vx "$i\.journal" | grep -vx "$i\.autofsck" > $output.MID 117 118 sync -
branches/2.06/mondo/mondo/mondorestore/mondo-rstr-compare.c
r128 r275 376 376 if (length_of_file(logfile) > 5) { 377 377 sprintf(command, 378 " cat %s | sed s/': \\\"'/\\|/| sed s/'\\\": '/\\|/ | cut -d'|' -f2 | sort | uniq | grep -vx \"dev/.*\" >> /tmp/changed.txt",378 "sed s/': \\\"'/\\|/ %s | sed s/'\\\": '/\\|/ | cut -d'|' -f2 | sort | uniq | grep -vx \"dev/.*\" >> /tmp/changed.txt", 379 379 logfile); 380 380 system(command); -
branches/2.06/mondo/mondo/restore-scripts/mondo/hack-lilo
r273 r275 15 15 GetOldFstabMountpoint() { 16 16 local res 17 res=` cat $old_fstab | tr -s '\t' ' '| grep "$1" | cut -d' ' -f2`17 res=`tr -s '\t' ' ' < $old_fstab | grep "$1" | cut -d' ' -f2` 18 18 # echo "old_fstab = $old_fstab" >> /dev/stderr 19 19 if [ "$res" = "" ] ; then 20 20 # echo "OK, resB" >> /dev/stderr 21 res=` cat $old_mountlist | tr -s '\t' ' '| grep " $1 " | cut -d' ' -f1`21 res=`tr -s '\t' ' ' < $old_mountlist | grep " $1 " | cut -d' ' -f1` 22 22 fi 23 23 echo "$res" … … 34 34 old_mountpoint=`GetOldFstabMountpoint $1` 35 35 # echo "old_mountpoint = $old_mountpoint" >> /dev/stderr 36 new_mountpoint=` cat $new_mountlist | tr -s '\t' ' '| grep " $old_mountpoint" | cut -d' ' -f1`36 new_mountpoint=`tr -s '\t' ' ' < $new_mountlist | grep " $old_mountpoint" | cut -d' ' -f1` 37 37 if [ "$new_mountpoint" = "" ] ; then 38 mtpt=` cat $new_mountlist | tr -s '\t' ' '| grep " $old_mountpoint " | cut -d' ' -f2`39 dev=` cat $new_mountlist | tr -s '\t' ' '| grep " $mtpt " | cut -d' ' -f1`38 mtpt=`tr -s '\t' ' ' < $new_mountlist | grep " $old_mountpoint " | cut -d' ' -f2` 39 dev=`tr -s '\t' ' ' < $new_mountlist | grep " $mtpt " | cut -d' ' -f1` 40 40 # echo "NEW_MP (A) = $dev" >> /dev/stderr 41 41 # else -
branches/2.06/mondo/mondo/restore-scripts/mondo/stabelilo-me
r30 r275 86 86 87 87 WhatIsFirstDriveCalled() { 88 c at /tmp/mountlist.txt | cut -d' ' -f1\88 cut -d' ' -f1 /tmp/mountlist.txt \ 89 89 | sed s/[0-9]// | sed s/[0-9]// \ 90 | sort | uniq| head -n 190 | sort -u | head -n 1 91 91 } 92 92
Note:
See TracChangeset
for help on using the changeset viewer.