Re: asl_search() no longer returns old messages
Re: asl_search() no longer returns old messages
- Subject: Re: asl_search() no longer returns old messages
- From: Jason Coco <email@hidden>
- Date: Mon, 3 Nov 2008 12:18:45 -0500
On Nov 3, 2008, at 11:27 , Karl Moskowski wrote:
On 3-Nov-08, at 11:16 AM, Jason Coco wrote:
Yes... by default messages are pruned every 24 hours by syslog. See
the section on Messaging Expiry and Archival in the manpage for
syslogd(8) for more information on how to adjust this...
Thanks for the pointer to that manpage section.
It looks like some types of messages have a longer time-to-live than
the default 24 hours. Is it possible to similarly increase the TTL
for messages logged using the functions in asl.h? (It's not
practical to reconfigure every user's instance of syslogd.)
If not, I'm probably going to have to go back to logging to files.
Yes, there are two things you can do.
1) You can add a physical log file as well as using the database so
that users get both. Use asl_add_log_file(3) to add a log file to a
client. This will allow you to use the ASL API the same and it will
add the entry to the asl database as well as logging it to the
physical file you supply.
2) Add the key ASLExpireTime key to the message... the message will
not be archived or deleted until at least sometime after this time has
passed.
J
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden