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

Failed serial commands do not get dequeued. #789

Open
rdebath opened this issue Jan 6, 2024 · 3 comments
Open

Failed serial commands do not get dequeued. #789

rdebath opened this issue Jan 6, 2024 · 3 comments

Comments

@rdebath
Copy link
Contributor

rdebath commented Jan 6, 2024

If a command fails with the Command Failed message ... https://github.com/UnknownShadow200/MCGalaxy/blob/7bd2ad38ea3269c36f9e00d648cb2ef4476cde91/MCGalaxy/Player/Player.Handlers.cs#L528
And this command went through the ExecuteSerialCommands function ...
https://github.com/UnknownShadow200/MCGalaxy/blob/7bd2ad38ea3269c36f9e00d648cb2ef4476cde91/MCGalaxy/Player/Player.Handlers.cs#L701
The command will not get Dequeue'd ...
https://github.com/UnknownShadow200/MCGalaxy/blob/7bd2ad38ea3269c36f9e00d648cb2ef4476cde91/MCGalaxy/Player/Player.Handlers.cs#L715
Because that is skipped and not run by the exception handler.
It will remain in on the queue and may get rerun when it's not wanted.

Waiting for /Ping  to finish first before running /Ping
Command failed
@UnknownShadow200
Copy link
Collaborator

What did you do to trigger the Command failed case to get reached?

@rdebath
Copy link
Contributor Author

rdebath commented Jan 12, 2024

Hammered the server.

It's running lots of sessions (40) each placing blocks at just under the spam limit (no actual /place, or other, commands though). Then the server saves the level, I think. Which causes all commands on all sessions to error in this way. It also doesn't seem to recover unless every session logs out.

Unfortunately I haven't been able to repeat it on a server I own, despite clobbering them both less and so much the the kernel kills them off.

@rdebath
Copy link
Contributor Author

rdebath commented Jan 13, 2024

Well, I've found something that kinda looks the same, except the server usually dies completely rather soon after.

Type: ExecutionEngineException
Source:
Message: Couldn't create thread. Error 0x2733
Trace:   at (wrapper managed-to-native) System.Threading.Thread.Thread_internal(System.Threading.Thread,System.MulticastDelegate)
  at System.Threading.Thread.StartInternal (System.Object principal, System.Threading.StackCrawlMarkstackMark) [0x0001a] in <12b418a7818c4ca0893feeaaf67f1e7f>:0
  at System.Threading.Thread.Start (System.Threading.StackCrawlMarkstackMark) [0x0002d] in <12b418a7818c4ca0893feeaaf67f1e7f>:0
  at System.Threading.Thread.Start () [0x00002] in <12b418a7818c4ca0893feeaaf67f1e7f>:0
  at MCGalaxy.Server.StartThread (System.Threading.Threadthread, System.String name, System.Threading.ThreadStart threadFunc) [0x00023] in /opt/mcgalaxy/MCGalaxy/MCGalaxy/Server/Server.cs:343
  at MCGalaxy.Player.HandleCommand (System.String cmd, System.String args, MCGalaxy.CommandData data) [0x000eb] in /opt/mcgalaxy/MCGalaxy/MCGalaxy/Player/Player.Handlers.cs:528



Type: ExecutionEngineException
Source:
Message: Couldn't create thread. Error 0x0
Trace:   at (wrapper managed-to-native) System.Threading.Thread.Thread_internal(System.Threading.Thread,System.MulticastDelegate)
  at System.Threading.Thread.StartInternal (System.Object principal, System.Threading.StackCrawlMarkstackMark) [0x0001a] in <12b418a7818c4ca0893feeaaf67f1e7f>:0
  at System.Threading.Thread.Start (System.Threading.StackCrawlMarkstackMark) [0x0002d] in <12b418a7818c4ca0893feeaaf67f1e7f>:0
  at System.Threading.Thread.Start () [0x00002] in <12b418a7818c4ca0893feeaaf67f1e7f>:0
  at MCGalaxy.Server.StartThread (System.Threading.Threadthread, System.String name, System.Threading.ThreadStart threadFunc) [0x00023] in /opt/mcgalaxy/MCGalaxy/MCGalaxy/Server/Server.cs:343
  at MCGalaxy.Player.HandleCommand (System.String cmd, System.String args, MCGalaxy.CommandData data) [0x000eb] in /opt/mcgalaxy/MCGalaxy/MCGalaxy/Player/Player.Handlers.cs:528



Type: ExecutionEngineException
Source:
Message: MonoError reused after mono_error_cleanup
Trace:   at (wrapper managed-to-native) System.Threading.Thread.Thread_internal(System.Threading.Thread,System.MulticastDelegate)
  at System.Threading.Thread.StartInternal (System.Security.Principal.IPrincipal principal, System.Threading.StackCrawlMarkstackMark) [0x0001a] in <d0e12f672b88444ab4b6d9b2ecf20142>:0
  at System.Threading.Thread.Start (System.Threading.StackCrawlMarkstackMark) [0x0002d] in <d0e12f672b88444ab4b6d9b2ecf20142>:0
  at System.Threading.Thread.Start () [0x00002] in <d0e12f672b88444ab4b6d9b2ecf20142>:0
  at MCGalaxy.Server.StartThread (System.Threading.Threadthread, System.String name, System.Threading.ThreadStart threadFunc) [0x00023] in /opt/mcgalaxy/MCGalaxy/MCGalaxy/Server/Server.cs:343
  at MCGalaxy.Player.HandleCommand (System.String cmd, System.String args, MCGalaxy.CommandData data) [0x000eb] in /opt/mcgalaxy/MCGalaxy/MCGalaxy/Player/Player.Handlers.cs:528

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