MetaHookSv icon indicating copy to clipboard operation
MetaHookSv copied to clipboard

Process hangs and stops responding

Open di57inct opened this issue 1 year ago • 29 comments

This has been happening very often since a few updates ago(can't remember since which update this started happening, sorry). Before updating, the game was very stable. Please tell me how I can give more helpful info and i'll be glad to do so.

EDIT: It's probably related to the following clips. The server uses viewmodel sub-models and that's probably what causes it. On regular classic servers it didn't seem to happen. Don't have the exact code for it but i'm guessing it's something like this: https://forums.alliedmods.net/showthread.php?p=2785316

https://github.com/hzqst/MetaHookSv/assets/3608544/ebbce7db-5d4b-42c1-8b58-2e986fc2d5d6

https://github.com/hzqst/MetaHookSv/assets/3608544/8e1577d6-b4af-46cf-ba1d-54ad37758daa

https://github.com/hzqst/MetaHookSv/assets/3608544/59839379-1600-4223-a803-c5aeb18b0a8c

di57inct avatar Feb 05 '24 16:02 di57inct

I am not able to repro the issue with viewmodels downloaded from https://forums.alliedmods.net/showthread.php?p=2785316. Can you send me the exact ak47 viewmodel you were using in the first clip? the viewmodel looks kinda weird as the vertices seem to be broken or somewhat.

and use SystemInformer to check the thread stack of the hanging thread (mostly main thread with highest cpu usage) if possible. better come with the plugin dlls you were using.

hzqst avatar Feb 06 '24 10:02 hzqst

Will do. Unfortunately, it's not my server and i think not even the owner has the source for the mod as it is licensed and paid for the compiled scripts. Server is csgo.mascatii.ro and it happens pretty often when i play on it(around 50/50 chance).

di57inct avatar Feb 06 '24 10:02 di57inct

Will do. Unfortunately, it's not my server and i think not even the owner has the source for the mod as it is licensed and paid for the compiled scripts. Server is csgo.mascatii.ro and it happens pretty often when i play on it(around 50/50 chance).

I don't have to go with amxx script or sth. I was testing by directly modifing viewmodel.body from renderer and that's enough.

hzqst avatar Feb 06 '24 10:02 hzqst

Okay, here are the models. It seems i was wrong about the sub-models. Instead, they have multiple body groups because they have too many polygons. https://drive.google.com/file/d/1Gu46_LFNV7R-4NxwGcTrrdUxR8LzBjFv/view?usp=sharing image

di57inct avatar Feb 06 '24 13:02 di57inct

Okay, here are the models. It seems i was wrong about the sub-models. Instead, they have multiple body groups because they have too many polygons. https://drive.google.com/file/d/1Gu46_LFNV7R-4NxwGcTrrdUxR8LzBjFv/view?usp=sharing image

Still unable to repro the issue with your viewmodels. I doubt if it's VGUI2 stuffs or it's BulletPhysics that caused the hangup/crash.

btw: There is an infinite loop that may cause the game to hang up in VGUI2 code that happenes when a dialog get scaled to an extreme small size, like 10x10. but I didn't see any VGUI2 panel operations in the clips.

hzqst avatar Feb 06 '24 14:02 hzqst

I've noticed the crashes occur after weapon change, that's why i thought this was it. Been playing for a while now and it didn't crash so far while i have system informer on.

di57inct avatar Feb 06 '24 14:02 di57inct

I've noticed the crashes occur after weapon change, that's why i thought this was it. Been playing for a while now and it didn't crash so far while i have system informer on.

if it's a crash rather than a hang up, the systemformer is not gonna work. you will have to upload dmp files in C:\Program Files (x86)\Steam\dumps if you believe that it's a crash.

hzqst avatar Feb 06 '24 14:02 hzqst

I meant hang, sorry.

di57inct avatar Feb 06 '24 15:02 di57inct

Ok, it finally hanged again. Looks like it happens when there are many players on the server i think. https://youtu.be/YUPiJvrrFNA

di57inct avatar Feb 06 '24 17:02 di57inct

Ok, it finally hanged again. Looks like it happens when there are many players on the server i think. https://youtu.be/YUPiJvrrFNA

looks like the main thread is not even visible in the thread list, can you try again and inspect the main thread when it's not hanging up?

hzqst avatar Feb 07 '24 11:02 hzqst

Main thread being the emulator(SmartSteamLoader.exe), right?

di57inct avatar Feb 07 '24 12:02 di57inct

Main thread being the emulator(SmartSteamLoader.exe), right?

The one with highest cpu usage is the main thread (about 6.25% on 8c16t processor or 8.33% on 6c12t processor ), while game is running without problem.

hzqst avatar Feb 07 '24 12:02 hzqst

I'm on a laptop with a 2c4t cpu(AMD Ryzen 3 3200U) right now and this is what i got

image

di57inct avatar Feb 07 '24 12:02 di57inct

I'm on a laptop with a 2c4t cpu(AMD Ryzen 3 3200U) right now and this is what i got

image

This is the main thread image

hzqst avatar Feb 07 '24 13:02 hzqst

image

image

di57inct avatar Feb 07 '24 21:02 di57inct

image

image

The main thread in your screenshots seems to be working fine

hzqst avatar Feb 08 '24 01:02 hzqst

Ok, will try to capture it again when it freezes if that helps you with anything.

di57inct avatar Feb 08 '24 06:02 di57inct

image is this related?

hzqst avatar Feb 10 '24 04:02 hzqst

Doubt I've seen that in the console. When it freezes for me, it freezes permanently. I don't get temporary freeze.

di57inct avatar Feb 10 '24 06:02 di57inct

Doubt I've seen that in the console. When it freezes for me, it freezes permanently. I don't get temporary freeze.

Any progress on this issue?

hzqst avatar Feb 28 '24 02:02 hzqst

Unfortunately no. Didn't have the time to play anymore and the server mod changed. Will try just using the skins client side when i have time.

di57inct avatar Feb 28 '24 06:02 di57inct

Idk if this is related to the hang after all or not, but the visual bug with the mesh happened as soon as i started using the models. It seems to have something to do with 3rd party custom server entities. In the first clip, where i killed the T should of been an ammo box entity. It seems invisible and as soon as I pick it up(use sound on when watching the clip), the random mesh disappears. I was also monitoring it with system informer. Hope this is something useful, even if not actually related to this topic. Link to AMXMODX plugin with the 3rd party entities: https://forums.alliedmods.net/showthread.php?p=619788 (or it can be seen on my server 82.76.20.181:27015)

|index|api|             plugin name|          plugin version|
|    0| v2|   Gmcx_model_effect.dll|                        |
|    1| v4|         ThreadGuard.dll|     2024-02-27T03:45:43|
|    2| v4|     PrecacheManager.dll|     2024-02-27T03:44:50|
|    3| v4|        StudioEvents.dll|     2024-02-27T03:45:40|
|    4| v4|  BulletPhysics_AVX2.dll|     2024-02-27T03:43:56|
|    5| v4|       Renderer_AVX2.dll|     2024-02-27T03:40:29|
|    6| v4|          CaptionMod.dll|     2024-02-27T03:44:26|
|    7| v4|      VGUI2Extension.dll|     2024-02-27T03:44:03|

https://youtu.be/8_qfSxvaMFM https://youtu.be/WQlqnbdLORA https://youtu.be/EmLVEUlgsUY https://youtu.be/XTTxfe7W3jE https://youtu.be/-8hh6SMsSdM https://youtu.be/OJAr4H9pTIU https://youtu.be/pgRUaPjF794 https://www.youtube.com/watch?v=26FIHpkNgEM

di57inct avatar Feb 28 '24 22:02 di57inct

Idk if this is related to the hang after all or not, but the visual bug with the mesh happened as soon as i started using the models. It seems to have something to do with 3rd party custom server entities. In the first clip, where i killed the T should of been an ammo box entity. It seems invisible and as soon as I pick it up(use sound on when watching the clip), the random mesh disappears. I was also monitoring it with system informer. Hope this is something useful, even if not actually related to this topic. Link to AMXMODX plugin with the 3rd party entities: https://forums.alliedmods.net/showthread.php?p=619788 (or it can be seen on my server 82.76.20.181:27015)

|index|api|             plugin name|          plugin version|
|    0| v2|   Gmcx_model_effect.dll|                        |
|    1| v4|         ThreadGuard.dll|     2024-02-27T03:45:43|
|    2| v4|     PrecacheManager.dll|     2024-02-27T03:44:50|
|    3| v4|        StudioEvents.dll|     2024-02-27T03:45:40|
|    4| v4|  BulletPhysics_AVX2.dll|     2024-02-27T03:43:56|
|    5| v4|       Renderer_AVX2.dll|     2024-02-27T03:40:29|
|    6| v4|          CaptionMod.dll|     2024-02-27T03:44:26|
|    7| v4|      VGUI2Extension.dll|     2024-02-27T03:44:03|

https://youtu.be/8_qfSxvaMFM https://youtu.be/WQlqnbdLORA https://youtu.be/EmLVEUlgsUY https://youtu.be/XTTxfe7W3jE https://youtu.be/-8hh6SMsSdM https://youtu.be/OJAr4H9pTIU https://youtu.be/pgRUaPjF794 https://www.youtube.com/watch?v=26FIHpkNgEM

the random mesh seems to be from /Half-Life/valve/w_357ammobox.mdl isn't it?

hzqst avatar Feb 29 '24 05:02 hzqst

Yes that's the model used for the ammo box entity

di57inct avatar Feb 29 '24 09:02 di57inct

Probably related to #420. Fixed in https://github.com/hzqst/MetaHookSv/releases/tag/v20240314a

As for the random mesh, I am not able to repro this issue with Real Weapon Drop on my end.

hzqst avatar Mar 14 '24 14:03 hzqst

This was on dedicated, though, not listenserver. Will open a separate issue for the random mesh bug of you want. You can try to recreate it on my server: 82.76.20.181:27015

di57inct avatar Mar 14 '24 16:03 di57inct

This was on dedicated, though, not listenserver. Will open a separate issue for the random mesh bug of you want. You can try to recreate it on my server: 82.76.20.181:27015

RunListenServer is named with a confusing name by Valve while it's actually used for running non-dedicated engine.well, it has nothing to do with server inside this function.

After testing for 10 mins on your server, I was still not able to repro the random mesh issue. Can you verify the integrity of game files on Steam ? as I assumed that the /Half-Life/valve/w_357ammobox.mdl was somehow broken.

hzqst avatar Mar 15 '24 01:03 hzqst

I'm very sure the file was not corrupted. I was on pre-25th build tho(8xxx).

di57inct avatar Mar 15 '24 06:03 di57inct

Should've been fixed in the latest release. the r_studio_bone_caches better be disabled btw.

hzqst avatar Apr 01 '24 08:04 hzqst

Closing this as the latest builds are very stable now, even with bone caches 1.

di57inct avatar Feb 12 '25 16:02 di57inct