Re: Xapian locking errors with custom query parser
authorAustin Clements <amdragon@mit.edu>
Fri, 28 Jan 2011 16:35:03 +0000 (11:35 +1900)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:37:48 +0000 (09:37 -0800)
6f/9446f513d9fac5bcc0425d4e1c1c8f690a5d63 [new file with mode: 0644]

diff --git a/6f/9446f513d9fac5bcc0425d4e1c1c8f690a5d63 b/6f/9446f513d9fac5bcc0425d4e1c1c8f690a5d63
new file mode 100644 (file)
index 0000000..1c33a3d
--- /dev/null
@@ -0,0 +1,160 @@
+Return-Path: <amdragon@gmail.com>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 7BC7B431FB6\r
+       for <notmuch@notmuchmail.org>; Fri, 28 Jan 2011 08:35:07 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.698\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.698 tagged_above=-999 required=5\r
+       tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FREEMAIL_FROM=0.001,\r
+       HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id YQ8KLddUJvuA for <notmuch@notmuchmail.org>;\r
+       Fri, 28 Jan 2011 08:35:06 -0800 (PST)\r
+Received: from mail-vw0-f53.google.com (mail-vw0-f53.google.com\r
+       [209.85.212.53]) (using TLSv1 with cipher RC4-MD5 (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id 7929A431FB5\r
+       for <notmuch@notmuchmail.org>; Fri, 28 Jan 2011 08:35:06 -0800 (PST)\r
+Received: by vws8 with SMTP id 8so1299179vws.26\r
+       for <notmuch@notmuchmail.org>; Fri, 28 Jan 2011 08:35:03 -0800 (PST)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma;\r
+       h=domainkey-signature:mime-version:sender:in-reply-to:references:date\r
+       :x-google-sender-auth:message-id:subject:from:to:cc:content-type;\r
+       bh=3XBKkErOTfs11dGXuzaBWWgyfgh3B+fBA/kHEbj+bJU=;\r
+       b=sm9twBYvjoTfULT4bfdYLEEaKdoAqkfmmQ7Zs5n2nEoqlcdSNDYE7tsWATUExdS4EW\r
+       m0Z/UpPYs4AwL3sQ6mGPsI1JgQALl52P2J8ZOsZY5xWT2Aqub6nLLWAcZq6f22/Fm9Yo\r
+       jGKFORst4hKE1ygO/u2KhlHOtnVLHOis5AXPU=\r
+DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma;\r
+       h=mime-version:sender:in-reply-to:references:date\r
+       :x-google-sender-auth:message-id:subject:from:to:cc:content-type;\r
+       b=bQ1LeVrHyBP4SVoS8fT3GPxjkbVOSU8KW80prwaKc/9bJ2Uhf9a8phKVyA2dcWrTsH\r
+       VWVS1JbiiXINF8sHs9ND+UluH3juKciuTyW0u57db/eZD5apyRPFD2gxctQE1VbQ51gI\r
+       e7ljifzLe0VG9aXmnIfZ9M7G8Wjir+N1q+HEY=\r
+MIME-Version: 1.0\r
+Received: by 10.229.90.200 with SMTP id j8mr371587qcm.268.1296232503187; Fri,\r
+       28 Jan 2011 08:35:03 -0800 (PST)\r
+Sender: amdragon@gmail.com\r
+Received: by 10.229.97.143 with HTTP; Fri, 28 Jan 2011 08:35:03 -0800 (PST)\r
+In-Reply-To: <87d3nhe3g9.fsf@steelpick.2x.cz>\r
+References: <87d3nhe3g9.fsf@steelpick.2x.cz>\r
+Date: Fri, 28 Jan 2011 11:35:03 -0500\r
+X-Google-Sender-Auth: OvtkSP21LeXb3LPBBwXljMNq7vs\r
+Message-ID: <AANLkTinW_n+zMtLC-fy=naUGsAiFDwdd-mAqSWEDvF=W@mail.gmail.com>\r
+Subject: Re: Xapian locking errors with custom query parser\r
+From: Austin Clements <amdragon@mit.edu>\r
+To: Michal Sojka <sojkam1@fel.cvut.cz>\r
+Content-Type: multipart/alternative; boundary=001636aa2b74e61969049aeaa589\r
+Cc: notmuch@notmuchmail.org\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Fri, 28 Jan 2011 16:35:07 -0000\r
+\r
+--001636aa2b74e61969049aeaa589\r
+Content-Type: text/plain; charset=ISO-8859-1\r
+\r
+This should most definitely not happen.  I'll look in to it.\r
+\r
+On Fri, Jan 28, 2011 at 5:18 AM, Michal Sojka <sojkam1@fel.cvut.cz> wrote:\r
+\r
+> Hi Austin,\r
+>\r
+> when I switched to using your custom query parser I started experiencing\r
+> "Unable to get write lock" errors when I run my initial tagging script.\r
+> I thought that this was because I run the script while processing the\r
+> mail in Emacs, but today I realized that this happens even without Emacs\r
+> and that it can be reproduced by a simple command below.\r
+>\r
+> i=0; while notmuch tag +xxx tag:whatever; do i=$((i+1)); echo $i; done\r
+>\r
+> It seems that sometimes the unlocking of the Xapian database happens\r
+> somewhat lazily and when the subsequent command starts I get:\r
+>\r
+> A Xapian exception occurred opening database: Unable to get write lock on\r
+> /home/wsh/mail/.notmuch/xapian: already locked\r
+>\r
+> This happens almost regularly after a few iterations of the loop even if\r
+> the query doesn't match anything.\r
+>\r
+> Do you have an idea what may cause this?\r
+>\r
+> Can you reproduce this on your system?\r
+>\r
+> The version I use can be obtained from\r
+>\r
+>  git://rtime.felk.cvut.cz/notmuch.git custom-query-pasrser\r
+>\r
+> Thanks\r
+> -Michal\r
+> _______________________________________________\r
+> notmuch mailing list\r
+> notmuch@notmuchmail.org\r
+> http://notmuchmail.org/mailman/listinfo/notmuch\r
+>\r
+\r
+--001636aa2b74e61969049aeaa589\r
+Content-Type: text/html; charset=ISO-8859-1\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+This should most definitely not happen. =A0I&#39;ll look in to it.<br><br><=\r
+div class=3D"gmail_quote">On Fri, Jan 28, 2011 at 5:18 AM, Michal Sojka <sp=\r
+an dir=3D"ltr">&lt;<a href=3D"mailto:sojkam1@fel.cvut.cz">sojkam1@fel.cvut.=\r
+cz</a>&gt;</span> wrote:<br>\r
+<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=\r
+x #ccc solid;padding-left:1ex;">Hi Austin,<br>\r
+<br>\r
+when I switched to using your custom query parser I started experiencing<br=\r
+>\r
+&quot;Unable to get write lock&quot; errors when I run my initial tagging s=\r
+cript.<br>\r
+I thought that this was because I run the script while processing the<br>\r
+mail in Emacs, but today I realized that this happens even without Emacs<br=\r
+>\r
+and that it can be reproduced by a simple command below.<br>\r
+<br>\r
+i=3D0; while notmuch tag +xxx tag:whatever; do i=3D$((i+1)); echo $i; done<=\r
+br>\r
+<br>\r
+It seems that sometimes the unlocking of the Xapian database happens<br>\r
+somewhat lazily and when the subsequent command starts I get:<br>\r
+<br>\r
+A Xapian exception occurred opening database: Unable to get write lock on /=\r
+home/wsh/mail/.notmuch/xapian: already locked<br>\r
+<br>\r
+This happens almost regularly after a few iterations of the loop even if<br=\r
+>\r
+the query doesn&#39;t match anything.<br>\r
+<br>\r
+Do you have an idea what may cause this?<br>\r
+<br>\r
+Can you reproduce this on your system?<br>\r
+<br>\r
+The version I use can be obtained from<br>\r
+<br>\r
+ =A0git://<a href=3D"http://rtime.felk.cvut.cz/notmuch.git" target=3D"_blan=\r
+k">rtime.felk.cvut.cz/notmuch.git</a> custom-query-pasrser<br>\r
+<br>\r
+Thanks<br>\r
+-Michal<br>\r
+_______________________________________________<br>\r
+notmuch mailing list<br>\r
+<a href=3D"mailto:notmuch@notmuchmail.org">notmuch@notmuchmail.org</a><br>\r
+<a href=3D"http://notmuchmail.org/mailman/listinfo/notmuch" target=3D"_blan=\r
+k">http://notmuchmail.org/mailman/listinfo/notmuch</a><br>\r
+</blockquote></div><br>\r
+\r
+--001636aa2b74e61969049aeaa589--\r