Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


mwoffenden
2010-07-06T02:38:13Z
Would like VC to send an email when a drive falls below a certain number of free bytes. How could I do that?
Michael
Sponsor
Forum information
ErikC
2010-07-06T08:03:08Z
I know in the latest version 5.6.0 there is an event trigger called 'performance counter'. Here you can setup 'LogicalDisk - %Free space' trigger. I didn't test this myself, it looks easy to setup.

An other way to solve this is to find a utility that outputs the free percentage, or create your own in .NET.
With a condition you can check the output and manage the task flow.

Regards,
Erik
Uses Visualcron since 2006.
Support
2010-07-08T12:00:03Z
Yes, please use the performance counter Trigger.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
mwoffenden
2010-07-08T12:36:36Z
Support wrote:

Yes, please use the performance counter Trigger.


I tried to do that, but it sent out 350 emails in less than a second. How can I have the job stop running once it detects low disk space?

Michael
Support
2010-07-08T12:59:23Z
What if you alter duration to, let say, 30 seconds? Then you can add a Task that inactivates that Job.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
mwoffenden
2010-07-08T14:24:21Z
Support wrote:

What if you alter duration to, let say, 30 seconds? Then you can add a Task that inactivates that Job.


The problem is that the job can send out hundreds of emails in a second, and tens of thousands in 30 seconds.

How can I tell VC to send just 1 email, then deactivate, once the low space condition has been met?
Michael
Support
2010-07-08T14:52:34Z
Ok, I was under the assumption that it would trigger every 30 seconds if that condition was met when setting duration to 30.

I noticed when testing that this indeed waited 30 seconds but then executed very frequently after that, each second for me.

We will investigate this.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Support
2010-07-08T15:42:38Z
Please test this attached version.

Also, make the following changes. Go to Expire Tab of Trigger and set Expiration enabled and set it to Inactivate the Trigger after expiration. Now, activate the Job again and see that you only get one email.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
mwoffenden
2010-07-10T02:28:47Z
Support wrote:

Please test this attached version.

Also, make the following changes. Go to Expire Tab of Trigger and set Expiration enabled and set it to Inactivate the Trigger after expiration. Now, activate the Job again and see that you only get one email.


This worked well! 😁

To complete the process, I would like to automatically re-activate the trigger after a certain length of time. (Otherwise, I could forget to re-activate it.)

Any ideas on how to do that?

Michael
mwoffenden
2010-07-10T13:59:28Z
Just found an easier and more robust way to do this.

It works with VC 4.9.40 or later.

1) Setup a Windows performance alert that will fire when disk space is below x. Your alert must be set to log an entry in the event log (Action tab). This will be event id 2031 and can be set to run at any interval you choose. (Make sure you start the alert. By default it will be stopped.)

2) Setup a VC job that is triggered when the above event is found. VC will only run once per event, so there is no issue with multiple emails going out. Also no need to re-activate the event trigger, since it's always active.
mwoffenden attached the following image(s):

Michael
Support
2010-07-10T14:22:22Z
That sounds great, with the alternate approach. Thanks for finding and testing the performance counter trigger issue.

Right now there is no easy way to activate a Trigger on a specific Job. We will think about this but we are glad that you have found the workaround for now.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
mwoffenden
2010-07-10T16:00:13Z
Support wrote:

That sounds great, with the alternate approach. Thanks for finding and testing the performance counter trigger issue.


Your welcome! Been wanting to figure this our for some time now. There's nothing worse then letting Windows server get low on disk space. 😞

I ran it overnight at 15 minute intervals. As a side benefit, found this approach was able to identify temporary reductions in available space due to nightly batch jobs. This information would be hidden from my view otherwise. Just perfect. 😁

VC is one of those rare brilliant programs that has an endless number of uses. Great job! 👍

Michael
dnewman-scope
2013-01-10T17:59:19Z
I see the work-around from above, but why not just add the feature to only run the tasks at a defined interval regardless of how many times the job is triggered? Most remote monitoring systems have this feature, you could have it too :-)

Default it to 0. That is, let it run as often as it's triggered. But, have a an interval respected if it's set. For example, if you set the interval to 10 minutes, then regardless of how often the performance counter is triggered, only run the associated tasks every 10 minutes.
Support
2013-01-10T22:06:08Z
It is possible to use the Performance Trigger for this kind of monitoring. Try it out and browse through the tree until you find the disk. I believe that you can set interval on this performance counter as it is now.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Scroll to Top