From owner-cvs-src@FreeBSD.ORG Thu Aug 31 01:40:45 2006 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3CFD616A4E2; Thu, 31 Aug 2006 01:40:45 +0000 (UTC) (envelope-from trhodes@FreeBSD.org) Received: from pittgoth.com (ns1.pittgoth.com [216.38.206.188]) by mx1.FreeBSD.org (Postfix) with ESMTP id C934B43D45; Thu, 31 Aug 2006 01:40:44 +0000 (GMT) (envelope-from trhodes@FreeBSD.org) Received: from localhost (net-ix.gw.ai.net [205.134.160.6] (may be forged)) (authenticated bits=0) by pittgoth.com (8.13.6/8.13.6) with ESMTP id k7V1efTs047623 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 30 Aug 2006 21:40:43 -0400 (EDT) (envelope-from trhodes@FreeBSD.org) Date: Wed, 30 Aug 2006 21:40:34 -0400 From: Tom Rhodes To: Garance A Drosehn Message-Id: <20060830214034.16396d37.trhodes@FreeBSD.org> In-Reply-To: References: <200608290920.k7T9KmV9067843@repoman.freebsd.org> <86zmdmfoow.fsf@dwp.des.no> <20060830202834.GA11284@rambler-co.ru> Organization: The FreeBSD Project X-Mailer: Sylpheed version 1.0.6 (GTK+ 1.2.10; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, ru@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: "Chatty" config files in /etc X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 Aug 2006 01:40:45 -0000 On Wed, 30 Aug 2006 20:15:57 -0400 Garance A Drosehn wrote: > At 12:28 AM +0400 8/31/06, Ruslan Ermilov wrote: > >On Wed, Aug 30, 2006 at 01:41:51PM -0400, Garance A Drosehn wrote: > > > > > ... I wonder if it would be better to > > > have the comments and examples as files under /etc/defaults. I > > > suppose they could also go under /usr/share/examples, but for > > > these files I think there is some advantage that the comments > > > and examples be on '/', and not on '/usr'. > > > > >> Also, if the comment+example files are under /etc/defaults, then > >> changes to them *will* come up in mergemaster. It's just that > >> now they will show up in a file that has no local changes, so > >> the user can just read the change, instead of having to "merge" > > > all their local changes with the new official version. > > > >I think they should be moved to /usr/share/examples/etc/ (like > >make.conf), with files in /etc/ representing good (short) defaults > >with a minimum of comments and probably references to examples. > > Well, my thinking was something like: > > a) these example/comment files are for "system" things. Many > people mount their /usr directories from somewhere else, > thus /usr might not be an exact match for the running kernel. > (note that make.conf makes sense for /usr/share/examples, > because the `make` command is also under /usr). > b) by putting them in /etc/defaults, users do *see* the changes > when they run mergemaster, even though they won't have to > merge those changes with local changes. In some cases the > changes to the comments or examples will suggest some change > that the user should be making to their own already-working > configuration, even though their configuration won't match > the default system-config. I'm thinking when some comment > is added like: > # NOTE: Please see pf.conf(5) BUGS section before > # using user/group rules. > > As a sysadmin, I do not stop and read every man page when > it changes. But if I see a comment like that added to > pf.conf when I run mergemaster, then I *will* take the > time to read pf.conf(5) to see what this (possibly new) > issue is. > > So the file we install as /etc/pf.conf could easily be changed to: > > # $FreeBSD: src/etc/pf.conf,v 1.---- 2006/04/04 20:31:20 mlaier Exp $ > # > # See pf.conf(5) for syntax, and /etc/defaults/pf.conf for a detailed > # example of this file. The directory /usr/share/examples/pf contains > # some additional example configurations. > > # Required order: options, normalization, queueing, translation, filtering. > # Macros and tables may be defined and used anywhere. > # Note: translation rules are first match while filter rules are last match. > > # Filtering: the implicit first two rules are > #pass in all > #pass out all > > ...... and that's all. Just a 13-line file, with almost no > specific details in it. The few comments that are left are ones > which would always be helpful to have there as reminders, and > which are not likely to change over time. With any luck, we > should be able to go a few years without changing this file. I'm digging this idea. There are a lot of "basic" configuration files which either get modified or completely re-written. Perhaps we should start looking over those and consider moving them to defaults/ and have rc.conf default to there. We already do this with some files (rc.conf comes to mind) so why not all? ;) -- Tom Rhodes