in reply to Limit a filesize

How often are you planning on "pruning" this log? If you want to do this everytime an entry is added to the file you are going to add alot of overhead and disk accesses no matter how you do it. It maybe worth considering a different method if you are performance minded. Myself I would use log rotating because it is low cost and only has to be run once a day. It also makes it very easy to archive logs.

Cheers,
-Dogma

Replies are listed 'Best First'.
Re: Re: Limit a filesize
by Flame (Deacon) on Apr 09, 2002 at 02:24 UTC
    I'd consider rotating, but these logs aren't really the kind you'd want lasting copys of, mostly it's just to let the webmaster know where people tend to go, and tell if someone made it somewhere they shouldn't. It's not likely that most people using my program will ever look at the log, even if they bothered to turn it on, so I'd like to keep it from swamping them (this is a space issue as much as overhead problem)



    "Weird things happen, get used to it."

    Flame ~ Lead Programmer: GMS