Bug 13913 - dpkg-deb: tar: file changed as we read it errors
Summary: dpkg-deb: tar: file changed as we read it errors
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: unspecified
Hardware: x86 Multiple
: Medium+ normal
Target Milestone: 3.2 M1
Assignee: Paul Eggleton
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2020-05-20 15:09 UTC by Paul Eggleton
Modified: 2020-06-24 20:02 UTC (History)
4 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments
Log excerpt of failure (3.82 KB, text/plain)
2020-05-20 15:09 UTC, Paul Eggleton
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Eggleton 2020-05-20 15:09:12 UTC
Created attachment 4681 [details]
Log excerpt of failure

I'm currently seeing a repeatable "tar: file changed as we read it" failure in do_package_write_deb (log attached). Addition of logging "ls -l" before and after does not indicate any outward changes to the file, however when I did some searching I found that there was a patch added some time ago that should completely prevent this type of error from causing the task to fail:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=40731942515ec8d80c727ad561174986d4f05818

This patch was later renamed, and then the renamed patch was removed in the following commit:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=81b59a19ad6df490f1edbea70b2612d7a8e43164

The latter suggests that the patch was merged upstream in the following commit:

https://git.dpkg.org/cgit/dpkg/dpkg.git/commit/?id=7a91341446851cd3594a8b752823b8c1f26d652a

However, the indicated upstream commit appears to be a refactoring and does not specially handle a return of 1 from tar at all, so it seems to me that this patch possibly should have been rebased rather than removed. I could be missing something however, and it's possible that the patch is no longer needed in the general case.
Comment 1 Richard Purdie 2020-05-20 16:13:50 UTC
I suspect we need to add the patch. Could you do that Paul?
Comment 2 Paul Eggleton 2020-05-21 15:03:04 UTC
Will do.