PfBlockerNG Alerts - Allowed memory size of 268435456 bytes exhausted



  • Hey everyone!
    I'm new to PFSENSE but have been playing around with it for about a week now, I'm loving it!

    I'm running running pfsense version: 2.3.1-RELEASE-p1 (amd64)

    I'm running into an issue when trying to view the pfBlockerNG alerts, I get the following error:

    Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 32 bytes) in /etc/inc/util.inc on line 899 Call Stack: 0.0001 228280 1. {main}() /usr/local/www/pfblockerng/pfblockerng_alerts.php:0 0.1212 1610840 2. subnetv4_expand() /usr/local/www/pfblockerng/pfblockerng_alerts.php:383 PHP ERROR: Type: 1, File: /etc/inc/util.inc, Line: 899, Message: Allowed memory size of 268435456 bytes exhausted (tried to allocate 32 bytes)

    I have updated the RC_php_init file to include; memory_limit = 512M but that didn't correct the issue.

    I'm wondering if anyone else has run into this issue or has any ideas what I might be able to do to correct this?

    Thanks guys!


  • Moderator

    Thanks for the feedback!

    Try to lower the "Gui Log Entries" setting in:  Status / System Logs / Settings



  • Thanks BBcan177!

    After reinstalling pfBlockerNG everything seems to load fine now under alerts.



  • I am also having trouble with pfBlockerNG Alerts.  I get:
    PHP ERROR: Type: 1, File: /usr/local/pkg/pfblockerng/pfblockerng.inc, Line: 3630, Message: Allowed memory size of 134217728 bytes exhausted

    I see this error trying to go to the pfBlockerNG Alerts page, or if I click the link on the Dashboard pfBlockerNG hyperlink for packets, at the moment the 1031286 number like this:
    pfB_FireholLevel3 24867 1031286 Mar 27 01:27

    I was having some issues with Suricata php as well, so I changed my config.inc to allow 1024M instead of 512M and rebooted, like this:
    // Set memory limit to 512M on amd64.
    if ($ARCH == "amd64") {
      ini_set("memory_limit", "1024M");
    } else {
      ini_set("memory_limit", "128M");
    }
    (see this thread:  https://forum.pfsense.org/index.php?topic=139744.0  )

    That has seemed to eliminate the php issues with Suricata, but not with the pfBlockerNG Alerts.  I also tried lowering the "Gui Log Entries" setting in:  Status / System Logs / Settings to 200, but that did not help either.  So what I'd like to know is where is the "Allowed memory size of 134217728 bytes" or 128 Meg coming from?  I can't find that number in the config files anywhere, save maybe the config.inc limit for 32 bit systems.  I have confirmed my system is being detected as 64 bit/amd64.

    My specs:
    HP G6
    dual Intel Xeon X5650
    48 Gig RAM
    pfSense 2.4.2p1
    mailreport 3.1
    pfBlockerNG 2.1.2_2
    suricata 4.0.4

    Thanks!



  • Well it shouldn't break anything to change 128M to 1024M or bigger.  ;)
    Remember that /etc/inc/config.inc is overwritten when you update pfsense version.



  • O.K. I tried setting both memory limits to 1024M and rebooting.  Unfortunately I still get the same PHP error Allowed memory size of 134217728 bytes exhausted on the pfBlockerNG Alerts page.  Since PHP is obviously configured for more "Allowed" memory than this, does anyone know where this limit is coming from?
    Thanks!