PHP Error Backup
-
Hello,
When i use the Backup Files and Directories i got a Crash message :
Crash report begins. Anonymous machine information:amd64
12.3-STABLE
FreeBSD 12.3-STABLE RELENG_2_6_0-n226742-1285d6d205f pfSenseCrash report details:
PHP Errors:
[15-Apr-2022 11:11:30 Europe/Amsterdam] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 928636928 bytes) in /usr/local/www/packages/backup/backup.php on line 77No FreeBSD crash data found.
And the PHP error-log shows :
[15-Apr-2022 11:11:30 Europe/Amsterdam] PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 928636928 bytes) in /usr/local/www/packages/backup/backup.php on line 77
Is this a bug??
Henk
-
@henkbart said in PHP Error Backup:
Is this a bug??
Now read this :
@henkbart said in PHP Error Backup:
Allowed memory size of 536870912 bytes exhausted
PHP needed an extra 536870912 bytes or 536870 Kbytes or 536 Mbytes
But it wasn't available.A work around : make your individual backups smaller.
Or use the SSH/SFTP access to backup your entire / without size limitations.
Or, if the memory is available, modify the php.ini file so PHP has the extra memory.
It must be one of these :upload_max_filesize = 200M post_max_size = 200M
You'll find the file in /usr/local/etc/
Do not edit this file direcly, as pfSense uses a GUI, so it re creates the config files all the time.
You should edit the script that creates this file. Probably here /etc/rc.php_ini_setupBe carefull. I've not tested what I've said here.
I'm not aware of nasty side effects, and this doesn't mean there are none. -
512MiB (536870912B) is the total allowed size PHP can use. It exhausted that when it tried to allocate an extra 928636928 bytes (885MiB).
So something is doing something it should not there because that can never succeed. The Backup package trying to backup something far too large I would suggest.Steve