nextcloud / nextcloudpi

📦 Build code for NextcloudPi: Raspberry Pi, Odroid, Rock64, curl installer...
https://nextcloudpi.com
2.58k stars 298 forks source link

nc-limits struggles with grep: /etc/mysql/mariadb.conf.d/91-ncp.cnf: No such file or directory #1199

Closed schoetju closed 4 years ago

schoetju commented 4 years ago

Hi experts,

nc-limits does not find mariadb.conf. When trying to run it, following shows up [ nc-limits ] (Sat 24 Oct 14:13:22 CEST 2020) Using 727317504B for PHP Using 6 PHP threads grep: /etc/mysql/mariadb.conf.d/91-ncp.cnf: No such file or directory Using 192107520 memory for the database sed: can't read /etc/mysql/mariadb.conf.d/91-ncp.cnf: No such file or directory

I doublechecked the folder: pi@nextcloudpi:~ $ sudo ls /etc/mysql/mariadb.conf.d/ -al total 28 drwxr-xr-x 2 root root 4096 Jun 12 19:51 . drwxr-xr-x 4 root root 4096 Jun 12 19:51 .. -rw-r--r-- 1 root root 733 Aug 3 2019 50-client.cnf -rw-r--r-- 1 root root 336 Aug 10 2017 50-mysql-clients.cnf -rw-r--r-- 1 root root 1032 Aug 10 2017 50-mysqld_safe.cnf -rw-r--r-- 1 root root 3940 Aug 3 2019 50-server.cnf -rw-r--r-- 1 root root 3795 Nov 22 2018 90-ncp.cnf

So: There is a 90-ncp.cnf - but no 91-ncp-cnf

Does that make any sense?

Best regards Juergen

System information

NextCloudPi diagnostics ``` NextCloudPi version v1.31.0 NextCloudPi image NextCloudPi_11-22-18 distribution Raspbian GNU/Linux 10 \n \l automount no USB devices sda datadir /var/www/nextcloud/data data in SD yes data filesystem ext2/ext3 data disk usage 82G/458G rootfs usage 82G/458G swapfile /dev/zram3 dbdir /var/lib/mysql Nextcloud check ok Nextcloud version 19.0.3.1 HTTPD service up PHP service up MariaDB service up Redis service up Postfix service up internet check ok port check 80 open port check 443 open IP ***REMOVED SENSITIVE VALUE*** gateway ***REMOVED SENSITIVE VALUE*** interface eth0 certificates ***REMOVED SENSITIVE VALUE*** NAT loopback no uptime 9min ```
Nextcloud configuration ``` { "system": { "passwordsalt": "***REMOVED SENSITIVE VALUE***", "secret": "***REMOVED SENSITIVE VALUE***", "trusted_domains": { "0": "localhost", "5": "nextcloudpi.local", "7": "nextcloudpi", "8": "nextcloudpi.lan", "1": "***REMOVED SENSITIVE VALUE***", "4": "***REMOVED SENSITIVE VALUE***", "12": "***REMOVED SENSITIVE VALUE***" }, "datadirectory": "***REMOVED SENSITIVE VALUE***", "dbtype": "mysql", "version": "19.0.3.1", "overwrite.cli.url": "***REMOVED SENSITIVE VALUE***", "dbname": "***REMOVED SENSITIVE VALUE***", "dbhost": "***REMOVED SENSITIVE VALUE***", "dbport": "", "dbtableprefix": "oc_", "mysql.utf8mb4": true, "dbuser": "***REMOVED SENSITIVE VALUE***", "dbpassword": "***REMOVED SENSITIVE VALUE***", "installed": true, "instanceid": "***REMOVED SENSITIVE VALUE***", "memcache.local": "\\OC\\Memcache\\Redis", "memcache.locking": "\\OC\\Memcache\\Redis", "redis": { "host": "***REMOVED SENSITIVE VALUE***", "port": 0, "timeout": 0, "password": "***REMOVED SENSITIVE VALUE***" }, "mail_smtpmode": "smtp", "mail_smtpauthtype": "LOGIN", "mail_from_address": "***REMOVED SENSITIVE VALUE***", "mail_domain": "***REMOVED SENSITIVE VALUE***", "overwriteprotocol": "https", "loglevel": "2", "log_type": "file", "maintenance": false, "jpeg_quality": "60", "preview_max_x": "2048", "preview_max_y": "2048", "enabledPreviewProviders": [ "OC\\Preview\\PNG", "OC\\Preview\\JPEG", "OC\\Preview\\GIF", "OC\\Preview\\BMP", "OC\\Preview\\XBitmap", "OC\\Preview\\MP3", "OC\\Preview\\TXT", "OC\\Preview\\MarkDown", "OC\\Preview\\PDF" ], "data-fingerprint": "c239792ec7d840e01f0a6021430b0328", "mail_sendmailmode": "smtp", "mail_smtpsecure": "ssl", "mail_smtpauth": 1, "mail_smtphost": "***REMOVED SENSITIVE VALUE***", "mail_smtpport": "465", "mail_smtpname": "***REMOVED SENSITIVE VALUE***", "mail_smtppassword": "***REMOVED SENSITIVE VALUE***", "theme": "", "app_install_overwrite": [ "keeweb" ] } } ```
HTTPd logs ``` [Sat Oct 24 00:00:02.948272 2020] [ssl:warn] [pid 876:tid 1996337680] AH01909: localhost:4443:0 server certificate does NOT include an ID which matches the server name [Sat Oct 24 00:00:02.959124 2020] [mpm_event:notice] [pid 876:tid 1996337680] AH00489: Apache/2.4.38 (Raspbian) OpenSSL/1.1.1d configured -- resuming normal operations [Sat Oct 24 00:00:02.959153 2020] [core:notice] [pid 876:tid 1996337680] AH00094: Command line: '/usr/sbin/apache2' [Sat Oct 24 13:29:19.089909 2020] [mpm_event:notice] [pid 876:tid 1996337680] AH00491: caught SIGTERM, shutting down [Sat Oct 24 13:29:37.706246 2020] [ssl:warn] [pid 614:tid 1996128784] AH01909: localhost:4443:0 server certificate does NOT include an ID which matches the server name [Sat Oct 24 13:29:37.758617 2020] [ssl:warn] [pid 865:tid 1996128784] AH01909: localhost:4443:0 server certificate does NOT include an ID which matches the server name [Sat Oct 24 13:29:37.764445 2020] [mpm_event:notice] [pid 865:tid 1996128784] AH00489: Apache/2.4.38 (Raspbian) OpenSSL/1.1.1d configured -- resuming normal operations [Sat Oct 24 13:29:37.764536 2020] [core:notice] [pid 865:tid 1996128784] AH00094: Command line: '/usr/sbin/apache2' [Sat Oct 24 14:12:58.254886 2020] [core:warn] [pid 865:tid 1996128784] AH00045: child process 870 still did not exit, sending a SIGTERM [Sat Oct 24 14:13:00.257159 2020] [core:warn] [pid 865:tid 1996128784] AH00045: child process 870 still did not exit, sending a SIGTERM [Sat Oct 24 14:13:02.259399 2020] [core:warn] [pid 865:tid 1996128784] AH00045: child process 870 still did not exit, sending a SIGTERM [Sat Oct 24 14:13:04.261661 2020] [core:error] [pid 865:tid 1996128784] AH00046: child process 870 still did not exit, sending a SIGKILL [Sat Oct 24 14:13:05.263270 2020] [mpm_event:notice] [pid 865:tid 1996128784] AH00491: caught SIGTERM, shutting down [Sat Oct 24 14:13:20.753006 2020] [ssl:warn] [pid 566:tid 1995735568] AH01909: localhost:4443:0 server certificate does NOT include an ID which matches the server name [Sat Oct 24 14:13:20.814843 2020] [ssl:warn] [pid 793:tid 1995735568] AH01909: localhost:4443:0 server certificate does NOT include an ID which matches the server name [Sat Oct 24 14:13:20.820619 2020] [mpm_event:notice] [pid 793:tid 1995735568] AH00489: Apache/2.4.38 (Raspbian) OpenSSL/1.1.1d configured -- resuming normal operations [Sat Oct 24 14:13:20.820730 2020] [core:notice] [pid 793:tid 1995735568] AH00094: Command line: '/usr/sbin/apache2' ```
Database logs ``` 2020-10-24 14:15:42 0 [Note] InnoDB: Uses event mutexes 2020-10-24 14:15:42 0 [Note] InnoDB: Compressed tables use zlib 1.2.11 2020-10-24 14:15:42 0 [Note] InnoDB: Number of pools: 1 2020-10-24 14:15:42 0 [Note] InnoDB: Using generic crc32 instructions 2020-10-24 14:15:42 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M 2020-10-24 14:15:42 0 [Note] InnoDB: Completed initialization of buffer pool 2020-10-24 14:15:42 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority(). 2020-10-24 14:15:42 0 [Note] InnoDB: 128 out of 128 rollback segments are active. 2020-10-24 14:15:42 0 [Note] InnoDB: Creating shared tablespace for temporary tables 2020-10-24 14:15:42 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ... 2020-10-24 14:15:42 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB. 2020-10-24 14:15:42 0 [Note] InnoDB: 10.3.22 started; log sequence number 4964005951; transaction id 19937170 2020-10-24 14:15:42 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool 2020-10-24 14:15:42 0 [Note] Plugin 'FEEDBACK' is disabled. 2020-10-24 14:15:42 0 [Note] Server socket created on IP: '127.0.0.1'. 2020-10-24 14:15:43 0 [Note] Reading of all Master_info entries succeeded 2020-10-24 14:15:43 0 [Note] Added new Master_info '' to hash table 2020-10-24 14:15:43 0 [Note] /usr/sbin/mysqld: ready for connections. Version: '10.3.22-MariaDB-0+deb10u1' socket: '/var/run/mysqld/mysqld.sock' port: 3306 Raspbian 10 2020-10-24 14:15:43 0 [Note] InnoDB: Buffer pool(s) load completed at 201024 14:15:43 ```
Nextcloud logs ``` {"reqId":"ZW3hXBncvJgjZjVTVT0g","level":3,"time":"2020-10-17T00:00:08+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"unlink(/var/www/nextcloud/data/appdata_ockubejeb23o/preview/6/8/8/2/6/f/1/314963/341-256.jpg): No such file or directory at /var/www/nextcloud/lib/private/Files/Storage/Local.php#283","userAgent":"--","version":"19.0.3.1"} {"reqId":"wW9LCZMEr4DT86xRm22m","level":3,"time":"2020-10-17T00:00:08+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"unlink(/var/www/nextcloud/data/appdata_ockubejeb23o/preview/6/8/8/2/6/f/1/314963/341-256.jpg): No such file or directory at /var/www/nextcloud/lib/private/Files/Storage/Local.php#283","userAgent":"--","version":"19.0.3.1"} {"reqId":"wW9LCZMEr4DT86xRm22m","level":3,"time":"2020-10-17T00:00:10+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"unlink(/var/www/nextcloud/data/appdata_ockubejeb23o/preview/5/6/4/6/0/d/e/314965/192-256.jpg): No such file or directory at /var/www/nextcloud/lib/private/Files/Storage/Local.php#283","userAgent":"--","version":"19.0.3.1"} {"reqId":"ZW3hXBncvJgjZjVTVT0g","level":3,"time":"2020-10-17T00:00:10+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"unlink(/var/www/nextcloud/data/appdata_ockubejeb23o/preview/5/6/4/6/0/d/e/314965/192-256.jpg): No such file or directory at /var/www/nextcloud/lib/private/Files/Storage/Local.php#283","userAgent":"--","version":"19.0.3.1"} {"reqId":"WvKWE2QT4vSa6diNm4Pn","level":2,"time":"2020-10-17T18:00:02+00:00","remoteAddr":"","user":"--","app":"appstoreFetcher","method":"","url":"--","message":"Could not connect to appstore: cURL error 6: Could not resolve host: apps.nextcloud.com (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)","userAgent":"--","version":"19.0.3.1"} {"reqId":"Hxkh3uLhvaSGnWgRpWlc","level":2,"time":"2020-10-18T18:05:02+00:00","remoteAddr":"","user":"--","app":"appstoreFetcher","method":"","url":"--","message":"Could not connect to appstore: cURL error 6: Could not resolve host: apps.nextcloud.com (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)","userAgent":"--","version":"19.0.3.1"} {"reqId":"SBoA1Kcxd3whMGwM0N35","level":2,"time":"2020-10-19T18:10:02+00:00","remoteAddr":"","user":"--","app":"appstoreFetcher","method":"","url":"--","message":"Could not connect to appstore: cURL error 6: Could not resolve host: apps.nextcloud.com (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)","userAgent":"--","version":"19.0.3.1"} {"reqId":"OVV9nW5VJZxNYRETfC7y","level":2,"time":"2020-10-21T18:20:02+00:00","remoteAddr":"","user":"--","app":"appstoreFetcher","method":"","url":"--","message":"Could not connect to appstore: cURL error 6: Could not resolve host: apps.nextcloud.com (see https://curl.haxx.se/libcurl/c/libcurl-errors.html)","userAgent":"--","version":"19.0.3.1"} {"reqId":"ScPEDD2IlMjKB1XDDcSc","level":3,"time":"2020-10-23T00:00:06+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"unlink(/var/www/nextcloud/data/appdata_ockubejeb23o/preview/d/f/1/6/f/7/5/316001/64-64-crop.jpg): No such file or directory at /var/www/nextcloud/lib/private/Files/Storage/Local.php#283","userAgent":"--","version":"19.0.3.1"} {"reqId":"peOBm8tSE2aefsYDhfOc","level":3,"time":"2020-10-23T00:00:06+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"unlink(/var/www/nextcloud/data/appdata_ockubejeb23o/preview/d/f/1/6/f/7/5/316001/64-64-crop.jpg): No such file or directory at /var/www/nextcloud/lib/private/Files/Storage/Local.php#283","userAgent":"--","version":"19.0.3.1"} {"reqId":"X5MAO9m5TINXl22rz83q9AAAAFI","level":3,"time":"2020-10-23T16:09:31+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"PROPFIND","url":"/remote.php/dav/files/juergen/","message":"Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found at /var/www/nextcloud/remote.php#61","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5MAO9m5TINXl22rz83q9QAAAFM","level":3,"time":"2020-10-23T16:09:31+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"GET","url":"/ocs/v2.php/core/navigation/apps?absolute=true&format=json","message":"Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occurred in driver: SQLSTATE[HY000] [2002] No such file or directory at /var/www/nextcloud/lib/private/DB/Connection.php#67","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5MAO9m5TINXl22rz83q9gAAAFY","level":3,"time":"2020-10-23T16:09:31+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"PROPFIND","url":"/remote.php/dav/files/juergen/","message":"Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found at /var/www/nextcloud/remote.php#61","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5QBwLka6rMpJcVDUtl1CAAAAEA","level":3,"time":"2020-10-24T10:28:16+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"GET","url":"/ocs/v2.php/core/navigation/apps?absolute=true&format=json","message":"Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occurred in driver: SQLSTATE[HY000] [2002] No such file or directory at /var/www/nextcloud/lib/private/DB/Connection.php#67","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5QBwIlHIFBbP42VuhntswAAAAE","level":3,"time":"2020-10-24T10:28:16+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"PROPFIND","url":"/remote.php/dav/files/juergen/","message":"Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found at /var/www/nextcloud/remote.php#61","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5QDPrka6rMpJcVDUtl1HAAAAEA","level":3,"time":"2020-10-24T10:34:38+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"PROPFIND","url":"/remote.php/dav/files/juergen/","message":"Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found at /var/www/nextcloud/remote.php#61","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5QQJzUGjfq3UcJj-J2TvgAAAEY","level":3,"time":"2020-10-24T11:29:43+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"PROPFIND","url":"/remote.php/dav/files/juergen/","message":"Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found at /var/www/nextcloud/remote.php#61","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5QQJzUGjfq3UcJj-J2TvwAAAEc","level":3,"time":"2020-10-24T11:29:43+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"GET","url":"/ocs/v2.php/core/navigation/apps?absolute=true&format=json","message":"Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occurred in driver: SQLSTATE[HY000] [2002] No such file or directory at /var/www/nextcloud/lib/private/DB/Connection.php#67","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5QQJzUGjfq3UcJj-J2TwAAAAEg","level":3,"time":"2020-10-24T11:29:43+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"PROPFIND","url":"/remote.php/dav/files/juergen/","message":"Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found at /var/www/nextcloud/remote.php#61","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} {"reqId":"X5QQJzUGjfq3UcJj-J2TwQAAAEk","level":3,"time":"2020-10-24T11:29:43+00:00","remoteAddr":"2a00:6020:4009:1100:7c5f:256b:c900:77c9","user":"--","app":"PHP","method":"GET","url":"/ocs/v2.php/apps/notifications/api/v2/notifications?format=json","message":"Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occurred in driver: SQLSTATE[HY000] [2002] No such file or directory at /var/www/nextcloud/lib/private/DB/Connection.php#67","userAgent":"Mozilla/5.0 (Windows) mirall/3.0.2stable-Win64 (build 20200924) (Nextcloud)","version":"19.0.3.1"} ```
schoetju commented 4 years ago

Still digging into this. 1.) I am not sure, if i should have placed this into the forum (vs. Github-issue). Anyway - for now - i'll stay here 2.) I still do not fully understand what is behind 90-ncp.conf and/or 91-ncp.conf ... (according to https://github.com/nextcloud/nextcloudpi/blob/master/lamp.sh both files should exist!?) But: There is only a single 90-ncp.conf 90-ncp.conf.txt

To get a deeper understanding I simply renamed 90-ncp.conf to 91-ncp.conf + did a reboot: Result: Nextcloud is still up and running - but nc-info / ncp-diag struggles now: grep: /etc/mysql/mariadb.conf.d/90-ncp.cnf: No such file or directory d

--> So it seems - there should be both files!?

(Meanwhile i renamed back to 90-ncp.conf)

Any help is appreciated

schoetju commented 4 years ago

Got it. Created 91-ncp.conf according to https://github.com/nextcloud/nextcloudpi/blob/master/lamp.sh

Not sure, if i should delete everything of 90-ncp.conf

At least nc-info and nc-limit are running without error-message