System Privilege | Operations Authorized |
---|---|
SYSDBA |
Effectively, this system privilege allows a user to connect as user SYS. |
SYSOPER |
|
[ora11g@rac1 dbs]$ sqlplus sys/oracle@test01 as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Sat Nov 22 05:40:03 2014
Copyright (c) 1982, 2011, Oracle. All rights reserved.
ERROR:
ORA-01031: insufficient privileges
创建了密码文件之后,就没有问题
[ora11g@rac1 dbs]$ orapwd password=oracle file=orapwTEST01 entries=2
[ora11g@rac1 dbs]$ sqlplus sys/oracle@test01 as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Sat Nov 22 05:40:37 2014
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL> exit
#6 关于sysdba和dba的区别,可以通过如下的例子来简单示范一下。
用户n1是dba用户。我们使用sysdba和dba权限的时候来看一下不同之处。
[ora11g@rac1 dbs]$ sqlplus n1/n1 as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Sat Nov 22 05:56:40 2014
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL> select count(*)from cat;
COUNT(*)
----------
4809
SQL> conn n1/n1
Connected.
SQL> select count(*)from cat;
COUNT(*)
----------
406
#7 sysdba具有的权限要远大于dba。我们平常使用的dba角色主要包括创建表,视图,索引等等的明细权限,但是sysdba可以做数据库级的任何操作。
原文:http://blog.itpub.net/23718752/viewspace-1342927/