Quiescing a Database - Suspending a Database - Dropping a Database- Managing Initialization Files - Managing Parameters in SPFILE

Quiescing a Database - Suspending a Database -  Dropping a Database- Managing Initialization Files - Managing Parameters in SPFILE

Quiescing a Database - Suspending a Database -  Dropping a Database- Managing Initialization Files - Managing Parameters in SPFILE


Quiescing a Database

 Users will remain logged in, and they can continue to execute their requests that are in

progress, while the database is in the quiesced state. The database, however, will block all

new transactional requests except those made by the users SYS and SYSTEM (not DBA

grantees).

ALTER SYSTEM QUIESCE RESTRICTED;

ALTER SYSTEM UNQUIESCE;

SELECT instance_name, status, shutdown_pending, active_state FROM v$instance;

Suspending a Database

 All reads from and writes to the datafiles and control files are suspended.

ALTER SYSTEM SUSPEND;

ALTER SYSTEM RESUME;

SELECT instance_name, status, shutdown_pending, active_state FROM v$instance;

Dropping a Database

 Datafiles, redo log files, and control files are removed automatically. Alert log and

parameter file are not deleted.

CONNECT sys/sys_passwd AS SYSDBA

SHUTDOW IMMEDIATE

STARTUP RESTRICT MOUNT

SELECT name FROM v$database;

DROP DATABASE;

Initialization Files

Managing Initialization Files

 During startup, in $ORACLE_HOME/dbs (for UNIX/Linux) Oracle will look for the correct

initialization file to use, in the following order:

o spfile$ORACLE_SID.ora

o spfile.ora

o init$ORACLE_SID.ora

# currently used SPFiles (if null, pfile was used)

select * from v$parameter where name = 'spfile'

# create pfile

CREATE SPFILE='/u01/oracle/dbs/test_spfile.ora' FROM

PFILE='/u01/oracle/dbs/test_init.ora'

# use pecific spfile during startup

STARTUP PFILE = $ORACLE_HOME/dbs/initDBA1.ora

# PFILE can indicate to use SPFILE

SPFILE = /database/startup/spfileDBA1.ora

In Oracle 11g

# write current values of instance parameters

CREATE PFILE FROM MEMORY;

CREATE SPFILE FROM MEMORY;

Managing Parameters in SPFILE

-- display current value of a parameter

select * from v$parameter where name = 'spfile'

-- parameter values set in SPFILE

select NAME, ISSPECIFIED from V$SPPARAMETER where name like '%dest%';

-- in SQL Plus

show parameter target

-- set parameter value

alter system set parameter=value scope=SPFILE|MEMORY|BOTH

-- delete a parameter from SPFILe

ALTER SYSTEM RESET undo_suppress_errors SCOPE=BOTH SID='node01';

-- Only sessions started after the statement is executed are affected

-- this option is a must for the parameters whose ISSYS_MODIFIABLE column

-- in V$PARAMETER is DEFERRED. You cannot use it, if the column value is

FALSE

ALTER SYSTEM SET parameter_name DEFERRED;

-- undocumented parameters

SELECT

a.ksppinm parameter, a.ksppdesc description,

b.ksppstvl session_value, c.ksppstvl instance_value

FROM x$ksppi a, x$ksppcv b, x$ksppsv c

WHERE

a.indx = b.indx

AND a.indx = c.indx

AND SUBSTR (a.ksppinm,1,1) = '_'

ORDER BY a.ksppinm;

Alert and Trace Files

Monitoring Alert and Trace Files

# to obtain the Location of Trace Files
column NAME format a35
column VALUE format a35
select name, value from v$parameter
where name in ('background_dump_dest','user_dump_dest')
# to set maximum size of trace files (excluding the alert file)
# in number of block unless you sepcify K or M
select * from v$parameter where upper(name )= 'MAX_DUMP_FILE_SIZE'
alter session set MAX_DUMP_FILE_SIZE='100M'


1 comment:

Please Post your comment ...

Labels

Oracle Database Administrator (3) database analyst (3) jobs oracle dba (3) database administration (2) dba certification (2) dba resume (2) dba training (2) for oracle (2) how to be an oracle dba (2) job oracle dba (2) jobs in oracle dba (2) oracle 8 (2) oracle administration (2) oracle database dba (2) oracle dba (2) oracle dba interview (2) oracle dba questions (2) oracle free (2) oracle tutorials (2) sql dba (2) Automatically Starting Databases in Unix (1) Autostart of Database in Windows (1) Autostart of Database in Windows and Automatically Starting Databases in Unix (1) Best Operating System for Oracle DBA Practice Suggestions (1) CREATE ORACLE DATABASE MANUALLY ON LINUX STEP BY STEP PROCESS (1) DBA RAC Tips Best Practice Guidelines for Standalone and RAC Databases (1) Data Dictionary and Dynamic Performance Views (1) Database Administration Authentication (1) Installing Oracle 10g R2 on Enterprise Linux (1) Installing Oracle 11g R2 on Enterprise Linux 5 (1) Installing Oracle 11g R2 on Enterprise Linux 5.5 with ASM (1) Managing Oracle Database Instance (1) Obtaining Information about the Instance Processes (1) Obtaining Information about the SGA - Clearing the Buffer Cache (1) Oracle Database Installation Estimating Disk and Memory Requirements Consideration (1) Oracle Database Installation Optimal Flexible Architecture (1) Product Release Number - Obtaining License Information - Obtaining Information about the Instance Processes (1) Quiescing a Database - Suspending a Database - Dropping a Database- Managing Initialization Files - Managing Parameters in SPFILE (1) about (1) about oracle dba (1) data entry work from home (1) database (1) database administrator (1) database administrator oracle (1) database management (1) database oracle (1) dba in oracle (1) dba jobs (1) dba online (1) dba oracle (1) download oracle (1) how to be a dba (1) how to be a oracle dba (1) in oracle (1) interview questions on oracle dba (1) interview questions oracle dba (1) job for oracle dba (1) jobs for oracle dba (1) learn oracle (1) manually database (1) oracle 10g (1) oracle 10g download (1) oracle 11g (1) oracle 11g download (1) oracle 11i (1) oracle 9i (1) oracle apex (1) oracle application server (1) oracle apps dba (1) oracle architecture (1) oracle base (1) oracle careers (1) oracle certification (1) oracle certified associate (1) oracle consulting (1) oracle courses (1) oracle database (1) oracle database 10g (1) oracle database 11g (1) oracle database administration (1) oracle database download (1) oracle db (1) oracle dba interview questions (1) oracle dba job (1) oracle dba jobs (1) oracle developer (1) oracle discoverer (1) oracle express (1) oracle forms (1) oracle in (1) oracle job (1) oracle jobs (1) oracle oca (1) oracle reports (1) oracle server (1) oracle software (1) oracle training (1) oracle tutorial (1) oracle university (1) oracle with (1) oracle xe (1) sql server (1) support oracle (1) toad for oracle (1) what is oracle (1) what is oracle database (1) what is oracle dba (1) work from home data entry (1)