ASM storage capacity monitor

  • Last Updated 3/31/2023, 12:34:01 PM UTC
  • About 3 min read

Plugin info

name: ora-asm-dg-status

Collects ASM disk group capacity statistics and emits high utilization events.

# Prerequisites

  • Linux
    • User Groups: oinstall, asmadmin, asmdba
  • Windows
    • Group Memeberships: ORA_ASMADMIN, ORA_ASMDBA

Important, the connection to the database/ASM takes place over BEQ. This means that the process resource limits for myrmex-ad must match those set for the oracle database/ASM processes. Set these limits in the systemd unit file for myrmex-ad and then reload and restart the myrmex-ad service. Refer to https://www.man7.org/linux/man-pages/man5/systemd.exec.5.html#PROCESS_PROPERTIES (opens new window) for the process limit directives and their ulimit equivalents.

# Events

  • myrmex/ora-asm-dg-status/sid/dg/low set to 1 when disk group capacity is low
    • Dimensions
      • sid the ASM SID
      • dg the disk group name
  • myrmex/plugins/error/plugin/msg set to error message on plugin execution failure
    • Dimensions
      • plugin the name of the plugin that failed

# Configuration

Plugin is configured with a yaml file:

  • timeout: execution timeout in duration format (opens new window). Defaults to 10s
  • source: the value that will appear as the source of metrics generated by this configuration. defaults to plugin hostname
  • oracle_home: path to ASM ORACLE_HOME
  • sid: ASM SID
  • connect_as: (optional) one of sysdba, sysoper, sysasm. Default is sysdba
  • filters: chain of regular expressions to select disk groups for monitoring. A disk group is selected if it matches all filters in the chain
    • filter: regular expression to match disk group name. prefix the expression with ! to negate
  • default_policy: applies when no specific policies for a disk group have been found
    • available: defines an absolute or relative limit on the available space for a diskgroup. the format is "<amount>%|g|gb|m|mb|k|kb"
  • policies: list of disk group specific policies
    • disk_group: a regular expression to specify the disk groups to apply this policy on
    • available: defines an absolute or relative limit on the available space for a diskgroup. the format is "<amount>%|g|gb|m|mb|k|kb"

# Example Configuration

# path to oracle_home for this asm instance
oracle_home: /u01/app/12.2.0.1/grid
# sid to check
sid: +ASM1
# "filters" is chain of regular expressions to select disk groups 
# a disk group is selected if it matches all filters in the chain 
# - prefix the expression with ! to negate
#   fitler: "^TMP" will match all disk groups that begin with TMP
#   filter: "!^TMP" will match all disk groups that do not begine with TMP
filters:
  - filter: "!^RECO" # do not collect stats for any disk group staring with RECO

# "default_policy" applies when no specific policies for a disk group have been found
# properties:
#  - "available" defines an absolute or relative limit on the available space for a diskgroup
#    the format is "<amount>%|g|gb|m|mb|k|kb" 
default_policy:
  available: "10%" # emmit event when available space below 10%

# "policies" defines a list of disk group specific policies
#  - "disk_group" a regular expression to specify the disk groups to apply this policy on
#  - "available"  defines an absolute or relative limit on the available space for a diskgroup the format is "<amount>%|g|gb|m|mb|k|kb" 
policies:
  - disk_group: "^DATA$"
    available: "50g"  # emmit event when available space below 50gb

# Validate Configuration

ora-asm-dg-status  --run-conf /path/to/config/file.yaml --validate

# Testing

Run the plugin from the command line and get any emmited events on stdout

ora-asm-dg-status --run-conf /path/to/config/file.yaml

# List events emmited by this plugin

ora-asm-dg-status --events
Last Updated: 3/31/2023, 12:34:01 PM