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

installer: T7102: download upgrade images to a random path in the root filesystem #4330

Merged
merged 1 commit into from
Feb 4, 2025

Conversation

dmbaturin
Copy link
Member

Change summary

As of now, the image upgrade script always downloads the new image to /tmp/vyos_installation.iso. There are two problems with that approach:

  1. /tmp is a RAM-backed tmpfs, which means upgrade can fail if the system doesn't have enough free RAM to store a ~600MB image. Even if it does have that memory, a completely avoidable 600M RAM usage spike still isn't a good idea.
  2. If two people try to execute add system image at once, using a fixed location will lead to funny errors.

Storing the temporary image in the persistent root filesystem and using a random name for it solves both problems.

This PR is somewhat ugly — that's the price of making it minimal and easy to backport. The script can certainly benefit from a deep refactoring.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes)
  • Migration from an old Vyatta component to vyos-1x, please link to related PR inside obsoleted component
  • Other (please describe):

Related Task(s)

Related PR(s)

How to test / Smoketest result

Checklist:

  • I have read the CONTRIBUTING document
  • I have linked this PR to one or more Phabricator Task(s)
  • I have run the components SMOKETESTS if applicable
  • My commit headlines contain a valid Task id
  • My change requires a change to the documentation
  • I have updated the documentation accordingly

Copy link

github-actions bot commented Feb 3, 2025

👍
No issues in PR Title / Commit Title

Copy link

github-actions bot commented Feb 3, 2025

CI integration 👍 passed!

Details

CI logs

  • CLI Smoketests (no interfaces) 👍 passed
  • CLI Smoketests (interfaces only) 👍 passed
  • Config tests 👍 passed
  • RAID1 tests 👍 passed
  • TPM tests 👍 passed

@dmbaturin dmbaturin merged commit 2e80902 into vyos:current Feb 4, 2025
15 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

3 participants