ERPNext Install Errors

Trying Frappe Bench on a new install through the easy install and setup for production.

I am getting the following error:

sudo bash setup_frappe.sh --setup-production
Installing for Ubuntu trusty amd64
In case you encounter an error, you can post on https://discuss.frappe.io

Adding ubuntu mariadb repo
Installing packages for Ubuntu. This might take time…
Installing wkhtmltopdf

  • Stopping MariaDB database server mysqld [ OK ]
  • Starting MariaDB database server mysqld [ OK ]
  • Checking for corrupt, not cleanly closed and upgrade needing tables.
    Adding frappe user
    Installing frappe-bench
    Already using interpreter /usr/bin/python
    INFO:bench.app:getting app frappe
    Cloning into ‘frappe’…
    INFO:bench.app:installing frappe
    /home/tilak/frappe-bench/env/local/lib/python2.7/site-packages/pip/vendor/requests/packages/urllib3/util/ssl.py:315: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#snimissingwarning.
    SNIMissingWarning
    /home/tilak/frappe-bench/env/local/lib/python2.7/site-packages/pip/vendor/requests/packages/urllib3/util/ssl.py:120: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
    InsecurePlatformWarning
    INFO:urllib3.connectionpool:Starting new HTTPS connection (1): raw.githubusercontent.com
    DEBUG:urllib3.connectionpool:Setting read timeout to None
    DEBUG:urllib3.connectionpool:“GET /frappe/bench/master/install_scripts/erpnext-apps-master.json HTTP/1.1” 200 101
    INFO:bench.app:getting app erpnext
    Cloning into ‘erpnext’…
    INFO:bench.app:installing erpnext
    /home/tilak/frappe-bench/env/local/lib/python2.7/site-packages/pip/vendor/requests/packages/urllib3/util/ssl.py:315: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#snimissingwarning.
    SNIMissingWarning
    /home/tilak/frappe-bench/env/local/lib/python2.7/site-packages/pip/vendor/requests/packages/urllib3/util/ssl.py:120: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
    InsecurePlatformWarning
    /bin/sh: 1: npm: not found
    installing frappe
    installing erpnext
    Traceback (most recent call last):
    File “/usr/local/bin/bench”, line 9, in
    load_entry_point(‘bench==2.0.0’, ‘console_scripts’, ‘bench’)()
    File “/home/tilak/bench-repo/bench/cli.py”, line 40, in cli
    bench_command()
    File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 716, in call
    return self.main(*args, **kwargs)
    File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 696, in main
    rv = self.invoke(ctx)
    File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 1060, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
    File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 889, in invoke
    return ctx.invoke(self.callback, **ctx.params)
    File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 534, in invoke
    return callback(*args, **kwargs)
    File “/home/tilak/bench-repo/bench/commands/make.py”, line 17, in init
    no_auto_update=no_auto_update, frappe_path=frappe_path, frappe_branch=frappe_branch, verbose=verbose)
    File “/home/tilak/bench-repo/bench/utils.py”, line 69, in init
    setup_socketio(bench=path)
    File “/home/tilak/bench-repo/bench/utils.py”, line 109, in setup_socketio
    exec_cmd(“npm install socket.io redis express superagent cookie”, cwd=bench)
    File “/home/tilak/bench-repo/bench/utils.py”, line 99, in exec_cmd
    raise CommandFailedError(cmd)
    bench.utils.CommandFailedError: npm install socket.io redis express superagent cookie

If I run bench update I get the following error:

tilak@myERPNext:~$ bench update
Traceback (most recent call last):
File “/usr/local/bin/bench”, line 9, in
load_entry_point(‘bench==2.0.0’, ‘console_scripts’, ‘bench’)()
File “/home/tilak/bench-repo/bench/cli.py”, line 40, in cli
bench_command()
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 716, in call
return self.main(*args, **kwargs)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 696, in main
rv = self.invoke(ctx)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 534, in invoke
return callback(*args, **kwargs)
File “/home/tilak/bench-repo/bench/commands/update.py”, line 26, in update
deprecate_old_config(".")
File “/home/tilak/bench-repo/bench/config/common_site_config.py”, line 145, in deprecate_old_config
put_config(config, bench_path)
File “/home/tilak/bench-repo/bench/config/common_site_config.py”, line 38, in put_config
with open(config_path, ‘w’) as f:
IOError: [Errno 2] No such file or directory: ‘./sites/common_site_config.json’

Today’s bench update has the following progress:
First the Error:

frappe-bench-node-socketio: ERROR (abnormal termination)

Now the whole dump:

tilak@myERPNext:~/frappe-bench$ bench update
INFO:bench.utils:updating bench
Already up-to-date.
Requirement already satisfied (use --upgrade to upgrade): Pillow in ./env/lib/python2.7/site-packages
INFO:bench.app:pulling frappe
From https://github.com/frappe/frappe

  • branch master -> FETCH_HEAD
    Already up-to-date.
    INFO:bench.app:pulling erpnext
    From https://github.com/frappe/erpnext
  • branch master -> FETCH_HEAD
    Already up-to-date.
    /home/tilak/frappe-bench/env/local/lib/python2.7/site-packages/pip/vendor/requests/packages/urllib3/util/ssl.py:315: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#snimissingwarning.
    SNIMissingWarning
    /home/tilak/frappe-bench/env/local/lib/python2.7/site-packages/pip/vendor/requests/packages/urllib3/util/ssl.py:120: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
    InsecurePlatformWarning
    Requirement already up-to-date: pip in ./env/lib/python2.7/site-packages
    Wrote ./assets/js/print_format_v3.min.js - 18k
    Wrote ./assets/js/frappe-web.min.js - 101k
    Wrote ./assets/js/form.min.js - 111k
    Wrote ./assets/js/report.min.js - 157k
    Wrote ./assets/js/erpnext.min.js - 35k
    Wrote ./assets/css/list.min.css - 6k
    Wrote ./assets/js/erpnext-web.min.js - 1k
    Wrote ./assets/css/report.min.css - 7k
    Wrote ./assets/css/frappe-web.css - 51k
    Wrote ./assets/js/list.min.js - 66k
    Wrote ./assets/js/dialog.min.js - 58k
    Wrote ./assets/js/desk.min.js - 875k
    Wrote ./assets/css/form.min.css - 2k
    Wrote ./assets/js/editor.min.js - 26k
    Wrote ./assets/css/erpnext.css - 1k
    Wrote ./assets/css/desk.min.css - 256k
    Wrote ./assets/css/module.min.css - 2k
    [sudo] password for tilak:
    frappe-bench-frappe-async-worker: stopped
    frappe-bench-frappe-longjob-worker: stopped
    frappe-bench-frappe-workerbeat: stopped
    frappe-bench-frappe-web: stopped
    frappe-bench-frappe-worker: stopped
    frappe-bench-frappe-async-worker: started
    frappe-bench-frappe-longjob-worker: started
    frappe-bench-frappe-workerbeat: started
    frappe-bench-frappe-web: started
    frappe-bench-frappe-worker: started
    frappe-bench-node-socketio: ERROR (abnormal termination)

Bench: Open source installer + admin for Frappe and ERPNext (https://erpnext.com)

I’m getting the same node socket.io abnormal termination.

@JayRam I was not able to debug this issue. Check this thread: [Important] Bench version 2 - see this before you run bench update

You will need to see the logs in frappe-bench/logs and find out if there are specific error messages related to this. Look for any problems in redis-queue’s logs.

Or just create a new bench using bench init and try

Here’s the error from node-socketio.error.log file:

Thanks

Jay

module.js:340
throw err;
^
Error: Cannot find module ‘express’
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.
(/home/tilak/frappe-bench/apps/frappe/socketio.js:1:73)
at Module._compile (module.js:456:26)
at Object.Module._extensions…js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Function.Module.runMain (module.js:497:10)

And here’s the error from redis-cache.log & redis-queue.log:

[2191] 25 Mar 22:18:20.560 # Fatal error, can’t open config file
‘/home/tilak/frappe-bench/config/redis_cache.conf’

And here’s the error from redis-socketio.log:

[2192] 25 Mar 22:18:20.570 # Fatal error, can’t open config file
‘/home/tilak/frappe-bench/config/redis_socketio.conf’

And here’s the error from workerbeat.error.log:

[2016-03-24 08:01:33,281: ERROR/MainProcess] beat: Connection error: .
Trying again in 22.0 seconds…

Don’t know if that helps.

Thanks

Jay

Incidentally those two files don’t seem to be there. I will create blank
files and see if things change.

Thanks

Jay

@JayRam your socketio installation looks to be problematic. Try running bench setup socketio

same problem on fresh install, after “bench setup socketio” this is what i get:

vmdbn-erpnext:~$ bench setup socketio
/bin/sh: 1: npm: not found
Traceback (most recent call last):
File “/usr/local/bin/bench”, line 9, in
load_entry_point(‘bench==2.0.0’, ‘console_scripts’, ‘bench’)()
File “/home/user/bench-repo/bench/cli.py”, line 40, in cli
bench_command()
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 716, in call
return self.main(*args, **kwargs)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 696, in main
rv = self.invoke(ctx)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 534, in invoke
return callback(*args, **kwargs)
File “/home/user/bench-repo/bench/commands/setup.py”, line 77, in setup_socketio
setup_socketio()
File “/home/user/bench-repo/bench/utils.py”, line 109, in setup_socketio
exec_cmd(“npm install socket.io redis express superagent cookie”, cwd=bench)
File “/home/user/bench-repo/bench/utils.py”, line 99, in exec_cmd
raise CommandFailedError(cmd)
bench.utils.CommandFailedError: npm install socket.io redis express superagent cookie

I reinstalled Ubuntu, taking care to ensure that I used the 32 bit version
(wasn’t sure first time around) and it went though without any problems.

Thanks

Jay

I replace debian with CentOS… :stuck_out_tongue:

This topic might have a working solution: