Thanks Rainer,
I *think* I may have worked out something that may be a bit less
complicated, interested in your thoughts on {rel,v}iability:
touch testfile.txt.
ln -s testfile.txt current.txt
# then set the rsyslog.conf to tail current.txt and restarted
echo "test@$(date %s)" >> testfile.txt; # works. rsyslog caught and handled
new message
echo "test@$(date %s)" >> current.txt; # works. same
#update sym link and re-test
touch testfile2.txt
ln -f -s testfile2.txt current.txt
echo "test@$(date %s)" >> testfile2.txt; # works. rsyslog caught and
handled new message
echo "test@$(date %s)" >> current.txt; # works. same
echo "test@$(date %s)" >> testfile.txt; # doesn't work anymore. rsyslog no
longer monitoring
If this works I can just write a crontab task to update symlink nightly.
Am I missing anything?
Thanks again for you help.
Greg
On Mon, Mar 25, 2013 at 11:09 AM, Rainer Gerhards
<[email protected]>wrote:
> On Mon, 2013-03-25 at 11:06 -0400, Gregory Patmore wrote:
> > Hi all,
> >
> > Apologies for what may be such a beginner question, but I'm trying to
> work
> > out a file tail using imfile, but the file I want to tail is generated
> with
> > a date portion in the file name.
> >
> > filename format is: access_log.YYYY-MM-DD.txt
> >
> > Is it possible to set it up to watch a new file each day, and if so, can
> > anyone help me out with some guidance on the conf file syntax?
> >
> simple and unsatisfactory answer: it's currently not possible. However,
> an imfile rewrite/extension is scheduled for the first half of this
> year.
>
> A work-around may be to write a new config file via cron and a tool by
> midnight and restart rsyslog to pick it up. I know: it's ugly - but it
> works...
>
> Rainer
> >
> > Thanks for any help/advice you can give.
>
> _______________________________________________
> rsyslog mailing list
> http://lists.adiscon.net/mailman/listinfo/rsyslog
> http://www.rsyslog.com/professional-services/
> What's up with rsyslog? Follow https://twitter.com/rgerhards
> NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad
> of sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you
> DON'T LIKE THAT.
>
--
--Gregory Patmore | Senior DevOps Engineerappssavvy <http://appssavvy.com/>594
Broadway Suite 207 | New York, NY 10012C | 732.492.4140
[email protected]
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE
THAT.