I am trying to limit the maximum memory used by the VM on Linux and thought
that something like -mmap 2048m or -memory 2048m (or a combination of both)
would do the job. However, these flags appear to either be ignored or
aren't working in a way that's obvious to me. So what is the preferred way
to limit the maximum RAM footprint of the VM these days?