Fool proof install - step by step

I also have the same issue. The Easy Install fails on:

PLAY RECAP *******************************************************************************************************
localhost : ok=4 changed=1 unreachable=0 failed=1 skipped=1 rescued=0 ignored=0

Traceback (most recent call last):
File “”, line 413, in
File “”, line 135, in install_bench
run_playbook(‘site.yml’, sudo=True, extra_vars=extra_vars)
File “”, line 327, in run_playbook
success = subprocess.check_call(args, cwd=os.path.join(cwd, ‘playbooks’))
File “/usr/lib/python3.5/”, line 581, 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

No matter what i try, it fails (Ubuntu 18.04 server)

Run the command on the command line by itself, without the quotes and commas

ansible-playbook -c local site.yml -vvvv -e @/tmp/extra_vars.json –become –become-user=frappe

I had the same problem, tearing my hair trying to figure out the issue.

Hi All,

the setup steps I followed here worked for me: How to install erpnext from A-Z

Done Excellent

this modification to the install got me over the line … after 2 years of misery!


Hi folks,

Is it now possible to install ERPnext? My last try was 2 months ago. I want to use the easy install routine.

Has anyone managed to get it running on Ubuntu 18.04 LTS?

thx to all

Hi Curt,

Possible, but no guarantees. Sometimes the easy install works, for some people. Other times it does not. As our comrade @bkm is fond of saying: Your mileage may vary

Many of us have ERPNext successfully running on Ubuntu 18.04 LTS. I’m finishing an installation on that OS right now, actually. But not using the easy install.

Best way to find out is to give it another try.

It did not work, not 24 days ago and not now. I installed SuiteCRM without any problem on the fly to have something. But i want EPRNext :-(:face_with_symbols_over_mouth:

What’s the error message you’re receiving?

[WARNING]: No inventory was parsed, only implicit localhost is available
[WARNING]: provided hosts list is empty, only localhost is available. Note that the implicit localhost does not
match ‘all’
Traceback (most recent call last):
File “”, line 414, in
File “”, line 230, in install_bench
run_playbook(‘site.yml’, sudo=True, extra_vars=extra_vars)
File “”, line 351, in run_playbook
success = subprocess.check_call(args, cwd=os.path.join(cwd, ‘playbooks’), stdout=log_stream, stderr=sys.stderr)
File “/usr/lib/python3.6/”, line 311, 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=frappeuser’]’ returned non-zero exit status 2.

I don’t know enough about Ansible to understand or debug that. Hopefully another forum user does, though!

1 Like

Please do more searching. This topic has been posted on many times. I’m not going to repeat this here.

This issue is that the ansible-playbook command failed.

The suggestion now is to unpack that command into its various components and run it by youself on the command line. You will then see why the command is failing. (The install script is a wrapper and hides the actual error message.)

Thanks. I’ve searched for a solution since 3 to 4 months. All the “professionals” give no exact and detailed guide with step by step, and all the DIY-users try and try and try. What is so difficult for a pro to code a working installer?

Like you: i don’t know how to unpack an installer and merge it in the command line. Are you able to write step by step a guide of how to install ERPNext in Ubuntu 18.04 LTS? I did it in September 2019 ERPNext DNS-Multitenant - disable recursion on the DNS Server - #4 by Curt.Beck, that worked untill something changed, how ever. I did that because there were no working guides. And the official guide also didn’t worked back than.

Thanks for your help.

1 Like

Just scroll up this page. I posted exactly how to do that.

And that’s exactly the need AND the problem - to support numerous platforms, versions, environments and so on but these constantly change! As well, of course this an ambitious product that is a victim of it’s own popularity LOL

Crafter refers to post # 34

1 Like

You need to delete a previous install’s artifacts before doing a fresh install Search results for 'fatal: destination path ‘erpnext’ already exists and is not an empty directory' - Frappe Forum.

Another try with the help of Home · frappe/frappe Wiki · GitHub and How to Install ERPNext on Ubuntu 18.04 - SpeedySense

Fresh ubuntu installation and then step by step:

apt update && apt upgrade -y && apt autoremove -y
ufw allow 22/tcp
ufw enable
ufw allow http
ufw allow https
ufw allow sftp
apt-get install vsftpd
systemctl restart vsftpd
systemctl enable vsftpd
nano /etc/vsftpd.conf


systemctl restart vsftpd
add-apt-repository ppa:nginx/stable
apt-get update
apt-get install nginx
ufw allow ‘Nginx Full’
apt -y install python-minimal
apt -y install git build-essential python-setuptools python-dev libffi-dev libssl-dev
pip install --upgrade pip setuptools
pip install ansible
apt -y install curl
curl -sS | sudo apt-key add -
echo “deb stable main” | sudo tee /etc/apt/sources.list.d/yarn.list
apt -y update && sudo apt -y install yarn
apt -y install mariadb-server libmysqlclient-dev
nano /etc/mysql/my.cnf

character-set-client-handshake = FALSE
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci

default-character-set = utf8mb4

systemctl restart mariadb
systemctl enable mariadb

Set root password? [Y/n] y

curl --silent --location | sudo bash -
sudo apt-get install -y nodejs
apt -y install nginx nodejs redis-server
systemctl start nginx
systemctl enable nginx
systemctl start redis-server
systemctl enable redis-server
apt -y install libxrender1 libxext6 xfonts-75dpi xfonts-base
tar -xf wkhtmltox-0.12.4_linux-generic-amd64.tar.xz -C /opt
ln -s /opt/wkhtmltox/bin/wkhtmltopdf /usr/bin/wkhtmltopdf
ln -s /opt/wkhtmltox/bin/wkhtmltoimage /usr/bin/wkhtmltoimage
adduser beck
usermod -aG sudo beck
login beck
mkdir erpnext
cd erpnext/
sudo apt install virtualenv
virtualenv .
source ./bin/activate
git clone GitHub - frappe/bench: CLI to manage Multi-tenant deployments for Frappe apps bench-repo
sudo pip install -e bench-repo
bench init --frappe-branch master --frappe-path GitHub - frappe/frappe: Low code web framework for real world applications, in Python and Javascript frappe-bench
cd frappe-bench/
bench get-app --branch master erpnext GitHub - frappe/erpnext: Free and Open Source Enterprise Resource Planning (ERP)
bench config dns_multitenant on
sudo mysql -u root -p

UPDATE user SET plugin=‘mysql_native_password’ WHERE User=‘root’;

bench new-site
bench --site install-app erpnext
bench start
bench setup nginx
sudo bench setup production beck
./env/bin/pip install werkzeug==0.16.0
login beck
sudo service supervisor stopp
sudo service supervisor start
sudo supervisorctl status
sudo systemctl enable supervisor
sudo apt install certbot
sudo -H bench setup lets-encrypt
bench --site set-config enable_two_factor_auth true

That worked for me, after 3 months. Maybe someone can check the guide?

1 Like

Not difficult at all. Takes some time and effort. But few wish to spend that time. Or put in that effort. Therefore the installation has been garbage for years. And likely will continue to be, for a while longer.

For this reason, many of us gave up on “easy install” years ago. We either install ERPNext manually, or maintain our own forks of Bench. Or both.

Interesting thread. I watched the progress of this over the past few weeks.

An strange occurence happened to me today with the latest version installation (v12.5.1)

I went to a dormant Ubuntu server that I had running 18.04.3 and I ran the apt-get update and apt-get upgrade to get it up to v18.04.4 and then I ran the install.

It failed with the exact same error that @Curt.Beck posted.

This didn’t make any sense to me so I wiped the server and spun up an fresh ubuntu 18.04.4 image, ran the update and upgrade. Then I ran the same install script again (just like I had an hour earlier) and it worked.

Mind you this is running the Easy Install method!!

To make sure my results were consistent, I wiped another server I had and rand through the same process (on a different VPS service provider) and again ran the update and upgrade and the erpnext easy install script.

This also works perfectly.

Possible Conclusion…

There may be something amiss in the upgrade process of Ubuntu from 18.04.3 to 18.04.4.
When I tried to upgrade to 18.04.4 and run an install it failed.
When I installed a recent 180.0.4 image and then update and upgraded it to most current the ERPNext Easy Install works perfectly.

Is that definitive proof? um… NO

But it is a curious result because I am very meticulous about doing installs and I notice these things.

So that is my results today. Two successful installs when using a fresh Ubuntu image.

However, as always… Your mileage may vary. :sunglasses: