3

I already want to install edx-configuarion platform in my ubuntu server.I read this wiki on github but when I run this command :

$ sudo ansible-playbook -c local ./edx_sandbox.yml -i "localhost,"

I get this error:

TASK: [edxlocal | create a database for edxapp] ******************************* 
failed: [localhost] => {"failed": true, "item": ""}
msg: unable to connect, check login_user and login_password are correct, or alternatively check ~/.my.cnf contains credentials

FATAL: all hosts have already failed -- aborting

I changed my root user password to '' but still the same problem.I also change the EDXAPP_MYSQL_USER to root and EDXAPP_MYSQL_PASSWORD to another password in playbooks/roles/edxapp/defaults/main.yml but still same problem :(

mojibuntu
  • 307
  • 3
  • 16

1 Answers1

2

The method you were using suppose to work in a freshly installed Ubuntu server. It also meant that you'd already installed mysql in your server. So, to fix this issue, create this file /root/.my.cnf with the following content:

[client]
user=root
password=<your root pass>

[mysql]
user=root
password=<your root pass>

[mysqldump]
user=root
password=<your root pass>

[mysqldiff]
user=root
password=<your root pass>

Run the command again, It should work.

Trinh Nguyen
  • 1,445
  • 1
  • 14
  • 22
  • This is the correct answer. https://github.com/edx/configuration/wiki/Re-install-Open-edX-in-Ubuntu-12.04 and your password should be a string. http://stackoverflow.com/a/19913912/1154847 – Christopher Markieta Dec 15 '15 at 18:27
  • It's been a while since when I wrote that wiki page. I'm not sure if it's still correct in the newer releases of Open edX, but you can try. – Trinh Nguyen Dec 17 '15 at 00:54
  • Worked for me when installing Ironwood release, I was using one of the passwords generated in my_passwords.conf, but the real password to use was the password of the root user. Thanks @TrinhNguyen – Hector Pasarin Dec 12 '19 at 07:56