-
Notifications
You must be signed in to change notification settings - Fork 71
Snapshot and migrate functionality. #1540
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
Conversation
jacdavi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good. Tested that everything functioned as expected and it did. Just two things
- Could you run
scripts/all.bashI saw a missing curly brace and some formatting errors that should be fixed - Is this code block still relevant for snapshots? If not can we remove it and the associated part of the help output? https://github.com/sandia-minimega/minimega/pull/1540/files#diff-3e02ecaf1183b3cbe8d2924d7ff4d9bf7e0b0763d897cd7f98b65b02994fdf9dR798-R818
…grate) reword help docs for vm snapshot remove empty append
|
@glattercj thanks for the heads up! If I'm tracking everything correctly, it seems that |
|
Maybe keep each command atomic without hidden side effects?
|
|
Based on code comments, it seems unlikely that anyone would want to save just the memory state, since it's probably not bootable without the disk at that point as well. I think that's why @bjwrigh kept them coupled. |
|
In that case why not just combine the 2 and have:
I added |
|
I appreciate the input. Given how long it's taken me to wrap my head around all the disk commands in minimega/phenix, I understand how important naming is. I agree that |
|
I am interested in taking over this PR and will be submitting one that addresses the main requested changes. However, I was wondering how far down the refactor rabbit-hole should I go? It sounds like the changes needed are:
This will also need modifications to:
I think that is the minimum changes needed. However, there are a lot of references to both "migrate" and "snapshot". It feels reasonable to rename these function calls/debug statements/variables to use the new syntax. While this will make the new PR much more complicated to review/test, it will also improve maintainability in the future. Do you have opinions on this? It could be split into two PRs as well, if desired. |
That all sounds correct to me, and thanks for picking this up! If you're willing to make those extra updates, I'd be good with everything in 1 PR. |
|
closing in favor of #1555 which builds on this PR |
-29ea35c: Fixed some log levels causing unnecessary noise when using Phenix
-379c4bf: Snapshot now only does snapshot. Migrate does migrate (and snapshot, because they are often linked). Will also take care of multiple disks automatically. [Note: vm snapshot previously paused VM because of calling migrate. This is no longer the case. vm migrate still pauses the VM for the operation, but does not restart the VM]