From owner-svn-src-head@FreeBSD.ORG Mon Apr 5 09:17:19 2010 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2E357106564A; Mon, 5 Apr 2010 09:17:19 +0000 (UTC) (envelope-from avg@freebsd.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 04CB88FC1B; Mon, 5 Apr 2010 09:17:17 +0000 (UTC) Received: from porto.topspin.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id MAA05163; Mon, 05 Apr 2010 12:17:13 +0300 (EEST) (envelope-from avg@freebsd.org) Received: from localhost.topspin.kiev.ua ([127.0.0.1]) by porto.topspin.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1NyiQi-000FHX-NL; Mon, 05 Apr 2010 12:17:12 +0300 Message-ID: <4BB9AA98.1000701@freebsd.org> Date: Mon, 05 Apr 2010 12:17:12 +0300 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.24 (X11/20100321) MIME-Version: 1.0 To: Peter Jeremy , Kostik Belousov References: <201004030839.o338d0VV032828@svn.freebsd.org> <20100404210314.GH86236@server.vk2pj.dyndns.org> <4BB9006A.8080301@freebsd.org> <20100404212742.GJ2415@deviant.kiev.zoral.com.ua> <20100404221232.GJ86236@server.vk2pj.dyndns.org> <4BB99EDB.8030105@freebsd.org> In-Reply-To: <4BB99EDB.8030105@freebsd.org> X-Enigmail-Version: 0.96.0 Content-Type: text/plain; charset=KOI8-U Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r206129 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Apr 2010 09:17:19 -0000 on 05/04/2010 11:27 Andriy Gapon said the following: > Additionally, as noted above (and if I am not mistaken), the problem would > manifest itself when creating a new db in an existing file and the file has to > be large enough. OK, this is a nonsense, I misunderstood the code. The problem should manifest itself upon creating a new hash db in a (new) file. E.g. something like: dbopen("filename", O_RDWR | ..., ..., DB_HASH, ...) The good news is that the last optional argument (as in can be NULL) to dbopen provides overrides for certain parameters including block size. And it seems that in all places where dbopen is used by FreeBSD userland utilities in the above fashion, that last argument is indeed specified and has a sufficiently small block size value. And I've been wondering why I have never seen any problems with this change locally - I've been using it for quite a while before committing it. P.S. here is a command that I used for searching: $ find . -name "*.c" | xargs fgrep -w -A1 dbopen /dev/null | grep -v '^--' | paste - - | fgrep DB_HASH | fgrep O_RDWR -- Andriy Gapon