Re: Determining system resources

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Francisco M. Marzoa Alonso [fmmarzoa@xxxxxxx] wrote:
As far as you cannot lock another processes in the system, so this will not give you the security that the resources will not change -and probably they'll do it- while you're trying to download that file.

Yes, I understand, but not to know even if you are in the right order of magnitude, is kind of scary isn't it?


For example on my system, I have 1 Gig of physical memory, and 3Gig of swap. If I end up with only 512k free - something is very wrong, and I should disallow functions I know that eat up memory. There is a low probability that multiple connections will pass the test, and then consume the memory, so yes this is not 100% coverage.

Maybe what I am seeing is actually a bug in the way that readfile() handles low memory situations. If there is not enough memory for internal functions to run, they should error, not crash your system.

I assume that the way the converstation is moved is that there is not a way to see what free system memory is, without calling a command line function (free or mem).

-Robin

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux