Always always always:
use strict; use warnings;
Sorry, i just used (...) to indicate that i left out some lines of code. Including use strict, use warnings and all initialisations.
foreach my $logline (reverse(@lines)) {
#Search for Host-IP-Adress and bytes if( $logline =~ / (\d+\.\d+\.\d+\.\d+) \w*\/\w* (\d+) [A-Z]+/ ){ if($ipload{$1}) {$ipload{$1}+=$2} else {$ipload{$1}=$2}
Wht not just $ipload{$1} += $2; instead of the if else?
Thought it would be safer, because some ip-adresses have multiple file entries. But i guess it's not necessary.
Thanks
Folker Naumann
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>