ValveSoftware / csgo-osx-linux

Counter-Strike: Global Offensive
http://counter-strike.net
775 stars 69 forks source link

Starting fullscreen crashes on init in NVIDIA's library #3778

Open mSparks43 opened 3 months ago

mSparks43 commented 3 months ago

Your system information

Computer Information: ``` Manufacturer: Micro-Star International Co., Ltd. Model: MAG B550M BAZOOKA (MS-7C95) Form Factor: Desktop No Touch Input Detected Processor Information: CPU Vendor: AuthenticAMD CPU Brand: AMD Ryzen 9 5900X 12-Core Processor CPU Family: 0x19 CPU Model: 0x21 CPU Stepping: 0x0 CPU Type: 0x0 Speed: 4950 MHz 24 logical processors 12 physical processors Hyper-threading: Supported FCMOV: Supported SSE2: Supported SSE3: Supported SSSE3: Supported SSE4a: Supported SSE41: Supported SSE42: Supported AES: Supported AVX: Supported AVX2: Supported AVX512F: Unsupported AVX512PF: Unsupported AVX512ER: Unsupported AVX512CD: Unsupported AVX512VNNI: Unsupported SHA: Supported CMPXCHG16B: Supported LAHF/SAHF: Supported PrefetchW: Unsupported Operating System Version: "Fedora Linux 39 (KDE Plasma)" (64 bit) Kernel Name: Linux Kernel Version: 6.8.11-200.fc39.x86_64 X Server Vendor: The X.Org Foundation X Server Release: 12014000 X Window Manager: GNOME Shell Steam Runtime Version: steam-runtime_0.20240507.87025 Video Card: Driver: NVIDIA Corporation NVIDIA GeForce RTX 3070/PCIe/SSE2 Driver Version: 4.6.0 NVIDIA 550.90.07 OpenGL Version: 4.6 Desktop Color Depth: 24 bits per pixel Monitor Refresh Rate: 60 Hz VendorID: 0x10de DeviceID: 0x2484 Revision Not Detected Number of Monitors: 3 Number of Logical Video Cards: 1 Primary Display Resolution: 1920 x 1080 Desktop Resolution: 5760 x 1080 Primary Display Size: 20.75" x 11.65" (23.78" diag), 52.7cm x 29.6cm (60.4cm diag) Primary Bus: PCI Express 16x Primary VRAM: 8192 MB Supported MSAA Modes: 2x 4x 8x 16x Sound card: Audio device: Nvidia GPU 9e HDMI/DP Memory: RAM: 96469 Mb VR Hardware: Headset: SNY OpenHMD: PSVR () Miscellaneous: UI Language: English LANG: en_GB.UTF-8 Total Hard Disk Space Available: 914090 MB Largest Free Hard Disk Block: 80641 MB Storage: Number of SSDs: 3 SSD sizes: 2000G,960G,0B Number of HDDs: 0 Number of removable drives: 0 ```

Please describe your issue in as much detail as possible:

CS2 fails to start

Steps for reproducing this issue:

.local/share/Steam/steamapps/common/SteamLinuxRuntime_sniper/./run-in-sniper .local/share/Steam/steamapps/common/Counter-Strike\ Global\ Offensive/game/cs2.sh

... Loaded /home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/libcairo.so, got 0x557a391a53b0 Loaded /home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/libengine2.so, got 0x557a2a4c09e0 Loaded /home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/csgo/bin/linuxsteamrt64/libhost.so, got 0x557a392a1430 Loaded /home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/libscenefilecache.so, got 0x557a392b4830 Loaded /home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/csgo/bin/linuxsteamrt64/libmatchmaking.so, got 0x557a392c7030 crash_20240617150043_2.dmp[498223]: Uploading dump (out-of-process) /tmp/dumps/crash_20240617150043_2.dmp crash_20240617150043_2.dmp[498223]: Finished uploading minidump (out-of-process): success = yes crash_20240617150043_2.dmp[498223]: response: Discarded=1 crash_20240617150043_2.dmp[498223]: file ''/tmp/dumps/crash_20240617150043_2.dmp'', upload yes: ''Discarded=1'' .local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/cs2.sh: line 118: 498135 Segmentation fault (core dumped) ${STEAM_RUNTIME_PREFIX} ${GAME_DEBUGGER} "${GAMEROOT}"/${GAMEEXE} "$@"

IMarkoMC commented 3 months ago

Restarting steam and removing all args allowed me to launch the game somehow, i had the exact same error. Might be worth the try

Edit: Added hw information

mSparks43 commented 3 months ago

Restarting steam and removing all args allowed me to launch the game somehow, i had the exact same error. Might be worth the try

Edit: Added hw information

Still the same after verify files and a complete uninstall and reinstall, the core backtrace is showing

"signal": 11 , "executable": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/cs2" , "stacktrace": [ { "crash_thread": true , "frames": [ { "address": 140243346213454 , "build_id": "9d30aa4c6f2a8da11f1ae2fe6d322d76dbc669f3" , "build_id_offset": 13978190 , "file_name": "/run/host/usr/lib64/libnvidia-glcore.so.550.90.07" } , { "address": 140243505770467 , "build_id": "a7a200912e45bc88c95ef51df03f4efab9dbe0f1" , "build_id_offset": 1568739 , "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/librendersystemvulkan.so" } , { "address": 140243505787464 , "build_id": "a7a200912e45bc88c95ef51df03f4efab9dbe0f1" , "build_id_offset": 1585736 , "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/librendersystemvulkan.so" } , { "address": 140243505791696 , "build_id": "a7a200912e45bc88c95ef51df03f4efab9dbe0f1" , "build_id_offset": 1589968 , "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/librendersystemvulkan.so" } , { "address": 140243505033174 , "build_id": "a7a200912e45bc88c95ef51df03f4efab9dbe0f1" , "build_id_offset": 831446 , "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/librendersystemvulkan.so" } , { "address": 140243505034239 , "build_id": "a7a200912e45bc88c95ef51df03f4efab9dbe0f1" , "build_id_offset": 832511 , "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/librendersystemvulkan.so" } , { "address": 140243505561609 , "build_id": "a7a200912e45bc88c95ef51df03f4efab9dbe0f1" , "build_id_offset": 1359881 , "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/librendersystemvulkan.so" } , { "address": 140243973782551 , "build_id": "f8cd7461400ef59e5e09037afdf2282874bd11b9" , "build_id_offset": 1915927 , "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/libtier0.so" } , { "address": 140244008843415 , "build_id": "0d710e9d9dc10c500b8119c85da75004183618e2" , "build_id_offset": 583831 , "file_name": "/run/host/usr/lib64/libc.so.6" } , { "address": 140244009396828 , "build_id": "0d710e9d9dc10c500b8119c85da75004183618e2" , "build_id_offset": 1137244 , "file_name": "/run/host/usr/lib64/libc.so.6" } ]

I'll try a rollback to 550.76 when I get the chance.

IMarkoMC commented 3 months ago

I'll try a rollback to 550.76 when I get the chance.

That has been already tried, there's another issue with similar behavior here. According to that it's not a driver issue but a Valve/CS2 issue

mSparks43 commented 3 months ago

I'll try a rollback to 550.76 when I get the chance.

That has been already tried, there's another issue with similar behavior here. According to that it's not a driver issue but a Valve/CS2 issue

yep, looks like something in librendersystemvulkan.so got borkened. :(

"signal": 11 , "executable": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/cs2" "file_name": "/run/host/usr/lib64/libnvidia-glcore.so.550.76" "file_name": "/home/msparks/.local/share/Steam/steamapps/common/Counter-Strike Global Offensive/game/bin/linuxsteamrt64/librendersystemvulkan.so"

IMarkoMC commented 3 months ago

I was able to launch it again somehow, restarted the game and won't launch again. Checked out DMESG and saw this [ 2257.790241] VKRenderThread[11581]: segfault at 14b ip 000078379e154a4e sp 0000783778dfe450 error 4 in libnvidia-glcore.so.550.90.07[78379d400000+1d27000] likely on CPU 5 (core 5, socket 0) [ 2257.790252] Code: fc ff ff 66 0f 1f 84 00 00 00 00 00 48 85 f6 0f 84 50 e7 54 ff 41 57 41 56 41 55 41 54 55 53 48 83 ec 58 48 8b 86 98 00 00 00 <48> 8b 80 08 01 00 00 4c 8b b0 18 0d 00 00 41 0f b6 ae 08 2b 00 00 Seems like the dmp file was uploaded to valve CrashID=bp-ef232cae-b81e-42f2-9e2c-c6b912240618

jakubgiesler commented 3 months ago

The issue still persist but it appeared to me after kernel update. Cant verify since I removed older kernels already. I think there is something wrong with gameoverlayrenderer.so library, tried to reinstall steam/cs2, nothing helped.

Also it says error is in this block? Might be just noise.

STATUS=42
while [ $STATUS -eq 42 ]; do
    if [ "${GAME_DEBUGGER}" == "gdb" ] || [ "${GAME_DEBUGGER}" == "cgdb" ]; then
        ARGSFILE=$(mktemp $USER.cs2.gdb.XXXX)
        echo b main > "$ARGSFILE"

        # Set the LD_PRELOAD varname in the debugger, and unset the global version. This makes it so that
        #   gameoverlayrenderer.so and the other preload objects aren't loaded in our debugger's process.
        echo set env LD_PRELOAD=$LD_PRELOAD >> "$ARGSFILE"
        echo show env LD_PRELOAD >> "$ARGSFILE"
        echo set disable-randomization off >> "$ARGSFILE"
        unset LD_PRELOAD

        echo run $@ >> "$ARGSFILE"
        echo show args >> "$ARGSFILE"
        ${GAME_DEBUGGER} "${GAMEROOT}"/${GAMEEXE} -x "$ARGSFILE"
        rm "$ARGSFILE"
    elif [ "${GAME_DEBUGGER}" == "lldb" ]; then
        ${GAME_DEBUGGER} "${GAMEROOT}"/${GAMEEXE} -- $@
    else
        ${STEAM_RUNTIME_PREFIX} ${GAME_DEBUGGER} "${GAMEROOT}"/${GAMEEXE} "$@"
    fi
    STATUS=$?
done
exit $STATUS
IMarkoMC commented 3 months ago

Also it says error is in this block? Might be just noise.

It might as well be noise, the dmesg output shows a segfault in libnvidia-glcore and the game sometimes works just fine (at least in my pc) so idk.

Also what i found weird is that when the game crashes my sound starts acting up the same way it would be if the system hardlocked

jakubgiesler commented 3 months ago

I didnt observed this issue in fedora (x11, 6.9.4-200.fc40.x86_64) Also it seems like just our lovely nvidia, with newer drivers is affected.

Edit: steam just downloaded something for cs2 and its running now, so hopefully. Edit2: after another update its broken again.

mSparks43 commented 3 months ago

like just our lovely nvidia, with newer drivers is affected.

Nah, its a new bug in CS2 from an update, it's a vulkan game, shouldn't be touching the GL drivers afaik, given how buggy its been on multiple monitors since release possibly related to that. up until very recently the only way to start it was to turn all the other monitors off but one.

Also it says error is in this block? Might be just noise.

The 118 line is just where the segfault (reading an invalid memory address) in the cs2 executable is getting caught in the script waiting for cs2 to finish. not much we can do but wait for a fixed librendersystemvulkan.so from valve. I tried the -opengl switch on startup properties but that dll still segfaults.

jakubgiesler commented 3 months ago

Nah, its a new bug in CS2 from an update, it's a vulkan game, shouldn't be touching the GL drivers afaik, given how buggy its been on multiple monitors since release possibly related to that. up until very recently the only way to start it was to turn all the other monitors off but one.

I thought huge company like Valve would have unit tests written against latest stable systems (including drivers, kernels, etc...), considering they support cs2 natively. I might be mistaken, but this is laughable, ofc there would be bugs. But at least I would expect ship the product that runs out of the box, or with minor tweaks.

mSparks43 commented 3 months ago

Nah, its a new bug in CS2 from an update, it's a vulkan game, shouldn't be touching the GL drivers afaik, given how buggy its been on multiple monitors since release possibly related to that. up until very recently the only way to start it was to turn all the other monitors off but one.

I thought huge company like Valve would have unit tests written against latest stable systems (including drivers, kernels, etc...), considering they support cs2 natively. I might be mistaken, but this is laughable, ofc there would be bugs. But at least I would expect ship the product that runs out of the box, or with minor tweaks.

you would think, but, this has been an ongoing side quest for a few years now, funniest so far was

https://m.youtube.com/watch?v=pL-5PxV2edY&pp=ygUQY3NnbyBkYXJrbXNwYXJrcw%3D%3D

steamvr has been broken for like a year now 😞

mSparks43 commented 3 months ago

-sw option got it to start.

Chocolate-Banana commented 3 months ago

Don't know if is related but trying to post it anywhere I can to help. I fixed mine by disabling MANGOHUD, that seemed to crash it on startup.

mSparks43 commented 3 months ago

Don't know if is related but trying to post it anywhere I can to help. I fixed mine by disabling MANGOHUD, that seemed to crash it on startup.

No need to disable anything, just start windowed then switch to fullscreen once its loaded.

byzoo101 commented 3 months ago

I've noticed that the segfault tends to occur more frequently when using the in-game voice chat and pressing the mic button. This might indicate an issue with the voice chat integration. It would be great to investigate this angle further. Let me know if you need any additional logs or details.

mSparks43 commented 3 months ago

I've noticed that the segfault tends to occur more frequently when using the in-game voice chat and pressing the mic button. This might indicate an issue with the voice chat integration. It would be great to investigate this angle further. Let me know if you need any additional logs or details.

That sounds like a completely different issue, this is a segfault starting up CS2 that prevents it launching at all.

what .so is yours segfaulting in?

byzoo101 commented 3 months ago

I've noticed that the segfault tends to occur more frequently when using the in-game voice chat and pressing the mic button. This might indicate an issue with the voice chat integration. It would be great to investigate this angle further. Let me know if you need any additional logs or details.

That sounds like a completely different issue, this is a segfault starting up CS2 that prevents it launching at all.

what .so is yours segfaulting in?

It is this one: VKRenderThread [3519] general protection fault ip:7f196aa17f8a sp:7f18dd7fe2c0 error:0 in libnvidia-glcore.so.535.171.04[7f19694f9000+269e000]

Ok @mSparks43 , as it seems to be a truly different issue I’ve given more infos here: https://github.com/ValveSoftware/csgo-osx-linux/issues/3786

IMarkoMC commented 3 months ago

[ 2257.790241] VKRenderThread[11581]: segfault at 14b ip 000078379e154a4e sp 0000783778dfe450 error 4 in libnvidia-glcore.so.550.90.07[78379d400000+1d27000] likely on CPU 5 (core 5, socket 0) [ 2257.790252] Code: fc ff ff 66 0f 1f 84 00 00 00 00 00 48 85 f6 0f 84 50 e7 54 ff 41 57 41 56 41 55 41 54 55 53 48 83 ec 58 48 8b 86 98 00 00 00 <48> 8b 80 08 01 00 00 4c 8b b0 18 0d 00 00 41 0f b6 ae 08 2b 00 00

3786 it's the same error i had. Fixed by using -sw

Edit: Probably some kind of noise again

byzoo101 commented 3 months ago

[ 2257.790241] VKRenderThread[11581]: segfault at 14b ip 000078379e154a4e sp 0000783778dfe450 error 4 in libnvidia-glcore.so.550.90.07[78379d400000+1d27000] likely on CPU 5 (core 5, socket 0) [ 2257.790252] Code: fc ff ff 66 0f 1f 84 00 00 00 00 00 48 85 f6 0f 84 50 e7 54 ff 41 57 41 56 41 55 41 54 55 53 48 83 ec 58 48 8b 86 98 00 00 00 <48> 8b 80 08 01 00 00 4c 8b b0 18 0d 00 00 41 0f b6 ae 08 2b 00 00

3786 it's the same error i had. Fixed by using -sw

Edit: Probably some kind of noise again

Unfortunately, the -sw did not fix my issue https://github.com/ValveSoftware/csgo-osx-linux/issues/3786

pipebomb commented 2 months ago

-sw option got it to start.

Thank you so much - you're a lifesaver!