Quota Management on subfolders (Auto-Apply) W2k3 R2

Dear Experts
We are looking for a solution to manage the user home disk quotas on a W2k3 R2 File Server. Actually, we auto-apply quotas on f:\users\* (where * is the username) with the R2 built-in Management Tools. Our file structure looks like this:


The home folder path in the users' AD objects refer to this path. Now we want to set the quota directly on the folder "home", not the folder with the username, because besides the "home" folder, there are folders which the users must not see and on this folders, no quotas should be applied. Is there a possibility with wildcards (e.g. \\server\users$\*\home)?

Thanks for assistance!
Who is Participating?
Rob WilliamsConnect With a Mentor Commented:
Sorry, I had to go out of town for a few days.
I have installed the add-on (very useful), created a duplicate file structure, and tried numerous options. I would have to conquer with your findings. There is no way to create a wildcard at the folder level to apply the quotas in the manor you described. It can only be done on a folder by folder basis.

However, there is also a command line tool dirquota.exe that will allow you to create the quotas. This is installed along with the "file Server Management" tools. Unfortunately the full documentation for this has not even been released as of yet:

I am afraid I have not worked with the command line tool and although I write some basic scripts, it is not a strong point of mine. I am sure though that if you were to post a question in the DOS or VBS scripting forums they could write a simple script that would run through all user directories and set the quotas for your home folders, substituting the "variable" with each loop, using the following plus the options/switches you choose:
dirquota.exe  quota  add  /Path:\\server\users$\%variable%\home  /limit:500mb
Though this would work well and be relatively simple, you would have to re-run if you added a new user.

You can see the options/switches available by running from a command line:
dirquota.exe quota add /?
or the additional basic commands with:
dirquota.exe /?
Rob WilliamsCommented:
Are you saying you currently have disk quotas configured for a folder? Disk quotas in a windows environment can only be enabled on an entire disk and configured per user.
Perhaps I have mis-understood.
chassounaAuthor Commented:
I attached an image of the folder structure for you for better understanding.

Currently, quotas are defined on the user's directory (marked red). This was easy with the auto-apply function of the W2k3 R2 "File Server Resource Manager" (there you can define that quotas should be applied on every subfolder in a folder, as in the attached image, the folder "HomeFolderShare")

But, we want them to be configured on the folder "home" in the user's folder. That's the path the home drive connects to. The other folders under the user's folder are for temporary program files and administrative purposes. The quota should no applied there.

Thank you.
Problems using Powershell and Active Directory?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

Rob WilliamsCommented:
Perhaps there is a new feature that I am not aware of, but quotas are applied to an entire drive and entries are made for each user (rather than folder) such as User1, User2, and so forth. This limits the amount of data any user can place anywhere on that driver, within any folder. I was not aware there were any new Microsoft options to limit quotas by folders.
chassounaAuthor Commented:
There IS the possibility of defining quotas on folders. The W2k3 R2 built-in tool "File Server Resource Manager" even allows you to auto-apply quotas on subfolders. So we defined "x:\HomeFolderShare\*" where the wildcard * stands for every subfolder in it, in our case user1, user2, and so on. But we want them to be configure like this: "x:\HomeFolderShare\*\home". The quotas should only be applied on the folder "home" in every user's folder.
Rob WilliamsCommented:
I am quite embarrassed to say I have never seen that feature (reading about it now). I jut tried adding the console but it requires the CD and I do not have it here on this site. I will install tonight and see if I may be of any help tomorrow.
Again my apologies and thank you for pointing it out.
Rob WilliamsCommented:
If you don't have too many users you could write a simple batch file to set the quota for a given users.
For example the batch file below could be named SetQ, and to set the quota for a new user just enter at a command line (assuming the batch file contains your quota specifications):    
  SetQ  User1

:: Batch file to set quota for user %1
dirquota.exe  quota  add  /Path:D:\users$\%1\home  /limit:500mb

chassounaAuthor Commented:
I hoped that there is a way to automatically set the quotas on subfolders in the user's folder. But I think I will write a batch or VB script that comes out with dirquota.exe. This script must then also be integrated in the user account lifecycle process... Not sure about how I will do that exactly.

Many thanks for your engagement!
Rob WilliamsCommented:
Thanks chassouna. Good luck with it.
Cheers !
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.