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

Add Vm.update_spdk_version(...) #1478

Merged
merged 2 commits into from May 7, 2024
Merged

Add Vm.update_spdk_version(...) #1478

merged 2 commits into from May 7, 2024

Conversation

pykello
Copy link
Contributor

@pykello pykello commented Apr 18, 2024

Previously to change SPDK version of a VM we needed to do multiple weird manual steps. This patch automates some of them and what we need to do is:

  1. Install the new SPDK version on the host:
> Prog::Storage::SetupSpdk.assemble(
     vm_host.id, "some-spdk-version",
     start_service: true, allocation_weight: 100)
  1. Update all VMs we want to migrate to this SPDK version. Note that this will just update related configs and won't take effect until host reboot:
> vm.update_spdk_version("some-spdk-version")
  1. Reboot host:
> vm_host.incr_reboot
  1. Optionally, remove the old SPDK installation:
> Prog::Storage::RemoveSpdk.assemble(old_spdk_installation.id)

@pykello pykello changed the title offline storage upgrade draft Add Vm.update_spdk_version(...) Apr 19, 2024
@pykello pykello marked this pull request as ready for review April 19, 2024 00:08
@pykello pykello requested a review from fdr April 19, 2024 00:08
@pykello pykello force-pushed the pykello/storage_upgrade_2 branch 3 times, most recently from ee2c35b to ef5ee48 Compare April 19, 2024 00:11
Copy link
Collaborator

@fdr fdr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.

model/vm.rb Outdated Show resolved Hide resolved
Copy link
Collaborator

@fdr fdr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

alright, though regenerating the unit file is a step into a different world just a little bit, where can't get some implied backwards compatibility anymore. We'll need to keep the re-generation in order with all extant VMs.

For example, if we move to using hotplug to set up cloud-hypervisor rather than command line options, there will be new considerations.

Not a blocker, but it's a transition.

Base automatically changed from pykello/storage_upgrade to main April 25, 2024 21:32
When changing the SPDK version of a VM, we need to reinstall these to
update these, as VM services have dependencies to SPDK.
Previously to change SPDK version of a VM we needed to do multiple
weird manual steps. This patch automates some of them and what we need
to do is:

1. Install the new SPDK version on the host:

```
> Prog::Storage::SetupSpdk.assemble(
     vm_host.id, "some-spdk-version",
     start_service: true, allocation_weight: 100)
```

2. Update all VMs we want to migrate to this SPDK version. Note that
this will just update related configs and won't take effect until host
reboot:

```
> vm.update_spdk_version("some-spdk-version")
```

3. Reboot host:

```
> vm_host.incr_reboot
```

4. Optionally, remove the old SPDK installation:

```
> Prog::Storage::RemoveSpdk.assemble(old_spdk_installation.id)
```
@pykello pykello force-pushed the pykello/storage_upgrade_2 branch from b4edf29 to 22d7814 Compare May 7, 2024 20:46
@pykello pykello merged commit b2e21b8 into main May 7, 2024
6 checks passed
@pykello pykello deleted the pykello/storage_upgrade_2 branch May 7, 2024 20:50
@github-actions github-actions bot locked and limited conversation to collaborators May 7, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants