From 6b23f07c2d4436cb8de3f7925f8419212d07f738 Mon Sep 17 00:00:00 2001 From: Julien Cristau Date: Sat, 16 Sep 2017 13:58:47 +0200 Subject: [PATCH] Set LWP::UserAgent timeout in dsa-check-mirrorsync --- dsa-nagios-checks/checks/dsa-check-mirrorsync | 1 + 1 file changed, 1 insertion(+) diff --git a/dsa-nagios-checks/checks/dsa-check-mirrorsync b/dsa-nagios-checks/checks/dsa-check-mirrorsync index 8e8ec08..5a45e0c 100755 --- a/dsa-nagios-checks/checks/dsa-check-mirrorsync +++ b/dsa-nagios-checks/checks/dsa-check-mirrorsync @@ -111,6 +111,7 @@ my $schema = $params->{'ssl'} ? 'https' : 'http'; foreach my $slave (@slaves) { my $ua = LWP::UserAgent->new; + $ua->timeout(10); $ua->proxy('http', "$schema://$slave"); print "Requesting $schema://$host/$path from $slave\n" if $params->{'verbose'}; my $response = $ua->get("$schema://$host/$path"); -- 2.20.1