check_http long execution

This forum is intended for the discussion of Nagios plugin development. Feature requests, patches, bug fixes, and all types of development-related discussions are welcome!

NOTE: The SourceForge.net nagiosplug-devel mailing list has been deprecated in favor of this forum in order to expedite support and provide additional features not available on the old mailing list.

check_http long execution

Postby danielobst » Thu Apr 05, 2018 6:35 am

Hi everybody,

the check_http takes about 10-11 s to be executed on several machines if a string needs to be find

Code: Select all
time ./check_http -I 'tool.uni-leipzig.de' -H '141.39.229.93' -u '/einschreibung' --ssl -s 'Willkommen im TOOL' -t 20
HTTP OK: HTTP/1.1 200 OK - 7569 bytes in 10,124 second response time |time=10,124435s;;;0,000000;20,000000 size=7569B;;;0

real    0m10.127s
user    0m0.004s
sys     0m0.004s


without finding a string it is as fast as expected:

Code: Select all
time ./check_http -I 'tool.uni-leipzig.de' -H '141.39.229.93' -u '/einschreibung' --ssl -t 20 -N
HTTP OK: HTTP/1.1 200 OK - 5942 bytes in 0,053 second response time |time=0,052838s;;;0,000000;20,000000 size=5942B;;;0

real    0m0.055s
user    0m0.000s
sys     0m0.008s


Fetching the site with wget is pretty fast
Code: Select all
time wget https://tool.uni-leipzig.de/einschreibung
--2018-04-05 13:29:07--  https://tool.uni-leipzig.de/einschreibung
Resolving tool.uni-leipzig.de (tool.uni-leipzig.de)... 141.39.229.93
Connecting to tool.uni-leipzig.de (tool.uni-leipzig.de)|141.39.229.93|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 7107 (6,9K) [text/html]
Saving to: ‘einschreibung.1’

100%[============================================================================================================================>] 7.107       --.-K/s   in 0s

2018-04-05 13:29:07 (57,7 MB/s) - ‘einschreibung.1’ saved [7107/7107]


real    0m0.057s
user    0m0.008s
sys     0m0.004s


Also the packets are transmitted within 50 ms:

Code: Select all
17:03:53.563777 IP server.54493 > tool.uni-leipzig.de.https: Flags [S], seq 3230586004, win 29200, options [mss 1460,sackOK,TS val 121028250 ecr 0,nop,wscale 7], length 0
17:03:53.563919 IP tool.uni-leipzig.de.https > server.54493: Flags [S.], seq 3500481523, ack 3230586005, win 29200, options [mss 1460,nop,wscale 7], length 0
17:03:53.563955 IP server.54493 > tool.uni-leipzig.de.https: Flags [.], ack 1, win 229, length 0
17:03:53.567047 IP server.54493 > tool.uni-leipzig.de.https: Flags [P.], seq 1:292, ack 1, win 229, length 291
17:03:53.567183 IP tool.uni-leipzig.de.https > server.54493: Flags [.], ack 292, win 237, length 0
17:03:53.567363 IP tool.uni-leipzig.de.https > server.54493: Flags [.], seq 1:2921, ack 292, win 237, length 2920
17:03:53.567386 IP tool.uni-leipzig.de.https > server.54493: Flags [P.], seq 2921:4097, ack 292, win 237, length 1176
17:03:53.567392 IP server.54493 > tool.uni-leipzig.de.https: Flags [.], ack 2921, win 274, length 0
17:03:53.567405 IP server.54493 > tool.uni-leipzig.de.https: Flags [.], ack 4097, win 297, length 0
17:03:53.585879 IP tool.uni-leipzig.de.https > server.54493: Flags [P.], seq 4097:5041, ack 292, win 237, length 944
17:03:53.586098 IP server.54493 > tool.uni-leipzig.de.https: Flags [.], ack 5041, win 320, length 0
17:03:53.588334 IP server.54493 > tool.uni-leipzig.de.https: Flags [P.], seq 292:418, ack 5041, win 320, length 126
17:03:53.588722 IP tool.uni-leipzig.de.https > server.54493: Flags [P.], seq 5041:5092, ack 418, win 237, length 51
17:03:53.589246 IP server.54493 > tool.uni-leipzig.de.https: Flags [F.], seq 418, ack 5092, win 320, length 0
17:03:53.589402 IP tool.uni-leipzig.de.https > server.54493: Flags [F.], seq 5092, ack 419, win 237, length 0
17:03:53.589424 IP server.54493 > tool.uni-leipzig.de.https: Flags [.], ack 5093, win 320, length 0


So the execution/looking for the string takes about 10 s. Unfortunately this is put to the performance data too. Version is

Code: Select all
./check_http -Vv
check_http v2.2 (monitoring-plugins 2.2)


Any idea what causes the delay?

Kind Regards
danielobst
 
Posts: 1
Joined: Thu Apr 05, 2018 6:19 am

Re: check_http long execution

Postby scottwilkerson » Thu Apr 05, 2018 12:46 pm

Code: Select all
check_http v2.2 (monitoring-plugins 2.2)


This is not our plugin and is created by a different team.

If you were working with a version of nagios-plugins we may be able to assist but we have no idea what they may have wrong with their code.

nagios-plugins package may be found here
https://github.com/nagios-plugins/nagios-plugins
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
scottwilkerson
CTO
 
Posts: 9799
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises


Return to Nagios Plugin Development

Who is online

Users browsing this forum: No registered users and 1 guest