=====================================================
Here are the steps to be followed:
1. Make a init
file is in $ORACLE_HOME\database. To simplify, you can copy init.ora to
init
*** Path names, file names, and sizes will need to be modified
Example parameter settings :
db_block_size=8192
db_cache_size=52428800
background_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
core_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
user_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
timed_statistics=TRUE
control_files=("/u01/rbdb1/control_01.ctl", "/u01/rbdb1/control_02.ctl")
db_name=rbdb1
shared_pool_size=52428800
sort_area_size=524288
undo_management=AUTO
undo_tablespace=UNDOTBS
** You can also use an spfile as described in Note 162491.1.
2. Run the following sqlplus command to connect to the database:
sqlplus '/ as sysdba'
3. Startup up the database in NOMOUNT mode:
SQL> startup nomount
4. Create the Database :
*** Path names, file names, and sizes will need to be modified
CREATE DATABASE
MAXLOGFILES 255
MAXINSTANCES 1
MAXDATAFILES 256
MAXLOGHISTORY 256
DATAFILE '/u01/oracle/rbdb1/system_01.dbf' SIZE 400M REUSE
UNDO TABLESPACE "UNDOTBS" DATAFILE '/u01/oracle/rbdb1/undotbs_01.dbf'
SIZE 200M REUSE AUTOEXTEND ON NEXT 5120K MAXSIZE UNLIMITED
CHARACTER SET US7ASCII
LOGFILE GROUP 1 ('/u01/oracle/rbdb1/redo1_01.dbf') SIZE 100M REUSE,
GROUP 2 ('/u01/oracle/rbdb1/redo1_02.dbf') SIZE 100M REUSE;
5. Create a Users Tablespace :
*** Path names, file names, and sizes will need to be modified
CREATE TABLESPACE "USERS" DATAFILE '/u01/oracle/rbdb1/users01.dbf'
SIZE 300M REUSE AUTOEXTEND ON
NEXT 5M MAXSIZE 1500M;
6. Create a Temporary Tablespace :
*** Path names, file names, and sizes will need to be modified
CREATE TEMPORARY TABLESPACE "TEMP" TEMPFILE '/u01/oracle/rbdb1/temp_01.dbf'
SIZE 40M REUSE AUTOEXTEND ON NEXT 640K MAXSIZE UNLIMITED
EXTENT MANAGEMENT LOCAL;
ALTER DATABASE DEFAULT TEMPORARY TABLESPACE "TEMP";
7. Run the scripts necessary to build views, synonyms, etc. :
The primary scripts that you must run are:
i> CATALOG.SQL-- creates the views of data dictionary tables and the
dynamic performance views.
ii> CATPROC.SQL-- establishes the usage of PL/SQL functionality and
creates many of the PL/SQL Oracle supplied packages.
==============================================================
Manual Database Creation steps for Real Application Clusters
==============================================================
Here are the steps to be followed to create a Real Application Clusters database:
1. Make a init
file is in $ORACLE_HOME\database. To simplify, you can copy init.ora to
init
be pointing to a pre-existing raw device or cluster file system location.
*** Path names, file names, and sizes will need to be modified
Example parameter settings for the first instance:
Cluster-Wide Parameters for Database "RAC":
db_block_size=8192
db_cache_size=52428800
background_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
core_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
user_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
timed_statistics=TRUE
control_files=("/dev/RAC/control_01.ctl", "/dev/RAC/control_02.ctl")
db_name=RAC
shared_pool_size=52428800
sort_area_size=524288
undo_management=AUTO
cluster_database=true
cluster_database_instances=2
remote_listener=LISTENERS_RAC
Instance Specific Parameters for Instance "RAC1":
instance_name=RAC1
instance_number=1
local_listener=LISTENER_RAC1
thread=1
undo_tablespace=UNDOTBS
* The local_listener parameter requires that you first add the listener
address to the TNSNAMES.ORA - remember to do so on both Node 1 and Node 2.
** You can also use an spfile as described in Note 136327.1.
2. Run the following sqlplus command to connect to the database:
sqlplus '/ as sysdba'
3. Startup up the database in NOMOUNT mode:
SQL> startup nomount
4. Create the Database (All raw devices must be pre-created) :
*** Path names, file names, and sizes will need to be modified
CREATE DATABASE
CONTROLFILE REUSE
MAXDATAFILES 254
MAXINSTANCES 32
MAXLOGHISTORY 100
MAXLOGMEMBERS 5
MAXLOGFILES 64
DATAFILE '/dev/RAC/system_01_400.dbf' SIZE 400M
REUSE AUTOEXTEND ON NEXT 10240K MAXSIZE UNLIMITED
UNDO TABLESPACE "UNDOTBS" DATAFILE
'/dev/RAC/undotbs_01_210.dbf' SIZE 200M REUSE
NEXT 5120K MAXSIZE UNLIMITED
CHARACTER SET US7ASCII
LOGFILE GROUP 1 ('/dev/RAC/redo1_01_100.dbf') SIZE 100M REUSE,
GROUP 2 ('/dev/RAC/redo1_02_100.dbf') SIZE 100M REUSE;
5. Create a Users Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE TABLESPACE "USERS" LOGGING DATAFILE
'/dev/RAC/users_01_125.dbf' SIZE 120M REUSE
NEXT 1280K MAXSIZE UNLIMITED EXTENT MANAGEMENT LOCAL;
6. Create a Temporary Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE TEMPORARY TABLESPACE "TEMP" TEMPFILE
'/dev/RAC/temp_01_50.dbf' SIZE 40M REUSE
7. Create a 2nd Undo Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE UNDO TABLESPACE "UNDOTBS2" DATAFILE
'/dev/RAC/undotbs_02_210.dbf' SIZE 200M REUSE
NEXT 5120K MAXSIZE UNLIMITED;
8. Run the necessary scripts to build views, synonyms, etc.:
The primary scripts that you must run are:
i> CATALOG.SQL--creates the views of data dictionary tables and the
dynamic performance views
ii> CATPROC.SQL--establishes the usage of PL/SQL functionality and
creates many of the PL/SQL Oracle supplied packages
iii> CATPARR.SQL--creates RAC specific views
9. Edit init
2nd Node:
*** Names may need to be modified
instance_name=RAC2
instance_number=2
local_listener=LISTENER_RAC2
thread=2
undo_tablespace=UNDOTBS2
10. From the first instance, run the following command:
*** Path names, file names, and sizes will need to be modified
alter database
add logfile thread 2
group 3 ('/dev/RAC/redo2_01_100.dbf') size 100M,
group 4 ('/dev/RAC/redo2_02_100.dbf') size 100M;
alter database enable public thread 2;
12. Start the second Instance. (Assuming that your cluster configuration
is up and running).
1 comment:
I have heard about another way of mssql database corrupted recover. Besides, you can visit my blogs at: http://daspeac.livejournal.com/ or http://daspeac.blogspot.com/ where I’m trying to share my experience with regard to data corruption issues.
Post a Comment