> Senthil,
> Thanks for your reply. Actually I are running out of VM. That is why I
> am
> trying to flush the VM. Any Ideas?
>
> Thanks
Don't use these function to reduce the WS, they aren't of any help (jeez, I
wonder why they have been included in the FCL), all you are doing in forcing
pages to be written to disk, but your problems is that you are consuming
more memory than available and I'm not talking about RAM I'm talking about
virtual address space.
A normal .NET application has something like 1.5MB free VAS, but this space
(especially the Large Object Heap) can be higly fragmented such that only a
fraction of this is available in one large chunk.
Assume the largest free block is ~ 500MB, when your Dataset grows beyond
this , you will get OOM exceptions.
So what you have to do is; check the Dataset size and reduce it by returning
fewer rows or splitting the data over more than one Dataset you name it. If
your Dataset is not that large check other objects that might stay live when
not needed, in other words measure your memory consumption using tools like
CLRProfiler and perfmon.
Willy.
S. Senthil Kumar - 05 Aug 2005 07:21 GMT
"A normal .NET application has something like 1.5MB free VAS"
I'm sure you meant 1.5 GB :).
Willy Denoyette [MVP] - 05 Aug 2005 08:56 GMT
> "A normal .NET application has something like 1.5MB free VAS"
>
> I'm sure you meant 1.5 GB :).
Eek... back to DOS age!!!!
Thanks.
Willy.