Hi, Ken
From a software perspective hacking the registry this way is like eating
your lunch over the PC motherboard. You REALLY want to do this as little
as possible.
Peter's recommendation is still don't do this. If you must do this, flip
this key value in code just before you call Process.GetCurrentProcess() and
restore it afterward. You do NOT want to leave perf counters disabled.
Make sure you check which OS you are using and only do this on Win2K. If
this is used on a limited set of machines, Get them upgraded to WinXP or
Win2k3 as soon as you can.
HTH,
John Eikanger
Microsoft Developer Support
This posting is provided “AS IS” with no warranties, and confers no rights.
(c) 2003 Microsoft Corporation. All rights reserved.
--------------------
| Reply-To: "Ken Varn" <
[email protected]>
| From: "Ken Varn" <
[email protected]>
| References: <urJD5w#
[email protected]>
<epIne8#
[email protected]>
<
[email protected]>
<
[email protected]>
<
[email protected]>
<
[email protected]>
| Subject: Re: Why does call to Process.GetCurrentProcess() access the
floppy drive?
| Date: Wed, 16 Jul 2003 10:40:29 -0400
| Lines: 94
| Organization: Diebold Inc.
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <#
[email protected]>
| Newsgroups: microsoft.public.dotnet.general
| NNTP-Posting-Host: 204.151.249.23
| Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP11.phx.gbl
| Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.general:101356
| X-Tomcat-NG: microsoft.public.dotnet.general
|
| Thanks. That seems to work.
|
| I would think that disconnecting the floppy drive is a much uglier
solution
| than disabling disk performance counters.
|
| --
| -----------------------------------
| Ken Varn
| Senior Software Engineer
| Diebold Inc.
| (e-mail address removed)
| -----------------------------------
| | > hi, Ken
| >
| > Peter asked me to follow up with you.. There is no supported way to do
| > this on Win2K. If you want to try something speculative, you can
disable
| > the disk perf counters.
| > HKLM\SYSTEM\CurrentControlSet\Services\Perfdisk\performance
| >
| > Add a DWORD value called "Disable Performance Counters" and set it to 1.
| > No disk monitoring will work now. But their perf will increase.
| >
| > To reenable these counters, you should delete the key, or set it to 0
| >
| > This is an ugly, ugly solution, and we do NOT recommend using it. A
| better
| > solution would be to physically disconnect the floppy drive, given how
| > rarely they are used these days.
| >
| > Please get back to me if you have further questions.
| >
| > HTH,
| >
| > John Eikanger
| > Microsoft Developer Support
| >
| > This posting is provided "AS IS" with no warranties, and confers no
| rights.
| > (c) 2003 Microsoft Corporation. All rights reserved.
| > --------------------
| > | Reply-To: "Ken Varn" <
[email protected]>
| > | From: "Ken Varn" <
[email protected]>
| > | References: <urJD5w#
[email protected]>
| > <epIne8#
[email protected]>
| > <
[email protected]>
| > <
[email protected]>
| > | Subject: Re: Why does call to Process.GetCurrentProcess() access the
| > floppy drive?
| > | Date: Tue, 15 Jul 2003 12:33:48 -0400
| > | Lines: 30
| > | X-Tomcat-NG: microsoft.public.dotnet.general
| > |
| > | Is there anyway to configure Win 2000 so that it does not go to the
| floppy
| > | drive for performance counters? This really kills application
| performance
| > | when the floppy drive is accessed.
| > |
| > | --
| > | -----------------------------------
| > | Ken Varn
| > | Senior Software Engineer
| > | Diebold Inc.
| > | (e-mail address removed)
| > | -----------------------------------
| > | | > | > Ken,
| > | >
| > | > I can answer why this happens.
| > | >
| > | > Internally the current 1.0 and 1.1 frameworks call performance
| counters
| > as
| > | > part of the Process object. As the perf system initializes, it will
| > load
| > | > in various perf objects. When the disk object loads, it will
| enumerate
| > | the
| > | > known disks (this is Windows 2000). The disk performance counters
| > | changed
| > | > between Windows 2000 and XP (2k3).
| > | >
| > | > This posting is provided "AS IS" with no warranties, and confers no
| > | rights.
| > | >
| > |
| > |
| > |
| >
|
|
|