Windows Server 2003
1824846 Members
3696 Online
109674 Solutions
New Discussion юеВ

Re: Directory quota script

 
Chris Teuben
Occasional Advisor

Directory quota script

Is it possible to use a script for setting -directory- quotas on folders?
The folders are to be used by groups instead of single users. So I can't make use of user quotas...
8 REPLIES 8
Pat
Honored Contributor

Re: Directory quota script

Hi, Chris,

The following thread may be of help.

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=191461

Pat
Norman_21
Honored Contributor

Re: Directory quota script

Chris,

Here are sample scripts for Disk Quota.
Open notepad in your computer
Make sure the Word Wrap from the Format Menu is not checked off
Copy and paste the desired script
save as with vbs extension. filename.vbs

http://www.microsoft.com/technet/scriptcenter/scripts/storage/quotas/default.mspx

You may modify the scripts for your convenience!

For Windows 2000 there is a script tool called Diskquotasettings.pl. Refer here:

http://support.microsoft.com/default.aspx?scid=kb;en-us;320047

Hope this help
"Attitudes are contagious, is yours worth catching"/ My first point was given by SEP on January 31, 2003
Chris Teuben
Occasional Advisor

Re: Directory quota script

Ok, your solutions are fine for user based quota settings. But I'm looking for a directory (folder) based solution. The size of the folder should be limited, regardless of who stores the files there.
On our NAS4000S this can be accomplished through the webbased management tool but I need to automate it by means of a script.
Norman_21
Honored Contributor

Re: Directory quota script

Can you be more specific. Where is the folder located and is it a network shared folder?

More details will help us help you!

Thanks
"Attitudes are contagious, is yours worth catching"/ My first point was given by SEP on January 31, 2003
Norman_21
Honored Contributor

Re: Directory quota script

Are you trying to set up a logon script to run when the users login?
"Attitudes are contagious, is yours worth catching"/ My first point was given by SEP on January 31, 2003
Chris Teuben
Occasional Advisor

Re: Directory quota script

Hi LATIF,

What I want to do is the same what is normal for a Novell Netware environment: limiting the size of (sub)directories.

Well... I just found the tool I was looking for. It's very well hidden in the NAS management console. There is "?" in the upper right corner which provides context sensitive help. In there, a command line utility called "dirquota" is mentioned. (I couldn't find this anywhere else in the documentation!)
Just type "dirquota" on a command prompt and additional help is shown on the screen.

Thanks for the additional thinking. :)
Norman_21
Honored Contributor

Re: Directory quota script

UserSpace or DirQuota restrictions

You can set the userspace restrictions or Directory Quota's with a CSV-file import. See the sample.

userspacefl=0,1
0
no userspace info in csv-file.


1
userspace info in csv-file give usespace.

userspace=

is column number in csv-file with the new-value of the userspace limit, If value=0, then usespace limit will be removed.





dirquotafl=0,1
0
No dirquota info in csv-file.


1
DirQuota info in csv-file, give dirquota.

dirquota=

is column number in csv-file with the new-value of the dirquota
limit, If value=0, then dirquota will be removed.

http://www.hbware.net/downloads/apps/homes/homes-3.php

"Attitudes are contagious, is yours worth catching"/ My first point was given by SEP on January 31, 2003
Chris Teuben
Occasional Advisor

Re: Directory quota script

Oops! I'm sorry I put you in the wrong direction. The directory quotas are needed in a Server 2003 environment (HP NAS4000s).