UE4Editor constantly crashes and freezes using Linux

Hello everyone,

I’m new to UE4 and recently built the release version of the UE4Engine from git hub. I’m running linux (Studio Ubuntu).
The installation worked fine, but the Editor constantly crashes and freezes my laptop.

Some problems are:

  • Most of the time it randomly freezes. Just rarely it crashes.

  • A reproducible trigger for a freezing event is: I try to draw a texture in the texture paint mode and as soon as I click into the scene it freezes.

  • I am not able to exit the program, as it always freezes when trying to exiting

As it mostly freezes and I have to forcefully kill my PC I don’t have a crash report (I guess).

Does anybody know a stable version for linux? Or does anybod have similar problems? Or does anybody know how I could get more information about why it freezes?

Best,

1 Like

Hello,
It also happened to me on Ubuntu 18.04 (from github release, v4.23.1) running UE4 Editor freezes completly my laptop (brand new laptop, so probably not coming from the hardware), either on starting UE4Editor or loading a project. If anyone knows about this I am interested also,

My hardware : CPU: GenuineIntel ‘Intel(R) Core™ i7-10510U CPU @ 1.80GHz’ (signature: 0x806EC)
Thanks,
Pacome

I experience a periodicly freeze every 3 to 5 seconds since 4.23 to 4.24. origin/4.22.3-release runs fine without this freeze. I am on Manjaro, Intel i7 with Gforce GTX 1070 Ti and latest nvidia driver 440.31

Hi Everyone.

I tried both the latest stable and 4.24 bot got no success.

I followed the guide, how to compile it on my Linux (Ubuntu 19.04), everything went smooth. Then when I start the engine, after a while (not immediately) I got this error:



Fatal error: [File:/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Private/VulkanMemory.cpp] [Line: 279] Out of Device Memory, Requested=2960.00Kb MemTypeIndex=7 << callstack too long >>
libUE4Editor-Core.so!FGenericPlatformMisc::RaiseException(unsigned int) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Core/Private/GenericPlatform/GenericPlatformMisc.cpp:477]
libUE4Editor-Core.so!FOutputDevice::LogfImpl(char16_t const*, ...) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Core/Private/Misc/OutputDevice.cpp:71]
libUE4Editor-VulkanRHI.so!VulkanRHI::FDeviceMemoryManager::Alloc(bool, unsigned long, unsigned int, void*, float, char const*, unsigned int) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Private/VulkanMemory.cpp:279]
libUE4Editor-VulkanRHI.so!VulkanRHI::FResourceHeapManager::AllocateBuffer(unsigned int, unsigned int, unsigned int, char const*, unsigned int) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Private/VulkanMemory.cpp:1505]
libUE4Editor-VulkanRHI.so!FVulkanResourceMultiBuffer::FVulkanResourceMultiBuffer(FVulkanDevice*, unsigned int, unsigned int, unsigned int, FRHIResourceCreateInfo&, FRHICommandListImmediate*) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Private/VulkanIndexBuffer.cpp:112]
libUE4Editor-VulkanRHI.so!FVulkanVertexBuffer::FVulkanVertexBuffer(FVulkanDevice*, unsigned int, unsigned int, FRHIResourceCreateInfo&, FRHICommandListImmediate*) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Private/VulkanVertexBuffer.cpp:12]
libUE4Editor-VulkanRHI.so!FVulkanDynamicRHI::RHICreateVertexBuffer(unsigned int, unsigned int, FRHIResourceCreateInfo&) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Private/VulkanVertexBuffer.cpp:29]
libUE4Editor-VulkanRHI.so!FVulkanDynamicRHI::CreateVertexBuffer_RenderThread(FRHICommandListImmediate&, unsigned int, unsigned int, FRHIResourceCreateInfo&) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Public/VulkanDynamicRHI.h:197]
libUE4Editor-Renderer.so!FRWBuffer::Initialize(unsigned int, unsigned int, EPixelFormat, unsigned int, char16_t const*, FResourceArrayInterface*) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/RHI/Public/RHIUtilities.h:221]
libUE4Editor-Renderer.so!FDeferredShadingSceneRenderer::ComputeLightGrid(FRHICommandListImmediate&, bool, FSortedLightSetSceneInfo&) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Renderer/Private/LightGridInjection.cpp:623]
libUE4Editor-Renderer.so!FDeferredShadingSceneRenderer::Render(FRHICommandListImmediate&) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Renderer/Private/DeferredShadingRenderer.cpp:1445]
libUE4Editor-Renderer.so!RenderViewFamily_RenderThread(FRHICommandListImmediate&, FSceneRenderer*) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Renderer/Private/SceneRendering.cpp:3473]
libUE4Editor-Renderer.so!TEnqueueUniqueRenderCommandType<FRendererModule::BeginRenderingViewFamily(FCanvas*, FSceneViewFamily*)::FDrawSceneCommandName, FRendererModule::BeginRenderingViewFamily(FCanvas*, FSceneViewFamily*)::$_91>::DoTask(ENamedThreads::Type, TRefCountPtr<FGraphEvent> const&) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/RenderCore/Public/RenderingThread.h:198]
libUE4Editor-Renderer.so!TGraphTask<TEnqueueUniqueRenderCommandType<FRendererModule::BeginRenderingViewFamily(FCanvas*, FSceneViewFamily*)::FDrawSceneCommandName, FRendererModule::BeginRenderingViewFamily(FCanvas*, FSceneViewFamily*)::$_91> >::ExecuteTask(TArray<FBaseGraphTask*, TSizedDefaultAllocator<32> >&, ENamedThreads::Type) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Core/Public/Async/TaskGraphInterfaces.h:847]
libUE4Editor-Core.so!FNamedTaskThread::ProcessTasksNamedThread(int, bool) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Core/Private/Async/TaskGraph.cpp:686]
libUE4Editor-Core.so!FNamedTaskThread::ProcessTasksUntilQuit(int) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Core/Private/Async/TaskGraph.cpp:582]
libUE4Editor-RenderCore.so!RenderingThreadMain(FEvent*) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/RenderCore/Private/RenderingThread.cpp:339]
libUE4Editor-RenderCore.so!FRenderingThread::Run() [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/RenderCore/Private/RenderingThread.cpp:488]
libUE4Editor-Core.so!FRunnableThreadPThread::Run() [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Core/Private/HAL/PThreadRunnableThread.cpp:25]
libUE4Editor-Core.so!FRunnableThreadPThread::_ThreadProc(void*) [/home/mudlee/Applications/UnrealEngine/Engine/Source/Runtime/Core/Private/HAL/PThreadRunnableThread.h:177]
libpthread.so.0!UnknownFunction(0x9181)
libc.so.6!clone(+0x3e)


I tried to run the engine then with -opengl, but then I get this:


Trying to force OpenGL RHI but the project does not have it in TargetedRHIs list

What should I do to use either Vulkan or OpenGL?

Same is happening on my laptop. OpenGL solves the problem for me.
OpenGL RHI:

I am using version 4.23.1 from git release downloaded as zip. Compiled in two different machines both with the same Ubuntu 19.04 clean installation.
It freezes between 27 seconds aproximately depends of the complexity of the scene. And got frozen for near 20 seconds. So it is usable in gaps of 20 seconds during 27 seconds of usability. That is very annoying.

There are nothing apparent related in the Logs. I don’t know how to discover what is happening.

I am using Vulkan and an AMD Radeon RX580 with 4GB where it freezes.
And in the other computer an NVIDIA GFX 750 1GB without the problem and with propietary 418.56 drivers.

So, it is apparently an AMD graphics related problem. I am using the open source drivers because there are no radeonpro for Ubuntu 19.04.

There are no CPU use neither GPU use. It is used as normally except when It need to draw everything after the freezes I receive a peak of GPU use.
But when I launch the game in Standalone Game that does not happen in the game.
I adjusted the garbage collector time without success. It appears not to be related.

Edit: As I wrote down, there are 100% CPU use in one core. I have a 8 core processor so that is why I treated it as “normal” CPU use (because average CPU usage was low).

I had a problem like yours. I compiled successfull in one computer but when I tried to run it crashed with SIGSEGV related to some localization that cannot be allocated. I don’t discovered the source of the problem but I decided to do a fresh install of Ubuntu 19.04 and it worked. I think that was something related with some conflicting library. Maybe you updated from previous version of Ubuntu instead of doing a fresh install. But curiously my working system (in another computer) was an upgraded Ubuntu 19.04 from 18.04.

I suggest you trying on a fresh install of Ubuntu 19.04

I discovered how it happens: It is CPU related. The GPU is still processing things when the freeze happens but one of the threads is consuming 100% on CPU and that freezes the UI. It is something related with how the Editor handle the main thread of the UI. So I am sure mine is a software (Unreal Editor) related problem and have nothing to do with Video / Hardware / Drivers.
I disabled all options of multithread that I can and it is working more stable but still freezes sometimes.
I updated the mesa-vulkan-drivers to 19.1.4 (I know it is not the lastest but it is newer than what I had). There are not big noticeable difference but a little of improvement in performance.

I am actually compiling a OpenGL version to test…

Compiled with OpenGL, run with -opengl4 and same issue. In the computer that does not happen is an AMD Phemon X4, and mine (where the Editor freezes) is an AMD FX™-8350
I dont understand why this heppens but it is very annoying and I cannot develop anything (it takes more time waiting to unfreeze the editor than what I can do when it is working). I will test the “master” branch but I don’t think it is fixed.

The master branch does not suffer of that. It is working better and don’t freezes.

Cant test it because master does not build today :frowning:

I have also some problems with lags all some seconds. And sometimes the engine crashes with the error: Assertion failed: bSuccess [File:/media/nvme0n1p1/UnrealEngine/Engine/Source/Runtime/VulkanRHI/Private/VulkanCommandBuffer.cpp] [Line: 388]

This occurs only since engine version 4.23

I can confirm that. I also use radeon card RX570. I tested on master branch (commit: 59ab8c296e9)

Master does it on my System UE4 Master 2019 12 06 15 00 52 - YouTube

Look at the statgraph.

Intel i7-7700, 16gb RAM, Gforce GTX 1070 Ti , nvdriver: 440-36

Same as Slasher006 for me. Huge frame spike every 5 seconds or so when running 4.24.1 w/ my rx580 and latest amdgpu drivers. Thought maybe it was specific to AMD but as seen above it is happening on a 1070 Ti as well.

Cross posting from discussion on #linux on discord.

The version of SDL that is precompiled and bundeld with linux is definitely not using libudev. If libudev was being used then SDL would not end up polling all /lib/input/event* devices every 3 seconds. I pulled down SDL and built a stand alone example, and I happen to have libudev installed, and I get no hitching on the same hardware. Wondering if there is some reason libudev is not being used in the SDL built for linux by Epic?

I made sure that I did not init SDL_JOYSTICK | SDL_GAMEPAD | SDL_SENSORS in LinuxPlatformApplicationMisc.cpp and commented out the checks in LinuxApplication.cpp and no more hitching, at all.

I know for a fact libudev is not being used because in my profiling I can see the function MaybeAddDevice being called, and when SDL_USE_LIBUDEV is true that code will never execute.

Simply rebuilding SDL using build.sh in the ThirdParty/SDL2 directory fixes all my htiches. When grepping the output of that script libudev is marked as found, and the better code path is now taken. Looking at the scripts in that folder, it is not apparent that libudev-dev is being installed by the package manager in the install_ubuntu.sh, and install-centos.sh scripts.

TLDR;
Either use libudev with SDL or do not init SDL_Joystick and you can have a hitch free UE4 too.

I tryed rebuilding SDL2 wich worked. But when i try to build the engine i get stuff like this:


[71/72] Link (lld) CrashReportClient-Linux-Development
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_dynapi.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_dynapi.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_dynapi.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_dynapi.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_dynapi.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_dynapi.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_error.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_error.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_error.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_error.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_error.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_error.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_log.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_log.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_log.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_log.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_log.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL_log.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL.c.o): contains a compressed section, but zlib is not available
ld.lld: error: /home/slasher006/UnrealEngine/Engine/Source/ThirdParty/SDL2/SDL-gui-backend/lib/Linux/x86_64-unknown-linux-gnu/libSDL2.a(SDL.c.o): contains a compressed section, but zlib is not available
ld.lld: error: too many errors emitted, stopping now (use -error-limit=0 to see all errors)
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Makefile:308: CrashReportClient] Fehler 5

:open_mouth:

zlib is installed i checked. Am i missing something here?

Since I was debugging i also installed sdl2 dev packages, and this is probably how i got libudev and zlib. But this should do it…
sudo apt install zlib1g-dev libsdl2-dev technically libsdl2-dev is not required but it ends up installing a bunch of dependencies that you probably also need.

On second thought that is your linker complaining. No idea why that would happen, actually. When I link though, i’m not using lld, i’m only using ld. So not sure why your build environment is choosing lld and mine is choosing ld. And it looks as if golang ran across a similar issue (cmd/go: build fails when setting linker to lld using ldflags · Issue #27110 · golang/go · GitHub) once upon a time…

I compile with the toochain that comes with the engine. Commenting out the check for joystick in LinuxApplication.cpp does nothing (as far as i can see).