server
server copied to clipboard
[BUG]: PHP Fatal error: Allowed memory size of 268435456 bytes exhausted
Version Information
0.14.2 commit f4fc2b1
Hashcat
No response
Description
Upgraded from 0.12 to the latest master (build docker from sources) When navigating to Tasks, page spins for ~5 seconds and then gives blank screen. Logs contain this:
hashtopolis-backend | [Sun Mar 24 16:37:53.919486 2024] [php:error] [pid 53] [client 192.168.0.72:43800]
PHP Fatal error: Allowed memory size of 268435456 bytes exhausted
(tried to allocate 20480 bytes) in /var/www/html/src/dba/Util.class.php on line 24
Adding ini_set("memory_limit", "2G"); to the Util.class.php file resolves the issue.
Would be great to have max memory value configurable through docker env
Workaround: you can add a custom php.ini to the docker volume and mount that over /usr/local/etc/php/conf.d/custom.ini
services:
hashtopolis-backend:
container_name: hashtopolis-backend
image: hashtopolis/backend:latest
restart: always
volumes:
- hashtopolis:/usr/local/share/hashtopolis:Z
- somelocalpath/myphp.ini:/usr/local/etc/php/conf.d/custom.ini:Z
But I understand that having some customization over some critical settings is prefered.