• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

ASMLib-Managed Disks on Multipathed iSCSI Targets are not Discovered after Server Reboot in CentOS/RHEL 7

by admin

The Problem

Oracle Real Application Clusters (RAC) servers run on CentOS/RHEL 7 and utilizing ASMLib-managed iSCSI multipathed disks. Upon server reboot, Oracle ASMLib disks are not automatically discovered at boot time causing Oracle Cluster Ready Services (CRS) to fail to start. ASM disks are, however, correctly discovered when manually running the oracleasm scandisks command soon after the server reboot.

Following is the oracleasm configuration

# cat /etc/sysconfig/oracleasm
...
ORACLEASM_ENABLED=true
ORACLEASM_UID=oracle
ORACLEASM_GID=dba
ORACLEASM_SCANBOOT=true
ORACLEASM_SCANORDER=""
ORACLEASM_SCANEXCLUDE=""
ORACLEASM_USE_LOGICAL_BLOCK_SIZE=false
...
# cat -n /usr/lib/systemd/system/oracleasm.service
1 [Unit]
2 Description=Load oracleasm Modules
3 Requires=multipathd.service
4 After=multipathd.service
...

The Solution

Reviewing system startup messages within the system log (/var/log/messages), it is evident that:
– oracleasm.service starts before iscsid.service completes making all iSCSI targets fully available/operational and before multipathd.service adds at least one path to iSCSI targets.
– the ohasd.service starts after oracleasm.service but no ASM disks are discovered.

Modify file /usr/lib/systemd/system/oracleasm.service and append both the ‘Requires‘ and ‘After‘ lines with iscsid.service multi-user.target to ensure the oracleasm.service starts after completion of iscsid.service and multipathd.service and after multi-user.target has been reached i.e.:

# cat -n /usr/lib/systemd/system/oracleasm.service
1 [Unit]
2 Description=Load oracleasm Modules
3 Requires=multipathd.service iscsid.service multi-user.target
4 After=multipathd.service iscsid.service multi-user.target
...

Modify file /etc/systemd/system/oracle-ohasd.service – append the ‘After‘ line with oracleasm.service to ensure the CRS ohasd.service starts after oracleasm.service has successfully discovered all iSCSI multipathed ASM disks i.e.:

# cat -n /etc/systemd/system/oracle-ohasd.service
...
5 [Unit]
6 Description=Oracle High Availability Services
7 After=syslog.target network-online.target remote-fs.target oracleasm.service
...
Note: if /etc/systemd/system/oracle-ohasd.service is not available then please do refer /etc/systemd/system/ohasd.service which provides similar functionality.

Filed Under: ASM, CentOS/RHEL 7, Linux, oracle

Some more articles you might also be interested in …

  1. binwalk Command Examples in Linux
  2. Beginners Guide to Flash Recovery Area in Oracle Database
  3. rename Command Examples in Linux
  4. Magento 2 Rabbitmq configuration
  5. initctl Command Examples in Linux
  6. btrfs rescue Command Examples in Linux
  7. flameshot: command not found
  8. 12 RPM (Red Hat Package Manager) Command Examples
  9. Oracle Database: Redo log operations (Add/Drop/Change Location)
  10. How to change the interface name in CentOS/RHEL 8 using prefixdevname

You May Also Like

Primary Sidebar

Recent Posts

  • qsub Command Examples in Linux
  • qsub: command not found
  • qrcp Command Examples in Linux
  • qmrestore Command Examples in Linux

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright