lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dan Gould <>
Subject Re: JVM Crash in Lucene
Date Sun, 11 Dec 2005 09:10:49 GMT
First, thank you Chris, Yonik, and Dan for your ideas as to what might be 
causing this problem.

I tried moving things around so that the IndexReader is still open when it 
calls TermFreqVector.getTerms()/TermFreqVector.getTermFrequencies().  It 
didn't seem to make any difference.

I also tried running Java with the flags:
-Xmx2048m -XX:MaxPermSize=200m
(the box has 4GB of RAM) and it still crashes.  It's hard to tell, but the 
program does seem to run for a lot longer (maybe 10 hours), but that could 
just be randomness in my tests.

The JVM always seems to crash with

  Current CompileTask:
  (99 bytes)

which in the Lucene source is:

   private static IndexReader open(final Directory directory, final boolean 
closeDirectory) throws IOException {
     synchronized (directory) {			  // in- & inter-process 
       return (IndexReader)new Lock.With(
           IndexWriter.COMMIT_LOCK_TIMEOUT) {
           public Object doBody() throws IOException {
             SegmentInfos infos = new SegmentInfos();
             if (infos.size() == 1) {		  // index is optimized
               return SegmentReader.get(infos,, 
             IndexReader[] readers = new IndexReader[infos.size()];
             for (int i = 0; i < infos.size(); i++)
               readers[i] = SegmentReader.get(;
             return new MultiReader(directory, infos, closeDirectory, 


that's definitely a non-trivial bit of code, but I can't imagine that 
there's a problem that I'm seeing that no one else else.  Moreover, that 
code gets run hundreds or even thousands of times before it crashes, so I 
don't image it's being HotSpot-compiled for the first time.

I'm running the 1.4.3 release and the 1.5.0_06-b05 JVM on Centos Linux on 
an Opteron.

Any further guesses?

Thank you all very much,

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message