C114首页 | 新闻 技术 市场 会展 黄页 人物 | 3G NGN VoIP IPTV WiMax FTTH |          通信人家园 | 通信人博客 | 通信商情网 | 通信人才网 | English
近期导读

·通信行业女销售工作现状

·华为过冬的小棉袄

·电信买C网,可能赚不少

  技术 - 学院 - 网络基础 - 正文
用一个实例讲解如何生成autotrace权限
 
( 2008/4/3 09:58 )
本文关键字: 

生成autotrace权限的示例:

一、配置autotrace

1、cd [ORACLE_HOME]/rdbms/admin;

2、以system用户登陆;

3、执行@utlxplan;

4、执行create public synonym plan_table for plan_table;

5、执行 grant all on plan_table to public;

二、创建plustrace角色

1、cd [ORACLE_HOME]/sqlplus/admin;

2、以sys或sysdba登陆;

3、运行@plustrce;

4、执行grant plustrace to public;

注:也可以将public指定为某个用户。

[oracle@olivenan oracle]$ cd $ORACLE_HOME/rdbms/admin/

[oracle@olivenan admin]$ sqlplus system/oracle

SQL*Plus: Release 9.2.0.4.0 - Production on Wed Jun 27 11:00:20 2007

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

Connected to:

Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production

With the Partitioning, OLAP and Oracle Data Mining options

JServer Release 9.2.0.4.0 - Production

SQL> @utlxplan

Table created.

SQL> create public synonym plan_table for plan_table;

Synonym created.

SQL> grant all on plan_table to public;

Grant succeeded.

SQL> exit

Disconnected from Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production

With the Partitioning, OLAP and Oracle Data Mining options

JServer Release 9.2.0.4.0 - Production

[oracle@olivenan admin]$ cd $ORACLE_HOME/sqlplus/admin

[oracle@olivenan admin]$ sysplus "/as sysdba"

-bash: sysplus: command not found

[oracle@olivenan admin]$ sqlplus "/as sysdba"

SQL*Plus: Release 9.2.0.4.0 - Production on Wed Jun 27 11:04:55 2007

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

Connected to:

Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production

With the Partitioning, OLAP and Oracle Data Mining options

JServer Release 9.2.0.4.0 - Production

SQL> @plustrce

SQL>

SQL> drop role plustrace;

drop role plustrace

*

ERROR at line 1:

ORA-01919: role 'PLUSTRACE' does not exist

 

SQL> create role plustrace;

Role created.

SQL>

SQL> grant select on v_$sesstat to plustrace;

Grant succeeded.

SQL> grant select on v_$statname to plustrace;

Grant succeeded.

SQL> grant select on v_$mystat to plustrace;

Grant succeeded.

SQL> grant plustrace to dba with admin option;

Grant succeeded.

SQL>

SQL> set echo off

SQL> grant plustrace to public;

Grant succeeded.

SQL>

至此,执行成功。


作者:Carl    来源:赛迪网
  你是通信人才吗? C114通信人才网
  是通信人才就要上专业通信人才网! 专业、高效、低成本、资源广!
  助你迅速找到满意工作! 拥有中国最全的通信行业人才数据库资源。
C114-AdKey 行业广告系统 
C114 提醒您:1.尊重网上道德,遵守国家的各项法律法规;2.承担一切因为您的行为而导致的相关法律责任;

3.新闻留言板管理人员有权删减留言中的内容;4.您在留言板发表的作品,C114有权站内转载。

[参与本留言即表明您已经阅读并接受上述条款]

相关新闻:
 
Copyright©1999-2008 c114 All Right Reserved
上海荧通网络信息技术有限公司版权所有
南方广告业务部: 021-54451141,54451142 E-mail:c114@c114.net
北方广告业务部: 010-63533177,63533977 E-mail:shi@c114.net.cn
编辑部联系:021-54451141,54451142 E-mail:editor@c114.net.cn
服务热线:021-54451141,54451142