is there a max size to MySql?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • lawrence

    is there a max size to MySql?

    I'm playing around with the code that runs my site. Suddenly I started
    getting this error:

    <b>Fatal error</b>: Allowed memory size of 8388608 bytes exhausted
    (tried to allocate 311020 bytes) in
    <b>/home/www/krubner/atp/mcIncludes/mcDatabase.php</b> on line
    <b>72</b><br />

    This shows up at the bottom of the page, after everything else has
    run, when the code attempts to update how many times the page has been
    viewed. What could it mean? Does MySQL have some size limit?
  • Jochen Daum

    #2
    Re: is there a max size to MySql?

    Hi Lawrence!


    On 31 Aug 2003 16:28:04 -0700, lkrubner@geocit ies.com (lawrence)
    wrote:
    [color=blue]
    >I'm playing around with the code that runs my site. Suddenly I started
    >getting this error:
    >
    ><b>Fatal error</b>: Allowed memory size of 8388608 bytes exhausted
    >(tried to allocate 311020 bytes) in
    ><b>/home/www/krubner/atp/mcIncludes/mcDatabase.php</b> on line
    ><b>72</b><br />[/color]

    Thats the amount of bytes PHP has allocated. Most probably your
    recordset is a bit to big to put it into an array. The user might not
    want to see 100000 records anyway. Try LIMIT in the SQL statement
    [color=blue]
    >
    >This shows up at the bottom of the page, after everything else has
    >run, when the code attempts to update how many times the page has been
    >viewed. What could it mean? Does MySQL have some size limit?[/color]

    Nothing to do with MySQL directly.

    HTH, Jochen


    --
    Jochen Daum - CANS Ltd.
    PHP DB Edit Toolkit -- PHP scripts for building
    database editing interfaces.
    Download PHP DB Edit Toolkit for free. PHP DB Edit Toolkit is a set of PHP classes makes the generation of database edit interfaces easier and faster. The main class builds tabular and form views based on a data dictionary and takes over handling of insert/update/delete and user input.

    Comment

    • lawrence

      #3
      How to get around PHP's built-in size limits?

      lkrubner@geocit ies.com (lawrence) wrote in message news:<da7e68e8. 0309021243.42f4 2557@posting.go ogle.com>...[color=blue]
      > nc@iname.com (Nikolai Chuvakhin) wrote in message news:<32d7a63c. 0308312139.25a2 a204@posting.go ogle.com>...[color=green]
      > > lkrubner@geocit ies.com (lawrence) wrote in message
      > > news:<da7e68e8. 0308311528.1a40 7ccf@posting.go ogle.com>...[color=darkred]
      > > >
      > > > I'm playing around with the code that runs my site. Suddenly I started
      > > > getting this error:
      > > >
      > > > <b>Fatal error</b>: Allowed memory size of 8388608 bytes exhausted
      > > > (tried to allocate 311020 bytes) in
      > > > <b>/home/www/krubner/atp/mcIncludes/mcDatabase.php</b> on line
      > > > <b>72</b><br />[/color]
      > >
      > > This has nothing to do with MySQL per se. Note that 8388608 bytes
      > > is exactly eight megabytes. The default value for memory_limit
      > > directive is in fact "8M". So your script simply ran out of memory.
      > > Increase memory_limit or find a way to tame your script's apparent
      > > memory hunger...[/color]
      >
      > How does one test memory size in PHP? Am I looking for an array, or
      > series of arrays, that has more than 8 megs? That, I think, would make
      > sense: after the page has rendered, and printed to screen, the
      > software attempts to update the log info for that page, but that log
      > info might be huge, might easily be more than 10 megs. So my
      > hypothesis would be to go and look at that. But how does one test
      > memory size in PHP?[/color]

      Let's assume I'm stumbling on log info. How does one log info in PHP?
      Suppose I want to record the IP address of everyone visits my website.
      Suppose it is a popular site. After awhile, the log file, with
      everyone's IP address, is larger than 8 megs. How then, do I handle
      the file? How does anyone deal with files larger than 8 megs in PHP?

      Comment

      Working...