views:

284

answers:

1

I've got a windows service that has a part I'm very paranoid about, so I've instrumented it with custom performance counters (I'm moving calls from mta threads to sta threads--don't ask).

The counters and the configuration section have been tested and are known to work... on my machine, but they aren't appearing on the server I installed to.

The installer doesn't create the counters. I check for the existence of the counters and create them if they don't exist before using them.

Is this not working because the service is running under the Local System account? Is there something about 2k3 boxes (R2) that prevents this from working like it does on my XP dev box? What am I missing?

A: 

My best guess is that the account that the service is running under doesn't have the permissions to create the counters. I would expect it to be throwing an exception though. Can you catch the exception and log it?

Rob Prouse
That what I'd think as well, but no exceptions are being thrown.
Will
Created the counters via the installer and it worked. Apparently the service account was not able to create the counters. Not sure why no exception was being thrown; I might have been swallowing it rather than taking the service down (haven't checked my code in this area yet).
Will