<?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>8017</bug_id>
          
          <creation_ts>2015-07-16 10:02:21 +0000</creation_ts>
          <short_desc>selftest does pkill(qemu) which will kill ALL qemu processes</short_desc>
          <delta_ts>2015-08-17 19:00:56 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>10</classification_id>
          <classification>QA/Testing</classification>
          <product>Runtime Testing</product>
          <component>general</component>
          <version>1.9</version>
          <rep_platform>All</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>High</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>1.9 M2</target_milestone>
          
          <blocked>8176</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Ross Burton">ross.burton</reporter>
          <assigned_to name="Daniel Istrate">daniel.alexandrux.istrate</assigned_to>
          <cc>cristian.iorga</cc>
          
          <qa_contact name="Lucian Musat">georgex.l.musat</qa_contact>
          <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>52424</commentid>
    <comment_count>0</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2015-07-16 10:02:21 +0000</bug_when>
    <thetext>Many of the selftest runs do pkill(&quot;qemu&quot;) to kill the currently running qemu, but that will kill *all* qemu processes on the machine.

As pexpect is being used, you can do .kill(signal.SIGTERM) or .terminate().</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>52479</commentid>
    <comment_count>1</comment_count>
    <who name="Cristian Iorga">cristian.iorga</who>
    <bug_when>2015-07-20 09:58:21 +0000</bug_when>
    <thetext>Hi, is critical to fix it as soon as possible.
If a technical solution can&apos;t be found fast to pkill issue, please revert the changes that trigger it for now.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>52480</commentid>
    <comment_count>2</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2015-07-20 10:41:15 +0000</bug_when>
    <thetext>So the shell trap is only executed when the shell is processing, but when qemu is running the shell is waiting for qemu to return so it doesn&apos;t process the trap.  qemu doesn&apos;t get the kill so doesn&apos;t exit.  Thus, nothing happens.

Instead, send a kill to the entire process group (runqemu and all children) - qemu will exit and then runqemu will cleanup.

From a shell I do this with &quot;pkill -g &lt;pid of runqemu&gt;&quot;.  pexpect doesn&apos;t expose this ability directly so the idiom would be something like os.killpg(proc_qemu.pid).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>52544</commentid>
    <comment_count>3</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2015-07-23 10:44:06 +0000</bug_when>
    <thetext>Fixed in oe-core f58df3a630b774083934171463b2b07add29dc0e.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>52710</commentid>
    <comment_count>4</comment_count>
    <who name="Lucian Musat">georgex.l.musat</who>
    <bug_when>2015-07-29 13:13:56 +0000</bug_when>
    <thetext>Verified on master 19f77cf586fbee9e67d3698263402b717303c5ec</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>