~0x44/agent-smith/script_changes_for_testing

« back to all changes in this revision

Viewing changes to scripts/update_fstab_for_rescue.sh

  • Committer: Christopher MacGown
  • Date: 2010-10-07 17:34:17 UTC
  • Revision ID: chris@slicehost.com-20101007173417-90ghivkcr6wesr59
Updates to agent so that all scripts can be executed with messages

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/bin/bash
2
 
 
3
 
export ROOT="${ROOT:-}"
4
 
export AGENTSMITHDIR="${AGENTSMITHDIR:-/usr/share/agent-smith}"
5
 
export TEMP="${TEMP:-$ROOT/tmp}"
6
 
 
7
 
. "${AGENTSMITHDIR}/common.sh"
8
 
 
9
 
FSTAB="/etc/fstab"
10
 
 
11
 
backupfile="$(make_backup $ROOT/$FSTAB)"
12
 
 
13
 
if [ ! -f "${backupfile}" ]; then
14
 
  exit 1
15
 
fi
16
 
 
17
 
sed -i.backup. 's/sda1/sdb1/g' "$ROOT/$FSTAB"