YunoHost-Apps / nextcloud_ynh

Nextcloud package for YunoHost
https://nextcloud.com/
GNU Affero General Public License v3.0
147 stars 63 forks source link

OCP\HintException: [0]: Memcache OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?) #665

Closed stepcellwolf closed 7 months ago

stepcellwolf commented 7 months ago

How to post a meaningful bug report

  1. Read this whole template first.
  2. Determine if you are on the right place:
    • If you were performing an action on the app from the webadmin or the CLI (install, update, backup, restore, change_url...), you are on the right place!
    • Otherwise, the issue may be due to the app itself. Refer to its documentation or repository for help.
    • When in doubt, post here and we will figure it out together.
  3. Delete the italic comments as you write over them below, and remove this guide.

Describe the bug

I'm unable to execute the sudo -u www-data php8.2 occ status I'm getting the following error message:

An unhandled exception has been thrown:
OCP\HintException: [0]: Memcache OC\Memcache\APCu not available for local cache (Is the matching PHP module installed and enabled?) 

Context

Steps to reproduce

Expected behavior

To get status report or to be able to perform different nextcloud tasks. APCu is enabled

Logs

Logs can be provided on request.

orhtej2 commented 7 months ago

Proper syntax to use is to add --define apc.enable_cli=1 to occ invocation, and use nextcloud user (not www-data), like so:

sudo -u nextcloud php8.2 --define apc.enable_cli=1 occ status