I have noticed recently that sometimes tail -f <logfile>
will stop updating to the screen.
Doing a Ctrl>–C and restarting the tail
works fine, though. And I checked to make sure the logfile isn't being rotated midstream (which can make tail
lose its mind).
What would cause this? I'm running RHEL 5.2 x64.
Best Answer
Try wrapping your tail command with
strace
if you have it:Then just for crazy recursive kicks you can tail the strace output (doesnt' matter if that breaks because its going out to a file):
Mine looks like:
The -t switches on the time and -T switches on time spent in calls.
Hit return 4 or 5 times to make a bit of vertical space, then wait for it to stop tailing. Hopefully there will be some clues in the output.