Tuesday, February 16, 2010

Oracle user can, But my user can't

It is late and I am very tired and one of our servers encountered an issue (Oracle 10.2.0.2 instance on a Linux x86-64bit system). This required me to lay down a tar of the oracle_home directory I had on hand. All went well as long as I was the Oracle user. As soon as I tried to login as another user on the server I got the following error:

:/usr/users/username$>sqlplus username
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Feb 16 02:29:08 2010
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.
Enter password: *********
ERROR:
ORA-01034: ORACLE not available
ORA-27123: unable to attach to shared memory segment
Linux Error: 13: Permission denied

Well just looking at this information I knew it had to do with the permissions related to the oracle_home directory. So I took quick look at a long listing (ls –l) of the bin/ directory and there it was like a sore thumb:

server:/oracle/product/10g/bin$>ls -l oracle
total 185648
-rwxr-x--x 1 oracle dba 86468919 Jan 26 2007 oracle*

Note: The oracle file “must” have the permission set as such: -rwsr-s- -x that is: 6751
So I changed them as follows:

server:/oracle/product/10g/bin$>chmod 6751 oracle
server:/oracle/product/10g/bin$>ls -l oracle
total 185648
-rwsr-s--x 1 oracle dba 86468919 Jan 26 2007 oracle*

Ah… much better, after changing the permissions on the oracle executable file, all of the others users were able to connect via sqlplus to the instance without encountering the error.

Have a great day!