Wednesday, August 11, 2010

veritas: Cannot unmount a Locked VxFS filesystem

Storage Foundation 5.0MP3 introduced a new feature called VxFS filesystem lock which disallows accidental unmounts when the  file system resource is online. New umount option mntunlock is used to clear the lock and then unmount the filesystem. The offline script for the Mount resource will use this new option.








How to check if the filesystem is locked by VCS:

 # mount -v | grep mntlock


Sometimes, it may be necessary to unmount a mount locked filesystem. This is for cases where VCS service groups having DiskGroup resources configured with UnMountVolumes attribute set and the volumes are mounted outside of VCS control (this is not very common).

The filesystem locking system is to prevent accidental unmounts, if the attribute is set to 0 VCS will not lock the filesystem.
















The following fix from Symantec to umount the locked vxfs filesystem may not work, a bug in 5.0 MP3 was found and it could be fixed in future releases. 
If the following command does not work a bounce is required.

Solaris:

 # /opt/VRTS/bin/umount -o mntunlock=VCS /mount-point

If you continue to experience issues such as :

 UX:vxfs umount: ERROR: V-3-21705: mount-point cannot unmount : Device busy

The above "umount" command has already cleared the Mount Lock silently but the Mount Lock is still shown in the "mount -v" output.   Now the file system will not be able to be unmounted.
Run fuser checks on the mount points to confirm any outbound processes still running:

 # fuser -c /mount-point

but if you continue to encounter issues and recieve the following error:

 UX:vxfs umount: ERROR: V-3-26365: Incorrect mntlock id  (Invalid argument)

You can attempt to unmount it using the fsadm command:

 # fsadm -o mntunlock=VCS /mount-point

Trying to clear the Mount Lock using fsadm could also fail.

 UX:vxfs fsadm: ERROR: V-3-26348: file system not mount locked

The workaround is to lock the file system again using fsadm with the same lock name.

 # fsadm -o mntlock=VCS /mount-point

Now the system can be unmounted successfully by umount.

 # umount -o mntunlock=VCS /mount-point

Please note that if the VxFS file system is disabled, fsadm will not be able to remove the lock.   The only way to unmount the disabled file system is to reboot the system.

 Apr 17 13:00:07 alaw2 vxfs: [ID 702911 kern.warning] WARNING: msgcnt 3 mesg 031: V-2-31: vx_disable  - /mount-point file system disabled

 # fsadm -o mntlock=VCS /mount-point
 UX:vxfs fsadm: ERROR: V-3-20275: cannot open /mount-point



No comments:

Post a Comment