"Stargyver" <> wrote ...
> First of all my vista ultimate 64 bit runs some server software (e-mail,
> www,..) so I keep it online as long as possible. But actually the problem
> is
> after a while (maybe 10-20 hours) it stops running certain programs..
> Anyone have an idea what could cause this weird problem that programs
> cannot
> be run? Is there any service etc that I could try restarting to get it
> back
> working without restarting?
It sounds very much like you're hitting some form or resource depletion.
Something in the system is leaking some finite resource; after a period of
time, the global supply of that resource becomes depleted; and anything
which needs it, can no longer run. Typical finite resources which can leak
like this are: desktop heap, handles, non-paged pool memory.
To troubleshoot, you need to measure these resources while the system runs,
and look for any process which claims more and more handles, or non-paged
pool, or whatever, and does not release them again. When you have isolated
the offending process, you can either debug it to find the underlying cause;
or report the problem to the supplier of the software and ask for a fix.
Resource leaks are usually bugs in applications, rather than in Windows
itself (but not always).
You can get a quick overview of handles and non-paged memory using Task
Manager.
While the system is running normally, start Task Manager (ctrl-alt-delete,
or right click on task bar).
Choose the Processes tab
Choose the View menu, Select Columns
Add columns for handles, thread, session ID, Process ID, Handles Threads,
Memory - Non Paged Pool.
Click OK to accept the changes.
When the system gets into the rude state, run Task Manager again. You can
sort processes by each column heading. See what process has the highest
count for handles, threads and non-paged pool. This is not necessarily the
culprit - a process might have a high count for any of these, just because
it is legitimatly busy and performing a lot of work. But often, it provides
a clue as to resource hogs.
You can get more details information on resource consumption (and leakage)
by running Performance Monitor in the Administrative Tools. Add counters for
the Process object, All Instances, and Pool non paged, Threads, and anything
else which looks interesting.
The problem you're desccribing actually sounds most like a Desktop Heap
leak. For background information on this, see here:
http://beta.blogs.msdn.com/ntdebuggi...-overview.aspx
When Desktop Heap is exhausted, you cannot lauch new applications, they
often just die silently when you try to run them.
Microsoft has aan excellent tool for debugging desktop heap leaks, called
"Desktop Heap Monitor" or DHeapMon:
http://www.microsoft.com/downloads/d...displaylang=en
UNFORTUNATELY, Dheapmon is closely tied to operating system version; and as
yet it has not been ported to Vista* :-( So, you could troubleshoot your
services if they were running on Windows Server 2003 ... but not on Vista.
So far, I haven't found any good way to monitor desktop heap on Vista, apart
from raw debugging in WinDBG. This is not easy!! An alternative strategy is
to use the empirical method: disable processes and services one-by-one,
reboot, and let the system run. If it continues to run indefinitely with one
service or process disabled, that's your culprit. Obviously this is not
always practical for a production server. But if you're running on a desktop
OS like Vista, perhaps it isn't a mission critical situation (or, maybe it
is).
If you are lucky, the resource hog wil release its resources again when the
process is terminated. So when the system gets into the rude state, try
stopping or killing processes one by one, and look to see if the system
springs back into life after any particular process has been stopped. If you
stop the "fobar" service and suddenly you can run new applications agin,
then th foobar service is very likely to be the culprit. But with problems
like Desktop Heap depletion, the resources are never freed again, even when
the process is terminated. Closing and restarting the session may be the
only way to recover. For interactive applications, you can do this by
logging out and logging back in again. Services run in Session 0, which can
only be restarted by rebooting the whole box, so a reboot is necessary in
these cases.
If you google for terms like "Windows performance resource leak handles
heap" you'll find lot of technical articles about troubleshooting resource
leaks.
Other folks might have better ideas for you - hope this helps a bit, anyway.
--
Andrew McLaren
amclar (at) optusnet dot com dot au
* there's a good reason for this - Microsoft shares the source code licence
for DHeapmon with several other vendors; and every new release requires
complex legal wrangling and agreement. It usually takes some time. The
actual dev guys who write the tool are total gurus and legends.