You may use "\Process(<process>)\Virtual Bytes" counter to check virtual memory or "\Process(<process>)\Working Set" to monitor phisical memory.
Quote from Microsoft:
\Virtual Bytes is the current size in bytes of the virtual address space the process is using. Use of virtual address space does not necessarily imply corresponding use of either disk or main memory pages. Virtual space is finite, and by using too much, the process can limit its ability to load libraries.
\Working Set is the current number of bytes in the Working Set of this process. The Working Set is the set of memory pages touched recently by the threads in the process. If free memory in the computer is above a threshold, pages are left in the Working Set of a process even if they are not in use. When free memory falls below a threshold, pages are trimmed from Working Sets. If they are needed they will then be soft-faulted back into the Working Set before they leave main memory.
Quote from our manual
Note #2 (bugs): Windows implementation of performance counters has bugs. E.g., Windows 2000 (Professional, Server, and Advanced Server editions) can produce memory leak in PDH.DLL when user (application) querying performance counter that does not exist. This bug fixed in SP2. Also PDH.DLL does not work correctly with multithread applications.
That's why in HostMonitor we have implemented several different methods to work with pdh.dll:
MultiThread - allows to start several tests in separate threads (fastest method)
OneByOne - HostMonitor starts Performance Counter tests one by one
Smart - multithreading model, HostMonitor tries to reload pdh.dll when error occurs
External - HostMonitor uses external (perfobj.exe) utility to perform the tests. This is fast and most reliable method.
You can specify which test mode will be used on Miscellaneous page in the Options dialog.
I would like to find out the memory consumed by a running process. Like it has been mentioned in some of your posts, one can use Working Set property. I have written a C# application, using ProcessName.WorkingSet (where ProcessName is the actual name of the process running on a server, whose info we are looking for) to get the memory of the process. For all practical purposes this works fine.
I would like to get the same information via your Host Monitor application. But, I am finding difficulty to do that. You have also mentioned (post number 753 on May 24, 03) that it is not possible to do the task I am requesting. However, as I have mentioned above that I have already done it using ProcessName.WorkingSet.
Also, will it be possible to have "MemoryConsumed" as a column, which a user can select for any process being monitored?
Please provide detail response to this post. Also, please provide actual steps to be performed to achieve this request. You can use process name as proc1 (just as an example).
I would like to get the same information via your Host Monitor application. But, I am finding difficulty to do that. You have also mentioned (post number 753 on May 24, 03) that it is not possible to do the task I am requesting. However, as I have mentioned above that I have already done it using ProcessName.WorkingSet.
Post 753? There is log related question...
So, what exactly the problem? You don't want to use Performance Counter test?
Also, will it be possible to have "MemoryConsumed" as a column, which a user can select for any process being monitored?
Sorry, I do not understand you.
I would like to MONITOR memory-size of one or more processes not just find out the memory-size of a process.
So, what the problem? I still do not understand why you do not want to use Performance Counter test method.