lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: problem about backup index file
Date Fri, 26 Feb 2010 06:47:57 GMT
thanks for your paper,Michael McCandlessI have one quetion about thisFor all other files, Lucene
is "write once.”This makes doing
incremental backups very easy: Simply compare the file names.Once a
file is written, it will never change; therefore, if you've already
backed up that file, there's no need to copy it again.this means the number of files is growing
more and more.never getting less.another question:I should delete the files previous I backup
when I backup again. ----- 原文 ----- 发件人: Michael McCandless 主 题: Re: problem
about backup index file时 间: 2010年2月25日  23:19:59This is likely happening because
you're attempting to copy a file thatIndexWriter is currently writing?You shouldn't do that
(copy files that are still being written) --that just wastes bytes (they aren't used by the
index), and causesthis failure on Windows.Instead, you should use SnapshotDeletionPolicy --
it tells youspecifically which files make up the latest commit point.  Those fileswill not
be opened for writing (only for reading, if you have anIndexReader open on that commit) and
they should copy just fine onwindows.The "Hot backups with Lucene" article (NOTE: I'm the
author) inupcoming Lucene in Action 2 revision shows how to do this -- it'savailable for download
from Thu, Feb 25, 2010 at 3:15 AM,  <>
wrote:> I want backup my index file,but I get the follow error.> another
program lock the file! at Method) at Source) at com.common.Utils.copyDirectory( at
com.common.Utils.copyDirectory( at com.common.Utils.copyDirectory( at
com.index.IndexManager.backDataPolicy( at com.index.IndexManager.indexLoop( at
com.Main$ at Source)>
 > How can I backup lucene file in IR thread.---------------------------------------------------------------------To
unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.orgFor additional commands, e-mail:
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message