WINDOWS下的程序员出身,偶尔也写一些linux平台下小程序, 后转行数据库行业,专注于ORACLE和DB2的运维和优化。 同时也是ios移动开发者。欢迎志同道合的朋友一起研究技术。 数据库技术交流群:58308065,23618606
全部博文(599)
分类: Oracle
2013-09-10 16:10:30
ORACLE可执行文件的默认的权限为:
-rwsr-sr-x 如下:
[oracle@db2server ~]$ ls -ltr /u01/app/oracle/product/db11.2.0.3/bin/oracle
-rwsr-sr-x 1 oracle oinstall 192363463 Mar 10 20:49 /u01/app/oracle/product/db11.2.0.3/bin/oracle
这个S位比较重要,如果去掉S位,将会影响到服务器上其他OS账号的本地连接过程。
oracle@db2server ~]$ chmod 755 /u01/app/oracle/product/db11.2.0.3/bin/oracle
[oracle@db2server ~]$ ls -ltr /u01/app/oracle/product/db11.2.0.3/bin/oracle
-rwxr-xr-x 1 oracle oinstall 192363463 Mar 10 20:49 /u01/app/oracle/product/db11.2.0.3/bin/oracle
[oracle@db2server ~]$ su - yansp
Password:
[yansp@db2server ~]$ sqlplus test/test
SQL*Plus: Release 11.2.0.3.0 Production on Wed Aug 28 18:31:55 2013
Copyright (c) 1982, 2011, Oracle. All rights reserved.
ERROR:
ORA-12547: TNS:lost contact
Enter user-name:
ERROR:
ORA-12547: TNS:lost contact
Enter user-name:
ERROR:
ORA-12547: TNS:lost contact
SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
[yansp@db2server ~]$ exit
logout
通过TNS连接不会存在这个问题。
[yansp@db2server ~]$ sqlplus test/test@192.168.0.5/huateng
SQL*Plus: Release 11.2.0.3.0 Production on Wed Aug 28 18:36:34 2013
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL>
[oracle@db2server ~]$ chmod 6755 /u01/app/oracle/product/db11.2.0.3/bin/oracle
[oracle@db2server ~]$ su - yansp
Password:
[yansp@db2server ~]$ sqlplus test/test
SQL*Plus: Release 11.2.0.3.0 Production on Wed Aug 28 18:32:28 2013
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL>