Thread Logfile, maximal 10 Zeilen
(3 answers)
Opened by roooot at 2010-12-02 18:31
Wie wäre es mit File::Tail?
Code (perl): (dl
)
1 2 3 4 5 use File::Tail; my $logfile=File::Tail->new(name=>$filename, tail=>10); while (defined(my $line=$logfile->read)) { print "$line"; } Last edited: 2010-12-02 19:32:32 +0100 (CET) |