From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27294 invoked from network); 17 May 2002 18:15:33 -0000 Received: from unknown (HELO fencepost.gnu.org) (199.232.76.164) by sources.redhat.com with SMTP; 17 May 2002 18:15:33 -0000 Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 178mFu-0005aH-00; Fri, 17 May 2002 14:15:06 -0400 Received: from cluster2.netman.dk ([193.88.72.48]) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 178mF7-0005Tm-00 for ; Fri, 17 May 2002 14:14:17 -0400 Received: (from lh@localhost) by cluster2.netman.dk (8.11.4/8.11.4) id g4HID3m1561507; Fri, 17 May 2002 20:13:03 +0200 (MEST) From: Lars Henriksen To: Dirk Bergstrom Cc: Mel Hatzis , help-gnats@gnu.org Subject: Re: use of GNATSDB Message-ID: <20020517181303.GA1558598@cluster2.netman.dk> References: <3CA28C27.6010201@juniper.net> <20020517120308.GA1524344@cluster2.netman.dk> <3CE53E5E.2080402@juniper.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3CE53E5E.2080402@juniper.net> User-Agent: Mutt/1.3.25i Sender: help-gnats-admin@gnu.org Errors-To: help-gnats-admin@gnu.org X-BeenThere: help-gnats@gnu.org X-Mailman-Version: 2.0.9 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: General discussion about GNU GNATS List-Archive: Date: Fri, 17 May 2002 11:15:00 -0000 X-SW-Source: 2002-q2/txt/msg00050.txt.bz2 On Fri, May 17, 2002 at 10:31:10AM -0700, Dirk Bergstrom wrote: > On 5/17/2002 5:03 AM, this issued forth from the mind of Lars Henriksen: > > I can't reproduce this behaviour. Whether GNATSDB is set or not, the command > > "pr-edit --lockdb" seems to lock nothing at all. Neither does "pr-edit > > --database= --lockdb". On the other hand, "pr-edit --lock " > > honors GNATSDB as well as the --database option. > > this is a totally different issue. Is it? The issue is how or whether GNATSDB is honered by (for example) pr-edit and it was claimed, without reservations, that it always ended up locking the default database. As far as I can see, you confirm below that this is not the case. > so in pr-edit, the "network mode" lockdb code opens a socket to gnatsd > and issues a LKDB command, and gnatsd locks the database. ... > in "localhost > mode", pr-edit makes a call to gnats_lock() (actually, it calls foo, > which calls bar, which calls gnats_lock), which is the same call that > gnatsd makes. this *does* lock the database, but then, at the very end > of main(), there's a check that says something like: > > if (gnats_locked) { > unlock_gnats() > } > > this check is entirely reasonable, if you're trying to do an edit, or an > append, but it's just wrong if you're trying to lock the database. Thanks for the explanations. They agree with my observations. > so, you happen to have run into one of the many, many subtle and > outrageous bugs in localhost mode. this is why i counsel people to > *always* use network mode, even when talking to a local database. But of course you are right that this behaviour has nothing to do with GNATSDB. > how, you ask, do you make sure you're using network mode? by specifying > either --host or --port or both. Or by setting GNATSDB to point to the remote database. Lars Henriksen _______________________________________________ Help-gnats mailing list Help-gnats@gnu.org http://mail.gnu.org/mailman/listinfo/help-gnats