Grid Infrastructure 19c ASM Installation

Updated: Aug 14

Automatic Storage Management (ASM)

Let's talk a little bit about Automatic Storage Management (ASM) it has been one of the features that was introduced since the Oracle 10g version and has been improving throughout its updates. With ASM it is possible to have a storage pool as a disk controller in sets of groups because its extension of OMF (Oracle Managed Files) functionality.

With this understanding it is possible to reach some conclusions:

  • A datafile, controlfile, redo log file and among other files is considered by FileSystem ASM to be an Oracle ASM File over an Oracle ASM Disk Group;

  • An Oracle ASM Disk Group is a storage unit of the FileSystem, which consists of 1 or more disks from the operating system.

Want to progress in your DBA career, download our Oracle scripts now and collaborate with us, CLICK FOR ALL

Preparation List installation:

Before installation, Oracle recommends that you use checklists to plan, this is part of the entire process to achieve the minimum installation requirements for Grid and ASM.


  • VirtualBox Installation (know more)

  • Install Oracle Enterprise Linux (OEL 7) on VirtualBox (know more).

Preparation Operating System Installation Grid Infrastructure:


  • Installation Grid Infrastructure 19c 64-bit on Oracle Linux 7 64-bit (RHEL7 or CentOS7).

  • RAM memory At least 2 GB of RAM Installation Grid Infrastructure 19. To avoid slowness, we recommend 4 GB of RAM.

  • Oracle recommends that you allocate 100 GB to allow additional space for patches.

  • More 4 Disc 12 Gigas already configured in the Virtural Machine

  • Minimum 4G SWAP and always the current memory value.

  • Secure Linux set to Permissive.

Download software Grid Infrastructure (19.3) for Linux x86-64:

Oracle Database 19c (19.3) for Linux x86-64 (

Let's prepare Installation:

A tip, ideal and to do the full S.O update, remembering that this is not mandatory yet another recommendation.

# yum update -y

Package Installation:

It is necessary to install the packages that are listed below, it is possible that some of them are already installed.

yum install -y bc    
yum install -y binutils
yum install -y compat-libcap1
yum install -y compat-libstdc ++ - 33
yum install -y dtrace-modules
yum install -y dtrace-modules-headers
yum install -y dtrace-modules-provider-headers
yum install -y dtrace-utils
yum install -y elfutils-libelf
yum install -y elfutils-libelf-devel
yum install -y fontconfig-devel
yum install -y glibc
yum install -y glibc-devel
yum install -y ksh
yum install -y libaio
yum install -y libaio-devel
yum install -y libdtrace-ctf-devel
yum install -y libstdc++-devel *
yum install -y libXrender
yum install -y libXrender-devel
yum install -y libX11
yum install -y libXau
yum install -y libXi
yum install -y libXtst
yum install -y libgcc
yum install -y librdmacm-devel
yum install -y libstdc ++
yum install -y libstdc ++ - devel
yum install -y libxcb
yum install -y make
yum install -y net-tools # Clusterware
yum install -y nfs-utils # ACFS
yum install -y python # ACFS
yum install -y python-configshell # ACFS
yum install -y python-rtslib # ACFS
yum install -y python-seis # ACFS
yum install -y unixODBC
yum install -y targetcli # ACFS
yum install -y smartmontools
yum install -y sysstat
yum install oracleasm-support -y
yum install bind* -y
yum install unzip -y
yum install xauth -y

Kernel parameter values:

Now using any text editor (vi, vim, nano) we will put the settings in the file "vi /etc/sysctl.conf" and it can also be found in "vi /etc/sysctl.d/98-oracle.conf".

fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmall = 2097152
kernel.shmmax = 4294967295
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576

To change the current values of the kernel parameters:

# /sbin/sysctl --system
## Or
#/sbin/sysctl -p

Review the values, if they are incorrect, edit the file again as the command below will show you parameters.

# /sbin/sysctl -a

Add the following lines to a file called "vi /etc/security/limits.d/limits.conf" file.

orades   soft   nofile    1024
orades   hard   nofile    65536
orades   soft   nproc    16384
orades   hard   nproc    16384
orades   soft   stack    10240
orades   hard   stack    32768
orades   hard   memlock    134217728
orades   soft   memlock    134217728

Networks parameter values:

Configure hosts:

It must have a name for the server. In this example we will use the following:


Hostname: orades-19c;

With any text editor add to the file "vi /etc /hosts" localhost localhost.localdomain localhost4 orades-19c.localdomain orades-19c 

Configuring SELINUX with a text editor edit vi /etc/selinux/config as follows:


Run the following command. (If the command does not force the change, it is likely that the server must be restarted).

# setenforce Disabled

Let's go to the Linux firewall and disable it as the commands:

# systemctl stop firewalld 
# systemctl disable firewalld

Configuring Groups and Directories:

Create the new groups and users.

groupadd -g 501 oinstall
groupadd -g 502 dba
groupadd -g 503 oper
groupadd -g 504 backupdba
groupadd -g 505 dgdba
groupadd -g 506 kmdba
groupadd -g 507 asmdba
groupadd -g 508 asmoper
groupadd -g 509 asmadmin

useradd -m -u 501 -g oinstall -G dba,asmadmin,asmdba,asmoper -d /home/oragrid -s /bin/bash oragrid

useradd -u 510 -g oinstall -G dba,oper,asmdba,asmoper,asmadmin orades

Set user password.

passwd oragrid

passwd orades

Database 19c software will be installed in the following directories that must be created below:

mkdir -p /u01/app/orades/product/19.0.0/db_1
mkdir -p /u01/app/oragrid
chown -R oragrid:oinstall /u01/app
chown -R orades:oinstall /u01/app/orades
chmod -R 775 /u01/

Log into the oracle user oragrid and configure the variables in .bash_profile. Add the following parameters as below:


vi /home/oragrid/.bash_profile

Add row;

# Oracle oragrid
export GRID_HOME=/u01/app/oragrid
export PATH=/usr/sbin:/usr/local/bin:/$PATH

Log into the oracle user orades and configure the variables in .bash_provile. Add the following parameters as below:


vi /home/orades/.bash_profile

Add row;

# Oracle Settings
export TMP=/tmp
export TMPDIR=/$TMP
export ORACLE_BASE=/u01/app/orades
export ORACLE_HOME=$ORACLE_BASE/product/19.0.0/db_1
export GRID_HOME=/u01/app/oragrid
export ORACLE_SID=orades
export ORACLE_TERM=xterm
export PATH=/usr/sbin:/usr/local/bin:/$PATH
export LD_LIBRARY_PATH=/$ORACLE_HOME/lib:/lib:/usr/lib

Preparation for creating ASM disks

This step is very important here is where we will prepare the disks:

With command below we will list the existing disks (user root). If with this command you have not seen the disks, go back to the VM and create the disks correctly.

fdisk -l

We have the following 10 GB disks to be used according to the requirements mentioned above.

Disk /dev/sdb: 12.9 GB, 10737418240 bytes
Disk /dev/sdc: 12.9 GB, 10737418240 bytes
Disk /dev/sdd: 12.9 GB, 10737418240 bytes
Disk /dev/sde: 12.9 GB, 10737418240 bytes

We will use the command that provides disk partitioning functions, in all four (sdb, sdc, sdd, sde).

fdisk /dev/sdb
fdisk /dev/sdc
fdisk /dev/sdd
fdisk /dev/sde

Example log:

[root@orades-19c ~]# fdisk /dev/sdb
Welcome to fdisk (util-linux 2.23.2).

Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

Device does not contain a recognized partition table
Building a new DOS disklabel with disk identifier 0xf500d7b2.

Command (m for help): n
Partition type:
   p   primary (0 primary, 0 extended, 4 free)
   e   extended
Select (default p): p
Partition number (1-4, default 1): 1
First sector (2048-25165823, default 2048):
Using default value 2048
Last sector, +sectors or +size{K,M,G} (2048-25165823, default 25165823):
Using default value 25165823
Partition 1 of type Linux and of size 12 GiB is set

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.
Syncing disks.

Prepared all Disks now we will use the command "oracleasm configure"

/usr/sbin/oracleasm configure -i

Example log:

[root@orades-19c ~]# /usr/sbin/oracleasm configure -i
Configuring the Oracle ASM library driver.

This will configure the on-boot properties of the Oracle ASM library
driver.  The following questions will determine whether the driver is
loaded on boot and what permissions it will have.  The current values
will be shown in brackets ('[]').  Hitting <ENTER> without typing an
answer will keep that current value.  Ctrl-C will abort.

Default user to own the driver interface []: oragrid
Default group to own the driver interface []: asmadmin
Start Oracle ASM library driver on boot (y/n) [n]: y
Scan for Oracle ASM disks on boot (y/n) [y]: y
Writing Oracle ASM library driver configuration: done
[root@orades-19c ~]#

Now enable the library with command below:

/usr/sbin/oracleasm init

Enter the following commands to mark a disk as an Oracle Automatic Storage Management (ASM) disk:


  • The disk names you specify can contain uppercase letters, numbers, and the underscore character. They must start with an uppercase letter.

oracleasm createdisk ASM_DISK01 /dev/sdb1
oracleasm createdisk ASM_DISK02 /dev/sdc1
oracleasm createdisk ASM_DISK03 /dev/sdd1
oracleasm createdisk ASM_DISK04 /dev/sde1

Use the listdisks option to list the disk names of marked Oracle ASM library driver disks.

/usr/sbin/oracleasm listdisks





Then enter the command "/usr/sbin/oracleasm scandisks" to allow them to identify which shared disks have been marked.

Example log:

[root@orades-19c ~]# /usr/sbin/oracleasm scandisks
Reloading disk partitions: done
Cleaning any stale ASM disks...
Scanning system for ASM disks...
[root@orades-19c ~]#

Log into the oragrid user If you are using X emulation then set the DISPLAY environmental variable. DISPLAY=<machine-name>:0.0; export DISPLAY

Example log
[oragrid@orades-19c oragrid]$ hostname -a
[oragrid@orades-19c oragrid]$ DISPLAY=orades-19c:0.0; export DISPLAY

For the settings to update and the ORACLEASM service to be mounted, reboot.


Install Grid Infrastructure 19c

Go to the location where you downloaded the software with the user "oragrid", go to the directory ($GRID_HOME) and unzip the file.

mv /tmp/ /u01/app/oragrid

After decompression, execute the command below:

cd /u01/app/19.0.0/oragrid

After decompression execute the command:


Configuring the 19c Oracle Grid Infrastructure.

Now we follow all the steps to prepare install Grid Infrastructure.

Step 1:

We will select the option of installing the G.I by checking the following "Configure Oracle Grid Insfrastructure for a Standalone Server", as it is not a Cluster installation (RAC). "Next" button.

Step 2:

Let's prepare and select the Group Disk:

1) Put the name in the Disk group name field:

2) Check Redundancy External (If you want to know about each of the Redundancy Click here Oracle Reference)

3) Click on "Changer Discovery Path"

Step 3:

Put the correct path in the Changer Discovery Path "/dev/oracleasm/disks/*"

Click on OK to show the disks to be selected to the Group Disk

Step 4:

Select all disks already configured in oracleasm for provisioning Groups.

"Next" button.

Step 5:

We will not check Register with Enterprise Manager (EM) "Next" button.

Step 6:

As we had already configured the user groups and just move forward.

"Next" button.

Step 7:

Check if you agree with the directory where Oracle Grid Infrastructure will be installed, keep the creation of the base directory, this file will be the diagnosis and administration of logs."Next" button.

Step 8:

Leaves the inventory directory specified

"Next" button.

Step 9:

In this version you can now let the installer run the ./ script automatically, just check the Automatically run configuration scripts box, and pass the root password of your S.O."Next" button.

Step 10:

The installer will show a summary of your settings now just install "Install" button.

Step 11:

"Yes" to confirm the execution of the scripts automatically by the G.I installer, wait for the installation to finish.

Step 12:

Finally we successfully completed the installation of the Grid Infrastructure 19c ASM.

Access ASM with the following command below:

sqlplus / as sysasm

See the importance of having a good script to help with administration run the following script below:

COLUMN disk_group_name FORMAT a20
COLUMN disk_file_path FORMAT a20
COLUMN disk_file_name FORMAT a20
COLUMN disk_file_fail_group FORMAT a30
COLUMN total_mb FORMAT 999,999,999
COLUMN used_mb FORMAT 999,999,999 
COLUMN pct_used FORMAT 999.99

SELECT NVL(, '[CANDIDATE]') disk_group_name , b.path disk_file_path , disk_file_name
 , b.failgroup disk_file_fail_group , b.total_mb total_mb, (b.total_mb - b.free_mb) used_mb
 , ROUND((1- (b.free_mb / b.total_mb))*100, 2) pct_used
FROM  v$asm_diskgroup a RIGHT OUTER JOIN
v$asm_disk b USING (group_number)

See the Exit of the Script, confirming that the creation of the disks is done and everything is in perfect order in ASM.

Oracle Grid Infrastructure 19c ASM is completed successfully

Now we are going to use DBCA to create the Multitenant Database with Pluggable Database (PDB). (Learn more...)

See some scripts that can help you.

ASM Disk Performance ASM Disk Groups ASM DROP Files

Want to progress in your DBA career, download our Oracle scripts now and collaborate with us, CLICK FOR ALL