<?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>7880</bug_id>
          
          <creation_ts>2015-06-11 13:46:49 +0000</creation_ts>
          <short_desc>Toaster uses the same /tmp dir across releases</short_desc>
          <delta_ts>2016-05-04 10:17:54 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>Toaster</product>
          <component>toaster</component>
          <version>1.8</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard>GUI design available</status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.1 M4</target_milestone>
          
          <blocked>9209</blocked>
    
    <blocked>9058</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Belen Barros Pena">belen.barros.pena</reporter>
          <assigned_to name="Ed Bartosh">eduard.bartosh</assigned_to>
          <cc>alexandru.c.georgescu</cc>
    
    <cc>alexandru.damian</cc>
    
    <cc>belen.barros.pena</cc>
    
    <cc>bluelightning</cc>
    
    <cc>brian.avery</cc>
    
    <cc>cristiana.voicu</cc>
    
    <cc>jessica.zhang</cc>
    
    <cc>stanciux.mihail</cc>
          
          <qa_contact name="Alexandru Roman">alexandru.costinx.roman</qa_contact>
          <cf_os>---</cf_os>
          <cf_regression_type>New (Never tested)</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>51641</commentid>
    <comment_count>0</comment_count>
    <who name="Belen Barros Pena">belen.barros.pena</who>
    <bug_when>2015-06-11 13:46:49 +0000</bug_when>
    <thetext>If I build with master, and then build with a stable release, the builds with the stable release will fail. Apparently, this is caused by Toaster reusing the same /tmp directory for the second build.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>52434</commentid>
    <comment_count>1</comment_count>
    <who name="Mihail Stanciu">stanciux.mihail</who>
    <bug_when>2015-07-16 12:50:16 +0000</bug_when>
    <thetext>*** Bug 8022 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53228</commentid>
    <comment_count>2</comment_count>
    <who name="Michael Wood">michael.g.wood</who>
    <bug_when>2015-08-19 15:22:49 +0000</bug_when>
    <thetext>Proposed intermediate fix

- new tmp dir for project
- On release change rm tmp dir</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53386</commentid>
    <comment_count>3</comment_count>
    <who name="brian avery">brian.avery</who>
    <bug_when>2015-08-25 14:41:03 +0000</bug_when>
    <thetext>*** Bug 8204 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54542</commentid>
    <comment_count>4</comment_count>
    <who name="brian avery">brian.avery</who>
    <bug_when>2015-09-23 14:35:38 +0000</bug_when>
    <thetext>tmp needs to be :tmp_toaster_&lt;release&gt;
unfortunately we also need to fix buildhistory
it needs to be buildhistory_toaster_&lt;release&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55919</commentid>
    <comment_count>5</comment_count>
    <who name="Belen Barros Pena">belen.barros.pena</who>
    <bug_when>2015-10-28 13:54:16 +0000</bug_when>
    <thetext>I had a brief conversation with Paul Eggleton about this issue, and he believes that projects should not share anything apart from sstate-cache. This effectively means we should have a build directory per project, and an option to share the sstate directory across projects. In Paul&apos;s words: 

&quot;we would probably be asking if you want the sstate-cache shared when creating the project and then set it according to that checkbox&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55920</commentid>
    <comment_count>6</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2015-10-28 13:57:02 +0000</bug_when>
    <thetext>As a response to Brian&apos;s mention of buildhistory above, that issue goes away if we keep the build directories separate, because then the default path still works.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56067</commentid>
    <comment_count>7</comment_count>
    <who name="brian avery">brian.avery</who>
    <bug_when>2015-11-01 18:16:31 +0000</bug_when>
    <thetext>brian concurs.  I think Pauls approach is cleaner and may solve several issues at once. will try out an implementation.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56080</commentid>
    <comment_count>8</comment_count>
    <who name="Belen Barros Pena">belen.barros.pena</who>
    <bug_when>2015-11-02 11:34:15 +0000</bug_when>
    <thetext>(In reply to comment #7)
&gt; brian concurs.  I think Pauls approach is cleaner and may solve several
&gt; issues at once. will try out an implementation.

If we go for this, we&apos;ll need to add the sstate-dir option somewhere in the UI. Marking the issue as needing design.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56580</commentid>
    <comment_count>9</comment_count>
    <who name="Belen Barros Pena">belen.barros.pena</who>
    <bug_when>2015-11-18 13:56:54 +0000</bug_when>
    <thetext>(In reply to comment #8)
&gt; (In reply to comment #7)
&gt; &gt; brian concurs.  I think Pauls approach is cleaner and may solve several
&gt; &gt; issues at once. will try out an implementation.
&gt; 
&gt; If we go for this, we&apos;ll need to add the sstate-dir option somewhere in the
&gt; UI. Marking the issue as needing design.

There is now design for this: check the design document attached to bug 8422</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>57033</commentid>
    <comment_count>10</comment_count>
    <who name="Belen Barros Pena">belen.barros.pena</who>
    <bug_when>2015-12-04 09:25:29 +0000</bug_when>
    <thetext>Something else has occurred to me: what will be the naming scheme for the build directories for each project? If the plan is using the project name, then we&apos;ll need to make sure that we enforce a unique name policy for projects in Toaster. Right now, you can create more than one project with the same name, as reported by bug 7005.

We&apos;ll need to validate the project name when you are creating the project, and show you a little message if another project with the same name exists in the Toaster instance. I&apos;ll come up with something.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>58250</commentid>
    <comment_count>11</comment_count>
    <who name="brian avery">brian.avery</who>
    <bug_when>2016-01-26 19:08:57 +0000</bug_when>
    <thetext>Until this gets fixed, the workaround is to stick with one release for a given instance of toaster.  If you really need to switch releases, you can run one instance of toaster on port 8000 (the default) in dir /home/me/toaster1/ and another on port 8001 in dir /home/me/toaster2.

To set the port when starting toaster do :
. /home/me/poky/bitbake/bin/toaster webport=8001 start
If it&apos;s not set, it will default to port 8000.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>58534</commentid>
    <comment_count>12</comment_count>
    <who name="Alexandru Georgescu">alexandru.c.georgescu</who>
    <bug_when>2016-02-04 09:57:54 +0000</bug_when>
    <thetext>
seems that the issue still exists in YP 2.1_M2.rc1
master/3d2c0f5902cacf9d8544bf263b51ef0dd1a7218c</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>58704</commentid>
    <comment_count>13</comment_count>
    <who name="Ed Bartosh">eduard.bartosh</who>
    <bug_when>2016-02-07 18:09:22 +0000</bug_when>
    <thetext>I&apos;m not sure I understand what needs to be done here.

User has to initialize build environment *before* starting toaster. Specifying build directory is part of this. Does it mean that this is documentation issue? Should we suggest user to use non-default build directory?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>58706</commentid>
    <comment_count>14</comment_count>
    <who name="Belen Barros Pena">belen.barros.pena</who>
    <bug_when>2016-02-07 18:58:55 +0000</bug_when>
    <thetext>So the problem is that although Toaster happily allows you to select different releases of the Yocto Project, there is no connection between the release you select and the build directory used for the builds. As a result, the same build directory is used for different releases, and that causes build failures. 

(In reply to comment #13)
&gt; I&apos;m not sure I understand what needs to be done here.
&gt; 
&gt; User has to initialize build environment *before* starting toaster.
&gt; Specifying build directory is part of this. 

I guess this will need to change. Toaster needs to create a separate build directory for each project.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>59160</commentid>
    <comment_count>15</comment_count>
    <who name="brian avery">brian.avery</who>
    <bug_when>2016-02-17 17:41:51 +0000</bug_when>
    <thetext>I don&apos;t think that the user initializing the build dir before starting toaster needs to change. Instead we will end up with something like:
toaster/build -- this was created by sourcing poky/oe-init-build-env and is where you would do command line builds that toaster is listening to.
toaster/build-Project1 - when you make a project, this build dir is initialized and a bitbake memres server is started and attached to it.
toaster/build-ProjectN - more of the same.


The fix for bug 8422 means that we will leverage sstate and downloads across all the projects so that rebuild times will be low.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>59490</commentid>
    <comment_count>16</comment_count>
    <who name="Ed Bartosh">eduard.bartosh</who>
    <bug_when>2016-02-26 10:23:28 +0000</bug_when>
    <thetext>We decided to do builds by simply running bitbake instead of running 2 resident processes: bitbake server and bitbake observer. This should make implementation of this feature much simpler and reliable.

Running bitbake with toasterui requires toasterui to run in build mode. Currently it can only run in observer mode.
Here is a fix for this: https://lists.yoctoproject.org/pipermail/toaster/2016-February/003952.html

Please, review.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>59784</commentid>
    <comment_count>17</comment_count>
    <who name="Ed Bartosh">eduard.bartosh</who>
    <bug_when>2016-03-08 10:06:08 +0000</bug_when>
    <thetext>It turned out that we still need to run bitbake server to support builds for older releaases, so I had to reimplement the implementation.

Here is first draft:
https://lists.yoctoproject.org/pipermail/toaster/2016-March/004068.html

Please, review.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>59794</commentid>
    <comment_count>18</comment_count>
    <who name="Ed Bartosh">eduard.bartosh</who>
    <bug_when>2016-03-08 16:38:18 +0000</bug_when>
    <thetext>v2 has been sent for review: https://lists.yoctoproject.org/pipermail/toaster/2016-March/004093.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>59894</commentid>
    <comment_count>19</comment_count>
    <who name="Ed Bartosh">eduard.bartosh</who>
    <bug_when>2016-03-11 12:28:32 +0000</bug_when>
    <thetext>sent v3: https://lists.yoctoproject.org/pipermail/toaster/2016-March/004132.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>60887</commentid>
    <comment_count>20</comment_count>
    <who name="Ed Bartosh">eduard.bartosh</who>
    <bug_when>2016-04-07 08:21:25 +0000</bug_when>
    <thetext>The fix has been merged to bitbake master: http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=a43a16b9fd471d719761354eaab81409d4b07470</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61917</commentid>
    <comment_count>21</comment_count>
    <who name="Alexandru Roman">alexandru.costinx.roman</who>
    <bug_when>2016-05-04 10:17:54 +0000</bug_when>
    <thetext>Verified on master.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>