<?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>14183</bug_id>
          
          <creation_ts>2021-01-11 12:46:31 +0000</creation_ts>
          <short_desc>psuedo path mismatch during image build</short_desc>
          <delta_ts>2021-02-18 22:10:30 +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>OE-Core</product>
          <component>core</component>
          <version>3.4</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>AB-INT</status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>3.3 M3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ross Burton">ross.burton</reporter>
          <assigned_to name="Richard Purdie">richard.purdie</assigned_to>
          <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>richard.purdie</cc>
    
    <cc>ross.burton</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>88904</commentid>
    <comment_count>0</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2021-01-11 12:46:31 +0000</bug_when>
    <thetext>Building an image failed:

ERROR: core-image-sato-1.0-r0 do_rootfs: Unable to update the package index files. Command &apos;[&apos;/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/recipe-sysroot-native/usr/bin/apt-get&apos;, &apos;update&apos;]&apos; returned -6:
Get:1 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/qemux86 ./ InRelease
Ign:1 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/qemux86 ./ InRelease
Get:2 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/core2-32 ./ InRelease
Ign:2 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/core2-32 ./ InRelease
Get:3 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/all ./ InRelease
Ign:3 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/all ./ InRelease
Get:4 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/qemux86 ./ Release [1,219 B]
Get:5 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/core2-32 ./ Release [1,220 B]
Get:6 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/all ./ Release [1,215 B]
Get:4 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/qemux86 ./ Release [1,219 B]
Get:7 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/qemux86 ./ Release.gpg
Ign:7 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/qemux86 ./ Release.gpg
Get:5 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/core2-32 ./ Release [1,220 B]
Get:6 file:/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/oe-rootfs-repo/all ./ Release [1,215 B]
abort()ing pseudo client by server request. See https://wiki.yoctoproject.org/wiki/Pseudo_Abort for more details on this.
Check logfile: /home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/pseudo//pseudo.log

The pseudo.log has the following path mismatches:

path mismatch [1 link]: ino 143525936 db &apos;/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/apt/lists/partial/_home_pokybuild_yocto-worker_pkgman-non-rpm_build_build_tmp_work_qemux86-poky-linux_core-image-sato_1.0-r0_oe-rootfs-repo_qemux86_._Release.CBFzPd&apos; req &apos;/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/apt/lists/partial/_home_pokybuild_yocto-worker_pkgman-non-rpm_build_build_tmp_work_qemux86-poky-linux_core-image-sato_1.0-r0_oe-rootfs-repo_qemux86_._Release&apos;.

This happened more than once, the other build had the same error:

path mismatch [1 link]: ino 27666766 db &apos;/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/apt/lists/partial/_home_pokybuild_yocto-worker_pkgman-non-rpm_build_build_tmp_work_qemux86-poky-linux_core-image-sato_1.0-r0_oe-rootfs-repo_all_._Release.RpRzHw&apos; req &apos;/home/pokybuild/yocto-worker/pkgman-non-rpm/build/build/tmp/work/qemux86-poky-linux/core-image-sato/1.0-r0/apt/lists/partial/_home_pokybuild_yocto-worker_pkgman-non-rpm_build_build_tmp_work_qemux86-poky-linux_core-image-sato_1.0-r0_oe-rootfs-repo_all_._Release&apos;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>88925</commentid>
    <comment_count>1</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2021-01-14 15:45:46 +0000</bug_when>
    <thetext>RP: Looks like mkstemp is racing with pseudo occasionally.
Encounterd when using apt but likely happening elsewhere from time to time.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>89092</commentid>
    <comment_count>2</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2021-01-29 21:52:12 +0000</bug_when>
    <thetext>There was a recent fix in pseudo for rename() handling. We may want to audit the apt codepaths to see if that rename issue could have caused this. The worry is the rename()+fstat() issue should reproduce all the time and this does not.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>89198</commentid>
    <comment_count>3</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2021-02-10 14:46:59 +0000</bug_when>
    <thetext>https://autobuilder.yoctoproject.org/typhoon/#/builders/56/builds/1341/steps/14/logs/stdio

pid 959642 [parent 959629], doing new pid setup and server start
Setup complete, sending SIGUSR1 to pid 959629.
path mismatch [1 link]: ino 88221442 db &apos;/home/pokybuild/yocto-worker/oe-selftest/build/build-st-2079038/reproducibleB/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0-r0/apt/lists/partial/_home_pokybuild_yocto-worker_oe-selftest_build_build-st-2079038_reproducibleB_tmp_work_qemux86%5f64-poky-linux_core-image-sato_1.0-r0_oe-rootfs-repo_all_._Release.oY00En&apos; req &apos;/home/pokybuild/yocto-worker/oe-selftest/build/build-st-2079038/reproducibleB/tmp/work/qemux86_64-poky-linux/core-image-sato/1.0-r0/apt/lists/partial/_home_pokybuild_yocto-worker_oe-selftest_build_build-st-2079038_reproducibleB_tmp_work_qemux86%5f64-poky-linux_core-image-sato_1.0-r0_oe-rootfs-repo_all_._Release&apos;.
db cleanup for server shutdown, 03:04:13.117
memory-to-file backup complete, 03:04:13.118.
db cleanup finished, 03:04:13.118
pseudo.log (END)

so definitely still present</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>89202</commentid>
    <comment_count>4</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2021-02-10 23:17:38 +0000</bug_when>
    <thetext>I suspect what is is happening is that in between pseudo calling real_rename() and then running OP_RENAME on the pseudo database, something is calling something like stat() on the newpath.

This stat call would have the same inode as oldpath and oldpath would still be in the database but isn&apos;t marked as MAY_UNLINK so this abort triggers.

The fix is likely to mark oldpath as MAY_UNLINK in the database before real_rename call.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>89302</commentid>
    <comment_count>5</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2021-02-18 22:10:30 +0000</bug_when>
    <thetext>http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=064e203987fa9e5b46046ca48d0f9f0e27df490c</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>