Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Fatal error: Allowed memory size of xx bytes exhausted
  • I have app built with FuelPHP and it works fine until now when I log in (Simpleauth) it shows an error

    "Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 35 bytes) in /var/fuel/core/classes/database/pdo/connection.php on line 311 "

    but I still can access the app  (after login and the app shows an error) by accessing directly tru URL (for example www.apps.com/admin/kwitansi )

    I try to restart the apache, mysql server and even the server itself but it still shows an error.

    can anyone help me o fix this ?

    thanks before :)


  • HarroHarro
    Accepted Answer
    Assuming you are still on 1.7.x, that line is:

    $result = $result->fetchAll(\PDO::FETCH_ASSOC);

    which means your query simply fetches more data than you have memory available.

    So use the backtrace that is provided on the error page to find out which statement generates this query, and rewrite your code.
  • ahh.., 
    found it

    never thought that my database have 12 thousand added field in one hour. 
    I guest some suspicious activities happen .

    gotta find out.., 

    thanks for your help @Harro

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion