> -----Original Message-----
> From: Nathan Scott [mailto:nathans@xxxxxxxxxx]
> Sent: Friday, 14 February 2014 10:21 AM
> To: Frank Ch. Eigler; Ken McDonell
> Cc: pcp developers
> Subject: Re: Possible pmmgr issue?
> ...
> Ken, I'd be interested in your thoughts on a few observations from the
> pmlogger_daily scripts on this host (all defaults are in place, for
> everything -
> both pmlogger_daily & pmmgr):
> - there seems to be some older data that is not being culled?
See previous mail ... if merge finds a problem, culling and compressing is
skipped
> - there's a couple of logs that haven't merged, possibly cos one has a zero
> sized file or two?
I think the zero sized files are OK (expected, warnings issued but proceed),
the problem is the truncated archive (again, refer to earlier mail for possible
remediation options).
> - from inspection of the pmlogger_daily script, we appear to always do a
> logmerge, even if there is only one log - could this not simply be handled
> via a
> mv(1) of the files? (avoiding the read/write I/O there entirely, for the
> simple
> case of one archive for the previous day - i.e. no pmcd/pmlogger restarts).
Yep, that's an optimization that could be done.
Probably safer to do a 2 pass operation
1. hard link each of the index, meta, 0, 1, ... files
2. rm the original ones
This way you always have at least one complete archive, even if the system
crashes or the script is interrupted/terminated.
|