Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.php > #1432 > unrolled thread

Memory leak

Started bynewphp <shabarishhr@gmail.com>
First post2011-05-05 08:43 -0700
Last post2011-05-05 17:09 +0000
Articles 5 — 4 participants

Back to article view | Back to comp.lang.php


Contents

  Memory leak newphp <shabarishhr@gmail.com> - 2011-05-05 08:43 -0700
    Re: Memory leak "Mr. B-o-B" <mr.chew.baka@gmail.com> - 2011-05-05 10:46 -0500
      Re: Memory leak newphp <shabarishhr@gmail.com> - 2011-05-05 08:53 -0700
    Re: Memory leak "Álvaro G. Vicario" <alvaro.NOSPAMTHANX@demogracia.com.invalid> - 2011-05-05 17:49 +0200
    Re: Memory leak Denis McMahon <denis.m.f.mcmahon@gmail.com> - 2011-05-05 17:09 +0000

#1432 — Memory leak

Fromnewphp <shabarishhr@gmail.com>
Date2011-05-05 08:43 -0700
SubjectMemory leak
Message-ID<ba8dcb14-7847-4292-b434-75db643fedad@p7g2000yqh.googlegroups.com>
When I run a PHP script, the script gets killed , when I check the
memory using the command TOP, this process is taking lot of memory
eventually running out..!!
when i check for memory in the script using memory_get_usage or
memory_get_peak_usage functions its uses around 2mb..!! the script
takes a datalist file, reads each row and executes mysql queries..!!
wat could be the reason..!!??
Thanks

[toc] | [next] | [standalone]


#1433

From"Mr. B-o-B" <mr.chew.baka@gmail.com>
Date2011-05-05 10:46 -0500
Message-ID<NDzwp.21478$vT3.6571@newsfe06.iad>
In reply to#1432
On 5/5/2011 10:43 AM, newphp cried from the depths of the abyss:
> When I run a PHP script, the script gets killed , when I check the
> memory using the command TOP, this process is taking lot of memory
> eventually running out..!!
> when i check for memory in the script using memory_get_usage or
> memory_get_peak_usage functions its uses around 2mb..!! the script
> takes a datalist file, reads each row and executes mysql queries..!!
> wat could be the reason..!!??
> Thanks

You might want to include your script

[toc] | [prev] | [next] | [standalone]


#1435

Fromnewphp <shabarishhr@gmail.com>
Date2011-05-05 08:53 -0700
Message-ID<be0832e8-d463-46e7-ab37-00db866a10ed@24g2000yqk.googlegroups.com>
In reply to#1433
On May 5, 11:46 am, "Mr. B-o-B" <mr.chew.b...@gmail.com> wrote:
> On 5/5/2011 10:43 AM, newphp cried from the depths of the abyss:
>
> > When I run a PHP script, the script gets killed , when I check the
> > memory using the command TOP, this process is taking lot of memory
> > eventually running out..!!
> > when i check for memory in the script using memory_get_usage or
> > memory_get_peak_usage functions its uses around 2mb..!! the script
> > takes a datalist file, reads each row and executes mysql queries..!!
> > wat could be the reason..!!??
> > Thanks
>
> You might want to include your script

I cannot include the script, but can u guide me with different methods
to check..??

[toc] | [prev] | [next] | [standalone]


#1434

From"Álvaro G. Vicario" <alvaro.NOSPAMTHANX@demogracia.com.invalid>
Date2011-05-05 17:49 +0200
Message-ID<ipugv9$7vk$1@dont-email.me>
In reply to#1432
El 05/05/2011 17:43, newphp escribió/wrote:
> When I run a PHP script, the script gets killed , when I check the
> memory using the command TOP, this process is taking lot of memory
> eventually running out..!!
> when i check for memory in the script using memory_get_usage or
> memory_get_peak_usage functions its uses around 2mb..!! the script
> takes a datalist file, reads each row and executes mysql queries..!!
> wat could be the reason..!!??

I don't think that a killed process can still show up in the process 
list and even allocate more memory... What do you mean exactly with "the 
script gets killed"? Do you mean that you close the Firefox tab?


-- 
-- http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web: http://borrame.com
-- Mi web de humor satinado: http://www.demogracia.com
--

[toc] | [prev] | [next] | [standalone]


#1437

FromDenis McMahon <denis.m.f.mcmahon@gmail.com>
Date2011-05-05 17:09 +0000
Message-ID<4dc2d9d9$0$13945$bed64819@gradwell.net>
In reply to#1432
On Thu, 05 May 2011 08:43:23 -0700, newphp wrote:

> When I run a PHP script, the script gets killed , when I check the
> memory using the command TOP, this process is taking lot of memory
> eventually running out..!!
> when i check for memory in the script using memory_get_usage or
> memory_get_peak_usage functions its uses around 2mb..!! the script takes
> a datalist file, reads each row and executes mysql queries..!! wat could
> be the reason..!!??

Which process are you checking with top?

Are you sure it's not exceeding some arbitrary execution time?

What's the error message?

Are you running from command line or in a server environment?

Rgds

Denis McMahon

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.php


csiph-web