# PHP memory problem when updating

**URL:** <https://help.nextcloud.com/t/php-memory-problem-when-updating/220599>\
**Category:** ℹ️ Support\
**Tags:** update\_problems, plesk, nc29, php\
**Created:** [March 20, 2025, 12:27am UTC](https://help.nextcloud.com/t/php-memory-problem-when-updating/220599 "2025-03-20T00:27:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![LaurentR2D2](https://help.nextcloud.com/letter_avatar/laurentr2d2/32/5_5575768a8748004e209b776fc1b2916d.png) [@LaurentR2D2](https://help.nextcloud.com/u/LaurentR2D2)\
**Post date:** [March 20, 2025, 12:27am UTC](https://help.nextcloud.com/t/php-memory-problem-when-updating/220599/1 "2025-03-20T00:27:43Z")

</div>

## The Basics

- Nextcloud Server version _(e.g., 29.x.x)_:
  - Nextcloud Hub 8 (29.0.4)

- Operating system and version _(e.g., Ubuntu 24.04)_:
  - Debian 12.10

- Web server and version _(e.g, Apache 2.4.25)_:
  - httpd 2.4.62-1~deb12u2

- Reverse proxy and version \_(e.g. nginx 1.27.2)
  - nginx 1.26.2-v.debian.12+p18.0.67.3+t250217.0844

- PHP version _(e.g, 8.3)_:
  - 8.3.19-debian.12.250314.0835

- Is this the first time you’ve seen this error? (Yes / No):
  - yes

- Are you using CloudfIare, mod\_security, or similar? _(Yes / No)_
  - no

### Summary of the issue you are facing:

When I launch :

sudo -u laurent /opt/plesk/php/8.3/bin/php --define apc.enable\_cli=1 /var/www/vhosts/madonie.org/subdomains/nuage/updater/updater.phar

I get this error message

Verify integrity …PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 250207432 bytes) in phar:///var/www/vhosts/madonie.org/subdomains/nuage/updater/updater.phar/lib/Updater.php on line 674

### Log entries

#### Nextcloud

Please provide the log entries from your Nextcloud log that are generated during the time of problem (via the _Copy raw_ option from _Administration settings-\>Logging_ screen or from your `nextcloud.log` located in your data directory). Feel free to use a pastebin/gist service if necessary.

```auto
{"reqId":"IlbEfI84YAlUo8mQpTtC","level":3,"time":"2023-09-26T11:45:01+00:00","remoteAddr":"","user":"--","app":"cron","method":"","url":"--","message":"Not installed","userAgent":"--","version":"","exception":{"Exception":"Exception","Message":"Not installed","Code":0,"Trace":[{"file":"/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php","line":709,"function":"checkInstalled","class":"OC","type":"::"},{"file":"/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php","line":1196,"function":"init","class":"OC","type":"::"},{"file":"/var/www/vhosts/madonie.org/subdomains/nuage/cron.php","line":43,"args":["/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php"],"function":"require_once"}],"File":"/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php","Line":283,"CustomMessage":"--"}}
{"reqId":"7kWlOuEerdghOmb0xSJj","level":3,"time":"2023-09-26T12:00:01+00:00","remoteAddr":"","user":"--","app":"cron","method":"","url":"--","message":"Not installed","userAgent":"--","version":"","exception":{"Exception":"Exception","Message":"Not installed","Code":0,"Trace":[{"file":"/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php","line":709,"function":"checkInstalled","class":"OC","type":"::"},{"file":"/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php","line":1196,"function":"init","class":"OC","type":"::"},{"file":"/var/www/vhosts/madonie.org/subdomains/nuage/cron.php","line":43,"args":["/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php"],"function":"require_once"}],"File":"/var/www/vhosts/madonie.org/subdomains/nuage/lib/base.php","Line":283,"CustomMessage":"--"}}

```

### Configuration

#### Nextcloud

The output of `occ config:list system` or similar is best, but, if not possible, the contents of your `config.php` file from `/path/to/nextcloud` is fine (make sure to remove any identifiable information!):

```auto
The current PHP memory limit is below the recommended value of 512MB.
{
    "system": {
        "passwordsalt": " ***REMOVED SENSITIVE VALUE***",
        "secret": " ***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "localhost",
            "nuage.madonie.org"
        ],
        "datadirectory": " ***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "29.0.4.1",
        "overwrite.cli.url": "http:\/\/localhost",
        "dbname": " ***REMOVED SENSITIVE VALUE***",
        "dbhost": " ***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "dbuser": " ***REMOVED SENSITIVE VALUE***",
        "dbpassword": " ***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "instanceid": " ***REMOVED SENSITIVE VALUE***",
        "default_phone_region": "FR",
        "maintenance": false,
        "theme": "",
        "loglevel": 0,
        "app_install_overwrite": [
            "occweb"
        ],
        "mail_smtpmode": "smtp",
        "mail_sendmailmode": "smtp",
        "mail_from_address": " ***REMOVED SENSITIVE VALUE***",
        "mail_domain": " ***REMOVED SENSITIVE VALUE***",
        "mail_smtpauthtype": "LOGIN",
        "mail_smtpauth": 1,
        "mail_smtphost": " ***REMOVED SENSITIVE VALUE***",
        "mail_smtpname": " ***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": " ***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "993",
        "mail_smtpsecure": "ssl"
    }
}

```

PHP :  
Version : 8.3.19  
Limite de mémoire : 512 MB  
Temps d’exécution maximal : 3600  
Taille de téléversement maximale : 500 MB  
Fréquence de revalidation de l’OPcache : 2  
Extensions : Core, date, libxml, openssl, pcre, zlib, bz2, calendar, ctype, hash, filter, ftp, gettext, gmp, json, iconv, SPL, random, Reflection, session, standard, mbstring, SimpleXML, sockets, tokenizer, xml, cgi-fcgi, mysqlnd, bcmath, curl, dba, dom, enchant, fileinfo, gd, imagick, imap, intl, ldap, exif, mysqli, odbc, PDO, pdo\_mysql, PDO\_ODBC, pdo\_pgsql, pdo\_sqlite, pgsql, Phar, posix, pspell, redis, soap, sodium, sqlite3, sysvmsg, sysvsem, sysvshm, tidy, xmlreader, xmlwriter, xsl, zip, Zend OPcache

More details here :

[https://nuage.madonie.org/info.php](https://nuage.madonie.org/info.php)

#### Apps

Enabled:

- activity: 2.21.1
- circles: 29.0.0-dev
- cloud\_federation\_api: 1.12.0
- comments: 1.19.0
- contactsinteraction: 1.10.0
- dashboard: 7.9.0
- dav: 1.30.1
- federatedfilesharing: 1.19.0
- federation: 1.19.0
- files: 2.1.0
- files\_downloadlimit: 2.0.0
- files\_pdfviewer: 2.10.0
- files\_reminders: 1.2.0
- files\_sharing: 1.21.0
- files\_trashbin: 1.19.0
- files\_versions: 1.22.0
- firstrunwizard: 2.18.0
- forms: 4.2.4
- logreader: 2.14.0
- lookup\_server\_connector: 1.17.0
- nextcloud\_announcements: 1.18.0
- notifications: 2.17.0
- oauth2: 1.17.0
- password\_policy: 1.19.0
- photos: 2.5.0
- privacy: 1.13.0
- provisioning\_api: 1.19.0
- recommendations: 2.1.0
- related\_resources: 1.4.0
- serverinfo: 1.19.0
- settings: 1.12.0
- sharebymail: 1.19.0
- support: 1.12.0
- survey\_client: 1.17.0
- systemtags: 1.19.0
- tasks: 0.16.0
- text: 3.10.1
- theming: 2.4.0
- twofactor\_backupcodes: 1.18.0
- updatenotification: 1.19.1
- user\_status: 1.9.0
- viewer: 2.3.0
- weather\_status: 1.9.0
- workflowengine: 2.11.0  
Disabled:
- admin\_audit: 1.19.0
- bruteforcesettings: 2.9.0
- deck: 1.13.1 (installed 1.13.1)
- encryption: 2.17.0
- files\_accesscontrol: 1.19.1 (installed 1.19.1)
- files\_external: 1.21.0
- files\_rightclick: 0.15.1 (installed 1.6.0)
- groupfolders: 17.0.1 (installed 17.0.1)
- occweb: 0.2.0 (installed 0.2.0)
- suspicious\_login: 7.0.0
- twofactor\_totp: 11.0.0-dev
- user\_ldap: 1.20.0

---

<div class="post-metadata">

**Author:** ![tflidd](https://help.nextcloud.com/letter_avatar/tflidd/32/5_5575768a8748004e209b776fc1b2916d.png) [@tflidd](https://help.nextcloud.com/u/tflidd)\
**Post date:** [March 22, 2025, 10:46am UTC](https://help.nextcloud.com/t/php-memory-problem-when-updating/220599/2 "2025-03-22T10:46:03Z")

</div>

For the command line version, you normally have a different php.ini which in your case is set to a much lower value (128 MiB).

`sudo -u laurent /opt/plesk/php/8.3/bin/php --ini`

---

<div class="post-metadata">

**Author:** ![LaurentR2D2](https://help.nextcloud.com/letter_avatar/laurentr2d2/32/5_5575768a8748004e209b776fc1b2916d.png) [@LaurentR2D2](https://help.nextcloud.com/u/LaurentR2D2)\
**Post date:** [March 22, 2025, 2:50pm UTC](https://help.nextcloud.com/t/php-memory-problem-when-updating/220599/3 "2025-03-22T14:50:22Z")

</div>

I’ve changed the memory\_limit in /opt/plesk/php/8.3/etc/php.ini from 128M to 512M, and upgrade has worked. In fact I’ve made a first update of version 29, then an upgrade to version 30, and now I’m told I have version 31 available. Thank you for your help.

---

<div class="post-metadata">

**Author:** ![system](https://help.nextcloud.com/user_avatar/help.nextcloud.com/system/32/29333_2.png) [@system](https://help.nextcloud.com/u/system)\
**Post date:** [March 30, 2025, 2:51pm UTC](https://help.nextcloud.com/t/php-memory-problem-when-updating/220599/4 "2025-03-30T14:51:02Z")

</div>

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.
