I ran into the same error on an Azure Virtual Machine configured as a self-hosted Linux build agent for Azure DevOps. In our case, the problem was caused by insufficient memory. After increasing the VM size from 2 GB to 8 GB of RAM, the error was resolved.