Installation help (non-zero exit status 100) - E: Unable to acquire the dpkg frontend lock

lok@abc-computer:~$ sudo -H apt-get install python3-minimal
Reading package lists… Done
Building dependency tree
Reading state information… Done
python3-minimal is already the newest version (3.6.7-1~18.04).
0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.
lok@abc-computer:~$ sudo -H apt-get install python3-setuptools
Reading package lists… Done
Building dependency tree
Reading state information… Done
python3-setuptools is already the newest version (39.0.1-2).
0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.
lok@abc-computer:~$ sudo -H apt-get install build-essential
Reading package lists… Done
Building dependency tree
Reading state information… Done
build-essential is already the newest version (12.4ubuntu1).
0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.
lok@abc-computer:~$ sudo -H apt-get install redis-server
Reading package lists… Done
Building dependency tree
Reading state information… Done
redis-server is already the newest version (5:4.0.9-1ubuntu0.2).
0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.
lok@abc-computer:~$ wget https://raw.githubusercontent.com/frappe/bench/master/playbooks/install.py
–2020-01-23 23:04:39-- https://raw.githubusercontent.com/frappe/bench/master/playbooks/install.py
Resolving raw.githubusercontent.com (raw.githubusercontent.com)… 151.101.156.133
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|151.101.156.133|:443… connected.
HTTP request sent, awaiting response… 200 OK
Length: 14831 (14K) [text/plain]
Saving to: ‘install.py’
install.py 100%[==============>] 14.48K --.-KB/s in 0.1s
2020-01-23 23:04:40 (113 KB/s) - ‘install.py’ saved [14831/14831]
lok@abc-computer:~$ sudo -H python3 install.py --production --user lok
Logs are saved under /tmp/logs/easy-install__2020-01-23__17-34.log
Checking System Compatibility…
ubuntu 18 is compatible!
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?
Traceback (most recent call last):
File “install.py”, line 413, in
install_prerequisites()
File “install.py”, line 122, in install_prerequisites
‘sudo yum install -y epel-release redhat-lsb-core git python-setuptools python-devel openssl-devel libffi-devel’
File “install.py”, line 107, in run_os_command
returncode = subprocess.check_call(command, shell=True, stdout=log_stream, stderr=sys.stderr)
File “/usr/lib/python3.6/subprocess.py”, line 311, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command ‘sudo apt-get install -y git build-essential python3-setuptools python3-dev libffi-dev’ returned non-zero exit status 100.
lok@abc-computer:~$

@bkm I followed your steps from here (error-on-erpnext-ubuntu-18-04-lts-installation)
and I got this error. Any help?

“This method will work just fine 99% of time.”

1 Like

About 10 days ago the install script and playbooks were fixed so that those temporary instructions were no longer needed. Sadly, it appears that a new set of issues have reared their ugly head and again it will take another pioneer to find a workaround set of instructions.

Although everything that goes into the forum makes sense at the time of it’s publishing, the pace and nature of erpnext/frappe changes frequently renders any workarounds useless in a very short period of time. Likewise, those instructions are likely no longer valid.

Additionally, after another very short period of time, any of yours or mine original posts lose their edit icon and cannot be revisited to be changed. This “feature” of the forum script creates a condition where expired or bad information (that was once good) cannot be edited by the originator and it is left there for others to stumble across later.

The post you sited falls into that same trap. I can no longer edit it.

BKM

Wiped system > installed Bench and Frappe (official documentation). But now I am stuck with another issue.
Installed Bench and Frappe successfully > new site “lok.local” but cannot install the “erpnext” app over it.
Downloaded it via "bench get-app erpnext GitHub - frappe/erpnext: Free and Open Source Enterprise Resource Planning (ERP) "
After cloning it, it runs the build command and that where it gets stuck.
The error:

INFO:bench.utils:bench build --app erpnext
yarn run v1.21.1
$ FRAPPE_ENV=production node rollup/build.js --app erpnext
module.js:549
throw err;
^
Error: Cannot find module ‘chalk’
at Function.Module._resolveFilename (module.js:547:15)
at Function.Module._load (module.js:474:25)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at Object. (/home/lok/frappe-bench/apps/frappe/rollup/build.js:3:15)
at Module._compile (module.js:652:30)
at Object.Module._extensions…js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
error Command failed with exit code 1.
info Visit yarn run | Yarn for documentation about this command.

Used these commands and fixed it

Step 1: bench setup socketio
Step 2: bench setup requirements

But I cannot run the command

bench setup production
#output
WARN: superuser privileges required for this command

when I run the command with sudo

sudo bench setup production
#output
sudo: bench: command not found

sudo pip install -e bench-repo

Running this command solved it.