I want a command to run automatically on my NAS control station which is linux based.
nas_pool -size -a to run everyday at 12 AM .
I have my Control station IP added to exchange server and getting mail to my ID using mail -v [email protected]
I want the NAS utilization report to run nas_pool -size -a which gives the output as:
id = 3
name = clar_r5_performance
used_mb = 8388736
avail_mb = 405784
total_mb = 8794520
potential_mb = 0
can somebody help me with how to configure this output to my mail ID.
Your help will be appreciated!
I am not that comfortable around Linux so a step by step approach will help understand better. Thanks a lot for your time..
Direct answer is using cron on that device to do it. Without knowing the device, I can't tell you how to do this. Consult the product documentation for setting up cron or running 'scheduled tasks'.
The data that you want looks like it should be available via SNMP. I would look into setting up something to poll it periodically using SNMP. You can then put it in an RRD graph for historical analysis or have a log file on the external polling station with all of the results. I try to avoid email whenever possible, it's wasteful. Just an idea, your device should have documentation explaining how to set up SNMP on it if it supports it.
If that NAS is linux based and you have access to it, then it should probably have cron(*nix scheduler)
You can edit cron configuration by running
That's how crontab file would look tp run your command at 12am daily and email it's results to [email protected]:
Overall, you should read more about cron as there are tons of great tutorials online.