Skip to content
Home » Oracle Database » Grid Infrastructure » ASM » How to Create Database on ACFS

How to Create Database on ACFS

Assuming that you have created a ACFS file system for the database creation. Then you can go on reading this post.

Create a Database on ACFS

First of all, make sure everything is ready including ACFS mount point which is /u02/oradata1 in this case.

[grid@primary01 ~]$ crsctl status resource ora.data.oradata1.acfs -t
--------------------------------------------------------------------------------
Name           Target  State        Server                   State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.data.oradata1.acfs
               ONLINE  ONLINE       primary01                mounted on /u02/orad
                                                             ata1,STABLE
               ONLINE  ONLINE       primary02                mounted on /u02/orad
                                                             ata1,STABLE
--------------------------------------------------------------------------------

Check the permission of the ACFS directory.

[oracle@primary01 ~]$ ll /u02/
total 32
drwxr-xr-x 4 oracle oinstall 32768 Dec  6 13:45 oradata1

Call DBCA to initialize a database.

[oracle@primary01 ~]$ dbca
Oracle Database 18c - DBCA - Opening
Oracle Database 18c - DBCA - Opening
Oracle Database 18c - DBCA - Select Database Operation
Oracle Database 18c - DBCA - Select Database Operation
Oracle Database 18c - DBCA - Select Database Creation Mode
Oracle Database 18c - DBCA - Select Database Creation Mode
Oracle Database 18c - DBCA - Select Database Deployment Type
Oracle Database 18c - DBCA - Select Database Deployment Type
Oracle Database 18c - DBCA - Select List of Nodes
Oracle Database 18c - DBCA - Select List of Nodes
Oracle Database 18c - DBCA - Specify Database Identification Details
Oracle Database 18c - DBCA - Specify Database Identification Details
Oracle Database 18c - DBCA - Select Database Storage Option
Oracle Database 18c - DBCA - Select Database Storage Option
Oracle Database 18c - DBCA - Select Fast Recovery Option
Oracle Database 18c - DBCA - Select Fast Recovery Option
Oracle Database 18c - DBCA - Select Oracle Data Vault Config Option
Oracle Database 18c - DBCA - Select Oracle Data Vault Config Option
Oracle Database 18c - DBCA - Specify Configuration Options
Oracle Database 18c - DBCA - Specify Configuration Options
Oracle Database 18c - DBCA - Specify Management Options
Oracle Database 18c - DBCA - Specify Management Options
Oracle Database 18c - DBCA - Specify Database User Credentials
Oracle Database 18c - DBCA - Specify Database User Credentials
Oracle Database 18c - DBCA - Specify Database User Credentials - DBT-06208
Oracle Database 18c - DBCA - Specify Database User Credentials - DBT-06208
Oracle Database 18c - DBCA - Select Database Creation Option
Oracle Database 18c - DBCA - Select Database Creation Option
Oracle Database 18c - DBCA - Perform Prerequisite Checks
Oracle Database 18c - DBCA - Perform Prerequisite Checks
Oracle Database 18c - DBCA - Summary 1 of 3
Oracle Database 18c - DBCA - Summary 1 of 3
Oracle Database 18c - DBCA - Summary 2 of 3
Oracle Database 18c - DBCA - Summary 2 of 3
Oracle Database 18c - DBCA - Summary 3 of 3
Oracle Database 18c - DBCA - Summary 3 of 3
Oracle Database 18c - DBCA - Summary - Save Response File
Oracle Database 18c - DBCA - Summary - Save Response File
Oracle Database 18c - DBCA - Summary - Finish
Oracle Database 18c - DBCA - Summary - Finish
Oracle Database 18c - DBCA - Database Creating
Oracle Database 18c - DBCA - Database Creating
Oracle Database 18c - DBCA - Database Created
Oracle Database 18c - DBCA - Database Created

After installation, we can check the status of listener and database.

[oracle@primary01 ~]$ lsnrctl status
...
Services Summary...
Service "+APX" has 1 instance(s).
  Instance "+APX1", status READY, has 1 handler(s) for this service...
Service "+ASM" has 1 instance(s).
  Instance "+ASM1", status READY, has 1 handler(s) for this service...
Service "+ASM_DATA" has 1 instance(s).
  Instance "+ASM1", status READY, has 1 handler(s) for this service...
Service "+ASM_FRA" has 1 instance(s).
  Instance "+ASM1", status READY, has 1 handler(s) for this service...
Service "PRIMDB" has 1 instance(s).
  Instance "PRIMDB1", status READY, has 1 handler(s) for this service...
Service "PRIMDBXDB" has 1 instance(s).
  Instance "PRIMDB1", status READY, has 1 handler(s) for this service...
The command completed successfully

Let's see the configuration status of the newly created database.

[oracle@primary01 ~]$ srvctl config database -d primdb
Database unique name: PRIMDB
Database name: PRIMDB
Oracle home: /u01/app/oracle/product/18.0.0/db_1
Oracle user: oracle
Spfile: /u02/oradata1/DATA/PRIMDB/spfilePRIMDB.ora
Password file: /u02/oradata1/DATA/PRIMDB/orapwPRIMDB
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools:
Disk Groups:
Mount point paths: /u02/oradata1
Services:
Type: RAC
Start concurrency:
Stop concurrency:
OSDBA group: dba
OSOPER group: oper
Database instances: PRIMDB1,PRIMDB2
Configured nodes: primary01,primary02
CSS critical: no
CPU count: 0
Memory target: 0
Maximum memory: 0
Default network number for database services:
Database is administrator managed

Check the running status of both nodes.

[oracle@primary01 ~]$ srvctl status database -d primdb
Instance PRIMDB1 is running on node primary01
Instance PRIMDB2 is running on node primary02

[oracle@primary01 ~]$ sqlplus / as sysdba
...
SQL> select instance_name from gv$instance;

INSTANCE_NAME
----------------
PRIMDB1
PRIMDB2

The list of data files look like that it's a normal file system.

[oracle@primary01 ~]$ ll /u02/oradata1/DATA/PRIMDB/
total 2621824
-rw-r----- 1 oracle oinstall  19709952 Dec 12 13:41 control01.ctl
-rw-r----- 1 oracle oinstall      3584 Dec 12 12:37 orapwPRIMDB
-rw-r----- 1 oracle oinstall 209715712 Dec 12 12:49 redo01.log
-rw-r----- 1 oracle oinstall 209715712 Dec 12 13:33 redo02.log
-rw-r----- 1 oracle oinstall 209715712 Dec 12 13:41 redo03.log
-rw-r----- 1 oracle oinstall 209715712 Dec 12 13:38 redo04.log
-rw-r----- 1 oracle oinstall      4608 Dec 12 13:41 spfilePRIMDB.ora
-rw-r----- 1 oracle oinstall 545267712 Dec 12 13:41 sysaux01.dbf
-rw-r----- 1 oracle oinstall 880812032 Dec 12 13:41 system01.dbf
-rw-r----- 1 oracle oinstall  33562624 Dec 12 12:37 temp01.dbf
-rw-r----- 1 oracle oinstall 314580992 Dec 12 13:31 undotbs01.dbf
-rw-r----- 1 oracle oinstall  26222592 Dec 12 13:40 undotbs02.dbf
-rw-r----- 1 oracle oinstall   5251072 Dec 12 13:23 users01.dbf
[oracle@primary01 ~]$ ll /u02/oradata1/FRA/PRIMDB/
total 19404
drwxr-x--- 3 oracle oinstall    20480 Dec 12 12:12 archivelog
drwxr-x--- 3 oracle oinstall    20480 Dec 12 12:52 autobackup
-rw-r----- 1 oracle oinstall 19709952 Dec 12 13:43 control02.ctl
drwxr-x--- 2 oracle oinstall    20480 Dec 12 12:20 onlinelog

That's how we create database on ACFS file system. For more technical information, you can visit Oracle ASM administrator's guide: Creating an Oracle ACFS File System for Database Use

Leave a Reply

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