Oracle11gR2 manual database creation (createdatabasemanually)

Source: Internet
Author: User
Manual database creation is a common situation for DBAs because GUI environments cannot be provided in some cases. In fact, to manually create a database, you only need to set the relevant parameters or values.

Manual database creation is a common situation for DBAs because GUI environments cannot be provided in some cases. In fact, to manually create a database, you only need to set the relevant parameters or values.

Manual database creation is a common situation for DBAs, because GUI environments cannot be provided in some cases. In fact, it is very convenient to set relevant parameters or values for manual database creation. This document describes the steps for creating a manual database based on Oracle 11g and provides an example. Finally, a shell script is provided for manual database creation. The script can be modified according to your path before execution.

1. General steps for manual database creation

2. manually create a database

1. Set the environment variable. bash_profile
-- Make sure to include at least the following environment variables. skip this step if Oracle Database software is installed.
$ Vi. bash_profile
Export ORACLE_SID = catadb
Export ORACLE_BASE =/u01/app/oracle
Export ORACLE_HOME = $ ORACLE_BASE/db_1
Export PATH =/usr/sbin: $ PATH
Export PATH = $ ORACLE_HOME/bin: $ PATH
Export LD_LIBRARY_PATH = $ ORACLE_HOME/lib:/usr/lib
Export CLASSPATH = $ ORACLE_HOME/JRE: $ ORACLE_HOME/jlib: $ ORACLE_HOME/rdbms/jlib

2. Create a parameter file (location: $ ORACLE_HOME/dbs)
[Oracle @ linux1 dbs] $ export ORACLE_SID = catadb
[Oracle @ linux1 ~] $ Cd $ ORACLE_HOME/dbs
[Oracle @ linux1 dbs] $ grep-v \ # init. ora> init $ ORACLE_SID.ora

[Oracle @ linux1 dbs] $ more initcatadb. ora
Db_name = 'catadb'
Memory_target = 512 M
Processes = 150
Audit_file_dest = '/u03/uat/catadb/adump'
Audit_trail = 'db'
DB _ block_size = 8192
Db_domain =''
Db_recovery_file_dest = '/u03/uat/catadb/fr_area'
Db_recovery_file_dest_size = 2G
Diagnostic_dest = '/u03/uat/catadb'
Dispatchers = '(PROTOCOL = TCP) (SERVICE = ORCLXDB )'
Open_cursors = 300
Remote_login_passwordfile = 'clusive'
Undo_tablespace = 'undotbs1'
Control_files = ('/u03/uat/catadb/oradata/catadb01.ctl', '/u03/uat/catadb/oradata/catadb02.ctl ')
Compatible = '11. 2.0'

3. Create a directory structure
[Oracle @ linux1 ~] $ Mkdir-p/u03/uat/catadb
[Oracle @ linux1 dbs] $ cd/u03/uat/catadb
[Oracle @ linux1 catadb] $ mkdir adump diag fr_area oradata

4. Execute the database creation script
[Oracle @ linux1 catadb] $ more create_catadb. SQL
Create database catadb
Maxlogfiles 5
Maxlogmembers 5
Maxdatafiles 100
Maxinstances 1
Logfile
Group 1 ('/u03/uat/catadb/oradata/redo1.log') size 10 m,
Group 2 ('/u03/uat/catadb/oradata/redo2.log') size 10 m,
Group 3 ('/u03/uat/catadb/oradata/redo3.log') size 10 m
Datafile
'/U03/uat/catadb/oradata/system. dbf' size 200 m reuse
Sysaux datafile '/u03/uat/catadb/oradata/sysaux. dbf' size 100 m
Default tablespace user
Datafile '/u03/uat/catadb/oradata/userdata. dbf' size 100 m
Undo tablespace undotbs1
Datafile '/u03/uat/catadb/oradata/undo1.dbf' size 100 m
Default temporary tablespace temp1
Tempfile '/u03/uat/catadb/oradata/temp01.dbf'
Size 100 m reuse
Character set al32utf8
;

Idle> @/u03/uat/catadb/create_catadb. SQL

Database created.

-- Add a data dictionary
Idle> edit/u03/uat/catadb/post_create_catadb. SQL

@ $ ORACLE_HOME/rdbms/admin/catalog. SQL
@ $ ORACLE_HOME/rdbms/admin/catproc. SQL
Conn system/manager
@ $ ORACLE_HOME/sqlplus/admin/pupbld. SQL

Idle> @/u03/uat/catadb/post_create_catadb. SQL

System @ CATADB> select name, open_mode from v $ database;

NAME OPEN_MODE
-----------------------------
CATADB READ WRITE

Iii. manual database creation script

-- The following is a summary of the above actions, which are encapsulated into shell scripts for execution. Enter the password and sit down and have a cup of coffee!

Download Script: Oracle 11g R2 manual database creation script

Free on

Both the user name and password are

The specific download directory is available in/July 6,/July 16,/Oracle 11g R2 manual database creation (create database manually)

For the download method, see

Related reading:

Silent Installation of Oracle 11gR2 software and manual database creation

Full Process of 10 Gb manual Oracle database creation in Linux

Oracle elastic uard database creation

Notes for manual Oracle database creation

Rman cannot be enabled after Oracle manual database creation (RMAN-04015)

Detailed description of manual database creation for Oracle 11.2 GB

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.