Try File::Tail. I don't know just what rkill does, but chances are there's a module for it. As a bonus, the script will (be easy to get to) work wherever these modules are installed, if that's a concern. (I always keep it in mind, if only fleetingly.)