[smokeping-users] AnotherCurl issue?

Louis-Berthier Soullière shadow131 at hotmail.com
Mon Apr 6 13:46:24 CEST 2020


Hi,

I'm trying to get AnotherCurl working but I encountered some issues.

I've been using it in the past, but now there seems to be a bug.

Red Hat Enterprise Linux Server release 7.7
curl 7.29.0 (x86_64-redhat-linux-gnu) libcurl/7.29.0 NSS/3.44 zlib/1.2.7 libidn/1.28 libssh2/1.8.0
I have a fairly recent version of Smokeping fetched from github. Weirdly, if I do a smokeping -V, I get version 2.006000. But if I git clone the actual stuff in github today, it is the same version : lib/Smokeping.pm:$VERSION="2.006000"; Why is that?
Perl v5.16.3

First, I had to add \" to the following AnotherCurl.pm line, else, the probing would fail with AnotherCurl.pm using %{time_starttransfer} as hostname in the command ;  https://%time_appconnect/

Here is the line with the added \" at the beginning and at the end of the result parameter:

my @args = ("-w", "\"Total: %{time_total} DNS: %{time_namelookup} Redirect: %{time_redirect} Connect: %{time_connect} Appconnect: %{time_appconnect} Pretransfert: %{time_pretransfer} Starttransfert: %{time_starttransfer}\\n\"");

So now, if I do a "ps aux | grep curl", and reuse the command, it is working.

/usr/bin/curl -m 8 -o /dev/null -w "Total: %{time_total} DNS: %{time_namelookup} Redirect: %{time_redirect} Connect: %{time_connect} Appconnect: %{time_appconnect} Pretransfert: %{time_pretransfer} Starttransfert: %{time_starttransfer}\n" -k -x http://xx.xx.xx.xx:8080 https://login.microsoftonline.com/
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   145  100   145    0     0    294      0 --:--:-- --:--:-- --:--:--   294
Total: 0.493 DNS: 0.000 Redirect: 0.000 Connect: 0.002 Appconnect: 0.456 Pretransfert: 0.456 Starttransfert: 0.492

So I would expect a Appconnect result in my graph of 456ms. But, I don't see any result in my graph. If I do a smokeping --debug, here is the result :

AnotherCurl_SSL: forks 5, timeout for each target 25
AnotherCurl_SSL: executing command list '/usr/bin/curl','-m','8','-o','/dev/null','-w','"Total: %{time_total} DNS: %{time_namelookup} Redirect: %{time_redirect} Connect: %{time_connect} Appconnect: %{time_appconnect} Pretransfert: %{time_pretransfer} Starttransfert: %{time_starttransfer}\n"','-k','-x','http://xx.xx.xx.xx:8080','https://login.microsoftonline.com/'
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   145  100   145    0     0    292      0 --:--:-- --:--:-- --:--:--   292
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   145  100   145    0     0    286      0 --:--:-- --:--:-- --:--:--   287
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   145  100   145    0     0    292      0 --:--:-- --:--:-- --:--:--   292
AnotherCurl_SSL: login.microsoftonline.com: got

The last line seems truncated or missing a result?

Here is the probes config

++ AnotherCurl_SSL
binary = /usr/bin/curl
step = 10
extrare = / /
follow_redirects = no
include_redirects = no
insecure_ssl = 1
pings = 3
ssl2 = 0
timeout = 8
urlformat = https://%host%/
write_out = time_appconnect

Here is the target config

+++ OFFICE365_VIA_SPAIC_QC
probe=AnotherCurl_SSL
menu=OFFICE365_VIA_SPAIC_QC
title=OFFICE365_VIA_SPAIC_QC
host=login.microsoftonline.com
extraargs = -x http://xx.xx.xx.xx:8080
slaves =


Thank you for your help!



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.oetiker.ch/pipermail/smokeping-users/attachments/20200406/fa09e5c8/attachment.html>


More information about the smokeping-users mailing list