Skip to content

Add OVS database migration capabilities.#68

Merged
fnordahl merged 4 commits intocanonical:mainfrom
crypticC0der:migrateovs
Mar 28, 2026
Merged

Add OVS database migration capabilities.#68
fnordahl merged 4 commits intocanonical:mainfrom
crypticC0der:migrateovs

Conversation

@crypticC0der
Copy link
Copy Markdown
Collaborator

If the openvswitch-switch service is running and theres a conf.db file where its expected to be: shutdown that version of OVS, and take its database which we then use as the starting point for the microovn switch database.

@crypticC0der crypticC0der requested a review from a team as a code owner March 20, 2026 23:05
@crypticC0der crypticC0der force-pushed the migrateovs branch 2 times, most recently from 14d41ee to 37af0e2 Compare March 20, 2026 23:09
Copy link
Copy Markdown
Member

@fnordahl fnordahl left a comment

Choose a reason for hiding this comment

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

Thank you for your work on this.

I'd prefer if the charm would do the required steps prior to install, this would simplify the solution and also contain the feature in the charm, requiring no further changes to the snap.

I have a couple suggestions in-line on how we could test this without having to bend the implementation for test purposes.

@crypticC0der
Copy link
Copy Markdown
Collaborator Author

my concern with taking down OVS before microovn install is that if OVS is handling networking in such a way that taking it down means loosing external internet access, we would then be unable to install microovn (due to the lack of internet access now OVS is down)

@fnordahl
Copy link
Copy Markdown
Member

my concern with taking down OVS before microovn install is that if OVS is handling networking in such a way that taking it down means loosing external internet access, we would then be unable to install microovn (due to the lack of internet access now OVS is down)

ha, that is indeed a very good concern, perhaps even a better reason to put in that comment as I read it to be done this way mainly because of being hard to test as opposed to this chicken and egg problem.

@crypticC0der
Copy link
Copy Markdown
Collaborator Author

new token distributor library canonical/microcluster-token-distributor-operator#14

@crypticC0der
Copy link
Copy Markdown
Collaborator Author

canonical/microovn#320

@fnordahl fnordahl dismissed their stale review March 27, 2026 15:15

Dropping my request for changes on the back of discussion and to avoid deterring other reviewers if they get to look at the next iteration sooner than me

@crypticC0der
Copy link
Copy Markdown
Collaborator Author

K8s test fixed 👁️ 👁️

If the openvswitch-switch service is running and theres a conf.db file
where its expected to be: shutdown that version of OVS, and take its
database which we then use as the starting point for the microovn switch
database.

Signed-off-by: MJ Ponsonby <mj.ponsonby@canonical.com>
There has been an update by a very talented developer at the token
distributor charm, she has added prejoin and prebootstrap hooks, which
give us functionality to make our implementation of OVS DB migration
slightly cleaner.

Signed-off-by: MJ Ponsonby <mj.ponsonby@canonical.com>
Switch to k8s over microk8s for stability. Rework k8s integration test
to have smaller steps and fewer units to conserve resources.

Signed-off-by: MJ Ponsonby <mj.ponsonby@canonical.com>
Flags microovn to bypass the OVS checks and allow the user to install
microovn anyway.

Signed-off-by: MJ Ponsonby <mj.ponsonby@canonical.com>
Copy link
Copy Markdown
Member

@fnordahl fnordahl left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@fnordahl fnordahl merged commit 8cc5aa8 into canonical:main Mar 28, 2026
164 of 184 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants