we use NetApp built-in CIFS Homedir functionality to share users home directories. It works very well and is more secure than a normal share.
There is only on issue: I can't delete
This is our configuration in /etc/cifs_homedir.cfg:
Adding a new homedir for a new user is no problem. Just create a directory and give modify permission.
But when I try to remove this dir I almost always get this messages:
rmdir: The process cannot access the file because it is being used by another process.
Explorer: Cannot remove folder win-accountname: It is being used by another program. Close any programs that might be using the file and try again.
I verified that there is no file left in this folders and I can't see this folder in "Open Files" from Computer Management.
I already read KB ID: 2010099 and tried
options cifs.oplocks.enable off
but nothing changed.
I can't see any access with:
ssh filer lock status -f |grep account
ssh filer cifs sessions |grep account
The users already left the company and I try to delete the directory from a share for Admins and backup: /vol/userhome
Structure is like this:
DOMAIN is a qtree and the account names are ordinary directories. They was used as dynamic shares but no the users in AD are disabled.
I've allready the Admin right with full access, anyway I have take ownership..., same result:
"Cannot remove folder abc : It is being used by another person or program.Close any programs that might be using the file and try again."
Notice that the folder was empty.
Hi I would suggest trying out these options
1. cifs terminate for the specific user and try deleting the folder
2. Reload the directory path, if client data loss is acceptable
cifs homedir load -f
3. Check if VSCAN or FPolicy is running on the controller
4. Check any preexisting locks and break the locks if present
lock status -f <file/folder> -p cifs
lock break -f <file/folder>
Note: Apart from these there is known issues with credential leak that was causing this problem. The problem is fixed and public report can be seen here: http://support.netapp.com/NOW/cgi-bin/bol?Type=Detail&Display=519891