Bug 9483

Summary: "Testing URL" hangs forever
Product: [Build System, Metadata & Runtime] BitBake Reporter: Jin <jin>
Component: bitbakeAssignee: Joshua Lock <joshuagloe>
Status: RESOLVED FIXED QA Contact:
Severity: minor    
Priority: Medium CC: poky.bs.watcher, poky.watcher
Version: unspecified   
Target Milestone: 2.0.2   
Hardware: x86   
OS: x86_64   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Jin 2016-04-19 08:39:42 UTC
This behaviour started about 1-2 weeks ago, we are running nightly builds and we noticed that they started to hang. Interestingly enough, it often happens happens during "package-index", so its not a source fetcher problem:

ps auxww | grep bitbake
oebuild  26788  0.0  0.3 222340 122820 ?       S    03:38   0:04 /opt/poky/2.0/sysroots/x86_64-pokysdk-linux/usr/bin/python2.7 /oe/dss-oe/yocto/feedconfig/devel/poky/bitbake/bin/bitbake -DDD package-index
oebuild  26803  0.0  0.6 377292 196464 ?       Sl   03:38   0:03 /opt/poky/2.0/sysroots/x86_64-pokysdk-linux/usr/bin/python2.7 /oe/dss-oe/yocto/feedconfig/devel/poky/bitbake/bin/bitbake -DDD package-index
oebuild  26805  0.0  0.3 298224 119308 ?       Sl   03:38   0:11 /opt/poky/2.0/sysroots/x86_64-pokysdk-linux/usr/bin/python2.7 /oe/dss-oe/yocto/feedconfig/devel/poky/bitbake/bin/bitbake -DDD package-index

There is no timeout,  it will stay in this state for days.

netstat -t -W shows:
tcp        0      0 CentOS-70-64-minimal:39783 yocto-www.yoctoproject.org:https ESTABLISHED

I added -DDD to my build script and now I can see where it actually hangs, the last entry is:

DEBUG: Testing URL http://bugzilla.yoctoproject.org/report.cgi

At this very moment bitbake still hangs, at the same time the URL can be opened in a browser. I now killed bitbake (had to use -9) and restarted the build and it works again, but it is failing very consistently every night (the build is started at 3:30 A.M. CEST

I also had a couple of cases where it was also hanging when I manually restarted the build, I can not trace it to any network outages or similar. In any case there should be a timeout.

I am building poky 2.0.1:

BB_VERSION        = "1.28.0"
DISTRO            = "poky"
DISTRO_VERSION    = "2.0.1"
Comment 1 Jin 2016-04-19 19:49:15 UTC
Lowering importance since there turned out to be a workaround CONNECTIVITY_CHECK_URIS=""
Comment 2 Bill Randle 2016-04-19 20:53:14 UTC
Sometimes networks and connections are just plain flakey. There was a commit on master back in January (423a2645377bff2cd7292e1dc9796eeb3595e937) that replaced CONNECTIVITY_CHECK_URIS in meta-yocto/conf/distro/poky.conf with just "https://www.example.com/". You might try that and see if it solves your problem.
Comment 3 Joshua Lock 2016-04-28 10:55:24 UTC
There's a series in review for jethro which includes backporting 423a2645377bff2cd7292e1dc9796eeb3595e937