Now I’m not sure if this is a bug or just my unrealistic expectations (Oracle Support are currently considering it) but I thought I’d throw it out to see if anyone else has an opinion. I’ve seen the same behaviour on Linux and AIX.
We have installed Grid Infrastructure using a software owner of “oracle” with a GID of “oinstall”. This is the group depicted in the documentation:
We’ve also created the ASM OS groups (“asmadmin”, “asmdba” & “asmoper”) as depicted in the link above. My user account is a DBA account but not necessarily one that should make changes in ASM. Therefore it looks like this.
id uid=10024(neiljohnson) gid=501(staff) groups=201(dba),204(asmdba)
I can successfully log into SQL*Plus as SYSDBA for a database and OSDBA for ASM. All is good. So then I tried to go into ASMCMD.
+ASM1%> asmcmd -p -bash: /u01/app/11.2.0/grid/bin/asmcmd: Permission denied
Checking the permissions we can see that only"oracle" or users with "oinstall" can execute ASMCMD.
ls -l /u01/app/11.2.0/grid/bin/asmcmd /u01/app/11.2.0/grid/bin/sqlplus -rwxr-x--- 1 oracle oinstall 5311 Mar 17 2009 /u01/app/11.2.0/grid/bin/asmcmd -rwxr-x--x 1 oracle oinstall 45768172 Jan 11 10:22 /u01/app/11.2.0/grid/bin/sqlplus
I got straight to thinking that something must have gone wrong but after a bit of digging around found the following line in a log file.
./cfgtoollogs/oui/installActions2010-03-04_12-13-41PM.log:INFO: chmod 0750 bin/amdu bin/setasmgid bin/rename bin/fmputl bin/fmputlhp bin/asmcmd
So, it looks like it's intentional. There's also another mention of an old favourite (setasmgid) too.
I'll update this post once I know the reason for the behaviour.
Update October 5th 2010 - Oracle support have finally responded to say that this is expected behaviour however they have opened an enhancement request to allow users other than the software owner to use ASMCMD.