Fresh install of v2.0.0 - throws error No such file or directory


#1

Hi,

After installing the v.2.0.0 and setting up the admin user I get the below error when I try to open web page.

root@b4f9b675769e:/var/log/supervisor# cat  redash_server-stderr---supervisor-Oto70U.log
[2017-08-14 22:46:37 +0000] [10] [INFO] Starting gunicorn 19.4.5
[2017-08-14 22:46:37 +0000] [10] [INFO] Listening at: http://0.0.0.0:5000 (10)
[2017-08-14 22:46:37 +0000] [10] [INFO] Using worker: sync
[2017-08-14 22:46:37 +0000] [38] [INFO] Booting worker with pid: 38
[2017-08-14 22:46:37 +0000] [41] [INFO] Booting worker with pid: 41
[2017-08-14 22:46:37 +0000] [44] [INFO] Booting worker with pid: 44
[2017-08-14 22:46:37 +0000] [46] [INFO] Booting worker with pid: 46
[2017-08-14 22:46:38,066][PID:38][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/Grammar.txt
[2017-08-14 22:46:38,084][PID:38][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/PatternGrammar.txt
[2017-08-14 22:46:38,262][PID:44][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/Grammar.txt
[2017-08-14 22:46:38,290][PID:41][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/Grammar.txt
[2017-08-14 22:46:38,309][PID:41][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/PatternGrammar.txt
[2017-08-14 22:46:38,310][PID:44][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/PatternGrammar.txt
[2017-08-14 22:46:38,517][PID:46][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/Grammar.txt
[2017-08-14 22:46:38,558][PID:46][INFO][root] Generating grammar tables from /usr/lib/python2.7/lib2to3/PatternGrammar.txt
[2017-08-14 22:48:48,348] ERROR in app: Exception on / [GET]
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1988, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1641, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python2.7/dist-packages/flask_restful/__init__.py", line 271, in error_router
    return original_handler(e)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1544, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1639, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1625, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/local/lib/python2.7/dist-packages/flask_login/utils.py", line 228, in decorated_view
    return func(*args, **kwargs)
  File "/opt/redash/redash.2.0.0/redash/handlers/static.py", line 41, in index
    return render_index()
  File "/opt/redash/redash.2.0.0/redash/handlers/static.py", line 34, in render_index
    response = send_file(full_path, **dict(cache_timeout=0, conditional=True))
  File "/usr/local/lib/python2.7/dist-packages/flask/helpers.py", line 536, in send_file
    file = open(filename, 'rb')
IOError: [Errno 2] No such file or directory: '/opt/redash/redash.2.0.0/redash/../client/dist/index.html'

Please note that there is no dist/index.html in the path:

root@b4f9b675769e:/opt/redash/redash.2.0.0/client# tree -L 2
.
`-- app
    |-- assets
    |-- components
    |-- directives
    |-- filters
    |-- index.html
    |-- index.js
    |-- multi_org.html
    |-- pages
    |-- services
    |-- sortable.js
    |-- utils
    `-- visualizations

9 directories, 4 files

Is in installation package something missing ?
For the install I used https://github.com/getredash/redash/archive/v2.0.0.tar.gz

Please could someone advise ?

Regards,
Constantin


#2

You used a copy of the source code, but that’s not the release. It’s just the source.

You can use the tar balls we link to from the version API (https://version.redash.io/API/releases).


#3

Thanks @arikfr for pointing out. I will try to use the link provided by you.

As a side note, I checked the getting started guide and didn’t find any reference of where to get the latest v2.0.0 (or a list of available) releases. As I mentioned in another reported issue - the provisioning scripts download the old version.


#4

@arikfr

I just installed a new redash 2.0.0 from suggested tarball https://s3.amazonaws.com/redash-releases/redash.2.0.0.b2990.tar.gz and I still get the below error upon first registration of Admin via web.

System is Ubuntu 16.04

[2017-08-15 09:25:27,698][PID:40][INFO][metrics] method=POST path=/setup endpoint=redash_setup status=302 content_type=text/html; charset=utf-8 content_length=209 duration=172.65 query_count=5 query_duration=21.42
[2017-08-15 09:25:27,770] ERROR in app: Exception on / [GET]
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1988, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1641, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python2.7/dist-packages/flask_restful/__init__.py", line 271, in error_router
    return original_handler(e)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1544, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1639, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1625, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/local/lib/python2.7/dist-packages/flask_login/utils.py", line 228, in decorated_view
    return func(*args, **kwargs)
  File "/opt/redash/redash.2.0.0/redash/handlers/static.py", line 41, in index
    return render_index()
  File "/opt/redash/redash.2.0.0/redash/handlers/static.py", line 34, in render_index
    response = send_file(full_path, **dict(cache_timeout=0, conditional=True))
  File "/usr/local/lib/python2.7/dist-packages/flask/helpers.py", line 536, in send_file
    file = open(filename, 'rb')
IOError: [Errno 2] No such file or directory: '/opt/redash/redash.2.0.0/redash/../client/dist/index.html'
[2017-08-15 09:25:27,770][PID:45][ERROR][redash] Exception on / [GET]
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1988, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1641, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python2.7/dist-packages/flask_restful/__init__.py", line 271, in error_router
    return original_handler(e)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1544, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1639, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1625, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/local/lib/python2.7/dist-packages/flask_login/utils.py", line 228, in decorated_view
    return func(*args, **kwargs)
  File "/opt/redash/redash.2.0.0/redash/handlers/static.py", line 41, in index
    return render_index()
  File "/opt/redash/redash.2.0.0/redash/handlers/static.py", line 34, in render_index
    response = send_file(full_path, **dict(cache_timeout=0, conditional=True))
  File "/usr/local/lib/python2.7/dist-packages/flask/helpers.py", line 536, in send_file
    file = open(filename, 'rb')
IOError: [Errno 2] No such file or directory: '/opt/redash/redash.2.0.0/redash/../client/dist/index.html'
[2017-08-15 09:25:27,774][PID:45][INFO][metrics] method=GET path=/ endpoint=redash_index status=500 content_type=? content_length=-1 duration=12.42 query_count=2 query_duration=4.63
[2017-08-15 09:25:28,067][PID:37][INFO][metrics] method=GET path=/favicon.ico endpoint=redash_send_static status=404 content_type=text/html content_length=233 duration=1.28 query_count=0 query_duration=0.00

and I don’s see the dist sub-folder under client created.

root@deb5c3840e9d:/opt/redash/current/client# tree -L 2
.
`-- app
    |-- assets
    |-- components
    |-- directives
    |-- filters
    |-- index.html
    |-- index.js
    |-- multi_org.html
    |-- pages
    |-- services
    |-- sortable.js
    |-- utils
    `-- visualizations

Any thoughts how to fix this ?

Thanks & Regards,
Constantin


#5

Apologies @arikfr , I guess I found the problem. I was still using old image build from source tarball and not from release :blush:

This issue can be considered closed.