Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id E7E7B200BD4 for ; Fri, 16 Dec 2016 22:22:16 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id E68B7160B10; Fri, 16 Dec 2016 21:22:16 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 3D7EE160B24 for ; Fri, 16 Dec 2016 22:22:16 +0100 (CET) Received: (qmail 98561 invoked by uid 500); 16 Dec 2016 21:22:15 -0000 Mailing-List: contact user-help@lucy.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@lucy.apache.org Delivered-To: mailing list user@lucy.apache.org Received: (qmail 98492 invoked by uid 99); 16 Dec 2016 21:22:15 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Dec 2016 21:22:15 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id B47551800B7 for ; Fri, 16 Dec 2016 21:22:14 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.999 X-Spam-Level: X-Spam-Status: No, score=-1.999 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id WpKDBycjMMSE for ; Fri, 16 Dec 2016 21:22:12 +0000 (UTC) Received: from hosting04.aevum.de (hosting04.aevum.de [188.68.58.30]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 1D5855F251 for ; Fri, 16 Dec 2016 21:22:11 +0000 (UTC) Received: from [IPv6:2001:a61:11c4:201:e56b:4c8f:8b5c:2c58] (unknown [IPv6:2001:a61:11c4:201:e56b:4c8f:8b5c:2c58]) by hosting04.aevum.de (Postfix) with ESMTPSA id 3F8FD60053 for ; Fri, 16 Dec 2016 22:22:08 +0100 (CET) To: user@lucy.apache.org References: <415e1dbe-27fe-3dab-2ed4-8ca57ebfab99@aevum.de> <61261e18-7351-17fd-00df-c26f564f7d9f@aevum.de> From: Nick Wellnhofer Message-ID: Date: Fri, 16 Dec 2016 22:22:09 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [lucy-user] LUCY_Folder_Open_Out_IMP at core/Lucy/Store/Folder.c line 119 archived-at: Fri, 16 Dec 2016 21:22:17 -0000 On 13/12/2016 18:05, Gupta, Rajiv wrote: > After I create directory by myself I'm getting this error: Which directory do you try to create? I wouldn't try to make manual changes inside Lucy's index directory. This will only make things worse. > Can't open '/u/smoke/presub/logs/cit-fg-adr-neg-rtp.rajivg.1481473130.41339_cmode_1of1/.lucyindex/1/seg_fd/lexicon-7.ixix': Invalid argument > 20161211 182109 [] * LUCY_FSFolder_Local_Open_FileHandle_IMP at core/Lucy/Store/FSFolder.c line 118 > 20161211 182109 [] * LUCY_Folder_Local_Open_In_IMP at core/Lucy/Store/Folder.c line 101 > 20161211 182109 [] * LUCY_Folder_Open_In_IMP at core/Lucy/Store/Folder.c line 75 > > There are two more failures they also failed due so similar reasons > > rename from '/u/smoke/presub/logs/cit-fg-adr-ndo-rtp.rajivg.1481473039.49384_cmode_1of1/.lucyindex/1/schema.temp' to '/u/smoke/presub/logs/cit-fg-adr-ndo-rtp.rajivg.1481473039.49384_cmode_1of1/.lucyindex/1/schema_e4.json' failed: No such file or directory > > Can't delete 'lexicon-3.ix' > > I believe all three are related to race condition while doing parallel indexing and should go away with retries. However my retries started failing with different error which is strange to me as if directory already exists shouldn't it skip from create attempt. > > 20161211 182109 [] * FAIL: [FAILED]: Retrying to add doc at path: /u/smoke/presub/logs/cit-fg-adr-neg-rtp.rajivg.1481473130.41339_cmode_1of1/.lucyindex/1 : Couldn't create directory '/u/smoke/presub/logs/cit-fg-adr-neg-rtp.rajivg.1481473130.41339_cmode_1of1/.lucyindex/1': No such file or directory > 20161211 182109 [] * LUCY_FSFolder_Initialize_IMP at core/Lucy/Store/FSFolder.c line 102 > > So my all retry attempts were also failed. These errors still look like multiple processes are modifying the index at the same time. Are you really sure that every indexer is created with an IndexManager and that every IndexManager is created with a `host` argument that is unique to each machine? All these errors mean that there's something fundamentally wrong with your code or that you hit a bug in Lucy. The only type of error where it makes sense to retry is LockErr. All other errors are mostly fatal and could result in index corruption. Retrying will only mask an underlying problem in this case. Unfortunately, I'm unable to help unless you provide some kind of self-contained, reproducible test case. I'm aware that this isn't easy, especially with multiple clients writing to a shared volume. As I already hinted at, you might want to reconsider your architecture and use some kind of search server that uses an index on a local filesystem. There are ready-made platforms on top of Lucy like Dezi, but it isn't too hard to roll your own solution. This should result in better performance and makes behavior of your code more predictable. Nick