OLR and ASM resource.

Changes in spfile can changed parameters in OLR but not vice versa.

SQL> show parameter string

NAME TYPE
------------------------------------ ---------------------------------
VALUE
------------------------------
asm_diskstring string
/dev/sd*

[oracle@db ~]$ srvctl config asm
ASM home: /opt/oracle/product/grid1123
ASM listener: LISTENER
Spfile: +dgrp/ASM/ASMPARAMETERFILE/REGISTRY.253.790098155
ASM diskgroup discovery string: /dev/sd*

Change in spfile.

SQL> alter system set asm_diskstring='/oradata/asm/sd*' scope=spfile;

System altered.

[oracle@db ~]$ srvctl config asm
ASM home: /opt/oracle/product/grid1123
ASM listener: LISTENER
Spfile: +dgrp/ASM/ASMPARAMETERFILE/REGISTRY.253.790098155
ASM diskgroup discovery string: /oradata/asm/sd*

But if we change in OLR, spfile will not be changed.

SQL> select value from v$spparameter where name = 'asm_diskstring';

VALUE
--------------------------------------------------------------------------------
/oradata/asm/sd*

[oracle@db ~]$ srvctl modify asm -d '/dev/sd*';
[oracle@db ~]$ srvctl config asm
ASM home: /opt/oracle/product/grid1123
ASM listener: LISTENER
Spfile: +dgrp/ASM/ASMPARAMETERFILE/REGISTRY.253.790098155
ASM diskgroup discovery string: /dev/sd*

SQL> select value from v$spparameter where name = 'asm_diskstring';

VALUE
--------------------------------------------------------------------------------
/oradata/asm/sd*

When we restart ASM through srvctl the following happens. In spfile we have asm_diskstring = “/oradata/asm/sd*” and exactly that we can see in alert.log,
but in OLR we have this ASM diskgroup discovery string: /dev/sd*

Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Automatic Storage Management option.
ORACLE_HOME = /opt/oracle/product/grid1123
System name: Linux
Node name: db
Release: 2.6.18-274.el5
Version: #1 SMP Fri Jul 8 17:36:59 EDT 2011
Machine: x86_64
Using parameter settings in server-side spfile +dgrp/ASM/ASMPARAMETERFILE/REGISTRY.253.790098155
System parameters with non-default values:
 shared_pool_size = 240M
 large_pool_size = 12M
 instance_type = "asm"
 _memory_broker_stat_interval= 999
 remote_login_passwordfile= "EXCLUSIVE"
 asm_diskstring = "/oradata/asm/sd*"

Along with this disks has been mounted through different path.

NOTE: GMON heartbeating for grp 1
GMON querying group 1 at 3 for pid 17, osid 14389
GMON querying group 1 at 4 for pid 17, osid 14389
NOTE: cache opening disk 0 of grp 1: dgrp_0000 path:/dev/sde5
NOTE: F1X0 found on disk 0 au 2 fcn 0.10632079
NOTE: cache opening disk 1 of grp 1: dgrp_0001 path:/dev/sdf5
NOTE: F1X0 found on disk 1 au 2 fcn 0.10632079
NOTE: cache opening disk 2 of grp 1: dgrp_0002 path:/dev/sdg5
NOTE: F1X0 found on disk 2 au 2 fcn 0.10632079
NOTE: cache opening disk 4 of grp 1: dgrp_0004 path:/dev/sdi5
NOTE: cache opening disk 5 of grp 1: dgrp_0005 path:/dev/sdj5
NOTE: cache opening disk 6 of grp 1: dgrp_0006 path:/dev/sdk5
NOTE: cache opening disk 7 of grp 1: dgrp_0007 path:/dev/sdl5
NOTE: cache opening disk 8 of grp 1: dgrp_0008 path:/dev/sdm5
NOTE: cache opening disk 9 of grp 1: dgrp_0009 path:/dev/sdn5
NOTE: cache opening disk 10 of grp 1: dgrp_0010 path:/dev/sdo5
NOTE: cache opening disk 11 of grp 1: dgrp_0011 path:/dev/sdp5
NOTE: cache opening disk 12 of grp 1: dgrp_0012 path:/dev/sdq5
NOTE: cache opening disk 13 of grp 1: dgrp_0013 path:/dev/sdr5
NOTE: cache opening disk 14 of grp 1: dgrp_0014 path:/dev/sds5

All successfully been started and mounted

SQL> ALTER DISKGROUP ALL ENABLE VOLUME ALL /* asm agent *//* {0:0:636} */
SUCCESS: ALTER DISKGROUP ALL ENABLE VOLUME ALL /* asm agent *//* {0:0:636} */
NOTE: diskgroup resource ora.DGGRP.dg is online

Along with this in spfile we can see this.

SQL> select value from v$spparameter where name = 'asm_diskstring';

VALUE
--------------------------------------------------------------------------------
/oradata/asm/sd*

SQL> show parameter string

NAME TYPE
------------------------------------ ---------------------------------
VALUE
------------------------------
asm_diskstring string
/oradata/asm/sd*

Quite frankly in OS we haven’t that path (/oradata/asm) and in OLR we can see this.

[oracle@db ~]$ srvctl config asm
ASM home: /opt/oracle/product/grid1123
ASM listener: LISTENER
Spfile: +dgrp/ASM/ASMPARAMETERFILE/REGISTRY.253.790098155
ASM diskgroup discovery string: /dev/sd*

Lets try to start ASM instance without srvctl, just with sqlplus with “bad” parameter asm_diskstring in spfile.

Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Automatic Storage Management option.
ORACLE_HOME = /opt/oracle/product/grid1123
System name: Linux
Node name: db
Release: 2.6.18-274.el5
Version: #1 SMP Fri Jul 8 17:36:59 EDT 2011
Machine: x86_64
Using parameter settings in server-side spfile +dgrp/ASM/ASMPARAMETERFILE/REGISTRY.253.790098155
System parameters with non-default values:
 shared_pool_size = 240M
 large_pool_size = 12M
 instance_type = "asm"
 _memory_broker_stat_interval= 999
 remote_login_passwordfile= "EXCLUSIVE"
 asm_diskstring = "/oradata/asm/sd*"
SQL> ALTER DISKGROUP dgrp MOUNT /* asm agent *//* {0:0:662} */
NOTE: cache registered group dgrp number=1 incarn=0xfebeff57
NOTE: cache began mount (first) of group dgrp number=1 incarn=0xfebeff57
NOTE: Loaded library: /opt/oracle/extapi/64/asm/orcl/1/libasm.so
Thu Jun 06 18:17:30 2013
ALTER SYSTEM SET local_listener='(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=0.0.0.0)(PORT=1521))))' SCOPE=MEMORY SID='+ASM';
NOTE: Assigning number (1,14) to disk (/dev/sds5)
NOTE: Assigning number (1,13) to disk (/dev/sdr5)
NOTE: Assigning number (1,12) to disk (/dev/sdq5)
NOTE: Assigning number (1,11) to disk (/dev/sdp5)
NOTE: Assigning number (1,10) to disk (/dev/sdo5)
NOTE: Assigning number (1,9) to disk (/dev/sdn5)
NOTE: Assigning number (1,8) to disk (/dev/sdm5)
NOTE: Assigning number (1,7) to disk (/dev/sdl5)
NOTE: Assigning number (1,6) to disk (/dev/sdk5)
NOTE: Assigning number (1,5) to disk (/dev/sdj5)
NOTE: Assigning number (1,4) to disk (/dev/sdi5)
NOTE: Assigning number (1,3) to disk (/dev/sdh5)
NOTE: Assigning number (1,2) to disk (/dev/sdg5)
NOTE: Assigning number (1,1) to disk (/dev/sdf5)
NOTE: Assigning number (1,0) to disk (/dev/sde5)
GMON querying group 1 at 5 for pid 13, osid 15558
NOTE: Instance updated compatible.asm to 11.2.0.0.0 for grp 1
SUCCESS: diskgroup dgrp was mounted
SUCCESS: ALTER DISKGROUP ALL MOUNT
WARNING: Disk Group dgrp containing spfile for this instance is not mounted
ORA-15032: not all alterations performed
ORA-15017: diskgroup "dgrp" cannot be mounted
ORA-15013: diskgroup "dgrp" is already mounted
ERROR: ALTER DISKGROUP dgrp MOUNT /* asm agent *//* {0:0:662} */
NOTE: diskgroup resource ora.dgrp.dg is online

As we can see we have successfully mounted diskgroup by path (/dev/sd*), this happened because sqlplus process goes to OLR.
Along with this we can see errors at end of the log, ORA-15017 and ORA-15013, this happened because two process sqlplus and srvctl try to mount diskgroup in the same time. Seems to like the BUG.

Conclusion: asm_diskstring parameter has a higher priority in OLR.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s