monitoring

SQL Alert when stored procedure executes for too long

廉价感情. 提交于 2019-12-01 05:49:00
I would like to set up a SQL Server 2008 Alert to notify me when any procedure executes for 1 second or longer (just an example). Any ideas? EDIT: Okay, it seems this is not possible. But, just to nudge you in another direction, I know that there are statistics tables in the master database which hold compilation counts, number of calls and other various statistics. Could I maybe periodically query them and then report on it, somehow? no there are no notifications for this. you'll have to set up a trace and poll it every now and then. I'd like to add to Mladen Prajdic's correct answer and to

Monitor directory listing for changes?

那年仲夏 提交于 2019-12-01 05:19:16
On a unix system, how do I monitor (like how 'tail' works) a directory for changes made to files - either new ones created, or size changes, etc. Looking for a command line tool rather than something to be installed. Most unix variants have an API for this, but it's not standardized. On Linux, there is inotify . On the command line, you can use inotifywait . Usage example: inotifywait -m /path/to/dir | while read -r dir event name; do case $event in OPEN) echo "The file $name was created or opened (not necessarily for writing)";; WRITE) echo "The file $name was written to";; DELETE) echo "The

Change process name when launched as batch file

依然范特西╮ 提交于 2019-12-01 05:16:30
I'm working on a monitoring system called "Nagios" which monitors services for UNIX and WINDOWS servers. Problem is WINDOWS services that are launched by batch files are named in task manager as "cmd.exe", so system can't distinguish between these services when monitoring. How can I change a process name on task manager when launching it so each one has a unique name rather than "cmd.exe"? Thank you in advance. You can run batch file as windows service to make a process name. You can set what to happen on start and on stop. You can kill the service using its PID. C# Tutorial to create batch

Change process name when launched as batch file

独自空忆成欢 提交于 2019-12-01 02:52:58
问题 I'm working on a monitoring system called "Nagios" which monitors services for UNIX and WINDOWS servers. Problem is WINDOWS services that are launched by batch files are named in task manager as "cmd.exe", so system can't distinguish between these services when monitoring. How can I change a process name on task manager when launching it so each one has a unique name rather than "cmd.exe"? Thank you in advance. 回答1: You can run batch file as windows service to make a process name. You can set

Monitor directory listing for changes?

▼魔方 西西 提交于 2019-12-01 02:52:36
问题 On a unix system, how do I monitor (like how 'tail' works) a directory for changes made to files - either new ones created, or size changes, etc. Looking for a command line tool rather than something to be installed. 回答1: Most unix variants have an API for this, but it's not standardized. On Linux, there is inotify. On the command line, you can use inotifywait. Usage example: inotifywait -m /path/to/dir | while read -r dir event name; do case $event in OPEN) echo "The file $name was created

Monitor ruby processes with Monit

别来无恙 提交于 2019-12-01 02:47:43
I have a bunch of Ruby scripts which are long running, I'd like to ensure that every 30 seconds or so these are up. I normally start the commands by simply ruby script-name.rb How can I configure monit to look after these scripts? Update: I tried to follow this method to create a wrapper script which would then launch the ruby process but it did not seem to create the .pid file and typing './wrapper-script stop' did nothing :/ Should I write the pid inside ruby or use a wrapper script to create the pid necessary for monit? The Monit Wiki has a lot of configuration examples: http://mmonit.com

Fetch Page source using HtmlUnit : URL got stuck

十年热恋 提交于 2019-12-01 00:38:37
I am trying to get page source of following URL using Html-Unit get method. http://denydesigns.com/collections/barbara-sherman-fleece-throw-blanket/products/barbara-sherman-antique-fleece-throw-blanket It is getting stuck somewhere. I am trying to find out the reason but I am not getting it. I also tried to see if the Thread created by HtmlUnit is BLOCKED ar WAITING, but this is also not the case. Following is my log generated by HTML Unit. 18 Jan 2013 04:14:47,832 - main - ERROR - com.gargoylesoftware.htmlunit.javascript.StrictErrorReporter.runtimeError(StrictErrorReporter.java:79) -

Best traffic / performance / usage monitoring module?

佐手、 提交于 2019-11-30 22:47:20
Are there any open source (or I guess commercial) packages that you can plug into your site for monitoring purposes? I'd like something that we can hook up to our ASP.NET site and use to provide reporting on things like: performance over time current load page traffic SQL performance PU time monitoring Ideally in c# :) With some sexy graphs. Edit : I'd also be happy with a package that I can feed statistics and views of data to, and it would analyse trends, spot abnormal behaviour (e.g. "no one has logged in for the last hour. is this Ok?", "high traffic levels detected", "low number of API

Monitor ruby processes with Monit

孤街浪徒 提交于 2019-11-30 22:37:08
问题 I have a bunch of Ruby scripts which are long running, I'd like to ensure that every 30 seconds or so these are up. I normally start the commands by simply ruby script-name.rb How can I configure monit to look after these scripts? Update: I tried to follow this method to create a wrapper script which would then launch the ruby process but it did not seem to create the .pid file and typing './wrapper-script stop' did nothing :/ Should I write the pid inside ruby or use a wrapper script to

How to Get Per Process Disk Activity in Windows

拟墨画扇 提交于 2019-11-30 16:09:41
I need to extract disk statistics for a given process, I can get the processes listed and get overall information such as CPU and Memory listed using WMI and PerformanceCounters. But the information is all bundled up, is there any way to extract those data per process. Kind of like in Windows Resource Monitor? Thanks in Advance If you need live data, you should implement ETW listener. ETW are the way of tracing performance information in Windows. It is supported back to Windows 2000. Every component in Windows report ETW events (if there is a listener waiting for data). For example, Disk info,