Locations of visitors to this page

Tuesday, February 24, 2009

clearing nfs locks on netapp - 清除NetApp上NFS的锁

clearing nfs locks on netapp - 清除NetApp上NFS的锁



startup启动数据库时报错:
Tue Feb 24 09:18:15 2009
ORA-00202: control file: '/home/oracle/app/oracle/oradata/test/control01.ctl'
ORA-27086: unable to lock file - already in use
Linux-x86_64 Error: 11: Resource temporarily unavailable
Additional information: 8
因为文件建在netapp的nfs上, 怀疑是nfs的资源出了问题
查询google, 应该是数据库非正常关闭或网络意外中断, 导致nfs上的锁没有释放


关闭数据库, 卸载
shutdown immediate
umount /u02/oem_db

登录netapp存储, 释放锁
ssh root@LabNetapp1-A
priv set advanced
lock status -h
sm_mon -l MGT
lock status -h
LabNetapp1-A> priv set advanced
Warning: These advanced commands are potentially dangerous; use
         them only when directed to do so by Network Appliance
         personnel.
LabNetapp1-A*> lock status -h
======== NLM host MGT
13620 0x00099d9a:0xdf04c35c 0:0 1 GRANTED (0xc0000004327d94b8)
13620 0x00099dab:0xdf04c35c 0:0 1 GRANTED (0xc0000004327d9398)
13620 0x00099d99:0xdf04c35c 0:0 1 GRANTED (0xc0000004327d9278)
13620 0x00099da5:0xdf04c35c 0:0 1 GRANTED (0xc0000004327d9158)
13620 0x00099d9c:0xdf04c35c 0:0 1 GRANTED (0xc0000004327d9038)
13620 0x00099da9:0xdf04c35c 0:0 1 GRANTED (0xc00000042f68fed8)
13620 0x00099d9b:0xdf04c35c 0:0 1 GRANTED (0xc00000042f68fdb8)
13620 0x00109d14:0xdf04c35c 0:0 1 GRANTED (0xc00000042f68fc98)
13620 0x00099da4:0xdf04c35c 0:0 1 GRANTED (0xc00000042f68fa58)
13624 0x00109d13:0xdf04c35c 0:0 1 GRANTED (0xc00000042f68f938)
13624 0x00099d9d:0xdf04c35c 0:0 1 GRANTED (0xc00000042f68f818)
13624 0x00099d9e:0xdf04c35c 0:0 1 GRANTED (0xc00000042f68f6f8)
======== NLM host DEV-DB-2
...

LabNetapp1-A*> sm_mon -l MGT
Tue Feb 24 09:59:20 GMT [LabNetapp1-A: nsm.notify.no.address:error]: no address for host "MGT"
运行完sm_mon -l, 全部锁被清除

启数据库
mount /u02/oem_db
startup
成功


据说删除原来控制文件, 再拷个新的也可以跳过被锁文件. 没有验证过





外部链接:
ORA-01157 ORA-01110 ORA-27086 after crash prevents database from opening
Clearing NFS locks during network crash or outage for Oracle datafiles (需要netapp账号)
ORA-1157 ORA-1110 ORA-27086 Starting up Database


-fin-

No comments:

Website Analytics

Followers