lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Miles Barr <>
Subject Re: Lucene on Linux problem...
Date Mon, 04 Apr 2005 08:24:50 GMT
On Sat, 2005-04-02 at 10:29 +0200, Kristian Ottosen wrote:
> I wonder if there is general problem running Lucene on top of some of the
> journaling file systems like ReiserFS or Ext3?

I haven't had any problems running Lucene on either of those file
systems. I've done updates to the index while people are still searching
and it all worked fine.

> The problem may not appear immediately - but only after several
> thousand documents have been indexed in a row using a combination of
> IndexSearcher (check for duplicates) and IndexWriter (add document)
> operations.

Are you deleting the duplicates as you find them? i.e. are you closing
and opening reader/writers all the time? If you are, besides
recommending switching to batch updates, I suggest being really thorough
with closing everything, e.g.

IndexReader reader = null;
IndexWriter writer = null;

try {
    reader =* Path to index */);

    ... do the deletes ...

    reader = null;

    writer = new IndexWriter(index, /* Your analyzer */, false);

    ... do the deletes ....

    writer = null;
catch (IOException e) {
    ... do any error processing ...
finally {
    // We can do both these closes in the same finally block because if
    // reader is not null then writer is null, so we don't need to worry
    // about reader.close() throwing another IOException
    if (reader != null) {
        reader = null;

    if (writer != null) {
        writer = null;

Miles Barr <>
Runtime Collective Ltd.

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

View raw message