FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » about memory usage with application written with php and mysql
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: about memory usage with application written with php and mysql [message #172536 is a reply to message #172532] Mon, 21 February 2011 17:01 Go to previous messageGo to previous message
Peter H. Coffin is currently offline  Peter H. Coffin
Messages: 245
Registered: September 2010
Karma:
Senior Member
On Mon, 21 Feb 2011 08:51:53 -0800 (PST), lovecreatesbeauty wrote:
> On Feb 21, 9:11?pm, "?lvaro G. Vicario"
> <alvaro.NOSPAMTH...@demogracia.com.invalid> wrote:
>> I'm not sure about your exact question but Linux tends to consider free
>> memory as a wasted resource (why purchase RAM if you are not using it?)
>> so it normally tries to give it some use (cache or whatever). System
>> load is often a better indicator.
>
> Thank you.
>
> From 89.5% (375900k - 39172k) to 98.7% (375900k - 4876k) of the memory
> is lost in my Php code issuing connection to Mysql. Some queries to
> database may return records of ten thousand.
>
> The Php mannual says it has garbage collection and mysql_close is not
> needed. How can the code lead to memory lose like that? Is the code
> wrong and needs to be rewritten?

It's not lost. It's in use for OS-related things. Any memory that PHP
uses would be in the "Used:" accounting, not in the "not listed but not
'free'" lack-of-accounting, including PHP's use of memor for the MySQL
connections.

--
Remember, a 12'x12'x18" raised floor can hold over a thousand gallons of
blood before it starts to seep up through the cracks.
-- Roger Burton West in the Monastery
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: PHP currency converter with XML feed
Next Topic: fopen with URL *never* fails
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Tue Nov 26 17:31:49 GMT 2024

Total time taken to generate the page: 0.04277 seconds