Re: How to remove a single line from a flat file (Still very off-topic.)
- From: "Larry W. Virden" <lvirden@xxxxxxxxx>
- Date: 21 May 2007 05:42:07 -0700
On May 19, 2:19 pm, Darren New <d...@xxxxxxxxxx> wrote:
Eric wrote:
But the fact that if you want to (say) edit the syslog file you have to
turn off syslog (so it's not writing to the file while you edit it),
that tells me you're missing something in the kernel.
If you need to edit it, it's not a log file.
Editting includes rotating the log file, removing old entries, etc.
Of course, part of the problem is the design of these files. Why are
they writing to one log file, then rotating that file to a new name
while creating a new one? Why not just open a log file a day? Or one a
week/month/year (what ever time span is used for splitting? If the
application designer simply took a parameter indicating the frequency
of creating a new log file (NN minutes/hours/days/months/years), then
nothing extra would be necessary - the application would just close
the old, open the new, and move on.
The point I'm trying to make is that many of the problems that people
attempt to work around stem from the "simplicity" design strategy. So
instead of someone writing a library for managing log files, they use
a simple "open file/write to file" strategy and allow the policy
management to fall to the administrator. And I'd suspect that in this
case, more time/energy/money is spent on the admin juggling log files
than would be spent on writing and debugging a library which used some
sort of config parameters to do the juggling, then integrating calls
to the library into each application generating logs that need
juggled.
.
- Follow-Ups:
- Re: How to remove a single line from a flat file (Still very off-topic.)
- From: Alexandre Ferrieux
- Re: How to remove a single line from a flat file (Still very off-topic.)
- References:
- Re: How to remove a single line from a flat file
- From: Larry W. Virden
- Re: How to remove a single line from a flat file
- From: Atte Kojo
- Re: How to remove a single line from a flat file
- From: Larry W. Virden
- Re: How to remove a single line from a flat file
- From: Darren New
- Re: How to remove a single line from a flat file
- From: billposer
- Re: How to remove a single line from a flat file
- From: Donal K. Fellows
- Re: How to remove a single line from a flat file
- From: Darren New
- Re: How to remove a single line from a flat file
- From: Atte Kojo
- Re: How to remove a single line from a flat file
- From: Darren New
- Re: How to remove a single line from a flat file
- From: Eric
- Re: How to remove a single line from a flat file (Still very off-topic.)
- From: Darren New
- Re: How to remove a single line from a flat file
- Prev by Date: Re: How to use pass by reference in procs in TCL
- Next by Date: Re: "X11 Control Characters" encoding
- Previous by thread: Re: How to remove a single line from a flat file (Still very off-topic.)
- Next by thread: Re: How to remove a single line from a flat file (Still very off-topic.)
- Index(es):
Relevant Pages
|
|