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

A player of the username is already logged in #4483

Open
bitrate16 opened this issue Mar 3, 2020 · 4 comments
Open

A player of the username is already logged in #4483

bitrate16 opened this issue Mar 3, 2020 · 4 comments

Comments

@bitrate16
Copy link

bitrate16 commented Mar 3, 2020

Client version: 1.12.2
Server OS: Raspbian Linux raspberrypi 4.19.97+ #1294 Thu Jan 30 13:10:54 GMT 2020 armv6l GNU/Linux
Cuberite Commit id: cfedb03

Expected behavior

If player lost network connection on the login state, he should be able to log in after bringing network back.
Attempt to kick a plyer should kick him even when he is in the login state.

Actual behavior

If player lost network connection on the login state, each time he attempts to log in again, he gets the message A player of the username is already logged in.
Attempt to kick ghost player prints out Kicking player @p for "You have been kicked." and player stays in the login state (but he still can not join).

Steps to reproduce the behavior

Try to join the server and turn the network off when Logging in message appears.
Then server log displays Player @p joined server and after network returns, player can not join anymore.

Server log

     [13:05:33] Startup complete, took 10748ms!
Info [13:05:48] Player bitrate16 has joined the game
     [13:07:43] Executing console command: "kick bitrate16"
Info [13:07:43] Kicking player bitrate16 for "You have been kicked."
Info [13:11:31] Kicking player bitrate16 for "Server shutdown"
     [13:11:32] Shutting down server...

@mathiascode
Copy link
Member

Also happens outside the login state, when a player has played for a bit. If they disable their network connection, Cuberite tries to disconnect the client repeatedly after 30 seconds (Nooooo!! You timed out! D: Come back!) until Cuberite gives up.

@peterbell10
Copy link
Member

Possibly fixed by #4533. Same series of events but with the authentication server setting m_State = csAuthenticated instead of csKicked.

@peterbell10
Copy link
Member

Actually, it looks like there are no timeouts set on cTCPLink. So, I think m_Link->Shutdown() will never actually shutdown the connection.

@bitrate16
Copy link
Author

This problem may be caused by natural behavior of the raspberry pi zero w, on which the server was running.
TCp/UDP sockets may stay in WAITING or CONNECTING state for very long time because of very slow cpu.

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

3 participants