In Windows 7, is there a way to know how much memory a service is using?

9

2

In windows 7, is there a way (by using common interface or a custom utility) to know how much memory a specific windows service is using ?

It seems most services are hosted by svchost.exe processes ( some svchosts.exe processes seems to host tons of services). While it is possible to know which services are hosted by a specific process, I found no way to get information about how much memory a service take.

tigrou

Posted 2012-06-15T20:22:37.250

Reputation: 759

You can see a script to check the memory of individual services in this SO answer.

– Rosberg Linhares – 2018-03-17T16:32:11.523

2

Take a look at process explorer, it identifies nested processes and gives a good overall picture of what is going on in a system. http://technet.microsoft.com/en-us/sysinternals/bb896653.aspx

– jmreicha – 2012-06-15T20:54:05.523

Answers

13

Take a look at Process Explorer from the SysInternals suite of tools. Sort the process column by name, and find svchost. Then, you can see in the description field (sometimes) the actual service that is running. The Private Bytes column will show you how much that particular service is using in memory. enter image description here

PenguinCoder

Posted 2012-06-15T20:22:37.250

Reputation: 628

1

As @kreemoweet observes, this does not answer the stated question, which is about when multiple services use the same process. The answer to the question is available over at Server Fault: you can configure each service to use its own process.

– Christian Conkle – 2015-09-07T23:16:27.187

is there a reason i should look in "private bytes" instead of "working set" (or "Virtual size") ? – tigrou – 2012-06-16T08:27:57.677

1

@tigrou Working set is recently referenced memory, you'll see its usually less than Private Bytes. Private Bytes is the current allocated memory by the process that is not shared with any other process. See this StackOverflow question.

– PenguinCoder – 2012-06-16T14:41:55.850

2The whole point of the question was to determine the memory statistics for individual services sharing a single svchost host process. This answer does not address that at all. – kreemoweet – 2014-01-13T05:12:30.730

@kreemoweet You didn't look at the screenshot did you?? scvhost.exe is broken down to the service using it in many locations. – PenguinCoder – 2014-01-13T13:56:56.647

6

By using task manager (Ctrl+Shift+Escape)you can right click the svchost process and select Go to service(s) and it will highlight the service(s) being hosted in that process.

Alternatively by selecting the PID column in the process tab you can then match the PID in services tab.

jdog

Posted 2012-06-15T20:22:37.250

Reputation: 61

1

You can also use the build in Windows Task Manager and go to View > Select Columns > and check the ones that say "Memory" this should be about seven they all give you different ideas about what the program is actually doing at that moment.

gabeio

Posted 2012-06-15T20:22:37.250

Reputation: 174

-1

There's also resource monitor. It's new to windows 7 and 2k8r2. It's like task manager on steroids. Not sure why nobody uses this. It's actually easier to sus out problems with it than with process explorer in my experience. With task manager open, just click the "resource monitor" button on the performance tab.

Rich.Weber

Posted 2012-06-15T20:22:37.250

Reputation: 1

1What information does it give? How about a screenshot? Can you also please just write 2008 R2, instead of initials, especially if it's only 2 extra characters? This answer is very low in quality. Please [edit] to improve it. – Canadian Luke – 2014-07-08T17:24:02.350