[OE-core] Connectivity check uris

Andrey Zhizhikin andrey.z at gmail.com
Thu Jan 23 13:22:54 UTC 2020


On Thu, Jan 23, 2020 at 2:14 PM Jean-Marie LEMETAYER
<jean-marie.lemetayer at savoirfairelinux.com> wrote:
>
> Hi folks,
>
> I have noticed some hang-ups at the beginning of my builds on the master branch.
> I have search a little and discovered that the connectivity check made by poky
> was the root cause. In fact connectivity check use the CONNECTIVITY_CHECK_URIS
> variable which is by default set to "https://www.example.com/".
>
> So I have made some tests with a little script which gets the URI 100 times:
>
>         $ cat connectivity_check.sh
>         #!/bin/sh
>         connectivity_check()
>         {
>                 local ok=0
>                 for i in $(seq 100)
>                 do
>                         $@ > /dev/null && ok=$(($ok + 1))
>                 done
>                 echo $ok $@
>         }
>         connectivity_check wget -qO- --timeout=1 --tries=1 $1
>         connectivity_check curl -s --connect-timeout 1 $1
>
> Note that in the script, I use wget and curl to see if there are any differences
> but I don't think that's a thing.
>
> Here are the results:
>         $ time ./connectivity_check.sh https://example.com
>         45 wget -qO- --timeout=1 --tries=1 https://example.com
>         45 curl -s --connect-timeout 1 https://example.com
>
>         real    2m23.595s
>         user    0m3.352s
>         sys     0m1.834s
>
>         $ time ./connectivity_check.sh https://openembedded.org
>         100 wget -qO- --timeout=1 --tries=1 https://openembedded.org
>         100 curl -s --connect-timeout 1 https://openembedded.org
>
>         real    4m36.188s
>         user    0m3.853s
>         sys     0m1.761s
>
>         $ time ./connectivity_check.sh https://google.com
>         100 wget -qO- --timeout=1 --tries=1 https://google.com
>         100 curl -s --connect-timeout 1 https://google.com
>
>         real    0m36.328s
>         user    0m4.265s
>         sys     0m2.028s
>
> So "example.com" is clearly not a good domain to do connectivity checks.
>
> The "openembedded.org" domain is good but have a slow response time.
>
> And finally "google.com" which have all sort of speedy networking stuff is very
> efficient.
>
> ---
>
> I think the CONNECTIVITY_CHECK_URIS variable must be updated and not use the
> "example.com" domain anymore. Using "google.com" may be the best option. But
> eetting up a custom domain like "connectivitycheck.openembedded.org" could be
> another idea.

Had this idea long time in the past... Unfortunately, google.com is
not available in all countries worldwide (Say "Nihao" to chinese Great
firewall ).

>
> Any ideas ?
>
> Jean-Marie LEMETAYER
> Passionate embedded systems engineer
> Savoir-faire Linux
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core at lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core



-- 
Regards,
Andrey.


More information about the Openembedded-core mailing list