Friday, 28 December 2012

Creting DB Manually

Hi

For Creating db manually.we need to know the first the three different modes to bring db up.
NOMOUNTbackground processes are started based on reading the spfile
MOUNTcontrol files are opened and read
OPENdata files are opened

NOMOUNTbackground processes are started based on reading the spfile
MOUNTcontrol files are opened and read
OPENdata files are opened


NOMOUNTbackground processes are started based on reading the spfile
MOUNTcontrol files are opened and read
OPENdata files are opened

NOMOUNTbackground processes are started based on reading the spfile
MOUNTcontrol files are opened and read
OPENdata files are opened
NOMOUNTbackground processes are started based on reading the spfile
MOUNTcontrol files are opened and read
OPENdata files are opened
Nomount state -- backgroup process wll be started up based on pfile/spfile
Mount state     -- control files are opened and read
open mode      -- datafiles should be open

syntax:
********************
startup nomount
startup mount
startup
********************
alter database mount;
alter database open;
alter database open read only;


Steps to create a database manually:
___________________________

1. Create a pfile initSID.ora and copy to the location $ORACLE_HOME/dbs/initSID.ora
        cp initsid.ora $ORACLE_HOME/dbs/initsid.ora

2. we nned to create a passwd file before starting up the db
$ORACLE_HOME/bin/orapwd file=$ORACLE_HOME/dbs/pwd<sid>.ora password=oracle entries=

3. sqlplus / as sysdba
        SQL> startup nomount;

4. now we have to issue the create database comand

create database test
logfile group 1 ('/path/to/redo1.log') size 100M,
            group 2 ('/path/to/redo2.log') size 100M,
            group 3 ('/path/to/redo3.log') size 100M
character set WE8ISO8859P1
national character set utf8
datafile '/path/to/system.dbf' size 500M autoextend on next 10M maxsize unlimited extent management local
sysaux datafile '/path/to/sysaux.dbf' size 100M autoextend on next 10M maxsize unlimited
undo tablespace undotbs1 datafile '/path/to/undotbs1.dbf' size 100M
default temporary tablespace temp tempfile '/path/to/temp01.dbf' size 100M;

Note: there's some other things you can do here, like "ARCHIVELOG" "SET TIME_ZONE =" and "USER SYS IDENTIFIED BY password" and "USER SYSTEM IDENTIFIED BY password"

Link:
http://www.dba-oracle.com/oracle_create_database.htm

Thursday, 27 December 2012

creating Oracle db using DBCA


Hi

We can create database using the tool DBCA (Database Base management configuration Assistant ) and we can create manually by using linux box.

Creating Oracle Database using DBCA:

The vedio has been provided above we create this database. using this We can create the database easeily

General cause for creating db failure is:
1. Need to check the services of oracle in services.msc
2. DB Name or database files that already has beens
3. OS level permission errors

In Windows :

To launch DBCA:
  1. Log on to your computer as a member of the administrative group that is authorized to install Oracle software and create and run the database.
  2. To launch DBCA on a Windows operating system, click Start and then select Programs, Oracle - home_name, Configuration and Migration Tools, and then Database Configuration Assistant.
In Unix:
  1. To launch the DBCA on UNIX, or as another method on a Windows operating system, enter the following command at a system prompt:
  2. dbca
    
Link for further clarification: