Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/build/cmd/releasebot: canceled release can create truncated tarballs #33025

Closed
toothrot opened this issue Jul 10, 2019 · 2 comments
Closed
Labels
Builders x/build issues (builders, bots, dashboards) FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@toothrot
Copy link
Contributor

toothrot commented Jul 10, 2019

During a recent patch release, releasebot appeared stalled during a --mode=release run. Restarting releasebot appeared to resume the release, and reported a successful release. The generated tarball for at least one architecture was truncated. The SHA sum of the tar matched the truncated tar.

Releasebot should:

Nice-to-have:

  • releasebot should mention what release steps were in-flight when it was cancelled.

Example of error:

$ tar xf goX.Y.Z.platform-arch.tar.gz 

gzip: stdin: unexpected end of file
tar: Unexpected EOF in archive
tar: Unexpected EOF in archive
tar: Error is not recoverable: exiting now

$ sha256sum goX.Y.Z.platform-arch.tar.gz
b9c7eb3e77c0489e0801ea5ba0ac7245425c4d3adcf051db99d527315667e965
$ cat goX.Y.Z.platform-arch.tar.gz.sha256
b9c7eb3e77c0489e0801ea5ba0ac7245425c4d3adcf051db99d527315667e965

/cc @dmitshur

@toothrot toothrot added Builders x/build issues (builders, bots, dashboards) NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Jul 10, 2019
@toothrot toothrot added this to the Unreleased milestone Jul 10, 2019
@dmitshur dmitshur self-assigned this Sep 13, 2019
@dmitshur
Copy link
Contributor

CL 189537 has helped with this, it changed the behavior of releasebot to first write release artifacts to a temporary directory while the release is in progress, and then after tests complete successfully, atomically moving them into their final location.

That means interrupting releasebot while it's in the process of downloading the release artifact from a buildlet will leave the truncated artifact in a temporary directory, and it will not be incorrectly re-used by the next releasebot run.

So releasebot should be safe to resume now. What's left here is to investigate if there are other scenarios where this can still happen, and investigate whether the timing/location of the SHA generation is optimal.

@dmitshur
Copy link
Contributor

dmitshur commented Aug 3, 2022

releasebot has been superseded by relui and this issue no longer applies, closing.

@dmitshur dmitshur closed this as not planned Won't fix, can't repro, duplicate, stale Aug 3, 2022
@dmitshur dmitshur added this to Done in Go Release Team Aug 3, 2022
@golang golang locked and limited conversation to collaborators Aug 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Builders x/build issues (builders, bots, dashboards) FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
Archived in project
Development

No branches or pull requests

3 participants