2012年04月12日

Problem


VERITAS NetBackup (tm) Oracle backups fail with status 6 and RMAN-01005: "syntax error: found "dot": expecting one of: "double-quoted-string, equal, identifier, single-quoted-string""

Error


RMAN-01005: syntax error: found "dot": expecting one of: "double-quoted-string, equal, identifier, single-quoted-string"

Solution


Oracle RMAN backup script fails with the following output. The dbclient log does not show any activity.

# ./hot_database_backup.sh
==== started on Sat Jul 6 15:04:11 BST 2002 ====

RMAN: /usr1/app/oracle/product/9.2.0/bin/rman
ORACLE_SID: oracle
ORACLE_USER: oracle
ORACLE_HOME: /usr1/app/oracle/product/9.2.0

NB_ORA_FULL:
NB_ORA_INCR:
NB_ORA_CINC:
NB_ORA_SERV:
NB_ORA_POLICY:

Default - Full backup requested
Sun Microsystems Inc. SunOS 5.8 Generic February 2000

Argument Value Description
-----------------------------------------------------------------------------
target quoted-string connect-string for target database
catalog quoted-string connect-string for recovery catalog
nocatalog none if specified, then no recovery catalog
cmdfile quoted-string name of input command file
log quoted-string name of output message log file
trace quoted-string name of output debugging message log file
append none if specified, log is opened in append mode
debug optional-args activate debugging
msgno none show RMAN-nnnn prefix for all messages
send quoted-string send a command to the media manager
pipe string building block for pipe names
timeout integer number of seconds to wait for pipe input
-----------------------------------------------------------------------------
Both single and double quotes (' or ") are accepted for a quoted-string.
Quotes are not required unless the string contains embedded white-space.

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00552: syntax error in command line arguments
RMAN-01005: syntax error: found "dot": expecting one of: "double-quoted-string, equal, identifier, single-quoted-string"
RMAN-01007: at line 2 column 1 file: command line arguments

Script ./hot_database_backup.sh
==== ended in error on Sat Jul 6 15:04:13 BST 2002 ====

This error is due to some versions of Recovery Manager (RMAN) not accepting a pathname relative to the current directory as an option for the msglog parameter.

The sample NetBackup Oracle backup scripts create an output log in the same directory as the backup script by using the pathname of the script and then pass this filename to RMAN.

RMAN_LOG_FILE=${0}.out

rman ... msglog $RMAN_LOG_FILE ...

Normally the backup script is invoked by the NetBackup master server, which uses a full pathname, e.g. /oracle/scripts/hot_database_backup.sh. This causes the following successful command line:

rman ... msglog /oracle/scripts/hot_database_backup.sh.out ...

However, if a user executes the shell script using a pathname relative to the local directory, e.g. ./hot_database_backup.sh, then RMAN does not correctly handle the relative pathname in the failing command line which results:

rman ... msglog ./hot_database_backup.sh.out ...


Solution:
Use a full pathname when executing the backup script.


Legacy ID


249670


Article URL http://www.symantec.com/docs/TECH21506


Terms of use for this information are found in Legal Notices

你可能感兴趣的:(2012)