rac环境修改SPFILE无权限ORA-01565、ORA-17503、ORA-01031: insufficient privileges
Tags: Insufficient PrivilegesORA-01031ORA-01565ORA-17503Oracle故障处理
、
前言部分
导读和注意事项
各位技术爱好者,看完本文后,你可以掌握如下的技能,也可以学到一些其它你所不知道的知识,\~O(∩_∩)O\~:
① 修改spfile文件报错:
ORA-01565: error in identifying file '+DATA/bocprm/spfilebocprm.ora'
ORA-17503: ksfdopn:2 Failed to open file +DATA/bocprm/spfilebocprm.ora
ORA-01031: insufficient privileges
故障分析及解决过程
故障环境介绍
项目 | source db |
---|---|
db 类型 | RAC |
db version | 11.2.0.3 |
db 存储 | ASM |
OS版本及kernel版本 | AIX 64位 6.1.0.0 |
故障发生现象及报错信息
[THPRMDB1:oracle]:/oracle>sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Mar 2 17:09:55 2016
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, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
SYS@BOCPRM1> alter system set db_recovery_file_dest_size=100G scope=spfile sid='*';
alter system set db_recovery_file_dest_size=100G scope=spfile sid='*'
*
ERROR at line 1:
ORA-01565: error in identifying file '+DATA/bocprm/spfilebocprm.ora'
ORA-17503: ksfdopn:2 Failed to open file +DATA/bocprm/spfilebocprm.ora
ORA-01031: insufficient privileges
SYS@BOCPRM1> alter system set db_recovery_file_dest='+data' sid='*';
alter system set db_recovery_file_dest='+data' sid='*'
*
ERROR at line 1:
ORA-01565: error in identifying file '+DATA/bocprm/spfilebocprm.ora'
ORA-17503: ksfdopn:2 Failed to open file +DATA/bocprm/spfilebocprm.ora
ORA-15055: unable to connect to ASM instance
ORA-01031: insufficient privileges
故障分析及解决过程
确认是使用的sys用户执行的,因为是shell脚本静默安装的数据库,可能有的地方有问题,查看oracle,grid的权限,如下:
[THPRMDB1:oracle]:/oracle>id oracle
uid=1024(oracle) gid=1024(dba) groups=3000(ftp),400(mqm)
[THPRMDB1:oracle]:/oracle>id grid
uid=1025(grid) gid=1024(dba) groups=1025(asmadmin),1026(asmdba),1027(asmoper)
THPRMDB1:root:/>chuser groups=asmadmin,asmdba,asmoper oracle
THPRMDB1:root:/>id oracle
uid=1024(oracle) gid=1024(dba) groups=1025(asmadmin),1026(asmdba),1027(asmoper)
THPRMDB1:root:/>su - oracle
[THPRMDB1:oracle]:/oracle>sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Mar 2 17:13:44 2016
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, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
SYS@BOCPRM1> alter system set db_recovery_file_dest_size=100G sid='*';
System altered.
SYS@BOCPRM1> alter system set db_recovery_file_dest='+data' sid='*';
System altered.
SYS@BOCPRM1> show parameter db_recovery_file_dest
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
db_recovery_file_dest string +data
db_recovery_file_dest_size big integer 100G
SYS@BOCPRM1> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
故障处理总结
SYS无权限,多半是OS权限的问题。