Re: FileLogTraceListener not writing to file beyond a constant max-size

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Oh Ok !

4833 K is the default max-size...since I was not setting this property,
the default was in play.

But my log files can grow up to 30 Mb in a day. And manageability could
be a problem.

How can I play around with my listener to:

- create a new file each day

- create multiple files each day, each of the same manageable size (say
5 Mb)



Thanks,

Kunal


On Jan 12, 12:05 pm, "Kunal" <koolku...@xxxxxxxxx> wrote:
Hi Friends,

I've been using FileLogTraceListener class to write log data to files.
Since the data being written is continuously generated, I set the file
to be created on a daily basis. I do not set up the maximum size for
the log file.

The problem is - My log files do not seem to grow beyond a fixed size
(4833 K). All messages are written to log file till the file grows to
this size and then no logs are appended. Here are my settings -

faultLoglistener = new FileLogTraceListener();
faultLoglistener.Location = LogFileLocation.Custom;
faultLoglistener.CustomLocation = "C:\\";
faultLoglistener.BaseFileName = "FaultLog";
faultLoglistener.LogFileCreationSchedule =
LogFileCreationScheduleOption.Daily;
faultLoglistener.Append = true;
faultLoglistener.Delimiter = "|";
faultLoglistener.AutoFlush = true;

Can I set the max-size to something (say 4000 K) and use the
"FullLogFileName" property to include a timestamp in the filename so
that when a file reaches its limit, another file with same name, date
and different timestamp is created and logging continued in that ?

If not, can somebody suggest how can I get over this problem so that I
continue to log messages ?

Thanks n Regards,

Kunal

.



Relevant Pages

  • Re: Problems with Cron not deleting log files
    ... >>server and have just recently found some new time to 'play' with the ... >>settings etc. ... log files, the problem is that I cannot delete them. ... the system were the long string of chmod commands I listed. ...
    (freebsd-questions)
  • Re: BCVs on a cluster
    ... should also be able to do a restore and play back the log files. ... no reason that this would not work. ... The next ClusterHelp classes are: ...
    (microsoft.public.sqlserver.clustering)
  • Re: iPAQ 1940 + GPS
    ... "Place the Blue Logger GPS on the dash and play back log files _later_ ... on a laptop or desktop..." ...
    (microsoft.public.pocketpc)
  • Re: Trojan on my Linux box????
    ... > I've been able to figure out that it only happens when I play ... My log files look like this ... ... If you're on DHCP, how does she know it's YOUR computer?!? ... Is it because the probing only happens when everyone has turned off ...
    (comp.os.linux.security)
  • Re: Parsing?
    ... the first 9 characters for matching the timestamp pattern. ... a whole line but not sure how to individually check each character. ... but what about the message tokens that have quotes ... When presenting lines from two log files in different formats, ...
    (comp.lang.c)