|
Posted by melmack3 on 09/10/07 18:22
On 9 Wrz, 16:24, Jerry Stuckle <jstuck...@attglobal.net> wrote:
> melma...@gmail.com wrote:
> > Hi
>
> > I have a big problem with shell commands execution via PHP.
> > I have written a very short PHP script ilustrating the problem:
>
> > <?php
>
> > for($i=0;$i<1000;$i++)
> > {
> > exec("test.bat");
> > }
>
> > ?>
>
> > test.bat is just an empty file.
>
> > This script causes about 10 MB memory leak. It can be observed
> > by usage of performance system monitor. This problems occurs in
> > all available enviroments:
> > - IIS Webserver.
> > - Apache webserver
> > - PHP command line interpreter
>
> > Memory leak is observable only on Windows platform
> > (tested on Windows XP). On Linux everything works OK.
>
> > Does someone know how to solve this problem? Any help appreciated
>
> > Best regards
> > Melmack
>
> I see it increase on my W2K system, but as soon as the program ends, the
> memory allocation goes back to what it was. Are you sure it isn't just
> the gc not having a chance to run?
>
> --
> ==================
> Remove the "x" from my email address
> Jerry Stuckle
> JDS Computer Training Corp.
> jstuck...@attglobal.net
> ==================- Ukryj cytowany tekst -
>
> - Poka cytowany tekst -
I have used sessions and forced garbage collector
to clean the memory with the probability 100%
(reconfiguring php.ini file)
and I called this script X times. The memory was not freed at all!
But I have discovered that it is Windows bug (see my reply to Aaron)
Thank you
Best regards
Melmack
Navigation:
[Reply to this message]
|