Random Project

Solution: Use of uninitialized value in sprintf at /usr/local/share/perl5/Nagios/Plugin/Performance.pm line 68

To “fix” this warning, please change the next lines in source code:

# Hits as % of all requests: 5min: 23.6%, 60min: 19.7%
$line =~ /s+Request Hit Ratios:s+5min:s+([0-9.]+)%,s+60min:s+([0-9.]+)%/ and $cache_requesthitratio5 = $1 and $cache_requesthitratio60 = $2;
# Byte Hit Ratios: 5min: 23.7%, 60min: 20.9%
$line =~ /s+Byte Hit Ratios:s+5min:s+([0-9.]+)%,s+60min:s+([0-9.]+)%/ and $cache_bytehitratio5 = $1 and $cache_bytehitratio60 = $2;

by

# Hits as % of all requests: 5min: 23.6%, 60min: 19.7%
$line =~ /s+Hits as % of all requests:s+5min:s+([0-9.]+)%,s+60min:s+([0-9.]+)%/ and $cache_requesthitratio5 = $1 and $cache_requesthitratio60 = $2;
# Hits as % of bytes sent: 5min: 1.4%, 60min: 5.1%
$line =~ /s+Hits as % of bytes sent:s+5min:s+([0-9.]+)%,s+60min:s+([0-9.]+)%/ and $cache_bytehitratio5 = $1 and $cache_bytehitratio60 = $2;