http://code.activestate.com/lists/perl-unix-users/189/
open(FILE, "my_file.txt") or die; $pos = -2; # Use this to get past EOF and last newline while($char ne "\n") { seek FILE, $pos, 2; read FILE, $char, 1; $pos--; } $final = <FILE>; print "Last line is: $final\n";