in reply to get few lines from a file

Or start to print as soon as you meet the desired input.

my $print_this = 0; while (<$IN>) { print if $print_this; $print_this = 1 if /^Status of the log/; }