1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49
|
--- Tail.pm.debug.old 2004-06-01 13:37:38.000000000 -0500
+++ Tail.pm.debug 2004-06-01 13:42:47.000000000 -0500
@@ -695,36 +695,35 @@
=item ignore_nonexistant
- Do not complain if the file doesn't exist when it is first
+Do not complain if the file doesn't exist when it is first
opened or when it is to be reopened. (File may be reopened after
resetafter seconds have passed since last data was found.)
=item tail
- When first started, read and return C<n> lines from the file.
+When first started, read and return C<n> lines from the file.
If C<n> is zero, start at the end of file. If C<n> is negative,
return the whole file.
- Default is C<0>.
+Default is C<0>.
=item reset_tail
- Same as tail, but applies after reset. (i.e. after the
+Same as tail, but applies after reset. (i.e. after the
file has been automaticaly closed and reopened). Defaults to
C<-1>, i.e. does not skip any information present in the
file when it first checks it.
- Why would you want it otherwise? I've seen files which
+Why would you want it otherwise? I've seen files which
have been cycled like this:
- grep -v lastmonth log >newlog
- mv log archive/lastmonth
- mv newlog log
- kill -HUP logger
-
+ grep -v lastmonth log >newlog
+ mv log archive/lastmonth
+ mv newlog log
+ kill -HUP logger
Obviously, if this happens and you have reset_tail set to
-c<-1>, you will suddenly get a whole bunch of lines - lines
+C<-1>, you will suddenly get a whole bunch of lines - lines
you already saw. So in this case, reset_tail should probably
be set to a small positive number or even C<0>.
|