odacli create-database

Use the odacli create-database command to create a new database.

Syntax

To create a database with a new Oracle Database Home:

   odacli  create-database    

To create a database using an existing Oracle Database Home:

   odacli  create-database -dbhomeid Database Home ID   

Parameters


Parameter Description

-m

Defines the password for SYS, SYSTEM, and PDB Admin.

-c

(Optional) Create a Container Database.

-cl OLTP|DSS|IMDB

Defines the database class. The options are: OLTP, DSS, or IMDB. The default is OLTP.

-co

(Optional) Enables the Database Console.

-dh

Identifies the existing Database Home ID.

-n

Defines the name given to the new database (dbname.)

-s dbshape

Identifies the database shape (dbshape). For example, odb1, odb2, and odb3. The default is odb1.

-ACFS|ASM

Defines the Database Storage, either ACFS or ASM. The default value is ACFS.

-y SI|RAC

Defines the Database Type (dbtype), either SI or RAC.  The default value is SI.

-io

Creates a standby instance.

-j

 (Optional) Displays JSON output.

--pdbadmin, -d

 

Defines the name of the Pluggable Database (PDB) Admin User. The default value is pdbadmin.

      

-p pdbname

Defines the name of the PDB. The default value is pdb1.

-g n

Defines the Node Number (for single-instance databases). The default is 0.

-vversion

Defines the database version. The default version is 12.1.0.2.

-h

(Optional) Displays help for using the command.


Usage Notes

  • You cannot mix Oracle Database Standard Edition and Enterprise Edition databases on the same appliance.

  • When --dbhomeid is not provided, thecreate-database command will create a new Oracle Database Home.

  • When --dbhomeid is provided, the create-database command creates the database using the existing Oracle Home. Use the odacli list-dbhomes command to obtain the dbhomeid.

  • Oracle Database 12.1 is supported on both Oracle Automatic Storage Management (Oracle ASM) and Oracle ASM Cluster file system (ACFS). The default is Oracle ACFS.

  • Oracle Database 11.2 is supported on Oracle ACFS.

  • When databases are created in Oracle ACFS, each database is configured with its own Oracle ACFS file system for the datafiles and uses the following naming convention: /u02/app/db user/oradata/db name. The default size of this mount point is 100G.

  • Online logs are stored in the /u03/app/db user/redo/ directory.

  • Oracle Fast Recovery Area (FRA) is located in the /u03/app/db user/fast_recovery_area directory.

Example 9-8 Creating a Database

To create a 12.1.0.2 OLTP container database named hrdb with shape odb-6:

# odacli create-database -n hrdb -c -m welcome1 -cl OLTP -s odb6 -p pdb1 -v 12.1.0.2