I was about to put together a script that would vol create with desired *usable* space (calcs based on ['vol size' = 'desired_usable' + 'snap reserve' + WAFL overhead]
.but thought someone on this planet must have done this before.
Bueller?
If none, I'll post when I'm done.
TIA
Best regards,
~~~~~~~~~~~~~~~~
Kevin Parker
Mobile: 919.606.8737
http://theparkerz.com blocked::http://theparkerz.com/
~~~~~~~~~~~~~~~~
Thought I would advertise a few scripts that have worked well for me, written in-house:
http://people.southwestern.edu/~jck/NETAPP/:
-r-xr-xr-x 1 root root 16415 Nov 10 10:27 find_overquota.pl -r-xr-xr-x 1 root root 5526 Nov 10 10:24 NAfixperms.pl -r-xr-xr-x 1 root root 5657 Nov 10 10:24 NAreportperms.pl drwxr-xr-x 2 root root 4096 Nov 10 10:23 quota
./quota: total 16 -r--r--r-- 1 root root 2978 Nov 10 10:22 db_functions.pm -r--r--r-- 1 root root 1865 Nov 10 09:53 mount_fs.pm -rwxr-xr-x 1 root root 5007 Nov 10 09:53 naquota.pl
################## find_overquota.pl: ################## *HOME VOLUME** Users over quota: ================= # USERNAME: NAME_&_NUMBER: PERC: VOL: USED: ALLOC: TYPE: 1 seilerr [Robin Seiler @ 1234] 100% HOME 614 614 MB 2 coopers [Smith Cooper @ 6534] 100% HOME 2326 2326 MB 3 alumni [ @ ] 100% HOME 614 614 MB
Users almost over quota: ======================== # USERNAME: NAME_&_NUMBER: PERC: VOL: USED: ALLOC: TYPE: 4 mendozaj [Jerry Mendoza @ 2354] 99% HOME 614 614 MB 5 hamptonk [Kelly Hampton @ 5533] 99% HOME 868 868 MB 6 sssf [Susan Anderson @ 3454] 86% HOME 8788 10240 file
**MAILDIR VOLUME** Users over quota: ================= # USERNAME: NAME_&_NUMBER: PERC: VOL: USED: ALLOC: TYPE: 1 usem [ @ ] 100% MAILD 5 5 MB
Users almost over quota: ======================== # USERNAME: NAME_&_NUMBER: PERC: VOL: USED: ALLOC: TYPE: 2 warrd [Dan Warren @ 2342] 96% MAILD 787 819 MB 3 pricek [Kim Price @ ] 96% MAILD 411 430 MB 4 simpsj [ @ ] 95% MAILD 407 430 MB 5 mennickp [Perl Mennicke @ 2342] 93% MAILD 568 614 MB
This script support multi volumes and validates netapp quota report against local/virtual quotas before alerting.
################## NAfixperms.pl: ################## This script is very handy when someone breaks UNIX permissions via an incorrectly executed recursive chown/chmod. Script chowns/chmods files based on their .snapshot status.
################## naquota.pl: ################## This script will allow helpdesk (or anyone else unfamiler with UIDs and syntax) to indirectly modify the /etc/quotas file w/o the worry about breaking the file.
usage: ./naquota.pl <user> <filesystem> <quota_limit M> <file_limit K>
Translates /etc/quotas: 100 user@/vol/vol3/QTREE3 814M 307K 200 user@/vol/vol3/QTREE3 480M 300K 300 user@/vol/vol3/QTREE3 1037M 307K 400 user@/vol/vol3/QTREE3 571M 307K
To: smithk user@/vol/vol3/QTREE3 814M 307K aaronb user@/vol/vol3/QTREE3 480M 300K honej user@/vol/vol3/QTREE3 1037M 307K berkk user@/vol/vol3/QTREE3 571M 307K
All changes are made through RCS.
Hope these scripts help someone else as they have helped us. All of these scripts will require /some/ recoding before functioning.
On Sat, Nov 08, 2008 at 09:08:39PM -0500, Kevin M. Parker wrote:
I was about to put together a script that would vol create with desired *usable* space (calcs based on ['vol size' = 'desired_usable' + 'snap reserve' + WAFL overhead]
.but thought someone on this planet must have done this before.
Bueller?
If none, I'll post when I'm done.
TIA
Best regards,
Kevin Parker Mobile: 919.606.8737 http://theparkerz.com <blocked::http://theparkerz.com/>