Easiest & Simple Way to Install ERPNext 13

I want try to install ERPNext via docker but without success, it is not many tutorials for this install type. Do you could give me a guide to do install via docker for OCI and tell me please if works at OCI ampere or only Amd.
Thanks
Rene Zamora

these are arm processors.

you’ll need to build your own images for arm64.

read through these issues to know more Issues · frappe/frappe_docker · GitHub

Hello, I appreciate your help but unfortunately I have no experience in building images or installing them. If you can help me with some installation scrpit I would appreciate it very much.

Traceback (most recent call last):
File “install.py”, line 497, in
install_bench(args)
File “install.py”, line 278, in install_bench
run_playbook(‘site.yml’, sudo=True, extra_vars=extra_vars)
File “install.py”, line 413, in run_playbook
success = subprocess.check_call(args, cwd=playbooks_folder, stdout=log_stream, stderr=sys.stderr)
File “/usr/lib/python3.8/subprocess.py”, line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command ‘[‘ansible-playbook’, ‘-c’, ‘local’, ‘site.yml’, ‘-vvvv’, ‘-e’, ‘@/tmp/extra_vars.json’, ‘–become’, ‘–become-user=frappe’]’ returned non-zero exit status 2.
frappe@v13-new:~$

I am getting the above error, can someone suggest please.

@Prasanna_CSA

Here’s the solution to this particular problem:

sudo pip3 uninstall setuptools
sudo pip3 install setuptools==59.6.0
sudo pip3 install -e /home/user/.bench/ 

Then re-run the easy install command.

4 Likes

Tried the commands but I am getting below error, please suggest.Thx

frappe@v13-new:~$ sudo pip3 install -e /home/user/.bench/
/usr/lib/python3/dist-packages/secretstorage/dhcrypto.py:15: CryptographyDeprecationWarning: int_from_bytes is deprecated, use int.from_bytes instead
from cryptography.utils import int_from_bytes
/usr/lib/python3/dist-packages/secretstorage/util.py:19: CryptographyDeprecationWarning: int_from_bytes is deprecated, use int.from_bytes instead
from cryptography.utils import int_from_bytes
ERROR: /home/user/.bench/ is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).

You ran the wrong command here. You were supposed to change the user bit of the code to your username which I assume is frappe from your traceback. so the correct command should be:

sudo pip3 install -e /home/frappe/.bench/

if your user is not frappe, change it to the correct user name.

1 Like

you are right that’s a very silly mistake I did…

Thanks a TON!! @flexy2ky !

i am new with Ubuntu, got same problem as you did. successed. only thing i did is to reboot after the update and upgrade in case of error, thanks for your same problem:rofl::rofl:

1 Like

Thank You
This Fix my Error returned non-zero exit status 2
after spending 3 hours searching the forum I found your great easy solution
thankyou again

Hi Members,
I have used the exact steps before and it worked like a charm.
Today I have encountered same error 3 times using different servers. Debian 10 and Ubuntu 20.04 LTS. Please help anyone if possible. I think it is a compatibility issue with recent updates.

Error logs are below:

TASK [bench : python3 bench init for production] ***************************************************************************
task path: /tmp/.bench/bench/playbooks/roles/bench/tasks/main.yml:44
<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 /var/tmp”&& mkdir /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342 && echo ansible-tmp-1642495545.8854184-47007-93725733107342=“echo /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342” ) && sleep 0’
Using module file /usr/local/lib/python3.8/dist-packages/ansible/modules/commands/command.py
<127.0.0.1> PUT /root/.ansible/tmp/ansible-local-30352lvc4iit5/tmpngmls08j TO /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/AnsiballZ_command.py
<127.0.0.1> EXEC /bin/sh -c ‘setfacl -m u:petsmall:r-x /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/ /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/AnsiballZ_command.py && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘chmod u+x /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/ /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/AnsiballZ_command.py && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘chown petsmall /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/ /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/AnsiballZ_command.py && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘sudo -H -S -n -u petsmall /bin/sh -c ‘"’“‘echo BECOME-SUCCESS-hzejkhmxxhkufqkxrqdicuhxqelfnfxq ; /usr/bin/python3 /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/AnsiballZ_command.py’”’“’ && sleep 0’
<127.0.0.1> EXEC /bin/sh -c ‘rm -f -r /var/tmp/ansible-tmp-1642495545.8854184-47007-93725733107342/ > /dev/null 2>&1 && sleep 0’
fatal: [localhost]: FAILED! => {
“changed”: true,
“cmd”: [
“bench”,
“init”,
“/home/petsmall/frappe-bench”,
“–frappe-path”,
GitHub - frappe/frappe: Low code web framework for real world applications, in Python and Javascript”,
“–frappe-branch”,
“version-13”,
“–python”,
“python3”
],
“delta”: “0:00:00.199411”,
“end”: “2022-01-18 14:15:46.208080”,
“invocation”: {
“module_args”: {
“_raw_params”: “bench init /home/petsmall/frappe-bench --frappe-path GitHub - frappe/frappe: Low code web framework for real world applications, in Python and Javascript --frappe-branch version-13 --python python3”,
“_uses_shell”: false,
“argv”: null,
“chdir”: null,
“creates”: “/home/petsmall/frappe-bench”,
“executable”: null,
“removes”: null,
“stdin”: null,
“stdin_add_newline”: true,
“strip_empty_ends”: true,
“warn”: true
}
},
“msg”: “non-zero return code”,
“rc”: 1,
“start”: “2022-01-18 14:15:46.008669”,
“stderr”: “Traceback (most recent call last):\n File "/usr/bin/bench", line 33, in \n sys.exit(load_entry_point(‘frappe-bench’, ‘console_scripts’, ‘bench’)())\n File "/usr/bin/bench", line 22, in importlib_load_entry_point\n for entry_point in distribution(dist_name).entry_points\n File "/usr/lib/python3.8/importlib/metadata.py", line 503, in distribution\n return Distribution.from_name(distribution_name)\n File "/usr/lib/python3.8/importlib/metadata.py", line 177, in from_name\n raise PackageNotFoundError(name)\nimportlib.metadata.PackageNotFoundError: frappe-bench”,
“stderr_lines”: [
“Traceback (most recent call last):”,
" File "/usr/bin/bench", line 33, in ”,
" sys.exit(load_entry_point(‘frappe-bench’, ‘console_scripts’, ‘bench’)())“,
" File "/usr/bin/bench", line 22, in importlib_load_entry_point”,
" for entry_point in distribution(dist_name).entry_points",
" File "/usr/lib/python3.8/importlib/metadata.py", line 503, in distribution",
" return Distribution.from_name(distribution_name)“,
" File "/usr/lib/python3.8/importlib/metadata.py", line 177, in from_name”,
" raise PackageNotFoundError(name)",
“importlib.metadata.PackageNotFoundError: frappe-bench”
],
“stdout”: “”,
“stdout_lines”: []
}

PLAY RECAP *****************************************************************************************************************
localhost : ok=67 changed=40 unreachable=0 failed=1 skipped=63 rescued=0 ignored=0

Traceback (most recent call last):
File “install.py”, line 497, in
install_bench(args)
File “install.py”, line 278, in install_bench
run_playbook(‘site.yml’, sudo=True, extra_vars=extra_vars)
File “install.py”, line 413, in run_playbook
success = subprocess.check_call(args, cwd=playbooks_folder, stdout=log_stream, stderr=sys.stderr)
File “/usr/lib/python3.8/subprocess.py”, line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command ‘[‘ansible-playbook’, ‘-c’, ‘local’, ‘site.yml’, ‘-vvvv’, ‘-e’, ‘@/tmp/extra_vars.json’, ‘–become’, ‘–become-user=petsmall’]’ returned non-zero exit status 2.

@Sukanta_Rakshit

Unable to install ERPNext on Ubuntu 18.04

Hope this helps!

Please see this thread

https://github.com/frappe/bench/issues/1240

1 Like

@mohsininspire Thank You So Much :slight_smile: :slight_smile:
This was the exact solution.

If anyone have the same problem refer the Bug above or use the below commands:
sudo pip3 uninstall setuptools
sudo pip3 install setuptools==59.6.0
sudo pip3 install -e /home/erp/.bench/

Don’t forget to change /home/[your-username]/.bench/

1 Like

Hello, do you mentioned above Oracle Instance works erpnext. What OCI instances type uses?, what script uses or if requiered any modification to make to works.

Thanks

EDIT: I follow all steps mentioned above + open network ports an OCI + open ports in ubuntu + lastest solutions here posted and works fine!!

Try this. Could solve the problem with ansible-playbook error.

Thanks for the installation guide. The installation was successful but the site won’t open. I am getting the following error page.

This site can’t be reached
The connection was reset.

Pleas help

The problem is with the supervisor service.

This doesnt work for me. I got the following error from the last command

I had to run the following with sudo
$sudo python3 install.py --verbose --production --user frappe --frappe-branch version-13 --erpnext-branch version-13
Got the following error

Traceback (most recent call last):
File “install.py”, line 497, in
install_bench(args)
File “install.py”, line 278, in install_bench
run_playbook(‘site.yml’, sudo=True, extra_vars=extra_vars)
File “install.py”, line 413, in run_playbook
success = subprocess.check_call(args, cwd=playbooks_folder, stdout=log_stream, stderr=sys.stderr)
File “/usr/lib/python3.8/subprocess.py”, line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command ‘[‘ansible-playbook’, ‘-c’, ‘local’, ‘site.yml’, ‘-vvvv’, ‘-e’, ‘@/tmp/extra_vars.json’, ‘–become’, ‘–become-user=frappe’]’ returned non-zero exit status 2.

So I ran

$sudo pip3 uninstall setuptools
$sudo pip3 install setuptools==59.6.0
$sudo pip3 install -e /home/frappe/.bench/

/usr/lib/python3/dist-packages/secretstorage/dhcrypto.py:15: CryptographyDeprecationWarning: int_from_bytes is deprecated, use int.from_bytes instead
from cryptography.utils import int_from_bytes
/usr/lib/python3/dist-packages/secretstorage/util.py:19: CryptographyDeprecationWarning: int_from_bytes is deprecated, use int.from_bytes instead
from cryptography.utils import int_from_bytes
ERROR: /home/frappe/.bench/ is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).

Anything I am missing something?

You are indeed missing something.

there was no need to specify –user frappe in your install command as this is the default user it installs to if you do not specify a different user. I realise that sometimes using the --user tag throws errors in some distros especially if you’re installing on a VPS and don’t apply the right permissions to logged in user. So I suggest you run the install command without the --user tag and if it breaks afterwards, use the setup tools fix to replace the setup tools installed.