While install ERPNext on Centos7 using easy install, I encountered the errors, when I issued the command sudo python install.py --production --user:

TASK [common : Setup prerequisites using yum] **************************************************************************[DEPRECATION WARNING]: Invoking "yum" only once while using a loop via squash_actions is deprecated. Instead of using a
 loop to supply multiple items and specifying `name: "{{ item }}"`, please use `name: ['bzip2-devel', 'cronie',
'dnsmasq', 'freetype-devel', 'git', 'htop', 'lcms2-devel', 'libjpeg-devel', 'libtiff-devel', 'libffi-devel', 'libwebp-
devel', 'libXext', 'libXrender', 'libzip-devel', 'libffi-devel', 'ntp', 'openssl-devel', 'postfix', 'python36u',
'python-devel', 'python-setuptools', 'python-pip', 'redis', 'screen', 'sudo', 'tcl-devel', 'tk-devel', 'vim', 'which',
'xorg-x11-fonts-75dpi', 'xorg-x11-fonts-Type1', 'zlib-devel', 'openssl-devel', 'openldap-devel', 'libselinux-python',
'cups-libs']` and remove the loop. This feature will be removed in version 2.11. Deprecation warnings can be disabled
by setting deprecation_warnings=False in ansible.cfg.
failed: [localhost] (item=[u'bzip2-devel', u'cronie', u'dnsmasq', u'freetype-devel', u'git', u'htop', u'lcms2-devel', u'libjpeg-devel', u'libtiff-devel', u'libffi-devel', u'libwebp-devel', u'libXext', u'libXrender', u'libzip-devel', u'libffi-devel', u'ntp', u'openssl-devel', u'postfix', u'python36u', u'python-devel', u'python-setuptools', u'python-pip', u'redis', u'screen', u'sudo', u'tcl-devel', u'tk-devel', u'vim', u'which', u'xorg-x11-fonts-75dpi', u'xorg-x11-fonts-Type1', u'zlib-devel', u'openssl-devel', u'openldap-devel', u'libselinux-python', u'cups-libs']) => {"ansible_loop_var": "item", "changed": false, "item": ["bzip2-devel", "cronie", "dnsmasq", "freetype-devel", "git", "htop", "lcms2-devel", "libjpeg-devel", "libtiff-devel", "libffi-devel", "libwebp-devel", "libXext", "libXrender", "libzip-devel", "libffi-devel", "ntp", "openssl-devel", "postfix", "python36u", "python-devel", "python-setuptools", "python-pip", "redis", "screen", "sudo", "tcl-devel", "tk-devel", "vim", "which", "xorg-x11-fonts-75dpi", "xorg-x11-fonts-Type1", "zlib-devel", "openssl-devel", "openldap-devel", "libselinux-python", "cups-libs"], "msg": "yum lockfile is held by another proces
PLAY RECAP *************************************************************************************************************localhost                  : ok=3    changed=0    unreachable=0    failed=1    skipped=1    rescued=0    ignored=0

Traceback (most recent call last):
  File "install.py", line 432, in <module>
  File "install.py", line 128, in install_bench
    run_playbook('site.yml', sudo=True, extra_vars=extra_vars)
  File "install.py", line 344, in run_playbook
    success = subprocess.check_call(args, cwd=os.path.join(cwd, 'playbooks'))
  File "/usr/lib64/python2.7/subprocess.py", line 542, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['ansible-playbook', '-c', 'local', 'site.yml', '-e', '@/tmp/extra_vars.json', '--become', '--become-user=frappe']' returned non-zero exit status 2

Please can you you provide the exact steps or command that led to this error. Thanks


seems yum is blocked by another process

  • ps aux | grep yum

Note the PID number of the process and run this to kill the process:

  • kill

Check to see if the process has been killed by rerunning:

  • ps aux | grep yum

No progress has been seen. Please see the output after running the kill command

–become’, ‘–become-user=frappe’]’ returned non-zero exit status 1
[frappe@erpnext ~]$ ps aux | grep yum
frappe 76920 0.0 0.0 112708 976 pts/0 R+ 05:29 0:00 grep --color=auto yum
[frappe@erpnext ~]$ kill 76920
-bash: kill: (76920) - No such process
[frappe@erpnext ~]$ kill 112708
-bash: kill: (112708) - No such process
[frappe@erpnext ~]$ ps aux | grep yum
frappe 76944 0.0 0.0 112708 980 pts/0 R+ 05:30 0:00 grep --color=auto yum
[frappe@erpnext ~]$ kill 9 76944
-bash: kill: (9) - Operation not permitted
-bash: kill: (76944) - No such process