Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Collect and Store performance counters into the database 1

Status
Not open for further replies.

ericnet

Programmer
Mar 29, 2006
106
I want to store into an SQL database the performance counters values collected by PerformanceCounter object, I mean using ASP.NET VB.NET code. But I am a little confused about what kind of application I have to build, so that I can start and stop a program that will collect data, maybe monitor, and store some data each period of time into the database. So, this program will automatically fire all those operations once started. This can be done using an aspx page, or several? Or I need to program some kind of windows application in VB.NET?

Thanks
 
I'd use a windows based application (either an application or a service) that monitored the log files of IIS or whichever files you are looking at. There may already be some 3rd party applications that dothis so you may want to search around first.


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
Hi,

I'd use a windows based application (either an application or a service) that monitored...
What do you mean with a ‘service’? In plain words

You said “there may already be some 3rd party applications that do this”. Do you think that such a programs will collect performance data and store them (only which I want) each period of time into the database? I only need to collect data and then store them into the DB, because to monitor performance I already have Windows Performance Monitoring tool, which is enough.
If there are such 3rd party applications that do this (collect performance data and store them into the database), please tell me some which are available (for free if it’s possible ;-))

It would not be easier make a windows based app that collect only the performance counters I need, and then insert them into the database? Or do you think this option is very difficult? I have never made a windows based app, but looking at the code that explains this very good article it doesn’ t seem very difficult.. But what do you think about this article and my specific case? By the way, is this article talking about a windows based app or aspx pages?

Thank you ca8msm
 
What do you mean with a ‘service’? In plain words
A service is something that generally runs silently (although not in all cases) on your PC. It could be used in your case to monitor performance and write the data to a database in the background (i.e. with no front end GUI). An example of them and how to create one can be found here:


As for 3rd party tools, I really don't know if any exist or if they have the functionality that you want (i.e. export the results into your own db) so it may be that you end up creating your own.

The article you linked to seems to cover the basics fairly well and is using a Console Application (which simply opens a DOS type screen and writes the results out to it). You can apply the logic and code from that article but I'd probably create a Windows Service to colect all the information as I wouldn't have thought you would need to see a console.


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.
 
Yeah..! This is a professional advise, I think that create a Windows Service can be the best solution to my case, thank you very much to clarify my doubts! :)

I see that the article uses Visual Studio to create the Windows Service, and I don’ t use it, I program my web app in line (typing the code in the page document). So, I don’ t know if I will find problems when trying to implement some steps, such as “Add a timer control”, “add an installer project”, “Select Build Solution from the Build menu to create an executable”, etc...

Do you think that I can achieve it without using Visual Studio?
 
Seems interesting. First of all I will try it without any IDE tool, but I will keep in mind this alternative, by the case.. ;-)

Thank you
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top