Return-Path: Delivered-To: apmail-lucene-java-dev-archive@www.apache.org Received: (qmail 24395 invoked from network); 16 Nov 2007 14:15:07 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 16 Nov 2007 14:15:07 -0000 Received: (qmail 71336 invoked by uid 500); 16 Nov 2007 14:14:51 -0000 Delivered-To: apmail-lucene-java-dev-archive@lucene.apache.org Received: (qmail 71291 invoked by uid 500); 16 Nov 2007 14:14:51 -0000 Mailing-List: contact java-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@lucene.apache.org Delivered-To: mailing list java-dev@lucene.apache.org Received: (qmail 71276 invoked by uid 99); 16 Nov 2007 14:14:51 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Nov 2007 06:14:51 -0800 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Nov 2007 14:14:50 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 9974E714249 for ; Fri, 16 Nov 2007 06:14:43 -0800 (PST) Message-ID: <9546957.1195222483625.JavaMail.jira@brutus> Date: Fri, 16 Nov 2007 06:14:43 -0800 (PST) From: "Chris Bowditch (JIRA)" To: java-dev@lucene.apache.org Subject: [jira] Issue Comment Edited: (LUCENE-425) "Cannot rename segments.new to segments" MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/LUCENE-425?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12543081 ] cbowditch edited comment on LUCENE-425 at 11/16/07 6:13 AM: ----------------------------------------------------------------- We have been using Lucene 1.9.1 for the past 2 years and this issue occurs on a regular basis. Always on Windows and more often on machines with slower hard disks, i.e. Laptops. A colleague of mine downloaded the source and patched it to retry the rename and delete operations several times before giving up. This works well on our environments so we would like to get the change into Trunk code. I will prepare a patch against trunk shortly which will solve the problem. was (Author: cbowditch): We have been using Lucene 1.9.1 for the past 2 years and this issue occurs on a regular basis. Always on Windows and more often on machines with slower hard disks, i.e. Laptops. A colleague of my downloaded the source and patched it to retry the rename and delete operations several times before giving up. I will prepare a patch against trunk shortly which will solve the problem. > "Cannot rename segments.new to segments" > ---------------------------------------- > > Key: LUCENE-425 > URL: https://issues.apache.org/jira/browse/LUCENE-425 > Project: Lucene - Java > Issue Type: Bug > Components: Index > Affects Versions: 1.4 > Environment: Operating System: Windows XP > Platform: PC > Reporter: Mikko Noromaa > > AddDocument periodically fails with "Cannot rename segments.new to segments". > Sometimes it happens after 10,000 documents, sometimes after 200,000 documents. > My index is placed on a FAT partition. My Lucene version is 1.4.3. I am using > a single IndexWriter object and doing all AddDocuments calls serially from a > single thread. > I saw some discussion about this problem in the mailing lists, but looks like > the problem wasn't completely eliminated yet. > My suggested solutions are as follows: > - If renameTo() fails, wait some time and retry. After this, apply the other > methods that are now in FSDirectory.java. Retry them as well after waiting for > some time. > - In the IndexWriter constructor, check for 'segments.new' if 'segments' > cannot be found. This would allow recovery if FSDirectory failed on a previous > run. Now I have to write the recovery code myself outside of Lucene. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org For additional commands, e-mail: java-dev-help@lucene.apache.org