In article <Pine.OSF.3.95.981210102642.17965B-100000_at_gonzo.wolfenet.com>,
Jeremiah Wilton <jeremiah_at_wolfenet.com> wrote:
> On Thu, 10 Dec 1998, Peter Kellner wrote:
> >
> > I'd like to automate backing up an NT server running oracle 7.3.
> > Right now, it is a big pain because of all the manual steps. I want
> > to have one script that does an incremental with the system HOT,
> > and another script that shuts the database down, does a full backup,
> > then starts it again.
> >
> > Any ideas or places I can find such a thing. I want to make sure that
> > error status are checked for things like deleting transaction logs.
>
> Hot backups in Oracle7 are not "incremental." They are complete backups of
> whatever files you copy in the process of the hot backup. If you copy all
> the files, it is a complete backup. Therefore, there is no real reason to
> take a cold backup, unless you don't trust your hot backup scheme.
>
> I don't know any Scripts for NT that are in the pulic domain, but I bet
> someone has one. Searching around the web might turn something up. There
> are many commercial products available as well. Oracle provides a backup
> and recovery solutution with 7.3 called Enterprise Backup Utility (EBU),
> which must be used with a storage manager, such as Legato or Veritas. More
> information on this strategy is available at Oracle's Backup Solutions
> Partners page:
>
> http://www.oracle.com/st/products/features/backupsp.html
>
> --
> Jeremiah Wilton http://www.wolfenet.com/~jeremiah
>
>
Actually, if you connect to metalink and check under SERVERS->Oracle Server
Enterprise Edition->Microsoft You will find some documents under the
Technical Bulletins (look under WINDOWS NT heading. There are several there
that give full COLD/HOT backup scripts and how to schedule them in NT.
Here's one of the documents (sorry cut/paste doesnt work to well from HTML to
the text box im typing in.)
-Frank
Document ID: 11816480.61Title: NT: Scheduled Backups on
Windows NT Creation Date: 3-Feb-97Last Revision Date: 3-Feb-97Revision
Number: 0 Product Version: 7.2x, 7.3xPlatform: Windows NT versions
3.51, 4.0 Information Type: SolutionImpact: Medium Abstract:
This is a tutorial which explains how to create command files
to backup an Oracle database, and how to schedule the events.
Keywords: DATABASE;INSTANCE;BACKUP;AUTOMATE,AUTOMATING,AUTOMATED
- NT: Scheduled Backups on Windows NT The following procedure will allow a
DBA to perform unattended cold backups of an Oracle database(s). This
procedure can be performed with both the Windows NT GUI scheduler which is
bundled with the Windows NT resource kit, and the command line AT scheduler.
This procedure involves the following steps: -Shutdown the Oracle database,
and stop associated services. -Copy associated database files. -Start the
Oracle services and the Oracle database. -Backup the files to tape.
Scheduling commands require the scheduler service. The Schedule Service
should be started through the Control Panel Services applet. Note: The
scheduler service runs as the Windows NT System account, therefore,
permissions on the Oracle directories must be set accordingly. You may also
change the scheduler service to start as a different account. Assumption:
This bulletin assumes the starter database name 'Oracle', a sid of
'ORCL', and an ORACLE_HOME of C:\ORANT. 1. Create a command file to startup,
copy files and shutdown the database. For version 7.2xContents of:
BACKORCL.CMD REM The following runs a sql script to shutdown the database.
c:\orant\bin\sqldba72 @c:\orant\admin\shutdown.sql REM The following will
shutdown the oracle services to close any open files. net stop
OracleServiceORCL REM The following assumes a separate d: drive with
orant\database directories. copy c:\orant\database\. d:\orant\backup Rem The
following will reload the oracle72 kernel into memory net start
OracleServiceORCL REM The following runs a sql script to startup the
database. c:\orant\bin\sqldba72 @c:\orant\admin\startup.sql REM Use the
NTBACKUP to backup filesREM Parameters: Description (/d), REM Backup the
local registry (/b)REM Backup with Hardware Compression (/hc), REM Type
Normal (/t not incremental), REM with Logfile BACKUP.LOG (/l), Include
Exceptions only (/e), REM To Tape 0 (/tape) NTBackup Backup d:\orant\backup
/d "NT backup of d:\orant\backup" /b /hc:on /t Normal /l
c:\orant\admin\ntbackup.log /e /tape:0For version 7.3x Contents of:
BACKORCL.CMD REM The following runs a sql script to shutdown the database.
c:\orant\bin\svrmgr23 @c:\orant\admin\shutdown.sql REM The following will
shutdown the oracle services to close any open files. net stop
OracleServiceORCL REM The following assumes a separate d: drive with
orant\database directories. copy c:\orant\database\. d:\orant\backup REM The
following will reload the oracle72 kernel into memory net start
OracleServiceORCL REM The following runs a sql script to startup the
database. c:\orant\bin\svrmgr23 @c:\orant\admin\startup.sql REM Use the
NTBACKUP to backup filesREM Parameters: Description (/d), REM Backup the
local registry (/b)REM Backup with Hardware Compression (/hc), REM Type
Normal (/t not incremental), REM with Logfile BACKUP.LOG (/l), Include
Exceptions only (/e), REM To Tape 0 (/tape) NTBackup Backup d:\orant\backup
/d "NT backup of d:\orant\backup" /b /hc:on /t Normal /l
c:\orant\admin\ntbackup.log /e /tape:0 2. Create startup and shutdown
scripts:Contents of shutdown.sql connect internal/password_at_2:orclshutdown
immediateexit Note: Shutdown immediate should be used to disconnect and
rollback any connected users, otherwise the shutdown will probably hang
waiting for users to disconnect. Shutdown immediate will work in most
occurrences. At your own discretion, you can create a script that performs
a shutdown abort, startup, the shutdown immediate. This will always work.
Contents of startup.sqlconnect internal/password_at_2:orcl startup
pfile=c:\orant\database\initorcl.oraexit 3. Scheduling the backup command
file. To schedule the backup with the Windows NT AT command line scheduler,
use the following command. This command will run every week day at 12pm, and
append output and errors, respectively, to the C:\ORANT\ADMIN\BACKUP.LOG
file. at 12:00p /every:M,T,W,TH,F "C:\ORANT\ADMIN\BACKORCL.CMD 1>>
C:\ORANT\ADMIN\BACKUP.LOG 2>> C:\ORANT\ADMIN\BACKUP.LOG" This will schedule
the backup to run the next 12pm. Below is the from the at command after
scheduling the backup.C:\tmp>at Status ID Day Time
Command Line
- 3 Each M T W Th F 12:00 PM C:\ORANT\ADMIN\BACKORCL.CMD
1>C:\ORANT\ADMIN\BACKUP.LOG 2>> C:\ORANT\ADMIN\BACKUP.LOG You can get help
with the 'at' command with the following command at the command prompt.at ?
To schedule with the GUI command scheduler, perform the following. Double
click on the scheduler from the resource kit program groupSelect 'Add' Enter
the full path and file name of the BACKORCL.CMD. Fill in the appropriate
time, days, and frequency.Select Okay.Hints: To locate the database files
that need to be backed up, you can use the following views: select name from
v$datafile; select member from v$logfile; select name from v$controlfile;
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
Received on Fri Dec 11 1998 - 09:14:32 CST