Skip to main content

Introduction

Yocto builds often compile large components such as LLVM, which require significant memory. Builds may fail with out-of-memory (OOM) errors if sufficient RAM or swap is not available. This section describes methods to increase available system memory and improve build stability.

Increase Swap Space

If your build fails due to OOM errors, increase the swap space to at least 32 GB (recommended: 64 GB). Run the following commands to resize the swap file

Increase zram

You can also increase compressed in-memory swap (zram) to improve memory usage efficiency