mirror of
https://github.com/munin-monitoring/contrib.git
synced 2018-11-08 00:59:34 +01:00
Use longer timeout.
This commit is contained in:
parent
0602fba8ac
commit
6eeb457fc2
@ -51,7 +51,7 @@ use constant {
|
||||
|
||||
if(defined $ARGV[0] and $ARGV[0] eq 'autoconf'){
|
||||
my $url = $ENV{url} || "http://192.168.1.254/cgi-bin/dslstatistics.ha";
|
||||
my $html = HTTP::Tiny->new(timeout => 1 )->get($url);
|
||||
my $html = HTTP::Tiny->new(timeout => 30 )->get($url);
|
||||
|
||||
if($html->{success} && $html->{content} =~ m{Broadband Status}){
|
||||
print "yes\n";
|
||||
@ -159,7 +159,7 @@ lof_up.min 0
|
||||
########################## MAIN #############################
|
||||
|
||||
my $url = $ENV{url} || "http://192.168.1.254/cgi-bin/dslstatistics.ha";
|
||||
my $html = HTTP::Tiny->new(timeout => 1 )->get($url);
|
||||
my $html = HTTP::Tiny->new(timeout => 30 )->get($url);
|
||||
die "Couldn't fetch $url" unless $html->{success};
|
||||
my @stats = $html->{content} =~ m{<td class="col2">(.*?)</td>}sg;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user