sort causes page faults on server machine

  • Thread starter Thread starter JÅns MÁrtin SchlÁttÅr
  • Start date Start date
J

JÅns MÁrtin SchlÁttÅr

Guest
We have a win 2003 server which is accessed by multiple clients
(around 10) by RDP.
The machine has 4GB memory.
When we start a SAS sort, the performance monitor shows a lot of page
faults, but the machine has still 2GB memory available.

Why does a process experience page faults when there is plenty of
memory free?

Martin
 
Re: sort causes page faults on server machine

On Sep 23, 2:46špm, "JÅns MÁrtin SchlÁttÅr"
<KmoEfrUew...@spammotel.com> wrote:
> We have a win 2003 server which is accessed by multiple clients
> (around 10) by RDP.
> The machine has 4GB memory.
> When we start a SAS sort, the performance monitor shows a lot of page
> faults, but the machine has still 2GB memory available.
>
> Why does a process experience page faults when there is plenty of
> memory free?
>
> Martin


Because the overall physical memory allowance for the sas job is less
than it needs. There must be a way of changing your limit but this
might have to be negotiated with the systems people.
 
Re: sort causes page faults on server machine

If the file(s) are read-only to begin with and a user does something
that writes to that memory location, windows will fault and write a copy
of the orginal file to the page file and then create a read/write copy
in memory. So if during this sort process, many files are manipulated
in memory then you could see this behavior. My suggestion would be to
contact the vendor and ask them what is going on in their product to
cause the page faults.

Jeff Pitsch
Microsoft MVP - Terminal Services

J?ns M?rtin Schl?tt?r wrote:
> We have a win 2003 server which is accessed by multiple clients
> (around 10) by RDP.
> The machine has 4GB memory.
> When we start a SAS sort, the performance monitor shows a lot of page
> faults, but the machine has still 2GB memory available.
>
> Why does a process experience page faults when there is plenty of
> memory free?
>
> Martin
>
 
Re: sort causes page faults on server machine

nothing to wonder about Martin. if an application commits some memory --
which obviously is a must for sorting -- the page-tables will be created but
tagged as non-present. that means the memory is mapped in virtual memory but
doesn't point to any physical memory.

if the application now accesses (r/w) one of this non-present pages, the
processor generates an exception (14) and calls the os page fault handler.
this handler now, will allocate a physical memory page and setup the
page-table-entry that it points to this physical page. on the handler
return, the causing instruction will be restarted and the memory access will
succeed.

since the os keeps tracks of various page-fault-counters, you will see this
on-demand-allocation in a raising number of page faults.

the background is that most programmers do over-commits. instead to geting
the file size and allocating exactly this amount of memory, they e.g. alloc
1MB memory to read in a 3k configuration file. with this on demapand
allocation, the system will only give away that much physical memory to the
process, as the application has touched and the remeaning memory can used
for caching still.

-jolt


"J?ns M?rtin Schl?tt?r" <KmoEfrUewEbx@spammotel.com> schrieb im Newsbeitrag
news:vImTVl25inkn-pn2-r0B5DztOIJrQ@registered.motzarella.org...
> We have a win 2003 server which is accessed by multiple clients
> (around 10) by RDP.
> The machine has 4GB memory.
> When we start a SAS sort, the performance monitor shows a lot of page
> faults, but the machine has still 2GB memory available.
>
> Why does a process experience page faults when there is plenty of
> memory free?
>
> Martin
>
 
Re: sort causes page faults on server machine

nothing to wonder about Martin. if an application commits some memory --
which obviously is a must for sorting -- the page-tables will be created but
tagged as non-present. that means the memory is mapped in virtual memory but
doesn't point to any physical memory.

if the application now accesses (r/w) one of this non-present pages, the
processor generates an exception (14) and calls the os page fault handler.
this handler now, will allocate a physical memory page and setup the
page-table-entry that it points to this physical page. on the handler
return, the causing instruction will be restarted and the memory access will
succeed.

since the os keeps tracks of various page-fault-counters, you will see this
on-demand-allocation in a raising number of page faults.

the background is that most programmers do over-commits. instead to geting
the file size and allocating exactly this amount of memory, they e.g. alloc
1MB memory to read in a 3k configuration file. with this on demapand
allocation, the system will only give away that much physical memory to the
process, as the application has touched and the remeaning memory can used
for caching still.

-jolt


"J?ns M?rtin Schl?tt?r" <KmoEfrUewEbx@spammotel.com> schrieb im Newsbeitrag
news:vImTVl25inkn-pn2-r0B5DztOIJrQ@registered.motzarella.org...
> We have a win 2003 server which is accessed by multiple clients
> (around 10) by RDP.
> The machine has 4GB memory.
> When we start a SAS sort, the performance monitor shows a lot of page
> faults, but the machine has still 2GB memory available.
>
> Why does a process experience page faults when there is plenty of
> memory free?
>
> Martin
>
 
Re: sort causes page faults on server machine

thanks for your perfect answer!
 
Back
Top