Remove stale log files and speed up apache log sync
authorClinton Ebadi <clinton@unknownlamer.org>
Sun, 14 Jul 2013 05:58:53 +0000 (01:58 -0400)
committerClinton Ebadi <clinton@unknownlamer.org>
Sun, 14 Jul 2013 05:58:53 +0000 (01:58 -0400)
commite16ccb3a3556890425230ef0eb2d398acb8694f0
treea91df7244c4f926a3ba27ec3cd8d4494ad58db79
parentabfe84ca1bf183ef33ee25ac66820a2e256cb520
Remove stale log files and speed up apache log sync
* Major speedup: The apache log directory was pointlessly being copied
  for each user on each sync so that it could be chowned and
  transferred. But there is no need: afs ignores the owner/group and
  unix permissions and root can read the keytabs. Eliminating the
  redundant copy sped the script by from ~9 minutes to ~2 minutes.
* Limit scope of each transfer to the per-host apache log
  directory. This could result in less stat()ing, but more importantly
  allows us to...
* Pass --delete to rsync to clean up stale log files. It turns out
  that for a very long time we've just been leaving the uncompressed
  logrotated apache logs behind, and never removing old log files. Fix
  that.
apache-sync-logs