Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

session: missing session table makes inveniogc fail #3205

Closed
nharraud opened this issue Jun 3, 2015 · 0 comments
Closed

session: missing session table makes inveniogc fail #3205

nharraud opened this issue Jun 3, 2015 · 0 comments
Assignees
Milestone

Comments

@nharraud
Copy link
Member

nharraud commented Jun 3, 2015

This was first reported in EUDAT-B2SHARE/b2share#663

SCENARIO:

  • install invenio and invenio-demosite from branch maint-2.0
  • $ inveniomanage runserver
  • $ inveniogc (in another shell)

Bibsched log:

...
2015-06-02 16:51:37 --> idxWORD01F normal wordtable flush ended
2015-06-02 16:51:37 --> Task #3 finished. [DONE]
2015-06-03 09:35:00 --> Task #3 started.
2015-06-03 09:35:00 --> Deleting expired sessions since 2015-06-03 07:35:00
2015-06-03 09:35:00 --> Task #3 finished. [RUNNING]
2015-06-03 09:35:00 -->
Traceback (most recent call last):
  File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/bibsched/bibtask.py", line 615, in task_init
    ret = _task_run(task_run_fnc)
  File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/bibsched/bibtask.py", line 1191, in _task_run
    if callable(task_run_fnc) and task_run_fnc():
  File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/websession/inveniogc.py", line 676, in task_run_core
    clean_sessions()
  File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/websession/inveniogc.py", line 340, in clean_sessions
    deleted_sessions += run_sql(query, (timelimit,))
  File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/dbquery_mysql.py", line 268, in run_sql
    rc = cur.execute(sql, param)
  File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/lib/python2.7/site-packages/MySQLdb/cursors.py", line 205, in execute
    self.errorhandler(self, exc, value)
  File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/lib/python2.7/site-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
    raise errorclass, errorvalue
ProgrammingError: (1146, "Table 'inv_maint_2_0.session' doesn't exist")
2015-06-03 09:35:00 --> Unexpected error occurred: (1146, "Table 'inv_maint_2_0.session' doesn't exist").
2015-06-03 09:35:00 --> Traceback is:
2015-06-03 09:35:00 -->   File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/bibsched/bibtask.py", line 615, in task_init
2015-06-03 09:35:00 -->     ret = _task_run(task_run_fnc)
2015-06-03 09:35:00 -->   File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/bibsched/bibtask.py", line 1191, in _task_run
2015-06-03 09:35:00 -->     if callable(task_run_fnc) and task_run_fnc():
2015-06-03 09:35:00 -->   File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/websession/inveniogc.py", line 676, in task_run_core
2015-06-03 09:35:00 -->     clean_sessions()
2015-06-03 09:35:00 -->   File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/websession/inveniogc.py", line 340, in clean_sessions
2015-06-03 09:35:00 -->     deleted_sessions += run_sql(query, (timelimit,))
2015-06-03 09:35:00 -->   File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/src/invenio/invenio/legacy/dbquery_mysql.py", line 268, in run_sql
2015-06-03 09:35:00 -->     rc = cur.execute(sql, param)
2015-06-03 09:35:00 -->   File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/lib/python2.7/site-packages/MySQLdb/cursors.py", line 205, in execute
2015-06-03 09:35:00 -->     self.errorhandler(self, exc, value)
2015-06-03 09:35:00 -->   File "/Users/nharraud/.virtualenvs/invenio-maint-2.0/lib/python2.7/site-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
2015-06-03 09:35:00 -->     raise errorclass, errorvalue
2015-06-03 09:35:00 --> Exiting.

As we now use redis to store sessions, the session table is not created.

@jirikuncar jirikuncar added this to the v2.0.5 milestone Jun 3, 2015
nharraud pushed a commit to nharraud/invenio that referenced this issue Jun 3, 2015
* FIX Fixes inveniogc crash when mysql is NOT used to store sessions.
  (closes inveniosoftware#3205)

Signed-off-by: Nicolas Harraudeau <[email protected]>
nharraud pushed a commit to nharraud/invenio that referenced this issue Jun 9, 2015
* FIX Fixes inveniogc crash when mysql is NOT used to store sessions.
  (closes inveniosoftware#3205)

Signed-off-by: Nicolas Harraudeau <[email protected]>
Reviewed-by: Jiri Kuncar <[email protected]>
nharraud pushed a commit to nharraud/invenio that referenced this issue Jun 9, 2015
* FIX Fixes inveniogc crash when mysql is NOT used to store sessions.
  (closes inveniosoftware#3205)

Signed-off-by: Nicolas Harraudeau <[email protected]>
Reviewed-by: Jiri Kuncar <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants