Correcting:
sudo -H python3 install.py --production --site site.name --user erpnext --mysql-root-password whatever_you_fancy --admin-password whatever_you_fancy --bench-name bench_you_would_like_to_call
Hi @Tufan_Kaynak2,
With reference to a post I made a few days ago - Erpnext installation issue on 16.04 and 18.04
I tried your method above and ran into the same issue when “bench init frappe-bench” runs as the last part of the install. In addition, I still had to to a manual wget for the wkhtmltox file.
Any ideas what I could be doing wrong.
The install base is a clean 18.04.1 VM guest on Proxmox.
Thanks
Thank you very much. Installed version 12 successfully using venilla machine.
Hi @ekabyte could you please put a note in the forum with lessons learned so any other community member could get benefit of your experience. you can add mistakes to avoid and clean steps (detailed) so even beginner can follow.
Thanks
- I have installed fresh Ubuntu 18.0.4LTS
- Ran the command apt-get update
- Ran the command apt-get upgrade
- Rebooted server
- apt-get install python3-setuptools python3-minimal redis-server build-essential
- created user erpnext
sudo adduser erpnext (Adding a new user erpnext)
usermod -aG sudo erpnext (giving proper permission)
su erpnext (login as erpnext user)
-
Download the installation script by running below command:
wget https://raw.githubusercontent.com/frappe/bench/master/playbooks/install.py -
Then install the erpnext by using this command (it will take nearly 45 minits to run in 4GB virtualbox image, below command install all the requisite for erpnext (example nginx, mariadb etc ):
sudo -H python3 install.py --production --site localhost --user erpnext --mysql-root-password your_password --admin-password your_password --bench-name your_bench_name
-
This will install the ERPNEXT. After this I have updated the bench by running below command:
cd erp_bench/
bench update
- I have accessed the application using the link http://localhost (It worked me from the port 80)
Just a doubt, by the way Thanks a lot to write steps it’s very helpfull I like it,
below command I see “–mysql-root-password your_password --admin-password your_password --bench-name your_bench_name” shall I changed or keep it as it is?
ex: your_password I should remove this text and replace it right? or can you give dummy command sample…
your_password write your own password (both places)
your_bench_name Name your bench example frappe_bench
thank you this working very well
many thanks for you
you save my life
One tricky point:
In case you receive redis-server configuration errors, possibly you have disabled ipv6 on the system. The default configuration does not recognize this and throws error while trying to bind to the ipv6 loopback interface.
Just edit /etc/redis/redis_conf file and edit the bind line erasing ipv6 related address.
looks like disabling ipv6 before installing Erpnext via easy install is not a good idea after all.
Thank you!
This is extremely helpful. Don’t know how many times I was going around in circles with the documentation on Github trying to resolve dependencies. This method cleared the fog out of my eyes and I’ve spun up a working instance finally. To anyone reading this - use @ekabyte 's process here for v12!
Glad to see things shifting out of the “inbetween time” and full time python3 but I think that might be a bit of what’s been causing confusion in the documentation for some. Guess it hasn’t been updated yet!
In particular, it’s mentioned as an option in the github docs but then there is the suggestion to use an alias to the old python names before the easy-install script, which causes errors of course and makes the script fail (ie: alias python=python3 implies that the install wants python, but really it’s python3…don’t use the alias any longer I guess)
- fresh ubuntu desktop 64 v18.04.2 inside ovb (host is windows 8.1 64)
- sudo mkdir buffer
- cd buffer
- sudo apt install python-minimal build-essential python-setuptools
reboot for snapshot
- sudo wget https://raw.githubusercontent.com/frappe/bench/master/playbooks/install.py
- sudo -H python install.py --production --user frappe
- enter mysql root password
- enter the default Administrator user password
- ERROR! The requested handler ‘restart network manager’ was not found in either the main handlers list nor in the listening handlers list
- sudo -H python install.py --production --user frappe
- Frappe/ERPNext has been successfully installed!
i have started to test erpnext since 3 years ago but never setup the whole server without install.py, feel so unsatisfied.
edit : failed at setup
Setting up your system
Updating global settings
Perhaps you meant to type the other, but did you try python3
for the packages instead of python
? AFAIK the new ERPNext requires python3 (correct me if I’m wrong?)
eg: sudo apt install python3-minimal python3-setuptools
, etc…
I had all sorts of errors (some pretty unintelligible and not clear) until getting the right dependencies sorted.
had the same issue, just define a password for the frappe user.
I think it is passwd frappe
How to solve below installation error?
TASK [dns_caching : Add dnsmasq to network config] ******************************************************************************************************************************
task path: /tmp/.bench/playbooks/roles/dns_caching/tasks/main.yml:11
<127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: root
<127.0.0.1> EXEC /bin/sh -c ‘echo ~root && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘( umask 77 && mkdir -p “echo /root/.ansible/tmp/ansible-tmp-1566961745.6961405-113787252108860
” && echo ansible-tmp-1566961745.6961405-113787252108860=“echo /root/.ansible/tmp/ansible-tmp-1566961745.6961405-113787252108860
” ) && sleep 0’
Using module file /usr/local/lib/python3.6/dist-packages/ansible/modules/files/lineinfile.py
<127.0.0.1> PUT /root/.ansible/tmp/ansible-local-5459hlf0qd1t/tmp0bovl9wv TO /root/.ansible/tmp/ansible-tmp-1566961745.6961405-113787252108860/AnsiballZ_lineinfile.py
<127.0.0.1> EXEC /bin/sh -c ‘chmod u+x /root/.ansible/tmp/ansible-tmp-1566961745.6961405-113787252108860/ /root/.ansible/tmp/ansible-tmp-1566961745.6961405-113787252108860/AnsiballZ_lineinfile.py && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘/usr/bin/python3 /root/.ansible/tmp/ansible-tmp-1566961745.6961405-113787252108860/AnsiballZ_lineinfile.py && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘rm -f -r /root/.ansible/tmp/ansible-tmp-1566961745.6961405-113787252108860/ > /dev/null 2>&1 && sleep 0’
ERROR! The requested handler ‘restart network manager’ was not found in either the main handlers list nor in the listening handlers list
Traceback (most recent call last):
File “install.py”, line 413, in
install_bench(args)
File “install.py”, line 135, in install_bench
run_playbook(‘site.yml’, sudo=True, extra_vars=extra_vars)
File “install.py”, line 327, in run_playbook
success = subprocess.check_call(args, cwd=os.path.join(cwd, ‘playbooks’))
File “/usr/lib/python3.6/subprocess.py”, line 291, in check_call
p.kill()
subprocess.CalledProcessError: Command ‘[‘ansible-playbook’, ‘-c’, ‘local’, ‘site.yml’, ‘-vvvv’, ‘-e’, ‘@/tmp/extra_vars.json’, ‘–become’, ‘–become-user=myfrappe’]’ returned non-zero exit status 1.
rerun the installation and successful with below log
TASK [dns_caching : Add dnsmasq to network config] ******************************************************************************************************************************
task path: /tmp/.bench/playbooks/roles/dns_caching/tasks/main.yml:11
<127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: root
<127.0.0.1> EXEC /bin/sh -c ‘echo ~root && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘( umask 77 && mkdir -p “echo /root/.ansible/tmp/ansible-tmp-1566962008.1090984-268896643148199
” && echo ansible-tmp-1566962008.1090984-268896643148199=“echo /root/.ansible/tmp/ansible-tmp-1566962008.1090984-268896643148199
” ) && sleep 0’
Using module file /usr/local/lib/python3.6/dist-packages/ansible/modules/files/lineinfile.py
<127.0.0.1> PUT /root/.ansible/tmp/ansible-local-26058q_agd9ji/tmpb9fo8aan TO /root/.ansible/tmp/ansible-tmp-1566962008.1090984-268896643148199/AnsiballZ_lineinfile.py
<127.0.0.1> EXEC /bin/sh -c ‘chmod u+x /root/.ansible/tmp/ansible-tmp-1566962008.1090984-268896643148199/ /root/.ansible/tmp/ansible-tmp-1566962008.1090984-268896643148199/AnsiballZ_lineinfile.py && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘/usr/bin/python3 /root/.ansible/tmp/ansible-tmp-1566962008.1090984-268896643148199/AnsiballZ_lineinfile.py && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘rm -f -r /root/.ansible/tmp/ansible-tmp-1566962008.1090984-268896643148199/ > /dev/null 2>&1 && sleep 0’
ok: [localhost] => {
“backup”: “”,
“changed”: false,
“diff”: [
{
“after”: “”,
“after_header”: “/etc/NetworkManager/NetworkManager.conf (content)”,
“before”: “”,
“before_header”: “/etc/NetworkManager/NetworkManager.conf (content)”
},
{
“after_header”: “/etc/NetworkManager/NetworkManager.conf (file attributes)”,
“before_header”: “/etc/NetworkManager/NetworkManager.conf (file attributes)”
}
],
“invocation”: {
“module_args”: {
“attributes”: null,
“backrefs”: false,
“backup”: false,
“content”: null,
“create”: false,
“delimiter”: null,
“dest”: “/etc/NetworkManager/NetworkManager.conf”,
“directory_mode”: null,
“firstmatch”: false,
“follow”: false,
“force”: null,
“group”: null,
“insertafter”: null,
“insertbefore”: null,
“line”: “dns=dnsmasq”,
“mode”: null,
“owner”: null,
“path”: “/etc/NetworkManager/NetworkManager.conf”,
“regexp”: “dns=”,
“remote_src”: null,
“selevel”: null,
“serole”: null,
“setype”: null,
“seuser”: null,
“src”: null,
“state”: “present”,
“unsafe_writes”: null,
“validate”: null
}
},
“msg”: “”
}
My errors were related with the fact that the script wasn’t authenticating with the provided password.
So every-time after I entered the Admin password for the data-base, etc, the script would crash. I realized later on that I had typed in the incorrect password so I changed it.
Installed beautifully on Ubuntu 18.04. However on bench update command got this error -
Traceback (most recent call last):
File "/usr/local/bin/bench", line 11, in <module>
load_entry_point('bench', 'console_scripts', 'bench')()
File "/home/frappe/.bench/bench/cli.py", line 40, in cli
bench_command()
File "/usr/lib/python3/dist-packages/click/core.py", line 722, in __call__
return self.main(*args, **kwargs)
File "/usr/lib/python3/dist-packages/click/core.py", line 697, in main
rv = self.invoke(ctx)
File "/usr/lib/python3/dist-packages/click/core.py", line 1066, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/lib/python3/dist-packages/click/core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/lib/python3/dist-packages/click/core.py", line 535, in invoke
return callback(*args, **kwargs)
File "/home/frappe/.bench/bench/commands/update.py", line 32, in update
patches.run(bench_path='.')
File "/home/frappe/.bench/bench/patches/__init__.py", line 21, in run
result = execute(bench_path)
File "/home/frappe/.bench/bench/patches/v3/celery_to_rq.py", line 7, in execute
frappe_branch = get_current_branch('frappe', bench_path)
File "/home/frappe/.bench/bench/app.py", line 281, in get_current_branch
return get_cmd_output("basename $(git symbolic-ref -q HEAD)", cwd=repo_dir)
File "/home/frappe/.bench/bench/utils.py", line 370, in get_cmd_output
output = subprocess.check_output(cmd, cwd=cwd, shell=True, stderr=subprocess.PIPE).strip()
File "/usr/lib/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/usr/lib/python3.6/subprocess.py", line 423, in run
with Popen(*popenargs, **kwargs) as process:
File "/usr/lib/python3.6/subprocess.py", line 729, in __init__
restore_signals, start_new_session)
File "/usr/lib/python3.6/subprocess.py", line 1364, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: './apps/frappe': './apps/frappe'
I have created a user by name frappe, but do I need to create a folder as well?