Search Unity

Bug 2022 LTS Crashes with latest nvidia drivers

Discussion in 'Linux' started by nnra, Sep 8, 2023.

  1. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    Hi, I am using openSUSE Tumbleweed.
    2 days ago, there were 8 package updates.
    Majority of them were nvidia drivers.
    I used Unity 2022.3.8f1 till then and it worked almost flawlessly(other than a few visual glitches).
    Once the packages were installed, I rebooted and when I tried to launch Unity, I got the error message shown in the first picture.
    My initial thought was that it could be a unity version bug or improperly installed drivers so I downloaded 2022.3.9f1 but the issue persisted.
    I then decided to check if the nvidia drivers are actually installed, which they are(picture 2).
    Since nothing worked, I decided to ask on the forums and see if anyone has a similar issue/a way to fix this.
    Thanks in advance! crash.png drivers.png
     
  2. tylerinthezoo

    tylerinthezoo

    Unity Technologies

    Joined:
    Jun 15, 2022
    Posts:
    92
    hi, would be helpful if you could attach your editor log if possible?
     
  3. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    Hi, I would like to provide it but I wasn't able to find it.
    I searched in the path provided here:
    https://docs.unity3d.com/2020.1/Documentation/Manual/LogFiles.html
    But there was no log of any kind in that directory, even after crashing Unity a few more times.
     
  4. tylerinthezoo

    tylerinthezoo

    Unity Technologies

    Joined:
    Jun 15, 2022
    Posts:
    92
    wha's the output if you run the editor in your terminal?
    logs should be here
    ~/.config/unity3d/Editor.log
     
  5. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    ok, I ran it using this command:
    nnra@localhost:~/Unity/Hub/Editor/2022.3.9f1/Editor> ./Unity -nographics -batchmode -force-free -quit

    This is the output in the Editor.log now:
    Code (CSharp):
    1. Unity Editor version:    2022.3.9f1 (ea401c316338)
    2. Branch:                  2022.3/staging
    3. Build type:              Release
    4. Batch mode:              NO
    5. System name:             Linux
    6. Distro version:          #1 SMP PREEMPT_DYNAMIC Fri Aug 25 08:26:31 UTC 2023 (f5aa89b)
    7. Kernel version:          6.4.12-1-default
    8. Architecture:            x86_64
    9. Available memory:        31998 MB
    10. [Licensing::Module] Trying to connect to existing licensing client channel...
    11. [Licensing::IpcConnector] Connection attempt to the License Client on channel: "LicenseClient-nnra" failed because channel doesn't exist; code: "0x80000002"
    12. [Licensing::Module] Successfully launched the LicensingClient (PId: 30894)
    13. [Licensing::IpcConnector] Successfully connected to the License Client on channel: "LicenseClient-nnra" at "2023-09-10T22:09:50.0248Z"
    14. [SignatureVerifier] Application signature verification not supported on this platform.
    15. [Licensing::Client] Handshaking with LicensingClient:
    16.  Version:                 1.13.1+ca5f299
    17.  Session Id:              5843c8602cdf4d8d88ac1240919b68c5
    18.  Correlation Id:          119433bb8143a85ee64ced0df17ac5f2
    19.  External correlation Id: 7740802890775945747
    20.  Machine Id:              CCGeVIqvH/cfK8z2SC8CHQBLsH4=
    21. [Licensing::Module] Successfully connected to LicensingClient on channel: "LicenseClient-nnra" (connect: 0.45s, validation: 0.04s, handshake: 0.00s)
    22. [Licensing::IpcConnector] Successfully connected to the License Notification on channel: "LicenseClient-nnra-notifications" at "2023-09-10T22:09:50.065009Z"
    23. [Licensing::Module] Connected to LicensingClient (PId: 30894, launch time: 0.00, total connection time: 0.49s)
    24. [Licensing::Module] Error: Access token is unavailable; failed to update
    25. [Licensing::Client] Error: Code 500 while processing request (status: Unable to update licenses. Errors: No ULF license found.,Token not found in cache)
    26. [Licensing::Client] Error: Code 500 while updating license in client (status: Unable to update licenses. Errors: No ULF license found.,Token not found in cache)
    27. [Licensing::Client] Successfully resolved entitlements
    28. [Licensing::Module] Error: License is not active (com.unity.editor.ui). HasEntitlements will fail.
    29. Pro License: NO
    30. Desktop is 5120 x 1440 @ 60 Hz
    31. Initialize udev device monitor.
    32. [Licensing::Client] Successfully resolved entitlements
    33. No valid Unity Editor license found. Please activate your license.
    34. Checking for leaked weakptr:
    35.  Found no leaked weakptrs.
    36. Memory Statistics:
    37. [ALLOC_TEMP_TLS] TLS Allocator
    38.  StackAllocators :
    39.    [ALLOC_TEMP_CoreBusinessMetricsCache]
    40.      Initial Block Size 64.0 KB
    41.      Current Block Size 64.0 KB
    42.      Peak Allocated Bytes 0 B
    43.      Overflow Count 0
    44.    [ALLOC_TEMP_EditorTaskManager]
    45.      Initial Block Size 64.0 KB
    46.      Current Block Size 64.0 KB
    47.      Peak Allocated Bytes 0 B
    48.      Overflow Count 0
    49.    [ALLOC_TEMP_Profiler.Dispatcher]
    50.      Initial Block Size 64.0 KB
    51.      Current Block Size 64.0 KB
    52.      Peak Allocated Bytes 0 B
    53.      Overflow Count 0
    54.    [ALLOC_TEMP_AssetGarbageCollectorHelper] x 15
    55.      Initial Block Size 64.0 KB
    56.      Current Block Size 64.0 KB
    57.      Peak Allocated Bytes 0 B
    58.      Overflow Count 0
    59. [ALLOC_MEMORYPROFILER]
    60.  Requested Block Size 1.0 MB
    61.  Peak Block count 1
    62.  Peak Allocated memory 4.6 KB
    63.  Peak Large allocation bytes 0 B
    64. ##utp:{"type":"MemoryLeaks","version":2,"phase":"Immediate","time":1694383809142,"processId":30876,"allocatedMemory":91347,"memoryLabels":[{"Default":730},{"Permanent":27},{"Thread":64},{"Manager":7319},{"GfxDevice":408},{"Serialization":52},{"BaseObject":12376},{"String":5447},{"DynamicArray":1152},{"HashMap":11914},{"Utility":1024},{"GI":2920},{"CloudService":336},{"VR":80},{"EditorUtility":2904},{"License":3608},{"UnityConnect":26128},{"Collab":25},{"HubClient":3696},{"LocalIPC":306},{"ProfilerEditor":10831}]}
    65.  
     
  6. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    Another thing I should mention is that I am not getting any updates to the Editor.log when I run unity from hub, I got this output only because I ran it through terminal and ended up with a completely different error.
    When ran through the hub I keep getting the same error I initially reported.
     
  7. tylerinthezoo

    tylerinthezoo

    Unity Technologies

    Joined:
    Jun 15, 2022
    Posts:
    92
    One note is, i believe, when you run the editor from the terminal, please do not use the batch mode stuff as you need to login for that. the error basically complains you have no license.
     
  8. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    This got even better.
    I tried running the command you suggested but now nothing happens at all, no log no nothing.
    When ran through hub it starts spinning the loading spinner and then stops after 20-30 seconds with no logs/errors.
    What am I supposed to do next?
     
  9. tylerinthezoo

    tylerinthezoo

    Unity Technologies

    Joined:
    Jun 15, 2022
    Posts:
    92
    you need to run ./Editor -projectPath yourProjectPath, but having nothing showing in the terminal sounds strange to me. it feels like the editor does not even run at all.
     
  10. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    I am guessing you meant ./Unity since ./Editor is not a thing.
    Nothing happened tho, the picture I provided shows the console after running the command as well as the folder with the last log being created yesterday at 12AM(no updates when the cmd is ran) in the top right.
     

    Attached Files:

  11. tylerinthezoo

    tylerinthezoo

    Unity Technologies

    Joined:
    Jun 15, 2022
    Posts:
    92
    one last thing i would try is to run this using sudo.
     
  12. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    nothing
     

    Attached Files:

  13. tylerinthezoo

    tylerinthezoo

    Unity Technologies

    Joined:
    Jun 15, 2022
    Posts:
    92
    is there anything in the log this time?
    i never used openSUSE but if unity crashed, it would produce a log on the system.
     
  14. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    The screenshot I provided shows the file explorer which displays that the last log was created yesterday and not at the time of running unity through either hub or terminal.
     
  15. dan_ginovker

    dan_ginovker

    Joined:
    Jun 13, 2021
    Posts:
    76
    Possibly related, probably not. About 2 months ago now, an Arch Linux update broke my Unity Editor (all versions), and I wasn't able to find anything easily by checking the logs (although if I remember, it was something GTK? I don't use Nvidia graphics btw).

    Because I need Unity for work and I know Arch Linux isn't officially supported, I simply rolled back my system and haven't updated since.

    I run KDE which is common for SUSE, so there could be a connection here, but again I haven't spent any quality time trying to repro it.
     
  16. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    So uhh, I reinstalled unity from flatpak and now it's working.
     
  17. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    Yeah, updates can obviously break unity easily for some reason.
    As I mentioned above, reinstalled solved the issue for me.
    As for it being related to KDE, unlikely, I am using Hyprland.
     
  18. ChiwTheNeko

    ChiwTheNeko

    Joined:
    Mar 24, 2022
    Posts:
    136
    I'm using KDE on Fedora. It is updated very regularly and I never had any problem with Unity.
     
  19. dan_ginovker

    dan_ginovker

    Joined:
    Jun 13, 2021
    Posts:
    76
    I wish Unity supported Flatpak officially, since whenever upstream gets involved, it "just works" after a tweak or two, no matter what random distro you're using (heck, it even works on WSL).
     
  20. tsanyqudsi

    tsanyqudsi

    Joined:
    Jul 17, 2016
    Posts:
    10
    hi @tylerinthezoo I have the same issue

    upload_2023-10-21_18-7-43.png

    upload_2023-10-21_18-7-1.png

    The problem is, there's no Editor.log file so I can't give you why

    Oh this is my OS.
    upload_2023-10-21_18-9-16.png

    I'm running using Flatpak since the "official" way doesn't even work for me.
     
  21. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
  22. tsanyqudsi

    tsanyqudsi

    Joined:
    Jul 17, 2016
    Posts:
    10
    @nnra reinstall unity and unity hub on flatpak ?
     
  23. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    What I've done is manually deleting the unity editor and hub but I suppose that you could delete the editor and then uninstall hub using flatpak.
     
  24. tsanyqudsi

    tsanyqudsi

    Joined:
    Jul 17, 2016
    Posts:
    10
    yea.. I gave up. I'm going to the store tomorrow and get me a new SSD and RAM. The only reason why I have to build it on Linux is because My disk is full and my ram is not enough. Windows hog too much space in RAM and SSD.

    However, Unity should consider flatpak as their linux distribution tho. Thanks for the help @nnra
     
  25. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    It's up to you to choose the OS you'll work on.
    I am personally dual booting and found Unity to load everything much faster on linux.
     
  26. ChiwTheNeko

    ChiwTheNeko

    Joined:
    Mar 24, 2022
    Posts:
    136
    @tsanyqudsi Why didn't the "official" install method work for you?
    If you installed Hub using flatpak then you should try using Flatseal to check the Hub permissions. Especially check if the Hub is allowed to use GPU acceleration and X11. Yes, Flatpak has a permission for that.

    Yes they should! They were using AppImage before and that was good too. I don't understand why they switched to system package instead.

    If they were using Flatpak the Ubuntu libSSL disaster wouldn't have append since Flatpak is designed to avoid this kind of issue.

    Also, sometimes you have to use an unsupported distro where the "official" install method just doesn't work. Just a few months ago I had to install Unity on SteamOS and if it wasn't for the unofficial Flatpak it wouldn't have been possible. And when I said I "had to", I mean I HAD TO. That's not me choosing to use a fancy distro. I just didn't anything else to work with at the moment.

    @tylerinthezoo please consider distributing future versions with Flatpak. It has become the de facto third party application distribution method and it better than system package in every ways.
     
  27. tylerinthezoo

    tylerinthezoo

    Unity Technologies

    Joined:
    Jun 15, 2022
    Posts:
    92
    notes taken. thanks for the feedback all. Our team is currently in a limited capacity, so this probably won't come in a short term.
     
  28. tsanyqudsi

    tsanyqudsi

    Joined:
    Jul 17, 2016
    Posts:
    10
    @ChiwTheNeko all the asset bindings went missing. Basically I have to reattach every single game objects, scripts, prefabs etc. My game is already in dev for a year and I'm not doing it solo. Reattaching them means I have to ask others and it seems very inefficient.

    @nnra yes.. IMO, Linux should be the main platform for Unity since it's a development tool. Windows are not built for development in mind, it's a general use OS.

    I mean seriously, nowadays I don't really need Windows more than playing games and/or doing Multimedia task ( Photoshop / Illustrator ). Although I don't do 3D stuff, but Maya and Blender able to run on Linux.

    IMO, @tylerinthezoo. Make Flatpak and Snap as Unity's main distribution instead of Deb.
     
  29. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    I think that you guys should really release the AppImage again.
    This issue seems to be related to flatpak and it saving the gpu driver version or something during the installation.
    I am on gentoo now and it's so annoying that every time I update the system I have to reinstall both unity and unity hub(I can't even get it to work this time 0_o).
    Flatpak is just not a good choice imho.
    Like seriously, the editor has 99% of the functionality(-some wayland flickering and window manager issues) and we are just being limited by the install method.
    Please, for the love of God, release the AppImage :/
     
  30. ChiwTheNeko

    ChiwTheNeko

    Joined:
    Mar 24, 2022
    Posts:
    136
    The Unity flatpak that is on flathub is not official and not made by Unity.
     
  31. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    I just wanna let you all know that the app image found here worked for me.
    I should mention that it takes a solid minute-two to launch but at least it works :/
     
  32. nnra

    nnra

    Joined:
    Feb 22, 2022
    Posts:
    21
    Ok, I managed to reduce the launch time by a lot.
    I created a Unity.sh script that goes like this:

    Code (CSharp):
    1. #!/bin/bash
    2. UNITY_DIR="/home/nnra/Unity/Hub/Editor/"
    3. UNITY_VERSION_REGEX="[0-9]+\.[0-9]+\.[0-9]+[a-zA-Z0-9]+"
    4. LATEST_VERSION=$(ls -d ${UNITY_DIR}/*/ | grep -oE "${UNITY_VERSION_REGEX}" | sort -Vr | head -n 1)
    5. "${UNITY_DIR}/${LATEST_VERSION}/Editor/Unity" "$@"
    6.  
    Replace
    nnra
    in the path with you name ofc.
    Then I created a desktop entry that launches the said shell script:

    Code (CSharp):
    1. [Desktop Entry]
    2.  
    3. Type=Application
    4. Version=1.0
    5. Name=Unity
    6. GenericName=Game Engine
    7. Comment=Game Engine
    8. Exec=/home/nnra/.local/share/applications/Unity.sh
    9. Icon=unityhub
    10. Categories=Game Engine;
    11. MimeType=
    12.  
    Again, replace the path to your shell script, I like to keep mine together with desktop entries which have to be placed in the path I provided.
    This will now show up in the launcher of your choice(rofi, wofi etc.) and will launch the unity editor directly(the latest installed version according to gpt).
    The downside is that it still takes like 10 seconds for the unity editor to close after launching but the hub is instantly launched which is miles better than 30s-1min of wait time when launching the hub directly.
    Hope this helps somebody in the future or, even better, the unity devs decide to make the engine actually usable on linux :/