ORA-15177: cannot operate on system aliases (DBD ERROR: OCIStmtExecute)
ASM操作的时候,删除一个文件夹,删除不了,报错如下:
ASMCMD> ls -l Type Redund Striped Time Sys Name Y IPAP/ ASMCMD> rm ipap ORA-15032: not all alterations performed ORA-15177: cannot operate on system aliases (DBD ERROR: OCIStmtExecute)
在alert日志中出现一条日志:
Thu Jun 12 20:28:50 2014 SQL> alter diskgroup 'KEL' drop directory '+kel/ipap'
用sqlplus进行删除,但是同样出现报错,如下:
SQL> alter diskgroup KEL drop directory '+KEL/IPAP'; alter diskgroup KEL drop directory '+KEL/IPAP' * ERROR at line 1: ORA-15032: not all alterations performed ORA-15177: cannot operate on system aliases
在这个文件夹中存放的是备份信息,使用强制删除能将其删除:
ASMCMD> rm -rf +kel/ipap
在alert日志中出现多条信息,如下:
Thu Jun 12 20:33:05 2014 SQL> alter diskgroup 'KEL' drop file '+kel/ipap/BACKUPSET/2014_06_12/nnsnf0_TAG20140612T195029_0.261.850074801' Thu Jun 12 20:33:06 2014 SQL> alter diskgroup 'KEL' drop file '+kel/ipap/DATAFILE/SYSTEM.260.850074633' Thu Jun 12 20:33:06 2014 SQL> alter diskgroup 'KEL' drop file '+kel/ipap/DATAFILE/SYSAUX.259.850074729' Thu Jun 12 20:33:06 2014 SQL> alter diskgroup 'KEL' drop file '+kel/ipap/DATAFILE/UNDOTBS1.258.850074785' Thu Jun 12 20:33:06 2014 SQL> alter diskgroup 'KEL' drop file '+kel/ipap/DATAFILE/USERS.257.850074797' Thu Jun 12 20:33:06 2014 SQL> alter diskgroup 'KEL' drop file '+kel/ipap/CONTROLFILE/Backup.256.850074797'
从而强制删除是可以删除所有的文件。
在进行这个的时候,发现如果asm的磁盘组没有使用,那么空间使用为0。
磁盘组使用的时候,空间大小:
ASMCMD> du kel ASMCMD> du asm Used_MB Mirror_used_MB 1620 3246 ASMCMD>
不过在sqlplus中查询空间的时候,还是可以查询到具体的情况的:
SQL> select name,state ,total_mb,free_mb from v$asm_diskgroup; NAME STATE TOTAL_MB FREE_MB ---------- ---------- ---------- ---------- ASM MOUNTED 4094 774 KEL MOUNTED 4094 3990
for linux and python