in reply to Avoiding Datecalc

Thank you for the replies... This is what ended up fixing the issue and speeding the script up greatly; seconds instead of minutes. I was coverting the unix seconds into a five minute interval for graphing by overwriting the $seconds variable, using it and then adding the interval to it. Instead, I needed to retain the original value, so I needed to use a second variable for the five minute interval. $fivemin = (int($seconds/300))*300;
foreach $cmd ('WBU', 'RTT') { my ( $time, $interval, $n_elements, @data ) = split(/,/, $Clie +nt{$client}{$cmd}); my $seconds = &UnixDate("$time","%s"); foreach (@data) { if ($cmd eq 'RTT') { $interval = 60; ### interval not set correctl +y in dataset $value = sprintf("%0.2f", ($_/1000)); } else { $interval = 30; ### interval not set correctl +y in dataset $value = sprintf("%0.2f", (($_*8)/1000)); # + Convert to bits then / by 1000 for graphing } $fivemin = (int($seconds/300))*300; $Counter{$fivemin}++; $Tot{$fivemin}+=$value; $Max{$fivemin}=$value if ($value>$Max{$fivemin}); $Min{$fivemin}=$value if (($value<$Min{$fivemin})or(!$ +Min{$fivemin})); $seconds+=$interval; }