MMapDirectory should only be used on 64bit machines with 64bit JVMs. This is described in the Javadocs.
The additional sizes are caused by reopens and have their reason in specialties with the Java VM, described in 2.9/3.0 Javadocs of the class, please take a look. You can also enable a workaround for the missing “unmap” call. ----- Uwe Schindler H.-H.-Meier-Allee 63, D-28213 Bremen <http://www.thetaphi.de/> http://www.thetaphi.de eMail: u...@thetaphi.de From: luocanrao [mailto:luocan19826...@sohu.com] Sent: Saturday, January 30, 2010 8:31 AM To: java-user@lucene.apache.org Subject: MMapDirectory need twice more virtual memory than actually need? Environment: 64 bit linux,memory 8G When I used pmap instruction to see virtual memory, I found two big anon memory which grows with the index file size. I had the two following pictures to show the problem, can you explain? This is why I got out of memory exception in 32 bit machine. Because my index file size is only 800m. Anon memory picture Indexfile memory picture