RE: automatic ontape level 0?
Posted in 1999
Topics: Backup & Restore, Migration, Import/Export & Data Conversion
Following is the script that I use for unattended backup. My backup fits on
one tape.
#! /bin/ksh
#
# /scripts/INFormix.archive
#
# Archive level 0 to be done Tuesday through Saturday at 2:00 AM
# Tape in slot 1 will be Tuesday, etc.
#
# 991117 Bo Dobbs
day_of_the_week=`date +%u`
let day_of_the_week=day_of_the_week-1
. /scripts/INFormix.env
cd $INFORMIXDIR
print "Wait while the tape is being loaded ..."
/usr/sbin/mc -p/dev/spt85 -sS${day_of_the_week} -dD1
ontape -s -L 0 <<EOF
EOF
/usr/sbin/mc -p/dev/spt85 -sD1 -dS${day_of_the_week}
print "Wait while the tape is being unloaded ..."
-----Original Message-----
From: Loz [mailto:gdf56@dial.pipex.com]
Sent: Friday, December 03, 1999 8:33 AM
To: informix-list@iiug.org
Subject: automatic ontape level 0?
Hi all, just a quick one.
We are using 7.23. at the moment, upgrading to 7.30 next
week. The IDS is
running on Data Generals DGUX.
Is there a way of running "ontape -s -L 0" in a cron? My
only theoretical
hurdle at present is the "mount tape in ...blah blah" prompt
which you need
to press enter at to start the backup.
Is there another switch for ontape that lets you force it
through?
Any help appreciated
TIA
Loz
Dobbs, Bo wrote:
> Following is the script that I use for unattended backup. My backup fits on
> one tape.
>
> #! /bin/ksh
> #
> # /scripts/INFormix.archive
> #
> # Archive level 0 to be done Tuesday through Saturday at 2:00 AM
> # Tape in slot 1 will be Tuesday, etc.
> #
> # 991117 Bo Dobbs
>
> day_of_the_week=`date +%u`
> let day_of_the_week=day_of_the_week-1
>
> . /scripts/INFormix.env
>
> cd $INFORMIXDIR
>
> print "Wait while the tape is being loaded ..."
> /usr/sbin/mc -p/dev/spt85 -sS${day_of_the_week} -dD1
> ontape -s -L 0 <<EOF>
> EOF
> /usr/sbin/mc -p/dev/spt85 -sD1 -dS${day_of_the_week}
> print "Wait while the tape is being unloaded ..."
>
> -----Original Message-----
> From: Loz [mailto:gdf56@dial.pipex.com]
> Sent: Friday, December 03, 1999 8:33 AM
> To: informix-list@iiug.org
> Subject: automatic ontape level 0?
>
> Hi all, just a quick one.
> We are using 7.23. at the moment, upgrading to 7.30 next
> week. The IDS is
> running on Data Generals DGUX.
> Is there a way of running "ontape -s -L 0" in a cron? My
> only theoretical
> hurdle at present is the "mount tape in ...blah blah" prompt
> which you need
> to press enter at to start the backup.
> Is there another switch for ontape that lets you force it
> through?
> Any help appreciated
>
> TIA
> Loz
>
Years ago I wrote a Perl utiility which is similar. It can handle an infinite
number of tapes
and has a place for you to customize where it prompts for tape mounts. It is
at:
http://www.iiug.org/members/memb_software/archive/db_ontape
Enjoy,
Bill Border
Agilent Technologies