删除磁盘组报错:ORA-15027: active use of diskgroup "DATA" precludes its dismount
2012-12-06 16:27
756 查看
作者 阿九【转载时请务必以超链接形式标明文章原始出处和作者信息】
今天删除一个刚装好的 Grid Infrastructure 下的磁盘组"DATA"的时候,报错:ORA-15027: active use of diskgroup "DATA" precludes its dismount
错误提示是因为在"DATA"磁盘组下有活动的文件存在,所以不能删除磁盘组。查看了磁盘组下的文件,发现ASM实例所使用的spfile是放在磁盘组下的,这也是oracle初始安装的一个特点,就是将第一个ASM实例的spile文件放在第一个磁盘组下。因此,解决过程如下:
1、删除磁盘组报错
[grid@rh5-ora11g ~]$ sqlplus /nolog SQL*Plus: Release 11.2.0.1.0 Production on 星期四 12月 6 23:47:19 2012 Copyright (c) 1982, 2009, Oracle. All rights reserved. SQL> conn /as sysasm 已连接。 SQL> SQL> drop diskgroup "DATA" force including contents; drop diskgroup "DATA" force including contents * 第 1 行出现错误: ORA-15039: diskgroup not dropped ORA-15230: diskgroup 'DATA' does not require the FORCE option SQL> SQL> SQL> drop diskgroup "DATA"; drop diskgroup "DATA" * 第 1 行出现错误: ORA-15039: diskgroup not dropped ORA-15053: diskgroup "DATA" contains existing files SQL> alter diskgroup "DATA" dismount; alter diskgroup "DATA" dismount * 第 1 行出现错误: ORA-15032: not all alterations performed ORA-15027: active use of diskgroup "DATA" precludes its dismount SQL> |
SQL> select group_number, file_number, bytes, type from v$asm_file; GROUP_NUMBER FILE_NUMBER BYTES TYPE ------------ ----------- ---------- ---------------------------------------------------------------------- 1 253 1536 ASMPARAMETERFILE SQL> |
3、将ASM的spfile重置一个新的地方
SQL> create pfile='/grid/base/grid/dbs/spfile_asm.ora' from spfile; File created. SQL> |
SQL> shutdown immediate; ASM diskgroups volume disabled ASM diskgroups dismounted ASM instance shutdown SQL> startup pfile='/grid/base/grid/dbs/spfile_asm.ora'; ASM instance started Total System Global Area 283930624 bytes Fixed Size 2212656 bytes Variable Size 256552144 bytes ASM Cache 25165824 bytes ORA-15110: no diskgroups mounted SQL> alter diskgroup all mount; alter diskgroup all mount * ERROR at line 1: ORA-15110: no diskgroups mounted SQL> alter diskgroup "DATA" mount; Diskgroup altered. SQL> |
[grid@rh5-ora11g ~]$ asmcmd ASMCMD> ls DATA/ ASMCMD> cd data ASMCMD> ls ASM/ ASMCMD> cd asm ASMCMD> ls ASMPARAMETERFILE/ ASMCMD> rm -rf * ASMCMD> ls ASMCMD-08002: entry 'asm' does not exist in directory '+data/' ASMCMD> cd +data ASMCMD> ls ASMCMD> exit [grid@rh5-ora11g ~]$ SQL> drop diskgroup "DATA"; Diskgroup dropped. SQL> exit Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production With the Automatic Storage Management option [grid@rh5-ora11g dbs]$ crs_stat -t 名称 类型 目标 状态 主机 ------------------------------------------------------------ ora....ER.lsnr ora....er.type ONLINE ONLINE rh5-ora11g ora.asm ora.asm.type ONLINE ONLINE rh5-ora11g ora.cssd ora.cssd.type ONLINE ONLINE rh5-ora11g ora.diskmon ora....on.type ONLINE ONLINE rh5-ora11g [grid@rh5-ora11g dbs]$ |
[grid@rh5-ora11g dbs]$ crs_stat -t 名称 类型 目标 状态 主机 ------------------------------------------------------------ ora.DATA.dg ora....up.type ONLINE ONLINE rh5-ora11g ora....ER.lsnr ora....er.type ONLINE ONLINE rh5-ora11g ora.asm ora.asm.type ONLINE ONLINE rh5-ora11g ora.cssd ora.cssd.type ONLINE ONLINE rh5-ora11g ora.diskmon ora....on.type ONLINE ONLINE rh5-ora11g [grid@rh5-ora11g dbs]$ [grid@rh5-ora11g dbs]$ asmcmd lsdg State Type Rebal Sector Block AU Total_MB Free_MB Req_mir_free_MB Usable_file_MB Offline_disks Voting_files Name MOUNTED EXTERN N 512 4096 1048576 3072 3020 0 3020 0 N DATA/ [grid@rh5-ora11g dbs]$ |
[grid@rh5-ora11g dbs]$ sqlplus /nolog SQL*Plus: Release 11.2.0.1.0 Production on 星期五 12月 7 00:09:09 2012 Copyright (c) 1982, 2009, Oracle. All rights reserved. SQL> conn /as sysasm 已连接。 SQL> create spfile='+DATA' from pfile='/grid/base/grid/dbs/spfile_asm.ora'; File created. SQL> shutdown immediate; ASM diskgroups volume disabled ASM diskgroups dismounted ASM instance shutdown SQL> startup ASM 实例已启动 Total System Global Area 283930624 bytes Fixed Size 2212656 bytes Variable Size 256552144 bytes ASM Cache 25165824 bytes ASM diskgroups mounted ASM diskgroups volume enabled SQL> SQL> exit Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production With the Automatic Storage Management option [grid@rh5-ora11g dbs]$ [grid@rh5-ora11g dbs]$ [grid@rh5-ora11g dbs]$ [grid@rh5-ora11g dbs]$ crs_stat -t 名称 类型 目标 状态 主机 ------------------------------------------------------------ ora.DATA.dg ora....up.type ONLINE ONLINE rh5-ora11g ora....ER.lsnr ora....er.type ONLINE ONLINE rh5-ora11g ora.asm ora.asm.type ONLINE ONLINE rh5-ora11g ora.cssd ora.cssd.type ONLINE ONLINE rh5-ora11g ora.diskmon ora....on.type ONLINE ONLINE rh5-ora11g [grid@rh5-ora11g dbs]$ |
本文参考如下博客,很感谢该博客给予的帮助。
文章作者:zhutianjie
文章地址:http://blog.sina.com.cn/s/blog_69e7b8d701014ta2.html
相关文章推荐
- ORA-15027: active use of diskgroup "TEST" precludes its dismount
- ASM删除磁盘报错:ORA-15054: disk "ORCL:VOL2" does not exist in diskgroup "DATA"
- ORA-15063: ASM discovered an insufficient number of disks for diskgroup "ASM,KEL"
- oracle11g RAC GI ORA-15003: diskgroup "XXXX" already mounted in another lock name space
- ALERT.LOG for ASM Shows "WARNING: failed to online diskgroup resource ora.GI.dg (unable to communica
- ORA-15063: ASM discovered an insufficient number of disks for diskgroup "ASM,KEL"
- ASM diskgroup dismount with "Waited 15 secs for write IO to PST" (文档 ID 1581684.1)
- One of the disks in this virtual machine is already in use by a virtual machine or by a snapshot"
- 创建ASM磁盘时报:Marking disk "VOL1" as an ASM disk:[FAILED]
- Data source rejected establishment of connection, message from server: "Too many connections"
- Warning LNK4098 : defaultlib "library" conflicts with use of other libs; use /NODEFAULTLIB:library
- warning LNK4098: defaultlib "MSVCRT" conflicts with use of other libs; use /NODEFAULTLIB:library
- Data source rejected establishment of connection, message from server: "Too many connections"
- ORA-15025: could not open disk"...." ORA-27041: unable to open file Linux-x86_64 Error: 13: Permiss
- "System.Data.OleDb.OleDbException: 无法从指定的数据表中删除"的解决办法
- LINK : warning LNK4098: defaultlib "LIBC" conflicts with use of other libs; use /NODEFAULTLIB:library
- ORA-12032: cannot use rowid column from materialized view log on "DCS_BIZ"."TMP_12"
- warning LNK4098: defaultlib "MSVCRT" conflicts with use of other libs; use /NODEFAULTLIB:library
- ASM关于添加与删除磁盘组(DISKGROUP)
- ORA-14037: partition bound of partition "T1_198012" is too high