WARNING: This web is not used anymore. Please use PDBService.ASM_Internals instead!
 

ASM Explorations

A collection of experiments and facts on ASM internals.
At CERN Physics DB we use Oracle 10g ASM (Automatic Storage Manager) as a cluster filesystem and volume manager for Oracle RAC. ASM is used to build 'SAME' (stripe and mirror everything') volumes from a number of low-cost storage arrays. Software mirroring by ASM is a key feature of the architecture Architecture_description.pdf ASM is managed via a specialized ASM instance, operations are done using special SQL commands, while metadata is visible via V$ and X$ views. 10.2.0.3 and normal redundancy is the reference for the examples below.

ASM metadata from V$ and X$ views

ASM instance V$ views and X$ tables:

View Name X$ Table name Description
V$ASM_DISKGROUP X$KFGRP performs disk discovery and lists diskgroups
V$ASM_DISKGROUP_STAT X$KFGRP_STAT ists diskgroups
V$ASM_DISK X$KFDSK, X$KFKID performs disk discovery, lists disks and their usage metrics
V$ASM_DISK_STAT X$KFDSK_STAT, X$KFKID lists disks and their usage metrics
V$ASM_FILE X$KFFIL lists ASM files, including metadata/asmdisk files
V$ASM_ALIAS X$KFALS lists ASM aliases, files and directories
V$ASM_TEMPLATE X$KFTMTA lists the available templates and their properties
V$ASM_CLIENT X$KFNCL lists DB instances connected to ASM
V$ASM_OPERATION X$KFGMG lists rebalancing operations
N.A. X$KFKLIB available libraries, includes asmlib path
N.A. X$KFDPARTNER lists disk-to-partner relationships
N.A. X$KFFXP extent map table for all ASM files
N.A. X$KFDAT extent list for all ASM disks

This list is obtained querying v$fixed_view_definition where view_name like '%ASM%' which exposes all the v$ and gv$ views with their definition. Additionally querying v$fixed_table where name like 'X$KF%' and name like 'X$KF%' (ASM views start with the KF prefix).

Oracle*NET to ASM


TIP: connecting to ASM instances via Oracle*NET requires an extra keyword (UR=A) in the tnsnames alias, or you will get an error message that the instance is blocked. You also need a password file Example:
ASM1 =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = [hostname])(PORT = [portN]))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = +ASM1)
      (INSTANCE_NAME = +ASM1)
      (UR=A)
    )
  )

Striping and Mirroring with ASM, extents and allocation units

ASM provides striping and mirroring similar to RAID 10 in normal redundancy. An example, using normal redundancy: the available storage, say 64 HDs over FC SAN, is used to create a diskgroup DATADG. At creation time DATADG is built using 2 evenly sized groups of disks: 32 disks in failgroup N.1 and 32 in failgroup N.2. When a file is create in DATADG, it is logically divided in extents (default of 1MB for datafiles) and allocated in 2 copies, called allocation units (AU): one AU in failgroup N.1 the other in failgroup N.2.

The actual workings can be more complex, depending also on tuning parameters, for example for VLDB _asm_ausize=16777216 and _asm_stripesize=1048576 can be used to optimize metadata storage.

Selected X$tables

X$KFFXP

This table contains the mapping between files and alocation units. It allows to track the position of all the extents of a given file striped and mirrored across storage.

X$KFDAT

X$KFDPARTNER

X$KFFIL and metadata files

Edit | Attach | Watch | Print version | History: r22 | r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions...
Topic revision: r1 - 2007-01-16 - LucaCanali
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    PSSGroup All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2023 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
or Ideas, requests, problems regarding TWiki? use Discourse or Send feedback