Operations in Plesk fail: Allowed memory size of X bytes exhausted (tried to allocate Y bytes)

Follow

Comments

6 comments

  • Avatar
    Gianluca

    I had this issue trying to delete a subscription, i followed this guide but it seems the restart of the Plesk management service does not "read" the new php.ini, in fact after the modification i tried again to delete the subscritpion but the error was the same.

    Then i tried to restart Plesk services by "Plesk service monitor": i restarted the entire "Plesk run-time" and "Mail service" then tried to delete the subscription again, no luck.

    Finally i restarted the server and finally i was able to delete the subscription.

    0
    Comment actions Permalink
  • Avatar
    Ivan Postnikov

    @Gianluca, which limit have you specified when applying the solution?

    There is a possibility that specified limit was not enough.

    0
    Comment actions Permalink
  • Avatar
    Gianluca

    I have increased the limit from 256M to 512M.

    0
    Comment actions Permalink
  • Avatar
    Ivan Postnikov

    @Gianluca, thank you for the provided info.

    If the issue will reoccur, increase the limit further. In case it would not help, consider submitting a ticket to Plesk Technical Support.

    0
    Comment actions Permalink
  • Avatar
    Oleg Burca

    Changes are lost after Plesk upgrade is performed (/usr/local/psa/admin/conf/php.ini is reset to default).

    Please provide a persistent solution.

    0
    Comment actions Permalink
  • Avatar
    Ivan Postnikov

    Hello Oleg Burca

    To prevent the changes from being reverted during Plesk update, replace the following line in /etc/cron.daily/50plesk-daily:

    • For Debian/Ubuntu:

      /usr/local/psa/bin/sw-engine-pleskrun /opt/psa/admin/plib/DailyMaintainance/script.php >/dev/null 2>&1

      With:

      /usr/local/psa/bin/sw-engine-pleskrun /opt/psa/admin/plib/DailyMaintainance/script.php >/dev/null 2>&1 && sed -i '/memory_limit/c\memory_limit = 512M' /usr/local/psa/admin/conf/php.ini

    • For CentOS:

      /usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php >/dev/null 2>&1

      With:

      /usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php >/dev/null 2>&1 && sed -i '/memory_limit/c\memory_limit = 512M' /usr/local/psa/admin/conf/php.ini

    1
    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request