C
CrashHunter
Guest
I have a Windows 2003 Server x64 Enterprise Edition with SP2 with 4GB RAM and
an application writing a huge file.
The write throughput is quite good in the beginning (~33MB/s) but it keeps
decreasing, while the CPU keeps increasing. In the beginning, the Kernel CPU
(both in the Task Manager and the Processor\% Privileged Time in performance
monitor) is pretty low, but it keeps increasing. Total CPU is ~ 50%, with
Kernel taking ~8% in the beginning, while later on, the Total CPU reaches
80-90% with Kernel using almost all of that CPU; at that point, the
throughput is very low.
Other numbers: the System Cache (in Task Manager) reaches very soon 3.5 GB
and it stays at that value, but the one that seems to be the problem is the
Paged Pool, which keeps increasing.
In poolmon, I can see that Mmst is the one that keeps increasing and it does
not free the memory unless I stop the write to file. Before starting the
process the Mmst uses 1.8MB, while after 1h:20min it uses 200 MB (at that
point, the Total CPU avarage is 74, with 48% in Privileged mode).
I read some info about the Paged pool (including the KB304101), but most of
them apply to x86 version, which has a limited value for the max pool size
(some 460 MB). On my computer (x64), the size should not be a problem (120GB
is a max value) and I do not get errors but the performance steadily goes
down, even with the Paged Pool under 100 MB !
I do not have anything else running on this computer and the behavior is
reproducible every time. As soon as I stop the process, the System Cache and
Paged Pool memory usage go down, so there is no memory leak.
My application writes data to disk using regular WriteFile API, with an
overlapped structure to write asynchronously. It writes a buffer, processes
the next one and then waits for the previous write to complete before issuing
another write request.
I also tried to use the FILE_FLAG_WRITE_THROUGH flag when opening the file;
the general behavior is similar: increasing Paged Pool, increasing usage of
CPU usage in Kernel mode and decreasing throughput, with some differences,
like the starting throughput is much lower (~6MB/s), and it goes down
slightly slower than the other scenario.
an application writing a huge file.
The write throughput is quite good in the beginning (~33MB/s) but it keeps
decreasing, while the CPU keeps increasing. In the beginning, the Kernel CPU
(both in the Task Manager and the Processor\% Privileged Time in performance
monitor) is pretty low, but it keeps increasing. Total CPU is ~ 50%, with
Kernel taking ~8% in the beginning, while later on, the Total CPU reaches
80-90% with Kernel using almost all of that CPU; at that point, the
throughput is very low.
Other numbers: the System Cache (in Task Manager) reaches very soon 3.5 GB
and it stays at that value, but the one that seems to be the problem is the
Paged Pool, which keeps increasing.
In poolmon, I can see that Mmst is the one that keeps increasing and it does
not free the memory unless I stop the write to file. Before starting the
process the Mmst uses 1.8MB, while after 1h:20min it uses 200 MB (at that
point, the Total CPU avarage is 74, with 48% in Privileged mode).
I read some info about the Paged pool (including the KB304101), but most of
them apply to x86 version, which has a limited value for the max pool size
(some 460 MB). On my computer (x64), the size should not be a problem (120GB
is a max value) and I do not get errors but the performance steadily goes
down, even with the Paged Pool under 100 MB !
I do not have anything else running on this computer and the behavior is
reproducible every time. As soon as I stop the process, the System Cache and
Paged Pool memory usage go down, so there is no memory leak.
My application writes data to disk using regular WriteFile API, with an
overlapped structure to write asynchronously. It writes a buffer, processes
the next one and then waits for the previous write to complete before issuing
another write request.
I also tried to use the FILE_FLAG_WRITE_THROUGH flag when opening the file;
the general behavior is similar: increasing Paged Pool, increasing usage of
CPU usage in Kernel mode and decreasing throughput, with some differences,
like the starting throughput is much lower (~6MB/s), and it goes down
slightly slower than the other scenario.