Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 Dec 2023 07:59:09 -0600
From:      Mike Karels <mike@karels.net>
To:        d@delphij.net
Cc:        Craig Leres <leres@freebsd.org>, Konstantin Belousov <kostikbel@gmail.com>, freebsd-current@freebsd.org
Subject:   Re: Proposal: Disable compression of newsyslog by default
Message-ID:  <B41F5D19-22F1-4E54-81D4-8C938D6640C4@karels.net>
In-Reply-To: <c767270b-1bf3-4279-869c-274984fb137c@delphij.net>
References:  <ace7d170-acd1-4dc8-8016-a08c261d91f0@delphij.net> <ZYb0P4XSCxhoNHmo@kib.kiev.ua> <b0c6b054-090e-45f5-a1e0-ddc40efcc27f@freebsd.org> <71C3C779-ACD1-4FF4-A213-5DBCD7707ED7@karels.net> <c767270b-1bf3-4279-869c-274984fb137c@delphij.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On 25 Dec 2023, at 2:12, Xin Li wrote:

> On 2023-12-23 14:17, Mike Karels wrote:
>> On 23 Dec 2023, at 15:23, Craig Leres wrote:
>>
>>> On 12/23/23 06:52, Konstantin Belousov wrote:
>>>> This is strange change at best.  I have no opinion about the disabli=
ng
>>>> of compression of the rotated logs by default, but we already have k=
nobs
>>>> to do that.  Adding a knob that disables (or enables) other knobs to=
 work
>>>> is weird.
>>>
>>> I totally agree. This moves the compression knob from the config file=
 to the command line. And what if the user wants some but not all files t=
o be compressed? Or wants to use different compression with different log=
 files?
>>
>> Another possibility would be to introduce some simple form of variable=
s in
>> newsyslog.conf, replacing J by a variable reference, with the variable=

>> being set near the beginning.  E.g.
>>
>> 	V=3Dzstd (or just V=3D for none?)
>> 	... $V
>> 	... $V
>>
>> Then there would be one global change, and much easier changing of the=

>> default.
>>
>> It would also be possible to add <include> /etc/newsyslog.local.conf a=
t the
>> beginning, and set variables there, making changes to the default file=
 less
>> painful in the future.
>
> I've implemented support of <compress> in https://reviews.freebsd.org/D=
43174 .  Let's don't add macro or variables to newsyslog.conf as it would=
 be a nightmare for compatibility with other newsyslog variants of other =
BSDs.

Looks like there is a fair amount of divergence from NetBSD, at least;
I don't think compatibility with other BSDs is a significant factor.
Compatibility with older FreeBSD is a bigger consideration.

An intermediate possibility would be to add an option letter for the
default compression to be used in each entry, and use <compress> to set
that default.  It seems wrong to attempt to use <compress> zstd with opti=
on
letters like J; it's contradictory, if not confusing.  It's still a knob
to disable other knobs, although it is in the right file.

		Mike



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?B41F5D19-22F1-4E54-81D4-8C938D6640C4>