#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
-# 02111-1307, USA.
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301, USA.
PROGNAME=`basename $0`
CONFIGPATH="$SYSCONFDIR/backup"
# The main configuration file may override any of these variables
MT_BEGIN=mt_begin
MT_REWIND=mt_rewind
-MT_OFFLINE=mt_offl
+MT_OFFLINE=mt_offline
MT_STATUS=mt_status
# Insure `mail' is in PATH.
if [ ! -w ${ROOT_FS-/} ]; then
bailout "The backup must be run as root or else some files will fail to be dumped."
fi
- case "${ROOT_FS}" in
- */) ;;
- *) ROOT_FS="${ROOT_FS}/"
- esac
}
+root_fs() {
+ echo "${ROOT_FS}$1" | tr -s /
+}
+
advice() {
echo "Directory $1 is not found." >&2
cat >&2 <<EOF
# usage: get_dump_time LEVEL
get_dump_time() {
ls -r ${LOGPATH}/log-*-level-$1 \
- | head -1 \
+ | head -n 1 \
| sed "s,.*log-\(.*\)-level-$1,\1,"
}
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
- 02111-1307, USA.
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ 02110-1301, USA.
EOF
}