This problem was solved with a workaround by @James_Robertson near the end of thread. Thanks again.
BKM
Ok, I have read through the thread here:
And I have tried editing the file /etc/mysql/conf.d/settings.cnf to comment out the line:
socket = /var/lib/mysql/mysql.sock
This was the solution provided by @anebi in this part of the same thread:
Well, after performing this edit to comment out the line and restarting the mariadb server, I am still unable to even get to the login screen for ERPNext. It seems as if the installation never completed enough to get the website to run.
Additionally I looked for the file âmy.cnfâ to attempt to edit it as well, but i never was able to locate it. Besides, there is really no indication of how it was supposed to be edited anyway in the solution post.
So Here I am asking if there is really a solution to this issue when trying to setp up a PRODUCTION server using the INSTALL.PY script?
Here is what I get when I try it, and it fails every time:
TASK [Gathering Facts] *****************************************************************************************
ok: [localhost]
TASK [Check whether a site exists] *****************************************************************************
ok: [localhost]
TASK [Create new site] *****************************************************************************************
fatal: [localhost]: FAILED! => {âchangedâ: true, âcmdâ: [âbenchâ, ânew-siteâ, âsite1.localâ, ââadmin-passwordâ,
âmypasswordâ, ââmariadb-root-passwordâ, âmypasswordâ], âdeltaâ: â0:00:01.978899â, âendâ: â2018-01-15 16:24:20.
546480â, âfailedâ: true, ârcâ: 1, âstartâ: â2018-01-15 16:24:18.567581â, âstderrâ: âERROR 2002 (HY000): Canât co
nnect to local MySQL server through socket â/var/run/mysqld/mysqld.sockâ (2)â, âstderr_linesâ: [âERROR 2002 (HY0
00): Canât connect to local MySQL server through socket â/var/run/mysqld/mysqld.sockâ (2)â], âstdoutâ: âDatabase
not installed, this can due to lack of permission, or that the database name exists.\nCheck your mysql root pas
sword, or use --force to reinstallâ, âstdout_linesâ: [âDatabase not installed, this can due to lack of permissio
n, or that the database name exists.â, âCheck your mysql root password, or use --force to reinstallâ]}
to retry, use: --limit @/tmp/.bench/playbooks/production/install.retry
PLAY RECAP *****************************************************************************************************
localhost : ok=73 changed=45 unreachable=0 failed=1
Traceback (most recent call last):
File âinstall.pyâ, line 388, in
install_bench(args)
File âinstall.pyâ, line 114, in install_bench
run_playbook(âproduction/install.ymlâ, sudo=True, extra_vars=extra_vars)
File âinstall.pyâ, line 326, in run_playbook
success = subprocess.check_call(args, cwd=os.path.join(cwd, âplaybooksâ))
File â/usr/lib/python2.7/subprocess.pyâ, line 541, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command â[âansible-playbookâ, â-câ, âlocalâ, âproduction/install.ymlâ, â-eâ, â@/t
mp/extra_vars.jsonâ, ââbecomeâ, ââbecome-user=erp_jmiâ]â returned non-zero exit status 2
erp_jmi@ubuntu16-test:~$
When I look into the passwords they are correct, so the line indicating we should check the password seems odd.
At this point I (and imagine many others) are still stuck in this install nightmare. I am currently working with a new hosting location and the only OS available to me are Ubuntu 16.04 and Centos 7 both of which fail with the install.py script but for different reasons. In both cases I have also followed the new additions to the instructions under the âEasy Installâ section located here:
https://github.com/frappe/bench
So, I am stuck. I have tried the supposed solution for this and it still does not work. I am looking for a way to get the install script to complete properly -or- a valid set of instructions to complete the process once the install.py breaks as posted above.
Any ideas?
BKM
EDIT:
After looking into the error log for mysql located /var/lib/mysql/mysql-error.log
I found the following error (or rather warning) posted as the last line:
2018-01-15 16:24:20 139812664715008 [Warning] Access denied for user âerp_jmiâ@âlocalhostâ (using password: NO)
So the next logical question is this: Does this error message tell me that for some reason the install script tried to start the database without using a password?
Any ideas?
BKM
EDIT #2:
You can see by this dump of passwords.txt that they are clearly in place and should be working:
erp_jmi@ubuntu16-test:~$ ls
frappe-bench get-pip.py install.py passwords.txt
erp_jmi@ubuntu16-test:~$ cat passwords.txt
{
âmysql_root_passwordâ: âmypasswordâ,
âadmin_passwordâ: âmypasswordâ
}erp_jmi@ubuntu16-test:~$
I am really at a loss here.
BKM