Access is denied when access Process class from aspx

From: pguan (peng.guan@bljc.com)
Date: 08/27/02


From: "pguan" <peng.guan@bljc.com>
Date: Tue, 27 Aug 2002 13:48:16 -0700


I tried to display process info on the web page, get:

Access is denied

Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and where
it originated in the code.

Exception Details: System.ComponentModel.Win32Exception:
Access is denied

Source Error:

Line 131: DllHostEnum = Process.GetProcessesByName
(sProcessName).GetEnumerator

 
Source File: D:\Perf_counter_dll\cPerformanceCounter.vb
Line: 131

Stack Trace:

[Win32Exception (0x80004005): Access is denied]
   System.Diagnostics.PerformanceMonitor.GetData(String
item) +375
   
System.Diagnostics.PerformanceCounterLib.GetPerformanceData
(String item) +150
   
System.Diagnostics.PerformanceCounterLib.get_CategoryTable
() +80
   
System.Diagnostics.PerformanceCounterLib.GetPerformanceData
(String[] categories, Int32[] categoryIndexes) +56
   System.Diagnostics.NtProcessManager.GetProcessInfos
(PerformanceCounterLib library) +157

[InvalidOperationException: Couldn't get process
information from remote machine.]
   System.Diagnostics.NtProcessManager.GetProcessInfos
(PerformanceCounterLib library) +259
   System.Diagnostics.NtProcessManager.GetProcessInfos
(String machineName, Boolean isRemoteMachine) +153
   System.Diagnostics.ProcessManager.GetProcessInfos
(String machineName) +37
   System.Diagnostics.Process.GetProcessesByName(String
processName, String machineName) +69
   System.Diagnostics.Process.GetProcessesByName(String
processName) +11
   Perf_counter_dll.PerformanceCounters.CollectCounters
(String sProcessName) in
D:\Perf_counter_dll\cPerformanceCounter.vb:131
   perfcounter.WebForm1.Page_Load(Object sender, EventArgs
e) in d:\inetpub\wwwroot\perfcounter\WebForm1.aspx.vb:27
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +29
   System.Web.UI.Page.ProcessRequestMain() +724

 



Relevant Pages

  • Re: yes my first web application with database :)
    ... An unhandled exception occurred during the execution of the ... current web request. ... exception can be identified using the exception stack trace below. ... > Source Error: ...
    (borland.public.delphi.language.objectpascal)
  • Re: date rendered differently on two computers with same regional settings
    ... current web request. ... Please review the stack trace for more information ... Source Error: ...
    (microsoft.public.dotnet.framework.aspnet)
  • Slow WebPart
    ... current web request. ... Exception Details: System.Web.HttpException: Request timed out. ... Source Error: ... exception can be identified using the exception stack trace below. ...
    (microsoft.public.sharepoint.portalserver.development)
  • converting String to uniqueidentifier
    ... An unhandled exception occurred during the execution of the current web request. ... Source Error: ... Information regarding the origin and location of the exception can be identified using the exception stack trace below. ...
    (microsoft.public.dotnet.languages.csharp)