SP2-0618: Cannot find the Session Identifier. Check PLUSTRACE role is enabled
发表于:2025-11-07 作者:千家信息网编辑
千家信息网最后更新 2025年11月07日,今天新建数据库使用hr用户练习的时候,set autotrace on时出现以下错误是因为没有PLUSTRACE权限涉及到@ORACLE_HOME/sqlplus/admin/plustrce.sql
千家信息网最后更新 2025年11月07日SP2-0618: Cannot find the Session Identifier. Check PLUSTRACE role is enabled
今天新建数据库使用hr用户练习的时候,set autotrace on时出现以下错误
是因为没有PLUSTRACE权限
涉及到@ORACLE_HOME/sqlplus/admin/plustrce.sql文件
内容如下
-- DESCRIPTION-- Creates a role with access to Dynamic Performance Tables-- for the SQL*Plus SET AUTOTRACE ... STATISTICS command.-- After this script has been run, each user requiring access to-- the AUTOTRACE feature should be granted the PLUSTRACE role by-- the DBA.---- USAGE-- sqlplus "sys/knl_test7 as sysdba" @plustrce---- Catalog.sql must have been run before this file is run.-- This file must be run while connected to a DBA schema.set echo ondrop role plustrace;create role plustrace;grant select on v_$sesstat to plustrace;grant select on v_$statname to plustrace;grant select on v_$mystat to plustrace;grant plustrace to dba with admin option;set echo off
1. 查找数据库中是否有该角色
SQL> select * from dba_roles where role='PLUSTRACE'; no rows selected
2.建立角色 (使用sys用户)
SQL> @?/sqlplus/admin/plustrce.sqlSQL> SQL> drop role plustrace;drop role plustrace *ERROR at line 1:ORA-01919: role 'PLUSTRACE' does not existSQL> 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
3.查询数据库
SQL> select * from dba_roles where role='PLUSTRACE';ROLE PASSWORD AUTHENTICAT------------------------------ -------- -----------PLUSTRACE NO NONE
4.授予操作用户改权限
SQL> grant plustrace to hr;Grant succeeded.
5.使用hr用户测试是否成功
SQL> conn hr/hrConnected.SQL> SQL> set autotrace on
用户
数据
数据库
权限
角色
成功
内容
文件
时候
错误
时出
查询
测试
数据库的安全要保护哪些东西
数据库安全各自的含义是什么
生产安全数据库录入
数据库的安全性及管理
数据库安全策略包含哪些
海淀数据库安全审计系统
建立农村房屋安全信息数据库
易用的数据库客户端支持安全管理
连接数据库失败ssl安全错误
数据库的锁怎样保障安全
清默网络技术
围城下载软件开发
千寻尔雅答案计算机网络技术
阿里云服务器推荐码
中咨科技互联网
西安疫情服务器的思考
吴义良网络技术服务部
网络安全和信息化调研题目
宁波平台软件开发
用友通联不上服务器
阿里云服务器挂软件
百度地图 软件开发
热血航线一直服务器繁忙
奇热网网络技术分析
学习通数据库原理答案
服务器能装双阵列卡么
数据库知识结构
软件开发有税收补贴吗
aix如何查看数据库进程
从事危害网络安全活动
综艺福彩互联网科技有限公司
哪个数据库对中文支持最好
国产开源数据库 对JPA的支持
西集网络安全产业园近况如何
光猫桥接无法连接服务器
2021太仓网络安全大赛
数据库视图编码
pptp服务器已达容量限制
p2p理财软件开发人员
网络安全必学渗透测试流程