Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 58784 invoked from network); 20 May 2009 11:27:14 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 20 May 2009 11:27:14 -0000 Received: (qmail 65141 invoked by uid 500); 20 May 2009 11:27:26 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 65061 invoked by uid 500); 20 May 2009 11:27:25 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 65051 invoked by uid 99); 20 May 2009 11:27:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 20 May 2009 11:27:25 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of zhengji.li@gmail.com designates 209.85.198.235 as permitted sender) Received: from [209.85.198.235] (HELO rv-out-0506.google.com) (209.85.198.235) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 20 May 2009 11:27:18 +0000 Received: by rv-out-0506.google.com with SMTP id g37so120355rvb.35 for ; Wed, 20 May 2009 04:26:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type:content-transfer-encoding; bh=K8Z4U6bkt/gtuNYQI6Y+7g8xgrIsVYyXTfz7YheYOhc=; b=rC6MQ48UgFgK4aZBx3FQWvbdh2yNKRDGAj9M/rtd2w7tGK1zhWmmNbO2ph9b5R/Wio yt4QuZoCO0NgplNrNtCIRkllWdGy6t51Mi3p4WHYLN8ty8/HUG2IZpeEXQmc5oTE2U2y z11x2AjfDa7wEMZU3qGBBxoZNdoY5K+hCZdBY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type :content-transfer-encoding; b=DjqCE5rwAIDTDer71tye9UFIlrsK5zp8PBjhTT0iR9TUVvn0vp2zbADyG8aSb0BI25 GveQoAKDd/NtmrLCc0qHhmmF2g+0+duv6XTpiagG9/Qgs7oHo3alEhj9f62e1iX5stOE UxeA4VBNSV4u55XzR6w0G7O66EQzyc/nL+QbU= MIME-Version: 1.0 Received: by 10.110.37.3 with SMTP id k3mr29000tik.1.1242818816956; Wed, 20 May 2009 04:26:56 -0700 (PDT) Date: Wed, 20 May 2009 19:26:56 +0800 Message-ID: Subject: DB compaction on Windows From: Li Zhengji To: user@couchdb.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org As we know, BEAM emulator need to add a share mode bit when calling CreateFile (GENERIC_SHARE_DELETE) for DB compaction. It's difficult for me to compile the emulator, so I have tried IDA instead. Here is a quick fix for R13B(5.7.1) beam.smp.dll (MD5: 4c733eaef7f8619cbac0c9a4b84e20d2): Change the byte at 0xB5720 from 0x03 to 0x07. Enjoy DB compaction. For a better solution, could someone here ask the Erlang/OTP team to modify the emulator? -- Li Zhengji