How To Create A Database Manually | Create a Database Using DBCA Silent Mode in Oracle

Hi,

Sometimes you may need to install Oracle database silent or manually instead of GUI( Graphical User Interface ), or sometimes there is no GUI tool like VNC Server, so you need to install and create Oracle database Manually or in silent mode.

 

Create a Database Using DBCA

To create an Oracle database, Firstly you should install Oracle database software.

You can read the following article to learn how to install Oracle database Software in Silent Mode.

Oracle Database 12c Silent Installation

 

 

 

How To Create A Database Manually in Oracle

Step-1: Set the bash profile parameters as follows. Bash profile file should consist the following Oracle Home and SID parameters.

 

bash-4.3$ cat .bash_profile

PATH=/usr/bin:/etc:/usr/sbin:/usr/ucb:$HOME/bin:/usr/bin/X11:/sbin:.

export PATH

if [ -s "$MAIL" ] # This is at Shell startup. In normal
then echo "$MAILMSG" # operation, the Shell checks
fi # periodically.

export ORACLE_SID=DEPLOY
export ORACLE_HOME=/u01/app/oracle/product/19c
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib

 

 

Step-2: Create a Parameter file ( PFILE ) for Oracle Instance as follows.

 

bash-4.3$ cat initDEPLOY.ora
control_files = '+DATATEST/DEPLOY/controlfile/controlfile01.ora'
undo_management = AUTO
undo_tablespace = UNDOTBS1
db_name = DEPLOY
db_block_size = 16384
sga_max_size = 20073741824
sga_target = 20073741824

 

Step-3: Set .bash_Profile and Startup Oracle instance in Nomount mode using PFILE as follows.

 

bash-4.3$ . .bash_profile

bash-4.3$ sqlplus / as sysdba

SQL> startup nomount pfile=initDEPLOY.ora
ORACLE instance started.

Total System Global Area 2.1379E+10 bytes
Fixed Size 2237776 bytes
Variable Size 8522828464 bytes
Database Buffers 1.2818E+10 bytes
Redo Buffers 36098048 bytes

 

 

 

Step-4: Create a Password file for Admin users.

$ORACLE_HOME/bin/orapwd file=$ORACLE_HOME/dbs/orapwDEPLOY.ora password=welcome1 entries=5

 

Step-5: Execute Create Database statement as follows to create an Oracle Database.

SQL> create database DEPLOY
logfile group 1 ('+DATADEPLOY/DEPLOY/onlinelog/redo01.log') size 100M,
group 2 ('+DATADEPLOY/DEPLOY/onlinelog/redo02.log') size 100M,
group 3 ('+DATADEPLOY/DEPLOY/onlinelog/redo03.log') size 100M
character set AL32UTF8
national character set AL16UTF16
datafile '+DATADEPLOY/DEPLOY/datafile/system01.dbf' size 500M autoextend on next 10M maxsize unlimited extent management local
sysaux datafile '+DATADEPLOY/DEPLOY/datafile/sysaux01.dbf' size 100M autoextend on next 10M maxsize unlimited
undo tablespace undotbs1 datafile '+DATADEPLOY/DEPLOY/datafile/undotbs01.dbf' size 100M
default temporary tablespace temp tempfile '+DATADEPLOY/DEPLOY/datafile/temp01.dbf' size 100M;

 

 

Step-6: If Step-5 is completed successfully, then execute the following SQLs to create system based objects.

SQL> @?/rdbms/admin/catalog.sql

SQL> @?/rdbms/admin/catproc.sql

 

If the Step-6 SQLs are executed successfully, then your database is ready to use.

 

 

Or you can create an Oracle database using DBCA ( Database configuration Assistant ) tool, You can use DBCA tool in silent mode as follows.

bash-4.3$ dbca -createDatabase -silent \
-gdbName DEPLOY \
-sid DEPLOY \
-sysPassword welcome1 \
-systemPassword welcome1 \
-diskGroupName 'DATATEST' \
-recoveryGroupName 'DATATEST' \
-storageType ASM \
-asmSysPassword welcome1 \
-nodelist 'MehmetSalih' \
-databaseType MULTIPURPOSE \
-responseFile NO_VALUE \
-asmsnmpPassword welcome1 \
-characterSet AL32UTF8 \
-nationalCharacterSet AL16UTF16 \
-memoryPercentage 3 \
-initparams audit_trail=NONE,db_recovery_file_dest_size=3000,db_block_size=8192 \
-templateName /u01/app/oracle/product/19c/assistants/dbca/templates/General_Purpose.dbc

 

 

 

Do you want to learn Oracle Database for Beginners, then read the following articles.

Oracle Tutorial | Oracle Database Tutorials for Beginners ( Junior Oracle DBA )

About Mehmet Salih Deveci

I am Founder of SysDBASoft IT and IT Tutorial and Certified Expert about Oracle & SQL Server database, Goldengate, Exadata Machine, Oracle Database Appliance administrator with 10+years experience.I have OCA, OCP, OCE RAC Expert Certificates I have worked 100+ Banking, Insurance, Finance, Telco and etc. clients as a Consultant, Insource or Outsource.I have done 200+ Operations in this clients such as Exadata Installation & PoC & Migration & Upgrade, Oracle & SQL Server Database Upgrade, Oracle RAC Installation, SQL Server AlwaysOn Installation, Database Migration, Disaster Recovery, Backup Restore, Performance Tuning, Periodic Healthchecks.I have done 2000+ Table replication with Goldengate or SQL Server Replication tool for DWH Databases in many clients.If you need Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS Consultancy and Training you can send my email adress [email protected].-                                                                                                                                                                                                                                                 -Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS ve linux Danışmanlık ve Eğitim için  [email protected] a mail atabilirsiniz.

Leave a Reply

Your email address will not be published. Required fields are marked *