Strange behavoir when building UE4 from sources

What’s up guys.

I try to build UE4 (version 4.27) from sources on Ubuntu 24.04 (x86-64). My desktop - Intel Xeon with 28 logical cores, RAM - 64 Gb.

When I do make -j28 my display turns off and ubuntu automatically logs me out from ui session. The same situation is with make -j14.

All works only with make but it’s very very slowly. What I do wrong ? Maybe there are some parameters to adjust memory consumption during the building ? or something else.

hey welcome. are you a bot?

you don’t pass the amount of threads to make. ubt already spawns and manages the max amount.

the threads are not the only limiting factor. the ram is, as each thread consumes a good amount of ram.

in fact it’s the free ram, so if you have something open before starting it will make it swoler.

my display turns off and ubuntu automatically logs me out from ui session.

that in linux sometimes means something crashes so badly that linux killed the session. can happen if you exhaust the system ram.

64gb is a good amount, though i’m not sure you can max out 14 cores. you should check with something like htop or gkrellm to see if you are maxing your cores or ram.

btw, not sure why you’re trying ue4 instead of 5 (5.5/5.6 works pretty well)

Hello @nande . No I’am not a bot. I’am a man. Now my device supports only opengl es hence i use ue4. Yes, I will try htop. Many thanks. I will write here results of tests.

p.s. I closed all applications and launch only ubuntu’s terminal.

1 Like

awesome.

sorry your name threw me off.

it’s important also to check your disk speed, as that can make the things slower.

also make sure you have a swap file or partition just in case, though be careful, as when you fill up your ram, and things have to be swapped it can become slow or unresponsive.

that won’t happen with ue compiling, but it might happen if you have too many apps open or if you open something else while ue is compiling.

in any case, having swap is better than not, otherwise linux has no other option than to kill the apps, or apps can simply crash when requesting memory.

kde has an app for monitoring the system, i think gnome does too. have a look at it, as it shows the disk, memory, and swap activity. all those are good indicators.

good luck, keep us posted.

I’ve built the engine from sources. How to clean all generated binaries, object files in order to repeat the problem?

just delete the intermediate, binary, and saved folders. under the Engine folder

1 Like

Very interesting. I move the ue4 sources to SSD that is connected via USB 3.1 and now I can’t repeat the problem. All works good.

But all cores are loaded at 100%

1 Like

Another image.

good, looks like you’re maxing out your cpu now.

so the ssd is fast enough and i see some slack in your ram, so you might be fine.

just a note, i personally am dubious about putting ue on an external drive.

by default on linux/some distros mounted external devices get the “noexec” flag, which means you can’t run programs stored on that disk.

you can check it with the command “mount”

also some files will still be located in your home directory, so i’m not sure how portable it is.

permissions can create issues, i have heard issues for people trying to share the same build with multiple users even on the same machine.