Monitoring Windows Scheduled Tasks
-
-
-
Hi,
Use PowerShell to retrieve the status of scheduled tasks:
https://blogs.technet.microsoft.com/heyscriptingguy/2015/01/12/use-powershell-to-show-results-of-scheduled-tasks/You can then monitor specific (or all) tasks using ExternalParameters/ExternalLists/ExternalParametersProvider depending on your exact requirements.
Cheers
-
-
Hi,
You can create an ExternalParameter (or ExternalParametersProvider) which can run a handful of commands or call a PowerShell script, which returns the data you are after. If you are after one very specific Scheduled Task, that may be enough. You can also implement an ExternalList, which can call PowerShell to generate a list of Scheduled Tasks you are interested in and which exist on that node, then use this with Instance Discovery to create DCIs for you (using the agent parameter created via ExternalParameter or ExternalParametersProvider).
For semi-native PowerShell, you can create an ExternalParameter that simply calls powershell -c "$1" (you can tweak that with -noninteractive, -noprofile, etc.), with $1 being the parameter passed from the DCI. We're using the above not as an ExternalParameter, but an Action, so we can run a single, arbitrary PowerShell command on Windows nodes at any time via NetXMS (and lock this object tool down to the users that we trust with that access).
This method is not suitable for running multi-line commands or scripts of course.Cheers
-
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login