ORA-01919: role 'PLUSTRACE' does not exist
环境:Oracle 10g,11g.
现象:在一次迁移测试中,发现有这样的角色赋权会报错不存在:
SYS@orcl> grant PLUSTRACE to jingyu;
grant PLUSTRACE to jingyu*
ERROR at line 1:
ORA-01919: role 'PLUSTRACE' does not exist
查询发现这个角色是需要手工执行脚本创建,直接执行Oracle自带的SQL脚本@?/sqlplus/admin/plustrce.sql即可:
SYS@orcl> @?/sqlplus/admin/plustrce.sql
SYS@orcl>
SYS@orcl> drop role plustrace;
drop role plustrace*
ERROR at line 1:
ORA-01919: role 'PLUSTRACE' does not existSYS@orcl> create role plustrace;Role created.SYS@orcl>
SYS@orcl> grant select on v_$sesstat to plustrace;Grant succeeded.SYS@orcl> grant select on v_$statname to plustrace;Grant succeeded.SYS@orcl> grant select on v_$mystat to plustrace;Grant succeeded.SYS@orcl> grant plustrace to dba with admin option;Grant succeeded.SYS@orcl>
SYS@orcl> set echo off
SYS@orcl>
可以看到这个角色就是封装了对v_$sesstat,v_$statname,v_$mystat这几个视图的查询权限。
执行以后就可以直接赋予用户PLUSTRACE的角色了:
SYS@orcl> grant PLUSTRACE to jingyu;Grant succeeded.
ORA-01919: role 'PLUSTRACE' does not exist相关推荐
- ORA-01919: role 'OLAPI_TRACE_USER' does not exist
我在用数据泵导入数据的时候报的错 TEST_USER1@ORCL> conn / as sysdba SYS@ORCL> grant plustrace to TEST_USER1; gr ...
- psql: FATAL: role “appleyuchi” does not exist与修改默认密码
$ psql 报错如下: psql: FATAL: role "appleyuchi" does not exist 使用: sudo -s -u postgres 就会把当前用户 ...
- postgresql 使用pg_restore时显示role root does not exist的解决办法
在docker里恢复bakcup格式的数据库,结果提示role "root" does not exist 解决方法: 切换用户: su - postgres 然后再次运行命令: ...
- ERROR: role company3 does not exist
授权失败 postgres=# grant all on schema test to company3; ERROR: role "company3" does not exis ...
- 【postgresql】role root does not exist 解决办法
问题原因 postgresql是不允许使用root用户启动服务的,所以必须切换到其他用户下才可以进行正常的服务启动,但是有些时候我们又需要使用root用户来使用postgresql 解决办法 方法一 ...
- SP2-0618: Cannot find the Session Identifier. Check PLUSTRACE role is enable
SP2-0618: Cannot find the Session Identifier. Check PLUSTRACE role is enable 以前一直用 SYS 用户使用 autotra ...
- 解决 Oralce 执行set autotrace on时的SP2-0618和SP2-0611错误
在Oracle sqlplus查看执行计划时. 我们一般使用 set autotrace on; 接下来的sql语句就会自动显示execution plan. 但是有时再执行set autotrace ...
- Oracle SQL_TRACE使用小结
一.关于基础表 Oc_COJ^c680758 rd-A6z/&[1R1] H680758 Oracle 10G之前,启用AUTOTRACE功能需要手工创建plan_table表,创建脚本为$O ...
- SQL*Plus环境下创建PLUSTRACE角色
普通用户在SQL*Plus中开启AUTOTRACE报告时,遇到SP2-0618: Cannot find the Session Identifier. Check PLUSTRACE role is ...
最新文章
- 从 Kafka 看时间轮算法设计
- python3 问题 No module named _sqlite3 解决方案
- Package xxx is not available, but is referred to by another package
- 【温故知新】CSS学习笔记(选择器)
- 使用p3p跨域设置Cookie
- html设置点击事件相同,html有多个类名相同的div,如何给每个div绑定click事件并区分?...
- SQL5 将查询后的列重新命名(数据库的几种去重方法)
- JVM优化系列-详解JDK1.8 Metaspace 参数配置
- MySQL深度剖析之事务隔离级别和锁机制(2021)
- Android应用开发(7)---Unicode和国际化支持
- android 后退按钮,如何在android中处理Search View的后退按钮
- 资源向导之 quot;APUEquot;
- checkbox 实例
- 【java学习之路】(java框架)010.声明式事务控制
- 方便的管理苹果Mac上菜单栏图标软件推荐:Bartender
- spark分片个数的确定及Spark内存错误(GC error)的迂回解决方式
- nginx+uwsgi启动Django项目
- 万字长文带你回顾Java集合框架
- 微信聊天记录加密图片还可查看??
- 解决退格键在MinGW的vim中不起作用的问题