Review the following sections for information on Oracle Automatic Storage Management (Oracle ASM) storage configuration:
Managing Disk Groups for Older Database Versions
Use Oracle ASM Configuration Assistant (Oracle ASMCA) to create and modify disk groups when you install earlier versions of Oracle databases on Oracle Grid Infrastructure installations.
Releases before Oracle Database 11g Release 2 used Database Configuration Assistant to perform administrative tasks on Oracle ASM. Starting with 11g Release 2 (11.2), Oracle ASM is installed with Oracle Restart. You can no longer use Oracle DBCA to perform administrative tasks on Oracle ASM.
Oracle Automatic Storage Management Installation Considerations
In previous releases, Oracle Automatic Storage Management (Oracle ASM) was installed as part of the Oracle Database installation. Starting with Oracle Database 11g Release 2 (11.2), Oracle Automatic Storage Management is part of an Oracle Grid Infrastructure installation, either for a cluster, or for a standalone server.
If you want to upgrade an existing Oracle Automatic Storage Management installation, then you must upgrade Oracle Automatic Storage Management by running an Oracle Grid Infrastructure upgrade (upgrades of existing Oracle Automatic Storage Management installations). If you do not have Oracle Automatic Storage Management installed and you want to use Oracle Automatic Storage Management as your storage option, then you must complete an Oracle Restart installation before you start your Oracle Database installation.
You must run Oracle Automatic Storage Management Configuration Assistant for installing and configuring Oracle ASM instances, disk groups, volumes, and Oracle Automatic Storage Management Cluster File System (Oracle ACFS). In addition, you can use the ASMCA command-line interface.
You must complete the steps listed under the Configuring Storage for Oracle Automatic Storage Management section to prepare a disk partition to use for the Oracle Automatic Storage Management disk groups.
Ensure that at least one disk is configured appropriately in an Oracle ASM disk group before beginning the installation.
When you install Oracle Automatic Storage Management, Oracle Automatic Storage Management Configuration Assistant creates a separate server parameter file (
SPFILE) and password file for the Oracle Automatic Storage Management instance. As soon as Oracle Automatic Storage Management is installed,
ASMSNMPschema and user are created.
The Oracle Automatic Storage Management instance that manages the existing disk group runs in the Oracle Grid Infrastructure home directory.
Configuring Storage for Oracle Automatic Storage Management
Identify storage requirements and ASM disk group options.
Identifying Storage Requirements for Oracle Automatic Storage Management
To identify the storage requirements for using Oracle Automatic Storage Management, you must determine the number of devices and the amount of free disk space that you require.
- Determine whether you want to use Oracle ASM for Oracle Database files, recovery files, or both. Oracle Database files include data files, control files, redo log files, the server parameter file, and the password file.
During the database installation, you have the option to select either a file system or Oracle ASM as the storage mechanism for Oracle Database files. Similarly, you also have the option to select either a file system or Oracle ASM as the storage mechanism for your recovery files.
You do not have to use the same storage mechanism for both Oracle Database files and recovery files. You can use a file system for one file type and Oracle ASM for the other.
If you select Oracle ASM as your storage option for Oracle Database files, then depending on your choice in the Specify Recovery Options screen, you have the following recovery options:
If you select the Oracle ASM option for your recovery files, then Oracle Universal Installer provides you with only the option to use the same disk group for both Oracle Database files and recovery files.
If you decide not to enable recovery during the database installation, then, after the database installation, you can modify the
DB_RECOVERY_FILE_DESTparameter to enable the fast recovery area.
- Choose the Oracle ASM redundancy level to use for each Oracle Automatic Storage Management disk group you create.
The redundancy level that you choose for the Oracle ASM disk group determines how Oracle ASM mirrors files in the disk group and determines the number of disks and amount of disk space that you require. The redundancy levels are as follows:
To optimize performance and reliability in a normal redundancy disk group, Oracle ASM uses two-way mirroring for data files and three-way mirroring for control files, by default. In addition, you can choose the mirroring characteristics for individual files in a disk group. You can use two-way mirroring or no mirroring.
A normal redundancy disk group requires a minimum of two failure groups (or two disk devices) if you are using two-way mirroring. The effective disk space in a normal redundancy disk group is half the sum of the disk space in all of its devices.
For most installations, Oracle recommends that you use normal redundancy disk groups.
The contents of the disk group are three-way mirrored by default. To create a disk group with high redundancy, you must specify at least three failure groups (a minimum of three devices).Although high-redundancy disk groups provide a high level of data protection, you must consider the higher cost of additional storage devices before deciding to use this redundancy level.
A flex redundancy disk group is a new disk group type with features such as flexible file redundancy, mirror splitting, and redundancy change. A flex disk group can consolidate files with different redundancy requirements into a single disk group. It also provides the capability for databases to change the redundancy of its files.
For database data, you can choose no mirroring (unprotected), two-way mirroring (mirrored), or three-way mirroring (high). A flex redundancy disk group requires a minimum of three disk devices (or three failure groups).
- Determine the total amount of disk space that you require for the data files and recovery files.
If an Oracle ASM instance is running on the system, then you can use an existing disk group to meet these storage requirements. If necessary, you can add disks to an existing disk group during the database installation.
Table 5-1 Oracle ASM Disk Number and Space Requirements for an Oracle database (non-CDB)
Redundancy Level Minimum Number of Disks Data Files Recovery Files Both File Types
Flex 3 7.8 GB
Table 5-2 Oracle ASM Disk Number and Space Requirements for a multitenant container database (CDB) with one pluggable database (PDB)
Redundancy Level Minimum Number of Disks Data Files Recovery Files Both File Types
Flex 3 12.9 GB
The disk devices must be owned by the user performing the grid installation.
Check with your system administrator to determine if the disks used by Oracle ASM are mirrored at the storage level. If so, select External for the redundancy. If the disks are not mirrored at the storage level, then select Normal for the redundancy.
Every Oracle ASM disk is divided into allocation units (AU). An allocation unit is the fundamental unit of allocation within a disk group. You can select the AU Size value from 1, 2, 4, 8, 16, 32 or 64 MB, depending on the specific disk group compatibility level. The default value is set to 4 MB.
- (Optional) Identify failure groups for the Oracle ASM disk group devices.
If you intend to use a normal or high redundancy disk group, then you can further protect your database against hardware failure by associating a set of disk devices in a custom failure group. By default, each device comprises its own failure group. However, if two disk devices in a normal redundancy disk group are attached to the same SCSI controller, then the disk group becomes unavailable if the controller fails. The controller in this example is a single point of failure. To protect against failures of this type, you could use two SCSI controllers, each with two disks, and define a failure group for the disks attached to each controller. This configuration enables the disk group to tolerate the failure of one SCSI controller.
Define custom failure groups after installation, using the GUI tool ASMCA, the command line tool asmcmd, or SQL commands.
If you define custom failure groups, then you must specify a minimum of two failure groups for normal redundancy disk groups and three failure groups for high redundancy disk groups.
For failure groups containing database files and clusterware files, including voting files, you must specify a minimum of three failure groups for normal redundancy disk groups, and five failure groups for high redundancy disk groups. Disk groups containing voting files must have at least three failure groups for normal redundancy or at least five failure groups for high redundancy. Otherwise, the minimum is two and three respectively. The minimum number of failure groups applies whether or not they are custom failure groups.
- If you are sure that a suitable disk group does not exist on the system, then install or identify appropriate disk devices to add to a new disk group. Use the following guidelines when identifying appropriate disk devices:
The disk devices must be owned by the user performing the Oracle Grid Infrastructure installation.
All the devices in an Oracle ASM disk group must be the same size and have the same performance characteristics.
Do not specify multiple partitions on a single physical disk as a disk group device. Oracle Automatic Storage Management expects each disk group device to be on a separate physical disk.
Although you can specify a logical volume as a device in an Oracle ASM disk group, Oracle does not recommend their use because it adds a layer of complexity that is unnecessary with Oracle ASM. Oracle recommends that if you choose to use a logical volume manager, then use the logical volume manager. The logical volume manager represents a single logical unit number (LUN) without striping or mirroring. You can minimize the effect on storage performance of the additional storage layer.
ASM Disk Group Options for Interactive and Noninteractive Installation
You can select new disk groups during interactive installations, but you must use existing disk groups for noninteractive installations.
Select from the following choices to store either database or recovery files in an existing Oracle ASM disk group, depending on installation method:
Installation method that runs Database Configuration Assistant in an interactive mode (either during installation or after installation)
Select new Disk Group
Select existing Disk Group
Installation method that runs Database Configuration Assistant in a noninteractive mode (either during installation or after installation)
Select an existing Disk Group only. You cannot create a disk group during noninteractive installations. You can add disk devices to an existing disk group if it has insufficient free space.
The Oracle ASM instance that manages the existing disk group can be running in a different Oracle home directory.
Step 1: Enabling Disk Automounting
Before you can configure partitions or logical drives on Windows, you must enable disk automounting. Enable disk automounting when using:
Disk partitions on both single-instance and Oracle RAC installations
Cluster file system for Oracle RAC
Raw partitions for a single-node database installation
Primary or logical partitions for Oracle Automatic Storage Management
To enable automounting:
Enter the following commands at a command prompt:
DRIVE_LETTER:\> diskpart DISKPART> automount enable DISKPART> exit
Restart your computer.
Step 2: Creating the Disk Partitions
To create disk partitions, use the disk administration tools provided by the operating system or third party vendors. The following administration tools are provided by the operating system:
The graphical user interface Disk Management snap-in to manage disks.
To access this tool, type
diskmgmt.mscat the command prompt. (Optional) From the Start menu, select All Programs, then Administrative Tools, then Computer Management. Then select the Disk Management node in the Storage tree.
Create primary partitions and logical drives in the extended partitions by selecting the New Simple Volume option. To create a raw device, assign a drive letter and remove the letter after the partition is created. You must select Do not format this partition to specify a raw partition. Do not use spanned volumes or striped volumes. These options convert the volume to a dynamic disk. Oracle Automatic Storage Management does not support dynamic disks.
For other Windows, create primary partitions by selecting the New Partition option. Create the logical drives by selecting the New Logical Drive option.
The command-line tool
diskpart.exe, which lets you create primary partitions, extended partitions, and logical drives.
DRIVE_LETTER:\> diskpart DISKPART> select disk diskn DISKPART> create partition primary | extended | logical size=sizen DISKPART>
diskpart.exeis the command-line tool for managing disks.
disknis the disk number where the partitions are created.
sizenis the size of the partition, for example 500 represents 500 MB.
The online help or documentation for the administration tool that you are using
You can enter the
diskpart.exe commands directly at the command line. Alternatively, you can enter the commands in a text file, and then run
diskpart /s using this file as a script.
You cannot create more than four primary disk partitions per disk. If you need more, you can get around this limitation by creating three primary partitions and then the fourth as an extended partition with as many logical partitions.
For example, to create the disk partitions on Disk 5 and assign them each a size:
DISKPART> select disk 5 DISKPART> create partition primary size=500 DISKPART> ... DISKPART> create partition extended DISKPART> create partition logical size=800 DISKPART> ... DISKPART> create partition logical size=500
Configuring Disks Manually for Oracle Automatic Storage Management
To use Oracle Automatic Storage Management with direct attached storage (DAS) or storage area network (SAN), the disks must be stamped with a header.
If you install Oracle Restart in an interactive mode, Oracle Universal Installer configures the headers of the disk during the installation process. However, if you intend to install Oracle Restart in a response file mode, then you must manually configure the disks before installation by using either
asmtoolg (GUI version) or
asmtool (command-line version). You can also use these tools to reconfigure the disks after installation. The
asmtool utilities work only on partitioned disks: you cannot use Oracle Automatic Storage Management on unpartitioned disks.
asmtool tools associate meaningful, persistent names with disks to facilitate using those disks with Oracle Automatic Storage Management. Oracle Automatic Storage Management uses disk strings to more easily operate on groups of disks at once, so the names that
asmtool creates make this easier than using Windows drive letters.
All disk names created by
asmtool begin with the prefix
ORCLDISK followed by a user-defined prefix (the default is
DATA) and a disk number for identification purposes.
Using the asmtoolg Tool (Graphical User Interface)
To add or change disk stamps:
In the installation media labeled Oracle Grid Infrastructure 12c Release 2 (12.2), from the media root, go to
asmtooldirectory and double-click
If Oracle Database is installed, go to
If User Account Control is enabled, then create a shortcut for the command prompt window on your desktop. An icon for that shortcut appears on the desktop. Right click the icon for the newly created shortcut, and specify "Run as administrator." When the command window opens, go to
\bin, and then type
Select the Add or change label option, then click Next.
asmtoolgtool shows the devices available on the system. Unrecognized disks are labeled as "Candidate device", stamped Oracle Automatic Storage Management disks as "Stamped ASM disk", and unstamped Oracle Automatic Storage Management disks as "Unstamped ASM disks." The tool also shows disks that are recognized by Windows as a file system (such as NTFS). These are not available for use as disks and cannot be selected. In addition, Microsoft Dynamic disks are not available for use as Oracle Automatic Storage Management disks.
In the Stamp Disks window, select the disks to stamp.
Oracle Automatic Storage Management can generate unique stamps for all of the devices selected for a given prefix. The stamps are generated by concatenating a number with the prefix specified. For example, if the prefix is
DATA, then the first Oracle Automatic Storage Management link name is
You can also specify the stamps of individual devices.
(Optional) Select a disk to edit the individual stamp (Oracle Automatic Storage Management link name).
To delete disk stamps:
- Select the Delete labels option, then click Next.
The delete option is only available if disks exist with stamps. The delete window shows all stamped Oracle Automatic Storage Management disks.
- In the Delete Stamps window, select the disks to unstamp.
- Click Next.
- Click Finish.
Example 5-1 Using the asmtool Utility (Command Line)
asmtool utility is a command-line interface for stamping disks. If User Account Control is enabled, then you can create a shortcut for the command prompt window on your desktop. An icon for that shortcut appears on the desktop. Right-click the icon for the newly created shortcut, and select "Run as administrator." Then start
It has the following options:
Adds or changes stamps. You must specify the hard disk, partition, and new stamp name. If the disk is a raw device or has an existing Oracle Automatic Storage Management stamp, then you must specify the
asmtool -add [-force] \Device\Harddisk1\Partition1 ORCLDISKASM0 \Device\Harddisk2\Partition1 ORCLDISKASM2...
Adds or changes stamps using a common prefix to generate stamps automatically. The stamps are generated by adding a number with the prefix specified. If the disk is a raw device or has an existing Oracle Automatic Storage Management stamp, then you must specify the
asmtool -addprefix ORCLDISKASM [-force] \Device\Harddisk1\Partition1 \Device\Harddisk2\Partition1...
Lists available disks. The stamp, windows device name, and disk size in megabytes are shown. Some disks may be file systems, and cannot be stamped. If the disk is a raw device or has an existing Oracle Automatic Storage Management stamp, then you must specify the
asmtool -list [-force]
Removes existing stamps from disks. Also sets Oracle Automatic Storage Management instances to rescan the available disks.
asmtool -delete ORCLDISKASM0 ORCLDISKASM1...