Minor comment, not meant to start an argument: I don't think it's necessary to always look to use a perl module as your comment, merlyn, seems to imply. Of course, if one is floundering with a task, look for a module.
But if one can pull a task off without much trouble, then I think one should try to create one's own code if for no other reason than for the experience. zentara doesn't seem to be knocking modules with the "pure perl" reference--I think he's trying to avoid system calls since that may feel like cheating sometimes--so there's no need to knock his code.
Having said all that, zentara, buddy, listen to merlyn and use the File::Tail module and get on with your life. There are more interesting fish tails to fry.
-Spenser
That's Spenser, with an "s" like the detective.