<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>13364</bug_id>
          
          <creation_ts>2019-05-29 01:44:28 +0000</creation_ts>
          <short_desc>oe-selftest runqemu test case error</short_desc>
          <delta_ts>2019-07-29 03:20:25 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>10</classification_id>
          <classification>QA/Testing</classification>
          <product>Functional (self) Testing</product>
          <component>oe-selftest</component>
          <version>2.8</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.8 M3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Chen Qi">Qi.Chen</reporter>
          <assigned_to name="Changqing Li">changqing.li</assigned_to>
          <cc>liezhi.yang</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>richard.purdie</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>83969</commentid>
    <comment_count>0</comment_count>
    <who name="Chen Qi">Qi.Chen</who>
    <bug_when>2019-05-29 01:44:28 +0000</bug_when>
    <thetext>The comment is:
oe-selftest -r runqemu meta_ide -j 15

The error link is:
https://autobuilder.yoctoproject.org/typhoon/#/builders/73/builds/635/steps/7/logs/step3d

Key error message is as below:

2019-2019-05-27 13:08:38,987 - oe-selftest - INFO - ERROR: runqemu.RunqemuTests.test_boot_machine_slirp (subunit.RemotedTestCase)
2019-05-27 13:08:38,987 - oe-selftest - INFO - ----------------------------------------------------------------------
2019-05-27 13:08:38,987 - oe-selftest - INFO - testtools.testresult.real._StringException: Traceback (most recent call last):
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/utils/commands.py&quot;, line 339, in runqemu
    qemu.start(params=qemuparams, ssh=ssh, runqemuparams=runqemuparams, launch_cmd=launch_cmd, discard_writes=discard_writes)
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/targetcontrol.py&quot;, line 178, in start
    raise bb.build.FuncFailed(&quot;%s - FAILED to start qemu - check the task log and the boot log&quot; % self.pn)
bb.build.FuncFailed: Function failed: core-image-minimal - FAILED to start qemu - check the task log and the boot log
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/selftest/cases/runqemu.py&quot;, line 107, in test_boot_machine_slirp
    with runqemu(self.recipe, ssh=False, launch_cmd=cmd) as qemu:
  File &quot;/usr/lib64/python3.6/contextlib.py&quot;, line 81, in __enter__
    return next(self.gen)
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/utils/commands.py&quot;, line 345, in runqemu
    raise Exception(msg)
Exception: Failed to start QEMU - see the logs in /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimageQemurunner log output from /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimage/qemurunner_log.20190527130524:
INFO: rootfs file: 
INFO: Qemu log file: /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimage/qemu_boot_log.20190527130524
INFO: SSH log file: /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimage/ssh_target_log.20190527130524
DEBUG: Created listening socket for qemu serial console on: 127.0.0.1:58811
DEBUG: Created listening socket for qemu serial console on: 127.0.0.1:39721
DEBUG: launchcmd=runqemu nographic kvm slirp qemux86-64 tcpserial=39721 bootparams=&quot;console=tty1 console=ttyS0,115200n8 printk.time=1&quot; qemuparams=&quot;-serial tcp:127.0.0.1:58811 -pidfile pidfile_43557&quot;
DEBUG: runqemu started, pid is 50135
DEBUG: waiting at most 120 seconds for qemu pid (05/27/19 13:05:26)
ERROR: Qemu pid didn&apos;t appear in 120 seconds (05/27/19 13:07:26)
[snip]
05-27 13:08:38,987 - oe-selftest - INFO - ERROR: runqemu.RunqemuTests.test_boot_machine_slirp (subunit.RemotedTestCase)
2019-05-27 13:08:38,987 - oe-selftest - INFO - ----------------------------------------------------------------------
2019-05-27 13:08:38,987 - oe-selftest - INFO - testtools.testresult.real._StringException: Traceback (most recent call last):
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/utils/commands.py&quot;, line 339, in runqemu
    qemu.start(params=qemuparams, ssh=ssh, runqemuparams=runqemuparams, launch_cmd=launch_cmd, discard_writes=discard_writes)
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/targetcontrol.py&quot;, line 178, in start
    raise bb.build.FuncFailed(&quot;%s - FAILED to start qemu - check the task log and the boot log&quot; % self.pn)
bb.build.FuncFailed: Function failed: core-image-minimal - FAILED to start qemu - check the task log and the boot log
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/selftest/cases/runqemu.py&quot;, line 107, in test_boot_machine_slirp
    with runqemu(self.recipe, ssh=False, launch_cmd=cmd) as qemu:
  File &quot;/usr/lib64/python3.6/contextlib.py&quot;, line 81, in __enter__
    return next(self.gen)
  File &quot;/home/pokybuild/yocto-worker/qemux86-64/build/meta/lib/oeqa/utils/commands.py&quot;, line 345, in runqemu
    raise Exception(msg)
Exception: Failed to start QEMU - see the logs in /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimageQemurunner log output from /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimage/qemurunner_log.20190527130524:
INFO: rootfs file: 
INFO: Qemu log file: /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimage/qemu_boot_log.20190527130524
INFO: SSH log file: /home/pokybuild/yocto-worker/qemux86-64/build/build-st-43557/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/testimage/ssh_target_log.20190527130524
DEBUG: Created listening socket for qemu serial console on: 127.0.0.1:58811
DEBUG: Created listening socket for qemu serial console on: 127.0.0.1:39721
DEBUG: launchcmd=runqemu nographic kvm slirp qemux86-64 tcpserial=39721 bootparams=&quot;console=tty1 console=ttyS0,115200n8 printk.time=1&quot; qemuparams=&quot;-serial tcp:127.0.0.1:58811 -pidfile pidfile_43557&quot;
DEBUG: runqemu started, pid is 50135
DEBUG: waiting at most 120 seconds for qemu pid (05/27/19 13:05:26)
ERROR: Qemu pid didn&apos;t appear in 120 seconds (05/27/19 13:07:26)
runqemu - ERROR - Failed to run qemu: qemu-system-x86_64: Could not set up host forwarding rule &apos;tcp::2323-:23&apos;
[snip]
2019-05-27 13:08:43,229 - oe-selftest - INFO - RESULTS - runqemu.RunqemuTests.test_boot_machine_slirp: ERROR (123.77s)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84003</commentid>
    <comment_count>1</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2019-05-30 14:41:51 +0000</bug_when>
    <thetext>I suspect this is race where if two slirp tests are run at the same time, they clash over resources. We should use variable port ranges or a lock file or something else if that is the problem.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84542</commentid>
    <comment_count>2</comment_count>
    <who name="Changqing Li">changqing.li</who>
    <bug_when>2019-07-29 03:20:25 +0000</bug_when>
    <thetext>https://git.openembedded.org/openembedded-core/commit/?id=ceb3555a40ba06e58914465376aaf41392c12a7c</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>