|
 |
|
Oracle Tips by Burleson |
Chapter 8 General Oracle Auditing
# Parameters :
1. 2-digit Year of the archival process
# 2. 2-digit Month of the process
# Assumption : A file .sys_passwd in this directory
# containing the password of SYS.
# Important:
# Change the variable SYS_PASSWORD to suit to
# your site.
# -------------------------------------------------------
#
# Site dependent variables
SYS_PASSWORD=manager
#
ARC_YEAR=$1
ARC_MONTH=$2
ARC_TS_NAME=AUD$ARC_YEAR$ARC_MONTH
sqlplus /nolog << EOF1
whenever sqlerror exit
connect sys/$SYS_PASSWD as sysdba
drop tablespace $ARC_TS_NAME
including contents
and datafiles /* Only in 9i */
/
prompt AudArch: Dropped Tablespace $ARC_TS_NAME
EOF1
echo Archival Complete
Retrieval
When the
archived data needs to be retrieved, this process makes it very
easy. Since the data was initially exported as transportable, all
that needs to be done while importing is to mount the WORM device
(or the filesystem containing the archived tablespace) and plug the
tablespace into the database using import. Since the
The above text is
an excerpt from
the bestselling book:
Oracle
Privacy Security Auditing.
It's only $39.95 and has an
download of working security scripts:
This is the only authoritative
book on Oracle Security, Oracle Privacy, and Oracle Auditing written
by two of the world’s leading Oracle Security experts.
This indispensable book is only $39.95 and has an
download of working security scripts:
http://rampant-books.com/book_2003_2_audit.htm
Download your Oracle scripts now:
www.oracle-script.com
The
definitive Oracle Script collection for every Oracle professional DBA
|
|