Fixing “Cannot allocate memory” with Solr 5.2.1

If you run Solr on a VM, it may appear to start and fail. bin/solr start -p 8000 -f If you run it with “-f” (preventing backgrounding the process) you will then seen an out of memory error: Starting Solr on port 8983 from /root/solr-5.2.1/server OpenJDK 64-Bit Server VM warning: INFO: os::commit_memory(0x00000000e8000000, 402653184, 0) failed; …