iamklaus / nextcloud

Nextcloud docker file including cron via supervisor and all dependencies to install the face recognition app.
17 stars 9 forks source link

command line allowed memory exhausted #8

Closed KoMa1012 closed 2 years ago

KoMa1012 commented 2 years ago

I'm running your container on unraid, I've set the environmental variable "PHP_MEMORY_LIMIT" to 4G and outputting phpinfo() shows this as well. However, when I run "sudo -u www-data php occ face:setup -m" (within the container) I'm getting the message: "Fatal error: Allowed memory size of 2097152 bytes exhausted (tried to allocate 446464 bytes) in /var/www/html/3rdparty/composer/autoload_real.php on line 37"

When I run "php --ini" in command line (within the container) I get the following output: Configuration File (php.ini) Path: /usr/local/etc/php Loaded Configuration File: (none) Scan for additional .ini files in: /usr/local/etc/php/conf.d Additional .ini files parsed: /usr/local/etc/php/conf.d/docker-php-ext-apcu.ini, /usr/local/etc/php/conf.d/docker-php-ext-bcmath.ini, /usr/local/etc/php/conf.d/docker-php-ext-bz2.ini, .... (more files following)

So, I'm not sure if this means something, but the line I marked bold seems weird to me. On the other hand, the Memory limit seems to be used (at least for the UI), but the message with the occ command is still there. I find it irritating, that the allowed memory size is multiple times bigger than it tries to allocate.

With this, I think it is not possible to set up the face recognition app.

guystreeter commented 2 years ago

This problem is reported by a number of users, for other apps besides facrecognition. A suggested solution is to ensure apc.enable_cli is on. See for instance https://github.com/nextcloud/docker/issues/1413

KoMa1012 commented 2 years ago

apc.enable_cli=1 is in /usr/local/etc/php/conf.d/docker-php-ext-apcu.ini can I check if this config is being used?

guystreeter commented 2 years ago

I believe php -i will tell you.

In ant case it isn't a problem specific to facerecognition ot this docker image, so the nextcloud community forum or their github issue tracker is the place to look for help.

KoMa1012 commented 2 years ago

I'm not sure about this statement, I just tried a different container and it is running perfectly smooth, except I can not install pdlib, since the other container is running on a not supported distro for this.

guystreeter commented 2 years ago

I'm using this container and I don't see that error.

KoMa1012 commented 2 years ago

Agreed, what I meant so say is, nextcloud is part of this container, so why would it behave differently for me than for you. The only thing I can see is, that the host somehow has an influence, which would make it more related to the container than nextcloud. But I will post this with nextcloud as well, they might be able to provide me debugging insight. Just to clarify it, I'm using this container "vanilla", so there are not even users there at the moment.

iamklaus commented 2 years ago

Issue is not related to this image.