Memory allocation error 1038 during connection to mysql

Nextcloud version (eg, 20.0.5): 22.0.0.11
Operating system and version (eg, Ubuntu 20.04): unknown (Strato)
Apache or nginx version (eg, Apache 2.4.25): unknown (Strato)
PHP version (eg, 7.4): 7.4

The issue you are facing:

i am running a nextclound instance for my family an me. Version 16 was the last update :slight_smile:
within this config it was running realy fine. So i decided today to install l the new version 22 (no upgrade, a clean installation). After a fine and errorless installing the system onto a Strato Webspace (no own server) i got an error-Page

Der Server konnte die Anfrage nicht fertig stellen.

Sollte dies erneut auftreten, senden Sie bitte die nachfolgenden technischen Einzelheiten an Ihren Server-Administrator.

Weitere Details können im Server-Protokoll gefunden werden.

Technische Details
Entfernte Adresse: 2a02:6d40:3bb4:8701:d941:375a:f156:3b99
YOsWUlA4TK1M0Su66G9gzwAAA2Y

the database tabeles where created. into the logfile o mentioned the following error:

Memory allocation error: 1038 Out of sort memory, consider increasing server sort buffer size

into my strato environment i have ne access to setup any mysql parameters. is there a other way to running this software?

Is this the first time you’ve seen this error? (Y/N): Yes (with Version 22)

Steps to replicate it:

  1. Installing it on any way
  2. Go to start page and try your first login

The output of your Nextcloud log in Admin > Logging:

{"reqId":"YOsQrS1t7YTrswsQI6kK2QAAAV0","level":3,"time":"July 11, 2021 15:39:26","remoteAddr":"2a02:6d40:3bb4:8701:d941:375a:f156:3b99","user":"admin","app":"index","method":"GET","url":"/index.php/apps/theming/favicon?v=0","message":"An exception occurred while executing a query: SQLSTATE[HY001]: Memory allocation error: 1038 Out of sort memory, consider increasing server sort buffer size","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.114 Safari/537.36 OPR/77.0.4054.172","version":"22.0.0.11","exception":{"Exception":"Doctrine\\DBAL\\Exception\\DriverException","Message":"An exception occurred while executing a query: SQLSTATE[HY001]: Memory allocation error: 1038 Out of sort memory, consider increasing server sort buffer size","Code":1038,"Trace":[{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Connection.php","line":1728,"function":"convert","class":"Doctrine\\DBAL\\Driver\\API\\MySQL\\ExceptionConverter","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Connection.php","line":1667,"function":"handleDriverException","class":"Doctrine\\DBAL\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Connection.php","line":1040,"function":"convertExceptionDuringQuery","class":"Doctrine\\DBAL\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/DB/Connection.php","line":231,"function":"executeQuery","class":"Doctrine\\DBAL\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Query/QueryBuilder.php","line":210,"function":"executeQuery","class":"OC\\DB\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/DB/QueryBuilder/QueryBuilder.php","line":287,"function":"execute","class":"Doctrine\\DBAL\\Query\\QueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc22/NC22ExtendedQueryBuilder.php","line":1340,"function":"execute","class":"OC\\DB\\QueryBuilder\\QueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc22/NC22ExtendedQueryBuilder.php","line":1276,"function":"getRows","class":"ArtificialOwl\\MySmallPhpTools\\Db\\Nextcloud\\nc22\\NC22ExtendedQueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Db/ShareWrapperRequestBuilder.php","line":125,"function":"asItems","class":"ArtificialOwl\\MySmallPhpTools\\Db\\Nextcloud\\nc22\\NC22ExtendedQueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Db/ShareWrapperRequest.php","line":334,"function":"getItemsFromRequest","class":"OCA\\Circles\\Db\\ShareWrapperRequestBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Service/ShareWrapperService.php","line":187,"function":"getSharedWith","class":"OCA\\Circles\\Db\\ShareWrapperRequest","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/ShareByCircleProvider.php","line":557,"function":"getSharedWith","class":"OCA\\Circles\\Service\\ShareWrapperService","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Share20/Manager.php","line":1360,"function":"getSharedWith","class":"OCA\\Circles\\ShareByCircleProvider","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/files_sharing/lib/MountProvider.php","line":79,"function":"getSharedWith","class":"OC\\Share20\\Manager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Config/MountProviderCollection.php","line":118,"function":"getMountsForUser","class":"OCA\\Files_Sharing\\MountProvider","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Filesystem.php","line":429,"function":"addMountForUser","class":"OC\\Files\\Config\\MountProviderCollection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Filesystem.php","line":354,"function":"initMountPoints","class":"OC\\Files\\Filesystem","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/legacy/OC_Util.php","line":325,"function":"init","class":"OC\\Files\\Filesystem","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Mount/Manager.php","line":91,"function":"setupFS","class":"OC_Util","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/View.php","line":1385,"function":"find","class":"OC\\Files\\Mount\\Manager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/Root.php","line":200,"function":"getFileInfo","class":"OC\\Files\\View","type":"->"},{"function":"get","class":"OC\\Files\\Node\\Root","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/LazyFolder.php","line":65,"function":"call_user_func_array"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/LazyFolder.php","line":142,"function":"__call","class":"OC\\Files\\Node\\LazyFolder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/AppData/AppData.php","line":141,"function":"get","class":"OC\\Files\\Node\\LazyFolder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/theming/lib/ImageManager.php","line":110,"function":"getFolder","class":"OC\\Files\\AppData\\AppData","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/theming/lib/Controller/IconController.php","line":121,"function":"getImage","class":"OCA\\Theming\\ImageManager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/Http/Dispatcher.php","line":217,"function":"getFavicon","class":"OCA\\Theming\\Controller\\IconController","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/Http/Dispatcher.php","line":126,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/App.php","line":156,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Route/Router.php","line":301,"function":"main","class":"OC\\AppFramework\\App","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/base.php","line":1000,"function":"match","class":"OC\\Route\\Router","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/index.php","line":36,"function":"handleRequest","class":"OC","type":"::"}],"File":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Driver/API/MySQL/ExceptionConverter.php","Line":114,"Previous":{"Exception":"Doctrine\\DBAL\\Driver\\PDO\\Exception","Message":"SQLSTATE[HY001]: Memory allocation error: 1038 Out of sort memory, consider increasing server sort buffer size","Code":1038,"Trace":[{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Driver/PDO/Statement.php","line":84,"function":"new","class":"Doctrine\\DBAL\\Driver\\PDO\\Exception","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Connection.php","line":1030,"function":"execute","class":"Doctrine\\DBAL\\Driver\\PDO\\Statement","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/DB/Connection.php","line":231,"function":"executeQuery","class":"Doctrine\\DBAL\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Query/QueryBuilder.php","line":210,"function":"executeQuery","class":"OC\\DB\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/DB/QueryBuilder/QueryBuilder.php","line":287,"function":"execute","class":"Doctrine\\DBAL\\Query\\QueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc22/NC22ExtendedQueryBuilder.php","line":1340,"function":"execute","class":"OC\\DB\\QueryBuilder\\QueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc22/NC22ExtendedQueryBuilder.php","line":1276,"function":"getRows","class":"ArtificialOwl\\MySmallPhpTools\\Db\\Nextcloud\\nc22\\NC22ExtendedQueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Db/ShareWrapperRequestBuilder.php","line":125,"function":"asItems","class":"ArtificialOwl\\MySmallPhpTools\\Db\\Nextcloud\\nc22\\NC22ExtendedQueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Db/ShareWrapperRequest.php","line":334,"function":"getItemsFromRequest","class":"OCA\\Circles\\Db\\ShareWrapperRequestBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Service/ShareWrapperService.php","line":187,"function":"getSharedWith","class":"OCA\\Circles\\Db\\ShareWrapperRequest","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/ShareByCircleProvider.php","line":557,"function":"getSharedWith","class":"OCA\\Circles\\Service\\ShareWrapperService","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Share20/Manager.php","line":1360,"function":"getSharedWith","class":"OCA\\Circles\\ShareByCircleProvider","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/files_sharing/lib/MountProvider.php","line":79,"function":"getSharedWith","class":"OC\\Share20\\Manager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Config/MountProviderCollection.php","line":118,"function":"getMountsForUser","class":"OCA\\Files_Sharing\\MountProvider","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Filesystem.php","line":429,"function":"addMountForUser","class":"OC\\Files\\Config\\MountProviderCollection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Filesystem.php","line":354,"function":"initMountPoints","class":"OC\\Files\\Filesystem","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/legacy/OC_Util.php","line":325,"function":"init","class":"OC\\Files\\Filesystem","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Mount/Manager.php","line":91,"function":"setupFS","class":"OC_Util","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/View.php","line":1385,"function":"find","class":"OC\\Files\\Mount\\Manager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/Root.php","line":200,"function":"getFileInfo","class":"OC\\Files\\View","type":"->"},{"function":"get","class":"OC\\Files\\Node\\Root","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/LazyFolder.php","line":65,"function":"call_user_func_array"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/LazyFolder.php","line":142,"function":"__call","class":"OC\\Files\\Node\\LazyFolder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/AppData/AppData.php","line":141,"function":"get","class":"OC\\Files\\Node\\LazyFolder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/theming/lib/ImageManager.php","line":110,"function":"getFolder","class":"OC\\Files\\AppData\\AppData","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/theming/lib/Controller/IconController.php","line":121,"function":"getImage","class":"OCA\\Theming\\ImageManager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/Http/Dispatcher.php","line":217,"function":"getFavicon","class":"OCA\\Theming\\Controller\\IconController","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/Http/Dispatcher.php","line":126,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/App.php","line":156,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Route/Router.php","line":301,"function":"main","class":"OC\\AppFramework\\App","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/base.php","line":1000,"function":"match","class":"OC\\Route\\Router","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/index.php","line":36,"function":"handleRequest","class":"OC","type":"::"}],"File":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Driver/PDO/Exception.php","Line":26,"Previous":{"Exception":"PDOException","Message":"SQLSTATE[HY001]: Memory allocation error: 1038 Out of sort memory, consider increasing server sort buffer size","Code":"HY001","Trace":[{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Driver/PDO/Statement.php","line":82,"function":"execute","class":"PDOStatement","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Connection.php","line":1030,"function":"execute","class":"Doctrine\\DBAL\\Driver\\PDO\\Statement","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/DB/Connection.php","line":231,"function":"executeQuery","class":"Doctrine\\DBAL\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Query/QueryBuilder.php","line":210,"function":"executeQuery","class":"OC\\DB\\Connection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/DB/QueryBuilder/QueryBuilder.php","line":287,"function":"execute","class":"Doctrine\\DBAL\\Query\\QueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc22/NC22ExtendedQueryBuilder.php","line":1340,"function":"execute","class":"OC\\DB\\QueryBuilder\\QueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc22/NC22ExtendedQueryBuilder.php","line":1276,"function":"getRows","class":"ArtificialOwl\\MySmallPhpTools\\Db\\Nextcloud\\nc22\\NC22ExtendedQueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Db/ShareWrapperRequestBuilder.php","line":125,"function":"asItems","class":"ArtificialOwl\\MySmallPhpTools\\Db\\Nextcloud\\nc22\\NC22ExtendedQueryBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Db/ShareWrapperRequest.php","line":334,"function":"getItemsFromRequest","class":"OCA\\Circles\\Db\\ShareWrapperRequestBuilder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/Service/ShareWrapperService.php","line":187,"function":"getSharedWith","class":"OCA\\Circles\\Db\\ShareWrapperRequest","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/circles/lib/ShareByCircleProvider.php","line":557,"function":"getSharedWith","class":"OCA\\Circles\\Service\\ShareWrapperService","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Share20/Manager.php","line":1360,"function":"getSharedWith","class":"OCA\\Circles\\ShareByCircleProvider","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/files_sharing/lib/MountProvider.php","line":79,"function":"getSharedWith","class":"OC\\Share20\\Manager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Config/MountProviderCollection.php","line":118,"function":"getMountsForUser","class":"OCA\\Files_Sharing\\MountProvider","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Filesystem.php","line":429,"function":"addMountForUser","class":"OC\\Files\\Config\\MountProviderCollection","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Filesystem.php","line":354,"function":"initMountPoints","class":"OC\\Files\\Filesystem","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/legacy/OC_Util.php","line":325,"function":"init","class":"OC\\Files\\Filesystem","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Mount/Manager.php","line":91,"function":"setupFS","class":"OC_Util","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/View.php","line":1385,"function":"find","class":"OC\\Files\\Mount\\Manager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/Root.php","line":200,"function":"getFileInfo","class":"OC\\Files\\View","type":"->"},{"function":"get","class":"OC\\Files\\Node\\Root","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/LazyFolder.php","line":65,"function":"call_user_func_array"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/Node/LazyFolder.php","line":142,"function":"__call","class":"OC\\Files\\Node\\LazyFolder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Files/AppData/AppData.php","line":141,"function":"get","class":"OC\\Files\\Node\\LazyFolder","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/theming/lib/ImageManager.php","line":110,"function":"getFolder","class":"OC\\Files\\AppData\\AppData","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/apps/theming/lib/Controller/IconController.php","line":121,"function":"getImage","class":"OCA\\Theming\\ImageManager","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/Http/Dispatcher.php","line":217,"function":"getFavicon","class":"OCA\\Theming\\Controller\\IconController","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/Http/Dispatcher.php","line":126,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/AppFramework/App.php","line":156,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/private/Route/Router.php","line":301,"function":"main","class":"OC\\AppFramework\\App","type":"::"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/lib/base.php","line":1000,"function":"match","class":"OC\\Route\\Router","type":"->"},{"file":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/index.php","line":36,"function":"handleRequest","class":"OC","type":"::"}],"File":"/mnt/web310/d2/03/58709503/htdocs/cloud03/www/3rdparty/doctrine/dbal/src/Driver/PDO/Statement.php","Line":82}},"CustomMessage":"--"}}

The output of your config.php file in /mnt/web310/d2/03/58709503/htdocs/cloud03/www/ (make sure you remove any identifiable information!):

  'datadirectory' => '/mnt/web310/d2/03/58709503/htdocs/cloud03/data',
  'dbtype' => 'mysql',
  'version' => '22.0.0.11',
  'overwrite.cli.url' => '****',
  'dbname' => '****',
  'dbhost' => 'rdbms.strato.de',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => '****',
  'dbpassword' => '***',
  'installed' => true,
  'log_type' => 'file',
  'logfile' => '/mnt/web310/d2/03/58709503/htdocs/cloud03/log/nextcloud.log',
  'loglevel' => 3,
  'logdateformat' => 'F d, Y H:i:s',

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

PASTE HERE
1 Like

I have the same issue! Did you get it figured out?

Thanks

1 Like

I found when i run this:

You can do it by running the given query

SET GLOBAL sort_buffer_size = 256000000

Then it works until reboot.

So i went to /etc/mysql/mysql.conf.d/ and modified mysql.cnf and added this string.

sort_buffer_size = 256M

Under the fine tuning area. now looks like this:

* Basic Settings

user = mysql
pid-file = /var/run/mysqld/mysqld.pid
socket = /var/run/mysqld/mysqld.sock
port = 3306
basedir = /usr
datadir = /var/lib/mysql
tmpdir = /tmp
lc-messages-dir = /usr/share/mysql
skip-external-locking

Instead of skip-networking the default is now to listen only on

localhost which is more compatible and is not less secure.

bind-address = 127.0.0.1

* Fine Tuning

sort_buffer_size = 256M
key_buffer_size = 16M
max_allowed_packet = 16M
thread_stack = 192K
thread_cache_size = 8

This replaces the startup script and checks MyISAM tables if needed

the first time they are touched

myisam-recover-options = BACKUP

Then service mysql restart

If it was just during upgrades, you could have moved the database to your own host to run the upgrade stuff. When you already get this errors on the setup, imagine what will happen when you have a bit of data in your database. However, on a fresh setup, there is not much to sort that should be a problem for any database. For a setup with many many files, then you get large tables and sorting take some resources. But during and directly after the setup that is not the case.

Perhaps some problems with the database? I’d check with a simple script to do some very basic operations on the database and if that is not working, I’d contact the support.

This solution is not useable for me. I am using a webhosting package. There ist no posibility to set up mysql issues. The tipp from the support from my hoster was “create an additional index to decrease the need of sorting memory”… But i have no idea on which table.

my not satisfying solution is to install version 21.0.3 and ignore Version 22.

Hope this issue will be solved during the 22’er development

The issue was happen into a fresh installation. No legacys there

best regards, Swen

I have also the same problem.
I got a Provider-Based nextcloud which i setup on CPanels “Softaculous” Installer. The update to 22.0 or 22.1 shows “all is fine” - but after login i get “internal server error” with the same error in nextcloud-log.

At first i thought it was an update problem from the version when updating from 21.0.2 to 22.0, but the error also occurs when updating to 22.1. :disappointed:

Like the thread creator, I am not able to set the buffer size, because i only can use the web-based part.

So how do I get the Nextcloud up and running again?
Is there a solution?

edit: my provider says that “sort_buffer_size” is still set to 512M. :man_shrugging::woman_shrugging::man_shrugging:

edit2:
Apache-Version: 2.4.48
PHP-Version: 7.3.29
MySQL-Version: 5.7.35-cll-lve

Since version 22 I’m experiencing the same problem.

Just like @keksl I have Nextcloud running on a shared hosting service with cPanel and Softaculous.

In my case sort_buffer_size is set to 262144 and I also can’t change this.

Affected Nextcloud versions: 22.0.0 and 22.1.0
PHP version: 7.4.22
MySQL version: 5.7.34

1 Like

My Nextcloud is just 1.5 GB - I think there are much larger instances, so mine is comparatively small.
I find it a pity that there is no easy way to backup the complete Nextcloud configuration including data over the WebUI and restore it to a new instance.

It is a bit strange, I can create a new instance with version 22.1 via CPanel and Softaculous and it works fine.
I could live with setting up a new Nextcloud instance and importing a backup - if there was a way to do that. But doing the complete config again is out of the question for me.

it seems to be an update problem (maybe generational?) - and i searched the net for a long time to find this post here. it reassures me a little that i’m apparently not alone. :pensive:

I’ve been getting this now after the upgrade to latest. I increased both the

innodb_sort_buffer_size=512M
sort_buffer_size = 512M

but no help. Still get the error. Update triggered this error, I’ve used the very same setup for several years, and the only thing changed was the nextcloud container version. The error is long, so I drop it to pastebin. One of such reasons could be looking for a value from db which is not indexed. I can’t judge, as the db query horrifies me :smiley:

Here’s the error log in json: https://pastebin.com/EbBXJCae

Something badly wrong here, which took the nextcloud down.

That’s perhaps something for the bug tracker, especially for those with their own setup and those who have been using it in previous versions.

What I’d try first is to disable some of the apps. @ikkeT you have a lot of errors with the share-circle, so I’d start with circles. So perhaps it’s related to a specific app.

3 Likes

Thanks a lot! Sniper quality spotting there. I disabled circles, and it works now. I turned it into an issue: circles causes: mariadb out of sort buffer memory · Issue #28434 · nextcloud/server · GitHub

1 Like

Fantastic, after disabling the “circles” app the problem seems to be solved for me too. I also gave a “thumbs up” to the GitHub issue. Thank you.

1 Like

Deactivating the Circles app also helped me.
Thanks for the tip. :ok_hand::+1:

1 Like

This worked for me:

You probably need to increase the buffer size of mysql in the /etc/mysql/my.cnf, something like:

[mysqld]
sort_buffer_size=256k

After a couple of hours fighting with this problem I landed here and deactivating the circles app solved the issue. Thanks a lot.

How do I disable circles on a fresh install when I can’t even login for the first time?

You could use the occ command from the command line:

Example:

sudo -u www-data php /var/www/nextcloud/occ app:disable circles

https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/occ_command.html#apps-commands

Thank you sir/madam. You are a gentleman/lady and a scholar.
Much appreciated.

Just go to your NextCloud installation path. Example: public_html/cloud/apps and then just rename the “circles” folder, like say “circles” or anything you want. Then reload your login instance, and it will work oob. :slight_smile:
This is for people who either do not have local server or have on say shared storage without root access.
Hope this helps. It worked for me on 22.2.0.2

1 Like