[plug] tailing misbehaving log files

Ryan ryan at is.as.geeky.as
Tue Jun 7 15:13:54 WST 2005


On Tue, 2005-06-07 at 15:04 +0800, Matthew Lambie wrote:
> > Another option is using watch to tail 50 odd lines etc, but this also
> > has issues with screen updates.  The screen is not cleared completely
> > between updates and after a while, the text becomes impossible to read.
> > ie: long lines that are replaced with short lines end up with all the
> > trailing text still visible on the end of the line.
> 
> Could you combine watch with clear? Maybe:
> watch -n1 "tail /var/log/groupwise.log && clear"
> 
> If you have the right tail parameters already then the clear should wipe
> the display every second.

It should, but it doesn't.  Whatever curses magic watch is using is not
obeying the clear.

Though I have now thought of this one:

	watch  "tail -50 0607gwia.003 | head -49"

It seems to perform as I expected.  A quick wrapper later and I should
have my new gwtail tool.

Cheers,

Ryan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.plug.org.au/pipermail/plug/attachments/20050607/e7b1d325/attachment.pgp>


More information about the plug mailing list