Skip to content

bug: can not log in after restart #300

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

Open
Xiguaalex opened this issue May 6, 2025 · 10 comments
Open

bug: can not log in after restart #300

Xiguaalex opened this issue May 6, 2025 · 10 comments

Comments

@Xiguaalex
Copy link

Xiguaalex commented May 6, 2025

Current Behavior

After installed successfully, I can login the dashboard.
But after restart the computer, it always login failed. My system is Ubuntu24.04.
And this is the log from terminal:
? Question: Please select the program you want to install:
➜ Point: 1. APIPark Dashboard and Node (API Gateway)
➜ Point: 2. Only APIPark Dashboard
➜ Point: 3. Only APIPark Node (API Gateway)
1
? Question: Container apipark-mysql already exists. Do you want to reinstall container? (yes/no)
NO
? Question: Container apipark-mysql already exists. Do you want to reinstall container? (yes/no)
NO
? Question: Container apipark-mysql already exists. Do you want to reinstall container? (yes/no)
no

────────────────────────────────────────────────────────────
? Question: Container apipark-redis already exists. Do you want to reinstall container? (yes/no)
no

────────────────────────────────────────────────────────────
? Question: Container apipark-influxdb already exists. Do you want to reinstall container? (yes/no)
no

────────────────────────────────────────────────────────────
? Question: Container apipark-loki already exists. Do you want to reinstall container? (yes/no)
no

────────────────────────────────────────────────────────────
? Question: Container apipark-grafana already exists. Do you want to reinstall container? (yes/no)
no

────────────────────────────────────────────────────────────
? Question: Container apipark-nsq already exists. Do you want to reinstall container? (yes/no)
no

────────────────────────────────────────────────────────────
? Question: Container apipark already exists. Do you want to reinstall container? (yes/no)
no

────────────────────────────────────────────────────────────
ℹ Info: Updating apipark openapi address...
ℹ Info: curl -s -i -H "Content-Type: application/json" -d "{"name":"admin","password":"ooD7Yoh4"}" http://192.168.3.34:18288/api/v1/account/login/username
quick-start.sh: line 1185: [: : integer expression expected
✘ Error: login failed:

Expected Behavior

No response

Error Logs

2025-05-06 09:28:43+08:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.37-1.el9 started.
2025-05-06 09:28:43+08:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
2025-05-06 09:28:43+08:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.37-1.el9 started.
2025-05-06 09:28:44+08:00 [Note] [Entrypoint]: Initializing database files
2025-05-06T01:28:44.138659Z 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.
2025-05-06T01:28:44.138746Z 0 [System] [MY-013169] [Server] /usr/sbin/mysqld (mysqld 8.0.37) initializing of server in progress as process 87
2025-05-06T01:28:44.145702Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2025-05-06T01:28:44.677984Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2025-05-06T01:28:46.602123Z 6 [Warning] [MY-010453] [Server] root@localhost is created with an empty password ! Please consider switching off the --initialize-insecure option.
2025-05-06 09:28:49+08:00 [Note] [Entrypoint]: Database files initialized
2025-05-06 09:28:49+08:00 [Note] [Entrypoint]: Starting temporary server
mysqld will log errors to /var/lib/mysql/49ce7113b05f.err
mysqld is running as pid 145
2025-05-06 09:28:50+08:00 [Note] [Entrypoint]: Temporary server started.
'/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock'
Warning: Unable to load '/usr/share/zoneinfo/iso3166.tab' as time zone. Skipping it.
Warning: Unable to load '/usr/share/zoneinfo/leap-seconds.list' as time zone. Skipping it.
Warning: Unable to load '/usr/share/zoneinfo/leapseconds' as time zone. Skipping it.
Warning: Unable to load '/usr/share/zoneinfo/tzdata.zi' as time zone. Skipping it.
Warning: Unable to load '/usr/share/zoneinfo/zone.tab' as time zone. Skipping it.
Warning: Unable to load '/usr/share/zoneinfo/zone1970.tab' as time zone. Skipping it.
2025-05-06 09:28:50+08:00 [Note] [Entrypoint]: Creating database apipark

2025-05-06 09:28:50+08:00 [Note] [Entrypoint]: /usr/local/bin/docker-entrypoint.sh: running /docker-entrypoint-initdb.d/start.sh

2025-05-06 09:28:50+08:00 [Note] [Entrypoint]: Stopping temporary server
2025-05-06 09:28:53+08:00 [Note] [Entrypoint]: Temporary server stopped

2025-05-06 09:28:53+08:00 [Note] [Entrypoint]: MySQL init process done. Ready for start up.

2025-05-06T01:28:53.272057Z 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.
2025-05-06T01:28:53.273707Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.37) starting as process 1
2025-05-06T01:28:53.281436Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2025-05-06T01:28:53.419573Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2025-05-06T01:28:53.597779Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
2025-05-06T01:28:53.597809Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
2025-05-06T01:28:53.601441Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
2025-05-06T01:28:53.614600Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.37' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server - GPL.
2025-05-06T01:28:53.614678Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock
2025-05-06T01:31:27.837219Z 0 [System] [MY-013172] [Server] Received SHUTDOWN from user . Shutting down mysqld (Version: 8.0.37).
2025-05-06T01:31:29.034092Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.37) MySQL Community Server - GPL.
2025-05-06 09:32:33+08:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.37-1.el9 started.
2025-05-06 09:32:34+08:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
2025-05-06 09:32:34+08:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.37-1.el9 started.
'/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock'
2025-05-06T01:32:34.493614Z 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.
2025-05-06T01:32:34.496237Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.37) starting as process 1
2025-05-06T01:32:34.512789Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2025-05-06T01:32:34.809470Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2025-05-06T01:32:35.109070Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
2025-05-06T01:32:35.109103Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
2025-05-06T01:32:35.116154Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
2025-05-06T01:32:35.148895Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.37' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server - GPL.
2025-05-06T01:32:35.148975Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock

Steps to Reproduce

No response

Environment

  • ApiPark version:v1.7.2-beta
  • Operating system (run uname -a): 6.11.0-24-generic feat:openapi ui #24~24.04.1-Ubuntu
@Dot-Liu
Copy link
Collaborator

Dot-Liu commented May 6, 2025

Okay, let's investigate quick-start.sh to see if the issue exists
You can start the container directly through Docker start first.
First, to obtain the container list,you can execute a command:

docker ps

then execute

docker start <container name>

@Xiguaalex
Copy link
Author

Okay, let's investigate quick-start.sh to see if the issue exists You can start the container directly through Docker start first. First, to obtain the container list,you can execute a command:

docker ps

then execute

docker start <container name>

I start all the containers,
docker start apipark-apinto
docker start apipark-nsq
docker start apipark-grafana
docker start apipark-loki
docker start apipark-influxdb
docker start apipark-redis
docker start apipark-mysql,
but when visiting http://127.0.0.1:18288, the page still shows 'The connection was reset'

@Dot-Liu
Copy link
Collaborator

Dot-Liu commented May 6, 2025

You also need to start the apipark container

docker start apipark

@Xiguaalex
Copy link
Author

You also need to start the apipark container

docker start apipark

thanks, but after running docker start apipark, the error still exists.
I can visit the dashboard only by reinstalling all the containers...

@Dot-Liu
Copy link
Collaborator

Dot-Liu commented May 6, 2025

May I ask what is the version number of apipark you originally installed?

@Xiguaalex
Copy link
Author

May I ask what is the version number of apipark you originally installed?

v1.7.2-beta
I installed by quick-start.sh

@Xiguaalex
Copy link
Author

May I ask what is the version number of apipark you originally installed?

v1.7.2-beta I installed by quick-start.sh

And when installing mysql container, there is the error:⏳ Waiting: Waiting for MySQL to start...
mysqladmin: [Warning] Using a password on the command line interface can be insecure.
mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
but mysql container still installed successfully.
Will this leads to the bug? and how to fix it.

@Dot-Liu
Copy link
Collaborator

Dot-Liu commented May 6, 2025

Sorry, we couldn't reproduce it
You can try uninstalling Apipark first and then reinstalling it.

Image

@Dot-Liu
Copy link
Collaborator

Dot-Liu commented May 7, 2025

Image
The issue has been reproduced and we will handle it immediately.

@Dot-Liu
Copy link
Collaborator

Dot-Liu commented May 7, 2025

The issue has been fixed and quick-start.sh has been modified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants