I’ve been running NCP for a year or so on a Rock64, in a Docker container. It’s a bit sluggish, and it loses the SSL certificate every 3 months, so I decided to set up Debian on an old Core2Duo, and do a standard install of NCP.
(I appreciate the convenience of NCP’s web interface and the ncp-config utility, so would prefer to use NCP if at all possible.)
I ran the Curl installer, but have hit a snag that I can’t seem to find a solution for anywhere online. I’ll be very grateful if the community here is able to help.
Everything seems to work with the installation until it gets to this point:
Downloading Nextcloud 19.0.3... Installing Nextcloud 19.0.3... Creating possible missing Directories chmod Files and Directories chown Directories chmod/chown .htaccess Setting up database... Setting up Apache... Enabling site nextcloud. To activate the new configuration, you need to run: systemctl reload apache2 Setting up system... Don't forget to run nc-init Job for mariadb.service failed because the control process exited with error code. See "systemctl status mariadb.service" and "journalctl -xe" for details.
Running systemctl status mariadb.service produces:
mariadb.service - MariaDB 10.3.23 database server Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Thu 2020-10-08 23:05:51 PDT; 18h ago Docs: man:mysqld(8) https://mariadb.com/kb/en/library/systemd/ Process: 26374 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exi Process: 26375 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=ex Process: 26377 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=`cd /us Process: 26472 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION Main PID: 26472 (code=exited, status=1/FAILURE) Status: "MariaDB server is down"
And journalctl -xe gives:
Oct 09 17:31:51 [myserver] anacron: Anacron 2.3 started on 2020-10-09 Oct 09 17:31:51 [myserver] anacron: Normal exit (0 jobs run) Oct 09 17:31:51 [myserver] systemd: anacron.service: Succeeded. -- Subject: Unit succeeded -- Defined-By: systemd -- Support: https://www.debian.org/support -- -- The unit anacron.service has successfully entered the 'dead' state. Oct 09 17:39:01 [myserver] CRON: pam_unix(cron:session): session opened for user root by (uid=0) Oct 09 17:39:01 [myserver] CRON: (root) CMD ( [ -x /usr/lib/php/sessionclean ] && if [ ! -d /run/systemd/system ]; then /usr/lib/php/sessionclean; fi) Oct 09 17:39:01 [myserver] CRON: pam_unix(cron:session): session closed for user root Oct 09 17:45:01 [myserver] CRON: pam_unix(cron:session): session opened for user www-data by (uid=0) Oct 09 17:45:01 [myserver] CRON: (www-data) CMD (php -f /var/www/nextcloud/cron.php) Oct 09 17:45:01 [myserver] CRON: pam_unix(cron:session): session closed for user www-data Oct 09 17:58:36 [myserver] sudo: clay : TTY=pts/1 ; PWD=/home/[myuser] ; USER=root ; COMMAND=/usr/bin/journalctl -xe Oct 09 17:58:36 [myserver] sudo: pam_unix(sudo:session): session opened for user root by [myuser](uid=0)
In researching, I came across this thread, so tried running
mysql_install_db --user=mysql --basedir=/usr --datadir=/var/lib/mysql, but that gave the following output:
Installing MariaDB/MySQL system tables in '/var/lib/mysql' ... Installation of system tables failed! Examine the logs in /var/lib/mysql for more information. The problem could be conflicting information in an external my.cnf files. You can ignore these by doing: shell> /usr/bin/mysql_install_db --defaults-file=~/.my.cnf You can also try to start the mysqld daemon with: shell> /usr/sbin/mysqld --skip-grant-tables --general-log & and use the command line tool /usr/bin/mysql to connect to the mysql database and look at the grant tables: shell> /usr/bin/mysql -u root mysql mysql> show tables; Try 'mysqld --help' if you have problems with paths. Using --general-log gives you a log in /var/lib/mysql that may be helpful. The latest information about mysql_install_db is available at https://mariadb.com/kb/en/installing-system-tables-mysql_install_db You can find the latest source at https://downloads.mariadb.org and the maria-discuss email list at https://launchpad.net/~maria-discuss Please check all of the above before submitting a bug report at http://mariadb.org/jira
Hopefully that’s a good start to get the troubleshooting going. If there’s anything else that would be helpful, I’ll be happy to add.