Whats the best practice way to access WMI?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,
I'm just starting out with C# and WMI.

Before I get to far I thought I'd ask what people have found out there.

I know where to find all the basic documentation, but i want to know if
there are any helper libraries , tools or excelent resources I should know
about.

Thanks
 
Mgmtclassgen.

It comes with .Net and allows you to create managed assemblies from the
schemas.

WMI is huge. It spans everything from performance counters to hardware
internals. What sort of apps are you looking to create?

ok,
aq
 
Thanks for point ing that out. Its exactly what i was looking for.

I'm looking to create two main kinds of applications.

Firstly i am looking at adding some custom functionality to our PC
information database, so that will inolve gathering machine data and loading
it into MSSQL.

Secondly. custom monitors for in house and propriatry software. I need to
write some applications that can monitor processes fand report alerts to our
monitoring system.
 
Peter Bates said:
Thanks for point ing that out. Its exactly what i was looking for. np

Firstly i am looking at adding some custom functionality to our PC
information database, so that will inolve gathering machine data and loading
it into MSSQL.

Even in a small network, you should be able to fill some ginormous tables
with the potential system data which can be mined from wmi, here's the link
to the docs:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/wmi_start_page.asp

Secondly. custom monitors for in house and propriatry software. I need to
write some applications that can monitor processes fand report alerts to our
monitoring system.

I believe this one falls in the realm of the Win32_Process WMI class. I
don't recall how limited it is but you should be able to get some good info
on memory and processor usage, and maybe security creds and stuff...good
luck!

ok,
aq
 
Back
Top