Home » Server Options » Data Guard » Data Script
Data Script [message #177816] Fri, 16 June 2006 12:59 Go to next message
howie_ho@hotmail.com
Messages: 3
Registered: June 2006
Junior Member
Hi,

I would like to know how to write a batch file in windows for dataguard environment.

For Example.
-------------------
I woud like to write a batch file to show me the help command.

c:\dgmgrl
help alter;

How do you put these two statements in the batch file in windows? Your help is highly apprecicated.

I need to automate the process to change the standby to read-only at midnight so I dont have to get up everyday at midnight at change the database to read-only mode. I can accomplish via sqlplus, but it's not recommended in the dataguard environment.



Thanks,
Howie Ho
Re: Data Script [message #177819 is a reply to message #177816] Fri, 16 June 2006 13:15 Go to previous messageGo to next message
Frank Naude
Messages: 4564
Registered: April 1998
Senior Member
I cannot test right now, but his should work:

C:> dgmgrl sys/oracle "help alter"
Re: Data Script [message #177825 is a reply to message #177819] Fri, 16 June 2006 13:37 Go to previous messageGo to next message
howie_ho@hotmail.com
Messages: 3
Registered: June 2006
Junior Member
The dataguard only takes these args.


dgmgrl [-silent] [-xml] [-debug] [-echo]

Thanks,
Howie Ho
Re: Data Script [message #177826 is a reply to message #177825] Fri, 16 June 2006 13:45 Go to previous messageGo to next message
Frank Naude
Messages: 4564
Registered: April 1998
Senior Member
Strange, on Oracle 10g R2/ Unix it takes these parameters:

$ dgmgrl -help
Unknown option: -help
Usage: dgmgrl [<options>] [<logon> [<command>]]
  <options> ::= -silent | -echo
  <logon>   ::= <usename>/<password>[@<connect_identifier>]
  <command> ::= <one DGMGRL command>
Re: Data Script [message #177833 is a reply to message #177826] Fri, 16 June 2006 15:07 Go to previous message
howie_ho@hotmail.com
Messages: 3
Registered: June 2006
Junior Member
We use 9iR2. I looks like 9i does not have the logon option.
Previous Topic: logical standby method for applying SQL to primary ?
Next Topic: Query on Standby Switchover
Goto Forum:
  


Current Time: Mon Apr 06 01:25:05 CDT 2020