I have successfully cloned, built, installed the mangostwo project and extracted all of the map data (I think). However, I am hitting a snag on the DB setup.
I am using this guide:
I've installed mysql-server with
sudo apt install mysql-server
Then I switched to root and loaded up mysql to do this command (which, BTW, "privileges" is misspelled in the guide:
CREATE USER 'mangos'@'localhost' IDENTIFIED BY 'mangos';
GRANT ALL PRIVILEGES ON *.* TO 'mangos'@'localhost' WITH GRANT OPTION;
I exited, and did
cd /home/mangos/db/
git clone https://github.com/mangoszero/database.git . --recursive --depth=1
./InstallDatabases.sh
(in the guide, the pictures are dead links, so I can't see what Database options to use, but I did mysql host name = localhost, mysql user name = mangos, mysql port = 3306, then I typed in my mangos linux user's password (which I also manually set the mangos mysql user's password to). Then I did all of the default database names.
Then, I get a big string of these errors:
Importing file World/Setup/FullDB/spell_learn_spell.sql
ERROR 1045 (28000): Access denied for user 'mangos'@'localhost' (using password: YES)
File World/Setup/FullDB/spell_learn_spell.sql imported
Importing file World/Setup/FullDB/spell_loot_template.sql
ERROR 1045 (28000): Access denied for user 'mangos'@'localhost' (using password: YES)
File World/Setup/FullDB/spell_loot_template.sql imported
I looked at the InstallDatabases.sh script, and I feel like there is an issue.
printBanner
printf "What is your MySQL host name ?\t[${svr_def}]: "
read svr
svr=${svr:-${svr_def}}
printf "What is your MySQL user name ?\t[${user_def}]: "
read user
user=${user:-${user_def}}
printf "What is your MySQL port ?\t[${port_def}]: "
read port
port=${port:-${port_def}}
printf "What is your MySQL password ?\t [], "
mysql_config_editor set --login-path=local --host=${svr} --port=${port} --user=${user} --password --skip-warn
if [ "${DUMP}" = "YES" ]; then
printf "Enter it again \t[]: "
read pass
fi
Here is the prompt for password. 1) It looks like the script doesn't even store the password in a variable. And 2) mysql_config_editor DEFINITELY prompts the user for a password if you use the --password flag like that. So... I feel like I'm totally missing something. Thoughts?