server icon indicating copy to clipboard operation
server copied to clipboard

Waiting for it to start

Open heredia21 opened this issue 2 years ago • 6 comments

http://localhost:3000/ is inaccessible, logs have been stuck on the following for the past 20 mins:

==> logs/syncing-server-worker.log <== localhost:3101 is unavailable yet - waiting for it to start

==> logs/revisions-worker.log <== localhost:3101 is unavailable yet - waiting for it to start

==> logs/revisions.log <== db:3306 is unavailable yet - waiting for it to start

==> logs/syncing-server.log <== db:3306 is unavailable yet - waiting for it to start

==> logs/files.log <== db:3306 is unavailable yet - waiting for it to start

heredia21 avatar Mar 03 '23 11:03 heredia21

It seems like database is not up. You should check state and log of database first.

jackyzy823 avatar Mar 04 '23 02:03 jackyzy823

how?

-------- Original Message -------- On Mar 3, 2023, 8:42 PM, jackyzy823 - notifications at github.com wrote:

It seems like database is not up. You should check state and log of database first.

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

heredia21 avatar Mar 04 '23 03:03 heredia21

check state: docker-compose ps

show log: docker-compose logs db

jackyzy823 avatar Mar 04 '23 09:03 jackyzy823

$ docker compose  ps
NAME                     IMAGE                       COMMAND                  SERVICE             CREATED             STATUS                          PORTS
cache_self_hosted        redis:6.0-alpine            "docker-entrypoint.s…"   cache               2 minutes ago       Up 2 minutes                    6379/tcp
db_self_hosted           mysql:8                     "docker-entrypoint.s…"   db                  2 minutes ago       Restarting (1) 30 seconds ago   
localstack_self_hosted   localstack/localstack:1.3   "docker-entrypoint.sh"   localstack          2 minutes ago       Up 2 minutes (healthy)          4510-4559/tcp, 4566/tcp, 5678/tcp
server_self_hosted       standardnotes/server        "docker-entrypoint.sh"   server              2 minutes ago       Up 2 minutes                    0.0.0.0:3000->3000/tcp, :::3000->3000/tcp, 0.0.0.0:3125->3104/tcp, :::3125->3104/tcp
$ docker compose logs db
db_self_hosted  | 2023-03-04 23:57:37+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.32-1.el8 started.
db_self_hosted  | 2023-03-04 23:57:38+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
db_self_hosted  | 2023-03-04 23:57:38+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.32-1.el8 started.
db_self_hosted  | 2023-03-04 23:57:38+00:00 [Note] [Entrypoint]: Initializing database files
db_self_hosted  | 2023-03-04T23:57:39.024816Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
db_self_hosted  | 2023-03-04T23:57:39.025039Z 0 [Warning] [MY-010918] [Server] 'default_authentication_plugin' is deprecated and will be removed in a future release. Please use authentication_policy instead.
db_self_hosted  | 2023-03-04T23:57:39.025078Z 0 [System] [MY-013169] [Server] /usr/sbin/mysqld (mysqld 8.0.32) initializing of server in progress as process 80
db_self_hosted  | 2023-03-04T23:57:39.029521Z 0 [ERROR] [MY-010457] [Server] --initialize specified but the data directory has files in it. Aborting.
db_self_hosted  | 2023-03-04T23:57:39.029539Z 0 [ERROR] [MY-013236] [Server] The designated data directory /var/lib/mysql/ is unusable. You can remove all files that the server added to it.
db_self_hosted  | 2023-03-04T23:57:39.029683Z 0 [ERROR] [MY-010119] [Server] Aborting
db_self_hosted  | 2023-03-04T23:57:39.030027Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.32)  MySQL Community Server - GPL.

heredia21 avatar Mar 04 '23 23:03 heredia21

root cause --initialize specified but the data directory has files in it. Aborting.

either 1 remove this parameter from db's command line or 2. create a new database in other path.

jackyzy823 avatar Mar 05 '23 03:03 jackyzy823

Maybe I did the same error as @heredia21 did. My mistake was that I copied the the legacy uploads from legacy/data/uploads to the wrong target sv2/data/uploads. The correct target is sv2/uploads (see Migration Guide)

e1025735 avatar May 02 '23 09:05 e1025735