Upgraded from 24 -> 25.0.1 & given hefty warning message

I upgraded last night 2022-11-25 and a dialog box popped up after the seemingly successful web-based upgrade to 25.0.1, containing several warning messages.

I’ve just set up NC primarily for a group sharing spreadsheets and this appears to be unaffected, but long term, I’d rather avoid carrying any background problems.

Here’s all the info I could gather:

Nextcloud version: 25.0.1
Operating system and version: Debian 5.10.140-1
Apache or nginx version: ???
PHP version: 7.4.33

  1. From the dialog box:
Repair warning: Failed to delete folder: "12", error: An exception occurred while executing a query: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'carbonc_nc.oc_photos_albums' doesn't exist
Repair warning: Failed to delete folder: "images", error: An exception occurred while executing a query: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'carbonc_nc.oc_photos_albums' doesn't exist
The following apps have been disabled: accessibility (incompatible), external (incompatible), files_videoplayer (incompatible), onlyoffice (incompatible), spreed (incompatible)
  1. in my admin settings:
There are some warnings regarding your setup.

    The PHP OPcache module is not properly configured. See the documentation ↗ for more information.
        The OPcache interned strings buffer is nearly full. To assure that repeating strings can be effectively cached, it is recommended to apply opcache.interned_strings_buffer to your PHP configuration with a value higher than 64.
    The database is missing some indexes. Due to the fact that adding indexes on big tables could take some time they were not added automatically. By running "occ db:add-missing-indices" those missing indexes could be added manually while the instance keeps running. Once the indexes are added queries to those tables are usually much faster.
        Missing index "preferences_app_key" in table "oc_preferences".
        Missing index "mounts_class_index" in table "oc_mounts".
    Some columns in the database are missing a conversion to big int. Due to the fact that changing column types on big tables could take some time they were not changed automatically. By running "occ db:convert-filecache-bigint" those pending changes could be applied manually. This operation needs to be made while the instance is offline. For further details read the documentation page about this ↗.
        file_metadata.id
  • I could run my occ but it does not have executable permissions - am I meant to run it via another command or shall I just add the exec permission?

The output of your Nextcloud log in Admin > Logging:

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

carbonc@webarch7:~$ cat sites/cloud/config/config.php
<?php
$CONFIG = array (
  'passwordsalt' => '***',
  'secret' => '*****',
  'trusted_domains' => 
  array (
    0 => 'localhost',
    1 => '',
    2 => '',
    3 => '',
  ),
  'datadirectory' => '/home/carbonc/sites/cloud/data',
  'dbtype' => 'mysql',
  'version' => '25.0.1.1',
  'overwrite.cli.url' => '***',
  'dbname' => 'carbonc_nc',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => '****',
  'dbpassword' => '***',
  'installed' => true,
  'instanceid' => '***',
  'htaccess.RewriteBase' => '/',
  'mail_smtpmode' => 'smtp',
  'mail_smtphost' => 'localhost',
  'mail_smtpport' => '25',
  'mail_smtpsecure' => '',
  'mail_smtpauth' => 'False',
  'mail_smtpname' => '',
  'mail_smtppassword' => '',
  'mail_smtpauthtype' => '',
  'mail_from_address' => 'carbonc',
  'mail_domain' => '***',
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'default_phone_region' => 'GB',
  'allow_local_remote_servers' => true,
  'allow_user_to_change_display_name' => false,
  'maintenance' => false,
  'theme' => '',
  'loglevel' => 2,
  'memcache.distributed' => '',
  'memcache.locking' => '',
  'updater.secret' => '',
);
carbonc@webarch7:~$ 

The output of your Apache/nginx/system log in /var/log/____:

[Fri Nov 25 10:48:47.071000 2022] [autoindex:error] [pid 588932:tid 140616097457920] [client 43.130.111.242:63059] AH01276: Cannot serve directory /home/carbonc/sites/wordpress/wp-admin/css/: No matching DirectoryIndex (index.php,index.html,index.htm,index.shtml) found, and server-generated directory index forbidden by Options directive, referer: binance.com
[Fri Nov 25 16:55:22.628343 2022] [proxy_fcgi:error] [pid 588932:tid 140616332453632] [client 51.155.201.220:32946] AH01071: Got error 'PHP message: PHP Warning:  Invalid argument supplied for foreach() in /home/carbonc/sites/wordpress/wp-content/plugins/wp-piwik/classes/WP_Piwik.php on line 269', referer: https://ecocounts.community/wp-admin/plugins.php
[Fri Nov 25 16:55:27.340523 2022] [proxy_fcgi:error] [pid 588932:tid 140616332453632] [client 51.155.201.220:32946] AH01071: Got error 'PHP message: PHP Warning:  Invalid argument supplied for foreach() in /home/carbonc/sites/wordpress/wp-content/plugins/wp-piwik/classes/WP_Piwik.php on line 269', referer: https://ecocounts.community/wp-admin/plugin-install.php
[Fri Nov 25 18:00:28.583119 2022] [access_compat:error] [pid 762073:tid 140616214955776] [client 51.155.201.220:57256] AH01797: client denied by server configuration: /home/carbonc/sites/cloud/data/.ocdata
[Fri Nov 25 18:20:24.284545 2022] [access_compat:error] [pid 762073:tid 140616231741184] [client 51.155.201.220:43100] AH01797: client denied by server configuration: /home/carbonc/sites/cloud/data/.ocdata
carbonc@webarch7:~$ 

Output errors in nextcloud.log in /var/www/ or as admin user in top right menu, filtering for errors. Use a pastebin service if necessary.

I have no nextcloud.log on my shared server - all my logs are in /home/me/logs/ - maybe my hosting provider hasn’t configured the redirect for NC on installation?

You can just run it by putting a php in front, and perhaps use the permissions of the webserver user:


sudo -u www-data php occ .....

Looks like some app is missing tables. Not sure which photo/image/gallery app you are using. It can help to disable and to enable the app again. It updates if there is a new version and should install the required tables as well.

This one should be fixed with 25.0.2 IIRC