Could not connect to the database. Please refer to suitecrm.log for details (2).

Hello I am having issue with installation I have ran into issue with the user being created.I am using Ubuntu 19.10 and Suite 7.11.8. Below are the commands that I am using for the installation and configurations. Also I have attached an image of the error and the message in the suitecrm.log.Any help would be appreciated greatly.

sudo su
apt-get update
apt-get upgrade
apt-get install apache2
apt-get install mysql-server
apt-get install php libapache2-mod-php
apt-get install curl libcurl4 libcurl3-dev php7.3-curl php-gd php-zip php-intl php-simplexml php-dom php-mysql php-imap
apt-get install composer
cd /var/www/html
rm index.html
mv SuiteCRM-7.11.8/* /var/www/html
rm -r SuiteCRM-7.11.8
composer update --dev
composer install --no-dev
mkdir cache
chown -R www-data:www-data .
chmod -R 755 .
chmod -R 775 cache custom modules themes data upload
chmod 775 config_override.php 2>/dev/null
nano /etc/php/7.3/apache2/php.ini
/sbin/iptables -A INPUT -i eth0 -p tcp --destination-port 3306 -j ACCEPT
nano /etc/mysql/mysql.conf.d/mysqld.cnf

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

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

# localhost which is more compatible and is not less secure.

bind-address =

mysql -u root

USE mysql;
SELECT User, Host, plugin FROM mysql.user;
UPDATE user SET plugin=‘mysql_native_password’ WHERE User=‘root’;
SELECT User, Host, plugin FROM mysql.user;

systemctl restart apache2
systemctl restart mysql

Wed Oct 30 04:42:40 2019 [16494][-none-][FATAL] Query Failed: GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, ALTER, DROP, INDEX
TO “suiteadmin”@“vm-suitecrm-mysql-01”
IDENTIFIED BY ‘MyPassword’;: MySQL error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use ne>
Wed Oct 30 04:42:40 2019 [16494][-none-][FATAL] Could not connect to DB server localhost as suiteadmin. port : Access denied for user ‘suiteadmin’@‘localhost’ (using password: YES)

I don’t advise “composer update”. You should only do “composer install --no-dev”. This is because the update in composer is actually an “upgrade to latest” command. It will take you past the versions that SuiteCRM is tested to work with.

Can you get the full MYSQL error from the log? It’s truncated just before the part that would let us understand what happened…

Also, please check that you are within the versions listed in the Compatibility Matrix

Thanks for sending your response. I went back over the compatible matrix and the versions of each components. I found the issue was MySQL was version 8. I reinstalled using MariaDB 10.2 and I was able to install successfully. Thanks again for your help. I had been searching and reading for the last week with no success until your post.

I’m glad you got it working! B-)

Can I ask you to please add a comment to this Github Issue, documenting the version you used before, and that error you got? We’ll need to work on this MySQl 8.0 pretty soon.