Hello Discourse Community,
@sat have you found a solution for this yet ?
I ran into the same error while trying to migrate from vBulletin5 using the Docker part of the same thread.
I also installed MariaDB instead of MySQL:
apt-get update && apt-get install libmariadb-dev mariadb-server-10.3
I imported my SQL data and I am able to connect to the database and see that the tables are created:
mysqlcheck -c vb5 -u root -p
At first, I used the default login (root / blank) and in a second attempt I set a password for the root user:
export DB_NAME="vb5"
export DB_USER="root"
export DB_PW="password1234"
export TABLE_PREFIX="vb5."
export ATTACHMENT_DIR='/vb5-attachments'
export TIMEZONE='Europe/Berlin'
cd /var/www/discourse
su discourse -c 'bundle exec ruby script/import_scripts/vbulletin5.rb'
I am not sure about the TABLE_PREFIX
here. But all table names start with vb5.
in my default installation - so I guess this should be ok (I also tried leaving it empty).
But the main issue is that I cannot connect to the MariaDB database with the discourse user:
su discourse -c 'bundle exec ruby script/import_scripts/vbulletin5.rb'
Loading existing groups...
Loading existing users...
Loading existing categories...
Loading existing posts...
Loading existing topics...
Traceback (most recent call last):
5: from script/import_scripts/vbulletin5.rb:632:in `<main>'
4: from script/import_scripts/vbulletin5.rb:632:in `new'
3: from script/import_scripts/vbulletin5.rb:27:in `initialize'
2: from script/import_scripts/vbulletin5.rb:27:in `new'
1: from /var/www/discourse/vendor/bundle/ruby/2.6.0/gems/mysql2-0.5.2/lib/mysql2/client.rb:90:in `initialize'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/mysql2-0.5.2/lib/mysql2/client.rb:90:in `connect': Access denied for user 'root'@'localhost' (Mysql2::Error)
su discourse
mysqlcheck -c vb5 -u root -p
Enter password: #password1234
mysqlcheck: Got error: 1698: Access denied for user 'root'@'localhost' when trying to connect