suriyun-production / mmorpg-kit-docs

This is document for MMORPG KIT project (https://www.assetstore.unity3d.com/#!/content/110188?aid=1100lGeN)
https://suriyun-production.github.io/mmorpg-kit-docs
48 stars 11 forks source link

Mysql issue #2436

Closed moepi2k closed 6 months ago

moepi2k commented 6 months ago

hi i have a really weird issue.

i setup a new server. when i connect i can register an account and even logiin and create a char. but then i cant use the char to enter the game. it hangs in loading.

when i check the db tables. there is no entry. like no account created. then i can shutdown server start again and login with that ghost account which is not in the db.

i checked logs and see those stuff.

ERROR No Tag [2024-03-24 22:56:44] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. System.Reflection.MonoMethodInfo.GetMethodInfo (System.IntPtr handle) (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.Reflection.RuntimeMethodInfo.GetPseudoCustomAttributes () (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.MonoCustomAttrs.GetPseudoCustomAttributes (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType) (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.MonoCustomAttrs.GetCustomAttributesBase (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType, System.Boolean inheritedOnly) (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.MonoCustomAttrs.GetCustomAttributes (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType, System.Boolean inherit) (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.Reflection.RuntimeMethodInfo.GetCustomAttributes (System.Type attributeType, System.Boolean inherit) (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.Attribute.GetCustomAttributes (System.Reflection.MemberInfo element, System.Type type, System.Boolean inherit) (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.Attribute.GetCustomAttribute (System.Reflection.MemberInfo element, System.Type attributeType, System.Boolean inherit) (at <60a657bf02c84e589a8b52b7e4e04376>:0) System.Reflection.CustomAttributeExtensions.GetCustomAttribute (System.Reflection.MemberInfo element, System.Type attributeType, System.Boolean inherit) (at <60a657bf02c84e589a8b52b7e4e04376>:0) DevExtUtils+<>c__DisplayClass6_0.b0 (System.Reflection.MethodInfo a) (at :0) System.Linq.Enumerable+WhereArrayIterator1[TSource].ToArray () (at <e420db10a3564cef98bf557915d3b37c>:0) System.Linq.Enumerable.ToArray[TSource] (System.Collections.Generic.IEnumerable1[T] source) (at :0) DevExtUtils.InvokeDevExtMethods (System.Type type, System.Object obj, System.String baseMethodName, System.Reflection.BindingFlags bindingFlags, System.Object[] args) (at :0) UnityEngine.Debug:LogException(Exception) DevExtUtils:InvokeDevExtMethods(Type, Object, String, BindingFlags, Object[]) DevExtUtils:InvokeInstanceDevExtMethods(MySQLDatabase, String, Object[]) MultiplayerARPG.MMO.MySQLDatabase:Initialize() MultiplayerARPG.MMO.d25:MoveNext() System.Runtime.CompilerServices.AsyncVoidMethodBuilder:Start(d25&) MultiplayerARPG.MMO.DatabaseNetworkManager:OnStartServer() LiteNetLibManager.LiteNetLibManager:StartServer() MultiplayerARPG.MMO.MMOServerInstance:StartDatabaseManagerServer() MultiplayerARPG.MMO.MMOServerInstance:OnGameDataLoaded() MultiplayerARPG.GameInstance:OnGameDataLoaded() MultiplayerARPG.GameInstance:LoadedGameData() MultiplayerARPG.d0:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoid1:Run() Cysharp.Threading.Tasks.AwaiterActions:Continuation(Object) Cysharp.Threading.Tasks.UniTaskCompletionSourceCore1:TrySetResult(AsyncUnit) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask1:SetResult() MultiplayerARPG.<LoadDataImplement>d__44:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask1:Run() Cysharp.Threading.Tasks.Internal.ContinuationQueue:RunCore() Cysharp.Threading.Tasks.Internal.ContinuationQueue:Run()

ERROR No Tag [2024-03-24 22:56:44] - Couldn't extract exception string from exception of type TypeLoadException (another exception of class 'FileNotFoundException' was thrown while processing the stack trace)

ERROR No Tag [2024-03-24 22:56:44] -

ERROR No Tag [2024-03-24 22:56:44] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. MultiplayerARPG.MMO.MySQLDatabase.UpdateUserCount (System.Int32 userCount) (at <8c1ac0e70e734970840ac962a06556cb>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.UpdateUserCount (LiteNetLibManager.RequestHandlerData requestHandler, MultiplayerARPG.MMO.UpdateUserCountReq request, LiteNetLibManager.RequestProceedResultDelegate1[TResponse] result) (at <8c1ac0e70e734970840ac962a06556cb>:0) UnityEngine.Debug:LogException(Exception) Cysharp.Threading.Tasks.UniTaskScheduler:PublishUnobservedTaskException(Exception) MultiplayerARPG.MMO.<UpdateUserCount>d__106:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoidMethodBuilder:Start(<UpdateUserCount>d__106&) MultiplayerARPG.MMO.DatabaseNetworkManager:UpdateUserCount(RequestHandlerData, UpdateUserCountReq, RequestProceedResultDelegate1) LiteNetLibManager.LiteNetLibRequestHandler`2:InvokeRequest(RequestHandlerData, RequestProceededDelegate) LiteNetLibManager.TransportHandler:ProceedRequest(Int64, NetDataReader) LiteNetLibManager.TransportHandler:ReadPacket(Int64, NetDataReader) LiteNetLibManager.LiteNetLibServer:OnServerReceive(TransportEventData) LiteNetLibManager.LiteNetLibServer:Update() LiteNetLibManager.LiteNetLibManager:Update()

ERROR No Tag [2024-03-24 22:56:45] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. MultiplayerARPG.MMO.MySQLDatabase.DeleteAllReservedStorage () (at <8c1ac0e70e734970840ac962a06556cb>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.DeleteAllReservedStorage (LiteNetLibManager.RequestHandlerData requestHandler, LiteNetLibManager.EmptyMessage request, LiteNetLibManager.RequestProceedResultDelegate1[TResponse] result) (at <8c1ac0e70e734970840ac962a06556cb>:0) UnityEngine.Debug:LogException(Exception) Cysharp.Threading.Tasks.UniTaskScheduler:PublishUnobservedTaskException(Exception) MultiplayerARPG.MMO.<DeleteAllReservedStorage>d__89:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoidMethodBuilder:Start(<DeleteAllReservedStorage>d__89&) MultiplayerARPG.MMO.DatabaseNetworkManager:DeleteAllReservedStorage(RequestHandlerData, EmptyMessage, RequestProceedResultDelegate1) LiteNetLibManager.LiteNetLibRequestHandler`2:InvokeRequest(RequestHandlerData, RequestProceededDelegate) LiteNetLibManager.TransportHandler:ProceedRequest(Int64, NetDataReader) LiteNetLibManager.TransportHandler:ReadPacket(Int64, NetDataReader) LiteNetLibManager.LiteNetLibServer:OnServerReceive(TransportEventData) LiteNetLibManager.LiteNetLibServer:Update() LiteNetLibManager.LiteNetLibManager:Update()

ERROR No Tag [2024-03-24 22:56:49] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. MultiplayerARPG.MMO.MySQLDatabase.ReadBuildings (System.String channel, System.String mapName) (at <8c1ac0e70e734970840ac962a06556cb>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.ReadBuildings (System.String channel, System.String mapName) (at <8c1ac0e70e734970840ac962a06556cb>:0) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2[TStateMachine,T].GetResult (System.Int16 token) (at <9f37682a6d254b9fbb5aa058823c2407>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.ReadBuildings (LiteNetLibManager.RequestHandlerData requestHandler, MultiplayerARPG.MMO.ReadBuildingsReq request, LiteNetLibManager.RequestProceedResultDelegate1[TResponse] result) (at <8c1ac0e70e734970840ac962a06556cb>:0) UnityEngine.Debug:LogException(Exception) Cysharp.Threading.Tasks.UniTaskScheduler:PublishUnobservedTaskException(Exception) MultiplayerARPG.MMO.d60:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoid1:Run() Cysharp.Threading.Tasks.AwaiterActions:Continuation(Object) Cysharp.Threading.Tasks.UniTaskCompletionSourceCore1:TrySetException(Exception) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask`2:SetException(Exception) MultiplayerARPG.MMO.d112:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:Run() Cysharp.Threading.Tasks.AwaiterActions:Continuation(Object) Cysharp.Threading.Tasks.UniTaskCompletionSourceCore1:TrySetResult(DatabaseCacheResult1) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:SetResult(DatabaseCacheResult1) MultiplayerARPG.MMO.<GetBuildings>d__51:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:Run() Cysharp.Threading.Tasks.Internal.ContinuationQueue:RunCore() Cysharp.Threading.Tasks.Internal.ContinuationQueue:Run()

ERROR No Tag [2024-03-24 22:56:49] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. MultiplayerARPG.MMO.MySQLDatabase.UpdateUserCount (System.Int32 userCount) (at <8c1ac0e70e734970840ac962a06556cb>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.UpdateUserCount (LiteNetLibManager.RequestHandlerData requestHandler, MultiplayerARPG.MMO.UpdateUserCountReq request, LiteNetLibManager.RequestProceedResultDelegate1[TResponse] result) (at <8c1ac0e70e734970840ac962a06556cb>:0) UnityEngine.Debug:LogException(Exception) Cysharp.Threading.Tasks.UniTaskScheduler:PublishUnobservedTaskException(Exception) MultiplayerARPG.MMO.<UpdateUserCount>d__106:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoidMethodBuilder:Start(<UpdateUserCount>d__106&) MultiplayerARPG.MMO.DatabaseNetworkManager:UpdateUserCount(RequestHandlerData, UpdateUserCountReq, RequestProceedResultDelegate1) LiteNetLibManager.LiteNetLibRequestHandler`2:InvokeRequest(RequestHandlerData, RequestProceededDelegate) LiteNetLibManager.TransportHandler:ProceedRequest(Int64, NetDataReader) LiteNetLibManager.TransportHandler:ReadPacket(Int64, NetDataReader) LiteNetLibManager.LiteNetLibServer:OnServerReceive(TransportEventData) LiteNetLibManager.LiteNetLibServer:Update() LiteNetLibManager.LiteNetLibManager:Update()

ERROR No Tag [2024-03-24 22:56:50] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. MultiplayerARPG.MMO.MySQLDatabase.ReadBuildings (System.String channel, System.String mapName) (at <8c1ac0e70e734970840ac962a06556cb>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.ReadBuildings (System.String channel, System.String mapName) (at <8c1ac0e70e734970840ac962a06556cb>:0) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2[TStateMachine,T].GetResult (System.Int16 token) (at <9f37682a6d254b9fbb5aa058823c2407>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.ReadBuildings (LiteNetLibManager.RequestHandlerData requestHandler, MultiplayerARPG.MMO.ReadBuildingsReq request, LiteNetLibManager.RequestProceedResultDelegate1[TResponse] result) (at <8c1ac0e70e734970840ac962a06556cb>:0) UnityEngine.Debug:LogException(Exception) Cysharp.Threading.Tasks.UniTaskScheduler:PublishUnobservedTaskException(Exception) MultiplayerARPG.MMO.d60:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoid1:Run() Cysharp.Threading.Tasks.AwaiterActions:Continuation(Object) Cysharp.Threading.Tasks.UniTaskCompletionSourceCore1:TrySetException(Exception) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask`2:SetException(Exception) MultiplayerARPG.MMO.d112:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:Run() Cysharp.Threading.Tasks.AwaiterActions:Continuation(Object) Cysharp.Threading.Tasks.UniTaskCompletionSourceCore1:TrySetResult(DatabaseCacheResult1) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:SetResult(DatabaseCacheResult1) MultiplayerARPG.MMO.<GetBuildings>d__51:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:Run() Cysharp.Threading.Tasks.Internal.ContinuationQueue:RunCore() Cysharp.Threading.Tasks.Internal.ContinuationQueue:Run()

ERROR No Tag [2024-03-24 22:56:50] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. MultiplayerARPG.MMO.MySQLDatabase.ReadBuildings (System.String channel, System.String mapName) (at <8c1ac0e70e734970840ac962a06556cb>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.ReadBuildings (System.String channel, System.String mapName) (at <8c1ac0e70e734970840ac962a06556cb>:0) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2[TStateMachine,T].GetResult (System.Int16 token) (at <9f37682a6d254b9fbb5aa058823c2407>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.ReadBuildings (LiteNetLibManager.RequestHandlerData requestHandler, MultiplayerARPG.MMO.ReadBuildingsReq request, LiteNetLibManager.RequestProceedResultDelegate1[TResponse] result) (at <8c1ac0e70e734970840ac962a06556cb>:0) UnityEngine.Debug:LogException(Exception) Cysharp.Threading.Tasks.UniTaskScheduler:PublishUnobservedTaskException(Exception) MultiplayerARPG.MMO.d60:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoid1:Run() Cysharp.Threading.Tasks.AwaiterActions:Continuation(Object) Cysharp.Threading.Tasks.UniTaskCompletionSourceCore1:TrySetException(Exception) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask`2:SetException(Exception) MultiplayerARPG.MMO.d112:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:Run() Cysharp.Threading.Tasks.AwaiterActions:Continuation(Object) Cysharp.Threading.Tasks.UniTaskCompletionSourceCore1:TrySetResult(DatabaseCacheResult1) Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:SetResult(DatabaseCacheResult1) MultiplayerARPG.MMO.<GetBuildings>d__51:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTask2:Run() Cysharp.Threading.Tasks.Internal.ContinuationQueue:RunCore() Cysharp.Threading.Tasks.Internal.ContinuationQueue:Run()

ERROR No Tag [2024-03-24 22:56:54] - FileNotFoundException: Could not load file or assembly 'MySqlConnector, Version=0.0.0.0, Culture=neutral, PublicKeyToken=d33d3e53aa5f8c92' or one of its dependencies. MultiplayerARPG.MMO.MySQLDatabase.UpdateUserCount (System.Int32 userCount) (at <8c1ac0e70e734970840ac962a06556cb>:0) MultiplayerARPG.MMO.DatabaseNetworkManager.UpdateUserCount (LiteNetLibManager.RequestHandlerData requestHandler, MultiplayerARPG.MMO.UpdateUserCountReq request, LiteNetLibManager.RequestProceedResultDelegate1[TResponse] result) (at <8c1ac0e70e734970840ac962a06556cb>:0) UnityEngine.Debug:LogException(Exception) Cysharp.Threading.Tasks.UniTaskScheduler:PublishUnobservedTaskException(Exception) MultiplayerARPG.MMO.<UpdateUserCount>d__106:MoveNext() Cysharp.Threading.Tasks.CompilerServices.AsyncUniTaskVoidMethodBuilder:Start(<UpdateUserCount>d__106&) MultiplayerARPG.MMO.DatabaseNetworkManager:UpdateUserCount(RequestHandlerData, UpdateUserCountReq, RequestProceedResultDelegate1) LiteNetLibManager.LiteNetLibRequestHandler`2:InvokeRequest(RequestHandlerData, RequestProceededDelegate) LiteNetLibManager.TransportHandler:ProceedRequest(Int64, NetDataReader) LiteNetLibManager.TransportHandler:ReadPacket(Int64, NetDataReader) LiteNetLibManager.LiteNetLibServer:OnServerReceive(TransportEventData) LiteNetLibManager.LiteNetLibServer:Update() LiteNetLibManager.LiteNetLibManager:Update()

never faced that weird issue. any hints?

insthync commented 6 months ago

What's did you do after you saw those messages?

moepi2k commented 6 months ago

Tried many things, its not the first time i setup a server. Never had that issue. I checked everything again. Opened ports etc. Weird is sometime its working from one sec to another.

First i thought there are running 2 mysql and it connect to wrong. So i removed everything again and only installed mariadb new

insthync commented 6 months ago

It is telling exactly what is occuring, it cannot find MySqlConnector, so you won't have to check ports, you just have to check MySqlConnector

moepi2k commented 6 months ago

Yea but the question is why. Mariadb is up and running and i can connect to it. Configfile data for mysql is correct too. So also weird why im able to make ghost accounts. I would have a better feeling when not even able to connect instead of creating ghost accounts to somewhere

insthync commented 6 months ago

It is not because of connection, it is about library file loading, as it says.

moepi2k commented 6 months ago

but why? the MySqlConnector file is in project, i never touched it.

insthync commented 6 months ago

Maybe the MySqlConnector.dll was removed when built, or when copy-paste/upload to server.

insthync commented 6 months ago

Or maybe because of managedStrippingLevel setting

moepi2k commented 6 months ago

i will check that too. but thats really weird because i never touched anything and always worked. what i just notice is that it automicly create a Config/Log + a sqlite file outside of my server folde https://gyazo.com/a8998ef544d56298db6091640f0c97dd

dont know why

moepi2k commented 6 months ago

thats def something weird which never happen before 187.

the config file which will create automaticly outside of my project has stuff in it which is not from me. it leads to a sqlite path and other stuff https://gyazo.com/5b3d7b8e973bc8b7fe96977824f6b8d2 https://gyazo.com/088dad0bc5a92f67589860f39309ee55 https://gyazo.com/3d63ff91f4192432693496b49ac26467

insthync commented 6 months ago

If you think it is never happen before 1.87 then you may try to compare codes between those versions, you've got all access, try do it.

moepi2k commented 6 months ago

-.-

insthync commented 6 months ago

Can you do it?

moepi2k commented 6 months ago

i can, but i will first try 186 version.

insthync commented 6 months ago

So you didn't try it yet, but you guess that it has no issues on 186?

moepi2k commented 6 months ago

i never had that issue before. so dont know from where it comes from. i just bought a new dedicated server and set it up and have it with 187. so yea i need to test

insthync commented 6 months ago

When you run servers, did you cd to your server folder ?

moepi2k commented 6 months ago

thats the command i always use to start it

nohup /root/Server/Server.x86_64 -startDatabaseServer -startCentralServer -startMapSpawnServer

use it from main directory

insthync commented 6 months ago

Try cd to server folder

moepi2k commented 6 months ago

please kill me. wtf was it ............ sorry for bugging u with that shit and thank you very much. just wondering why that command always worked for my old server. i always started it with that command from root directory