On Tue, 1 Feb 2011, Rainer Gerhards wrote:
This sounds useful, at least for some use cases. However, this most probably
requires considerable changes to the config engine. And as this engine is
scheduled to be replaced, I don't like to touch it too much.
However, there may be one solution. We could declare something like "if the
file name is defined as a template name, then make it a dynafile based on
that template".
Then, you would need to define templates e.g
$template /var/log/messages,"/var/log/messages_%$NoW%"
this sounds like a significant simplification to dynafiles in general.
And those would automatically be converted. That seems to require relatively
few changes.
Would that help?
I don't think this will help his case. He is wanting to leave the existing
config files untouched and have this change take place.
if this capibility was in rsyslog, then he _may_ get away with it, but
only if all writes to logs are done via includes and he can include his
redefinition of things prior to the outputs being defined, _and_ he
specifies all files this way.
this seems like a pretty fragile way of doing things. I will admit that I
don't understand his reluctance to modify the distro config files.
especially if he is just modifying the includes, there is nothing in those
files that should have to change from release to release (of either
rsyslog or the distro). the main rsyslog.conf file may change, so I can
understand wanting to avoid touching that (not neccessarily agree with,
but understand ;-) but the snippits that are included really are the local
configuration, and are expected to be tailored to your installation.
David Lang
Rainer
-----Original Message-----
From: rsyslog-boun...@lists.adiscon.com [mailto:rsyslog-
boun...@lists.adiscon.com] On Behalf Of martin f krafft
Sent: Tuesday, February 01, 2011 8:36 PM
To: da...@lang.hm
Cc: rsyslog-users; 536...@bugs.debian.org
Subject: Re: [rsyslog] Appending a timestamp to all log files
also sprach da...@lang.hm <da...@lang.hm> [2011.02.01.1957 +0100]:
rsyslog already has the include directive to include files (or all
files in a directory)
does this work for you? if not, what does it lack?
Hello David,
thanks for your time in writing back. Unfortunately, I think I was
unclear about what I am trying to do.
I am aware of the include directive. It has nothing to do with my
goals.
I am trying to tell rsyslog: "hey, all files that you write, append the
following suffix to their names!", or "hey, all files that you write,
run their names through this filter and use the output as actual
filename!".
I want this because it's a cleaner way to replace all hard-coded
filenames with templated filenames, than to change every instance of a
hard-coded filename.
Am I making myself clearer now?
--
martin; (greetings from the heart of the sun.)
\____ echo mailto: !#^."<*>"|tr "<*> mailto:" net@madduck
logik ist analsadismus: gedanken werden gewaltsam durch einen engen
gang gepre?t.
-- frei nach lacan
spamtraps: madduck.bo...@madduck.net
--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org