taigaio/taiga-docker

Errors in taiga-back and taiga-async

MinnML opened this issue · 1 comments

Hello,
I had a taiga docker instance running just fine for couple of years (either 6.4 or 6.5 version). But now, I get errors accessing the instance. I see two errors in the log file and am not sure how to deal with them.

Error 1:

taiga-docker-taiga-back-1             | Executing pending migrations
taiga-docker-taiga-back-1             | Traceback (most recent call last):
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/base/base.py", line 217, in ensure_connection
taiga-docker-taiga-back-1             |     self.connect()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/base/base.py", line 195, in connect
taiga-docker-taiga-back-1             |     self.connection = self.get_new_connection(conn_params)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/postgresql/base.py", line 178, in get_new_connection
taiga-docker-taiga-back-1             |     connection = Database.connect(**conn_params)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/psycopg2/__init__.py", line 127, in connect
taiga-docker-taiga-back-1             |     conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
taiga-docker-taiga-back-1             | psycopg2.OperationalError: could not connect to server: Connection timed out
taiga-docker-taiga-back-1             | 	Is the server running on host "taiga-db" (172.21.0.4) and accepting
taiga-docker-taiga-back-1             | 	TCP/IP connections on port 5432?
taiga-docker-taiga-back-1             | 
taiga-docker-taiga-back-1             | 
taiga-docker-taiga-back-1             | The above exception was the direct cause of the following exception:
taiga-docker-taiga-back-1             | 
taiga-docker-taiga-back-1             | Traceback (most recent call last):
taiga-docker-taiga-back-1             |   File "manage.py", line 17, in <module>
taiga-docker-taiga-back-1             |     execute_from_command_line(sys.argv)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/core/management/__init__.py", line 381, in execute_from_command_line
taiga-docker-taiga-back-1             |     utility.execute()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/core/management/__init__.py", line 375, in execute
taiga-docker-taiga-back-1             |     self.fetch_command(subcommand).run_from_argv(self.argv)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/core/management/base.py", line 323, in run_from_argv
taiga-docker-taiga-back-1             |     self.execute(*args, **cmd_options)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/core/management/base.py", line 364, in execute
taiga-docker-taiga-back-1             |     output = self.handle(*args, **options)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/core/management/base.py", line 83, in wrapped
taiga-docker-taiga-back-1             |     res = handle_func(*args, **kwargs)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/core/management/commands/migrate.py", line 87, in handle
taiga-docker-taiga-back-1             |     executor = MigrationExecutor(connection, self.migration_progress_callback)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/migrations/executor.py", line 18, in __init__
taiga-docker-taiga-back-1             |     self.loader = MigrationLoader(self.connection)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/migrations/loader.py", line 49, in __init__
taiga-docker-taiga-back-1             |     self.build_graph()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/migrations/loader.py", line 212, in build_graph
taiga-docker-taiga-back-1             |     self.applied_migrations = recorder.applied_migrations()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/migrations/recorder.py", line 73, in applied_migrations
taiga-docker-taiga-back-1             |     if self.has_table():
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/migrations/recorder.py", line 56, in has_table
taiga-docker-taiga-back-1             |     return self.Migration._meta.db_table in self.connection.introspection.table_names(self.connection.cursor())
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/base/base.py", line 256, in cursor
taiga-docker-taiga-back-1             |     return self._cursor()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/base/base.py", line 233, in _cursor
taiga-docker-taiga-back-1             |     self.ensure_connection()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/base/base.py", line 217, in ensure_connection
taiga-docker-taiga-back-1             |     self.connect()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/utils.py", line 89, in __exit__
taiga-docker-taiga-back-1             |     raise dj_exc_value.with_traceback(traceback) from exc_value
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/base/base.py", line 217, in ensure_connection
taiga-docker-taiga-back-1             |     self.connect()
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/base/base.py", line 195, in connect
taiga-docker-taiga-back-1             |     self.connection = self.get_new_connection(conn_params)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/django/db/backends/postgresql/base.py", line 178, in get_new_connection
taiga-docker-taiga-back-1             |     connection = Database.connect(**conn_params)
taiga-docker-taiga-back-1             |   File "/opt/venv/lib/python3.7/site-packages/psycopg2/__init__.py", line 127, in connect
taiga-docker-taiga-back-1             |     conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
taiga-docker-taiga-back-1             | django.db.utils.OperationalError: could not connect to server: Connection timed out
taiga-docker-taiga-back-1             | 	Is the server running on host "taiga-db" (172.21.0.4) and accepting
taiga-docker-taiga-back-1             | 	TCP/IP connections on port 5432?
taiga-docker-taiga-back-1             | 

Error 2:

taiga-docker-taiga-async-1            | [2023-05-27 11:17:35,627: INFO/Beat] beat: Starting...
taiga-docker-taiga-async-1            | [2023-05-27 11:17:40,072: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 2.00 seconds... (1/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:17:46,100: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 4.00 seconds... (2/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:17:54,155: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 6.00 seconds... (3/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:18:04,247: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 8.00 seconds... (4/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:18:16,263: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 10.00 seconds... (5/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:18:30,279: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 12.00 seconds... (6/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:18:46,304: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 14.00 seconds... (7/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:19:04,328: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 16.00 seconds... (8/100)
taiga-docker-taiga-async-1            | 
taiga-docker-taiga-async-1            | [2023-05-27 11:19:24,353: ERROR/MainProcess] consumer: Cannot connect to amqp://taiga:**@taiga-async-rabbitmq:5672/taiga: timed out.
taiga-docker-taiga-async-1            | Trying again in 18.00 seconds... (9/100)

Any help is appreciated.

Xenira commented

I had the same problem and no idea what caused it.

After some searching I stumbled over this https://stackoverflow.com/a/66068299.

  1. Remove the deployment using docker compose rm
  2. Remove the taiga network docker network rm taiga-docker_taiga
  3. Redeploy ./launch-taiga.sh && docker compose logs -f
  4. ...
  5. Profit