[SOLVED] Unable to update Seafile CE 13.0.18

Hi, I updated my seafile CE instance from v12 to v13 without issue some month ago. I’m actually on v13.0.12 thats works fine.

I’m using a docker compose stack with Traefik as reverse proxy since CE v11.

When I’m trying to update to v13.0.18 I can’t access anymore to my seafile instance. When I check my seafile docker health status I got :

docker inspect seafile --format '{{.State.Health.Status}}'
unhealthy

I tried to check logs :

seahub.error.log

2026/02/19 16:57:44 [error] 49#49: *47 upstream prematurely closed connection while reading response header from upstream, client: 127.0.0.1, server: , request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:8000/", host: "localhost"

seahub.log

full error log

[ERROR] django.request:253 log_response Internal Server Error: /api/v2.1/all-notifications/
Traceback (most recent call last):
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/backends/utils.py”, line 105, in _execute
return self.cursor.execute(sql, params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/backends/mysql/base.py”, line 76, in execute
return self.cursor.execute(query, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/dist-packages/MySQLdb/cursors.py”, line 179, in execute
res = self._query(mogrified_query)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/dist-packages/MySQLdb/cursors.py”, line 330, in _query
db.query(q)
File “/usr/local/lib/python3.12/dist-packages/MySQLdb/connections.py”, line 280, in query
_mysql.connection.query(self, query)
MySQLdb.ProgrammingError: (1146, “Table ‘seahub_db.sdoc_notification’ doesn’t exist”)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/core/handlers/exception.py”, line 55, in inner
response = get_response(request)
^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/core/handlers/base.py”, line 197, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/views/decorators/csrf.py”, line 65, in _view_wrapper
return view_func(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/views/generic/base.py”, line 105, in view
return self.dispatch(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/rest_framework/views.py”, line 515, in dispatch
response = self.handle_exception(exc)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/rest_framework/views.py”, line 475, in handle_exception
self.raise_uncaught_exception(exc)
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/rest_framework/views.py”, line 486, in raise_uncaught_exception
raise exc
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/rest_framework/views.py”, line 512, in dispatch
response = handler(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/seahub/api2/endpoints/notifications.py”, line 311, in get
sdoc_result_notices = update_sdoc_notice_detail(sdoc_notice_list)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/seahub/notifications/utils.py”, line 409, in update_sdoc_notice_detail
for notice in notices:
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/models/query.py”, line 384, in iter
self._fetch_all()
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/models/query.py”, line 1949, in _fetch_all
self._result_cache = list(self._iterable_class(self))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/models/query.py”, line 91, in iter
results = compiler.execute_sql(
^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/models/sql/compiler.py”, line 1623, in execute_sql
cursor.execute(sql, params)
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/backends/utils.py”, line 79, in execute
return self._execute_with_wrappers(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/backends/utils.py”, line 92, in _execute_with_wrappers
return executor(sql, params, many, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/backends/utils.py”, line 100, in _execute
with self.db.wrap_database_errors:
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/utils.py”, line 91, in exit
raise dj_exc_value.with_traceback(traceback) from exc_value
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/backends/utils.py”, line 105, in _execute
return self.cursor.execute(sql, params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/opt/seafile/seafile-server-13.0.12/seahub/thirdpart/django/db/backends/mysql/base.py”, line 76, in execute
return self.cursor.execute(query, args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/dist-packages/MySQLdb/cursors.py”, line 179, in execute
res = self._query(mogrified_query)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/dist-packages/MySQLdb/cursors.py”, line 330, in _query
db.query(q)
File “/usr/local/lib/python3.12/dist-packages/MySQLdb/connections.py”, line 280, in query
_mysql.connection.query(self, query)
django.db.utils.ProgrammingError: (1146, “Table ‘seahub_db.sdoc_notification’ doesn’t exist”)

When I downgrade to v13.0.12 from v13.0.18 it works well again …

I don’t use seadoc or notification server

Have someone have this issue ?

A few days ago I did that same upgrade, and had a similar problem. For me the clue was a couple of screens up in the seahub.log:

[2026-02-16 23:33:52] [ERROR] django.security.DisallowedHost:253 log_response Invalid HTTP_HOST header: 'localhost'.
 You may need to add 'localhost' to ALLOWED_HOSTS.

I think seafile was actually working, but the health check was failing because it wasn’t allowed to connect. Like it says, my “ALLOWED_HOSTS” in the seahub_settings.py had “127.0.0.1”, but not “localhost”, so I added “localhost” and it started working again. I don’t know what changed between version to go from needing 127.0.0.1 to needing “localhost”, but hopefully having both in there will keep it working if it changes again in the future.

If that isn’t what’s happening to you, you will want to check all the logs (seafile.log, fileserver.log, seahub.log, nginx’s logs, etc.) for clues.

I tried to reinstall from scratch v13.0.18 (withtout my old data folder mounted on my device) and I had the same error … For the moment only the v13.0.12 works for me.

I can’t find what changed after this version. When I try to do the healtcheck inside the seafile container I get :

root@xxxx:/opt/seafile# curl -f http://localhost:80
curl: (22) The requested URL returned error: 502

I can’t understand why I have this error with seahub on a fresh install :

error] 39#39: *13 upstream prematurely closed connection while reading response header from upstream, client: 127.0.0.1, server: , request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:8000/", host: "localhost" 

I didn’t find anything revelant in logs

So nginx is starting but it isn’t able to communicate with seafile. Purely a guess, but maybe you are having this problem with the docker image including an incompatible library.

You can also try adding “DEBUG = True” to your seahub_settings.py, and restart seahub. That should make it log some more stuff, some of which might be helpful.

Thanks for your response, please can you share your seahub_settings.py please (without your secret) ? I would like to compare whats wrong in mine

The only error I can see in seafile-monitor.log :

/opt/seafile/seafile-server-13.0.18/seafile-monitor.sh: line 242:   638 Illegal instruction     (core dumped) $PYTHON -m seafevents.main --config-file ${SEAFILE_CENTRAL_CONF_DIR}/seafevents.conf --logfile ${TOPDIR}/logs/seafevents.log -P ${TOPDIR}/pids/seafevents.pid

My seahub.log file is empty

Well it seems that my CPU is too old (Intel(R) Atom™ CPU N2800) to handle Numpy. I’ll try to update my setup.

Thanks