nextcloud / nextcloudpi

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

Internal error encountered using twingate #1934

Closed shiyic11 closed 1 month ago

shiyic11 commented 1 month ago

I am trying to add twingate for external access. At first it works fine, but later I run into a internal problem when I access it: Internal Server Error

The server encountered an internal error and was unable to complete your request.
Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report.
More details can be found in the server log. 

However, I can still ssh into it, and here is the report:

<--! Paste this in GitHub report -->

NextcloudPi diagnostics ``` grep: /etc/apache2/sites-available/nextcloud.conf: No such file or directory NextcloudPi version v1.54.0 NextcloudPi image OS Armbian-unofficial 24.2.1 Bookworm \l . 6.6.18-current-bcm2711 (aarch64) automount yes USB devices sda datadir /opt/ncdata/data data in SD yes data filesystem ext2/ext3 data disk usage 4.9G/28G rootfs usage 4.9G/28G swapfile /var/swap dbdir /media/secondDrive Nextcloud check error HTTPD service up PHP service up MariaDB service down Redis service up HPB service down Postfix service up Internet check ok Public IPv4 ***REMOVED SENSITIVE VALUE*** Public IPv6 ***REMOVED SENSITIVE VALUE*** Port 80 closed Port 443 open IP ***REMOVED SENSITIVE VALUE*** Gateway ***REMOVED SENSITIVE VALUE*** Interface end0 Certificates ***REMOVED SENSITIVE VALUE*** NAT loopback no Uptime 37min ```
Nextcloud configuration ``` An unhandled exception has been thrown: Doctrine\DBAL\Exception: Failed to connect to the database: An exception occurred in the driver: SQLSTATE[HY000] [2002] No such file or directory in /var/www/nextcloud/lib/private/DB/Connection.php:139 Stack trace: #0 /var/www/nextcloud/3rdparty/doctrine/dbal/src/Connection.php(1654): OC\DB\Connection->connect() #1 /var/www/nextcloud/3rdparty/doctrine/dbal/src/Connection.php(1081): Doctrine\DBAL\Connection->getWrappedConnection() #2 /var/www/nextcloud/lib/private/DB/Connection.php(261): Doctrine\DBAL\Connection->executeQuery() #3 /var/www/nextcloud/3rdparty/doctrine/dbal/src/Query/QueryBuilder.php(341): OC\DB\Connection->executeQuery() #4 /var/www/nextcloud/3rdparty/doctrine/dbal/src/Query/QueryBuilder.php(377): Doctrine\DBAL\Query\QueryBuilder->executeQuery() #5 /var/www/nextcloud/lib/private/DB/QueryBuilder/QueryBuilder.php(280): Doctrine\DBAL\Query\QueryBuilder->execute() #6 /var/www/nextcloud/lib/private/AppConfig.php(421): OC\DB\QueryBuilder\QueryBuilder->execute() #7 /var/www/nextcloud/lib/private/AppConfig.php(187): OC\AppConfig->loadConfigValues() #8 /var/www/nextcloud/lib/private/AppConfig.php(377): OC\AppConfig->getApps() #9 /var/www/nextcloud/lib/private/App/AppManager.php(128): OC\AppConfig->getValues() #10 /var/www/nextcloud/lib/private/App/AppManager.php(149): OC\App\AppManager->getInstalledAppsValues() #11 /var/www/nextcloud/lib/private/legacy/OC_App.php(231): OC\App\AppManager->getInstalledApps() #12 /var/www/nextcloud/lib/private/AppFramework/Bootstrap/Coordinator.php(90): OC_App::getEnabledApps() #13 /var/www/nextcloud/lib/base.php(700): OC\AppFramework\Bootstrap\Coordinator->runInitialRegistration() #14 /var/www/nextcloud/lib/base.php(1200): OC::init() #15 /var/www/nextcloud/console.php(48): require_once('...') #16 /var/www/nextcloud/occ(11): require_once('...') #17 {main} ```
HTTPd logs ``` [Thu May 02 01:10:53.913003 2024] [ssl:warn] [pid 1757:tid 281473697935392] AH01882: Init: this version of mod_ssl was compiled against a newer library (OpenSSL 3.0.13 30 Jan 2024 (OpenSSL 3.0.11 19 Sep 2023), version currently loaded is 0x300000B0) - may result in undefined or erroneous behavior [Thu May 02 01:10:53.965538 2024] [ssl:warn] [pid 1757:tid 281473697935392] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name [Thu May 02 01:10:53.968108 2024] [ssl:error] [pid 1757:tid 281473697935392] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=rpi4b / issuer: CN=rpi4b / serial: 1989C9E7DAF7D226438675DC05DA2D441043BC7D / notbefore: May 2 01:17:38 2024 GMT / notafter: Apr 30 01:17:38 2034 GMT] [Thu May 02 01:10:53.968167 2024] [ssl:error] [pid 1757:tid 281473697935392] AH02604: Unable to configure certificate localhost:443:0 for stapling [Thu May 02 01:10:54.064405 2024] [ssl:warn] [pid 1916:tid 281473697935392] AH01882: Init: this version of mod_ssl was compiled against a newer library (OpenSSL 3.0.13 30 Jan 2024 (OpenSSL 3.0.11 19 Sep 2023), version currently loaded is 0x300000B0) - may result in undefined or erroneous behavior [Thu May 02 01:10:54.071095 2024] [ssl:warn] [pid 1916:tid 281473697935392] AH01909: localhost:443:0 server certificate does NOT include an ID which matches the server name [Thu May 02 01:10:54.072510 2024] [ssl:error] [pid 1916:tid 281473697935392] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=rpi4b / issuer: CN=rpi4b / serial: 1989C9E7DAF7D226438675DC05DA2D441043BC7D / notbefore: May 2 01:17:38 2024 GMT / notafter: Apr 30 01:17:38 2034 GMT] [Thu May 02 01:10:54.072553 2024] [ssl:error] [pid 1916:tid 281473697935392] AH02604: Unable to configure certificate localhost:443:0 for stapling [Thu May 02 01:10:54.081264 2024] [mpm_event:notice] [pid 1916:tid 281473697935392] AH00489: Apache/2.4.59 (Debian) OpenSSL/3.0.11 configured -- resuming normal operations [Thu May 02 01:10:54.081384 2024] [core:notice] [pid 1916:tid 281473697935392] AH00094: Command line: '/usr/sbin/apache2' [Sun May 19 05:17:13.665426 2024] [ssl:warn] [pid 1092:tid 281473103179808] AH01882: Init: this version of mod_ssl was compiled against a newer library (OpenSSL 3.0.13 30 Jan 2024 (OpenSSL 3.0.11 19 Sep 2023), version currently loaded is 0x300000B0) - may result in undefined or erroneous behavior [Sun May 19 05:17:13.691972 2024] [ssl:warn] [pid 1092:tid 281473103179808] AH01909: localhost:4443:0 server certificate does NOT include an ID which matches the server name [Sun May 19 05:17:13.693717 2024] [ssl:error] [pid 1092:tid 281473103179808] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=rpi4b / issuer: CN=rpi4b / serial: 1989C9E7DAF7D226438675DC05DA2D441043BC7D / notbefore: May 2 01:17:38 2024 GMT / notafter: Apr 30 01:17:38 2034 GMT] [Sun May 19 05:17:13.693783 2024] [ssl:error] [pid 1092:tid 281473103179808] AH02604: Unable to configure certificate localhost:4443:0 for stapling [Sun May 19 05:17:13.821140 2024] [ssl:warn] [pid 1389:tid 281473103179808] AH01882: Init: this version of mod_ssl was compiled against a newer library (OpenSSL 3.0.13 30 Jan 2024 (OpenSSL 3.0.11 19 Sep 2023), version currently loaded is 0x300000B0) - may result in undefined or erroneous behavior [Sun May 19 05:17:13.833686 2024] [ssl:warn] [pid 1389:tid 281473103179808] AH01909: localhost:4443:0 server certificate does NOT include an ID which matches the server name [Sun May 19 05:17:13.835523 2024] [ssl:error] [pid 1389:tid 281473103179808] AH02217: ssl_stapling_init_cert: can't retrieve issuer certificate! [subject: CN=rpi4b / issuer: CN=rpi4b / serial: 1989C9E7DAF7D226438675DC05DA2D441043BC7D / notbefore: May 2 01:17:38 2024 GMT / notafter: Apr 30 01:17:38 2034 GMT] [Sun May 19 05:17:13.835597 2024] [ssl:error] [pid 1389:tid 281473103179808] AH02604: Unable to configure certificate localhost:4443:0 for stapling [Sun May 19 05:17:13.861890 2024] [mpm_event:notice] [pid 1389:tid 281473103179808] AH00489: Apache/2.4.59 (Debian) OpenSSL/3.0.11 configured -- resuming normal operations [Sun May 19 05:17:13.862077 2024] [core:notice] [pid 1389:tid 281473103179808] AH00094: Command line: '/usr/sbin/apache2' ```
Database logs ``` tail: cannot open '/var/log/mysql/*.log' for reading: No such file or directory ```
theCalcaholic commented 1 month ago

Your database seems to be down or broken (which is likely unrelated to the twingate setup). Please go to https://help.nextcloud.com and ask for help there (use the ncp tag) as this is more of a support request than a bug report