当前位置: 首页 > BASIC > 正文

本次测试来至于群一次聊天,问11G中非dba组用户执行sqlplus是否还需要执行changePerm.sh.

关于cheangePerm.sh脚本的说明见:Where is the script changePerm.sh? (文档 ID 438676.1)

 

欢迎大家加入ORACLE超级群:17115662 免费解决各种ORACLE问题

111.2.0.4测试

htz用户做为测试用户

[htz@www.htz.pw ~]$source .1124

[htz@www.htz.pw ~]$sqlplus sys/oracle as sysdba

 

SQL*Plus: Release 11.2.0.4.0 Production on Sat May 10 22:20:49 2014

 

Copyright (c) 1982, 2013, Oracle.  All rights reserved.

 

 

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

dba组的用户可以正常登陆数据库

 

210.2.0.4测试

[htz@www.htz.pw ~]$source .1024

[htz@www.htz.pw ~]$sqlplus sys/oracle as sysdba

Error 6 initializing SQL*Plus

Message file sp1<lang>.msb not found

SP2-0750: You may need to set ORACLE_HOME to your Oracle software directory

切换到ORACLE用户执行changePerm.sh脚本

[oracle@www.htz.pw ~]$source .1024

[oracle@www.htz.pw ~]$cd $ORACLE_HOME/install

[oracle@www.htz.pw install]$ls

changePerm.sh   createseed.sh       envVars.properties.bak  jlib      portlist.ini  restrict.lst  rootdeletenode.sh  seed.log   unix

createseed1.sh  envVars.properties  install.excl            make.log  readme.txt    rmfilemap.sh  rootlocaladd       templocal  utl

[oracle@www.htz.pw install]$./changePerm.sh

 

——————————————————————————-

Disclaimer: The purpose of this script is to relax permissions on some of the

files in the database Oracle Home so that all clients can access them.

Please note that Oracle Corporation recommends using the most restrictive file

permissions as possible for your given implementation.  Running this script

should be done only after considering all security ramifications.

——————————————————————————-

 

Do you wish to continue (y/n) [n]: y

Spooling the error log /tmp/changePerm_err.log…

Finished running the script successfully

再次切换到HTZ用户下:注意,以后已经登陆的HTZ用户不退出执行sqlplus会报下面的错误

[htz@www.htz.pw ~]$sqlplus / as sysdba

Message 395 not found;  product=SQLPlus; facility=SP2

Message 396 not found;  product=SQLPlus; facility=SP2

Message 397 not found;  product=SQLPlus; facility=SP2

Message 398 not found;  product=SQLPlus; facility=SP2

Message 399 not found;  product=SQLPlus; facility=SP2

Message 400 not found;  product=SQLPlus; facility=SP2

退出htz,再次登陆

[htz@www.htz.pw ~]$sqlplus sys/oracle as sysdba

 

SQL*Plus: Release 10.2.0.4.0 – Production on Sat May 10 22:51:07 2014

 

Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.

 

ERROR:

ORA-12547: TNS:lost contact

 

 

Enter user-name: 

[htz@www.htz.pw ~]$

这里只能通过监听的方式来远程登陆数据库

[htz@www.htz.pw ~]$sqlplus sys/oracle@127.0.0.1:1521/orcl1024 as sysdba

 

SQL*Plus: Release 10.2.0.4.0 – Production on Sat May 10 22:51:30 2014

 

Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.

 

 

Connected to:

Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 – 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

 

SQL> exit

Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 – 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

3.9.2.0.8测试

[htz@www.htz.pw ~]$source .9208

[htz@www.htz.pw ~]$sqlplus ‘sys/oracle as sysdba’

 

SQL*Plus: Release 9.2.0.8.0 – Production on Sat May 10 22:21:29 2014

 

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

 

ERROR:

ORA-09925: Unable to create audit trail file

Linux-x86_64 Error: 13: Permission denied

Additional information: 9925

ORA-01017: invalid username/password; logon denied

运行changePerm.sh脚本后,再次在htz用户下运行sqlplus

[htz@www.htz.pw ~]$sqlplus ‘sys/oracle as sysdba’

 

SQL*Plus: Release 9.2.0.8.0 – Production on Sat May 10 22:54:11 2014

 

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

 

ERROR:

ORA-01031: insufficient privileges

 

 

Enter user-name:

 

[htz@www.htz.pw admin]$sqlplus ‘sys/oracle@orcl9208 as sysdba’

 

SQL*Plus: Release 9.2.0.8.0 – Production on Sat May 10 22:42:49 2014

 

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

 

 

Connected to:

Oracle9i Enterprise Edition Release 9.2.0.8.0 – 64bit Production

With the Partitioning, OLAP and Oracle Data Mining options

JServer Release 9.2.0.8.0 – Production

 

SQL>

可以只能通过远程的方式来登陆数据库

非ORACLE安装用户执行sqlplus连接数据在不同版本中的测试:等您坐沙发呢!

发表评论

gravatar

? razz sad evil ! smile oops grin eek shock ??? cool lol mad twisted roll wink idea arrow neutral cry mrgreen

快捷键:Ctrl+Enter