- 15 3月, 2012 2 次提交
-
-
由 Luiz Capitulino 提交于
The migrate command is one of those commands where HMP and QMP completely mix up together. This made the conversion to the QAPI (which separates the command into QMP and HMP parts) a bit difficult. The first important change to be noticed is that this commit completes the removal of the Monitor object from migration code, started by the previous commit. Another important and tricky change is about supporting the non-detached mode. That is, if the user doesn't pass '-d' the migrate command will lock the monitor and will only release it when migration is finished. To support this in the new HMP command (hmp_migrate()), it is necessary to create a timer which runs every second and checks if the migration is still active. If it is, the timer callback will re-schedule itself to run one second in the future. If the migration has already finished, the monitor lock is released and the user can use it normally. All these changes should be transparent to the user. Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com> Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
-
由 Luiz Capitulino 提交于
The Monitor object is passed back and forth within the migration/savevm code so that it can print errors and progress to the user. However, that approach assumes a HMP monitor, being completely invalid in QMP. This commit drops almost every single usage of the Monitor object, all monitor_printf() calls have been converted into DPRINTF() ones. There are a few remaining Monitor objects, those are going to be dropped by the next commit. Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com> Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
-
- 17 2月, 2012 1 次提交
-
-
由 Paolo Bonzini 提交于
Notifiers do not need to access both ends of the list, and using a QLIST also simplifies the API. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 14 1月, 2012 1 次提交
-
-
由 Paolo Bonzini 提交于
All files under GPLv2 will get GPLv2+ changes starting tomorrow. event_notifier.c and exec-obsolete.h were only ever touched by Red Hat employees and can be relicensed now. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 13 12月, 2011 1 次提交
-
-
由 Eduardo Habkost 提交于
Also, we now return the qemu_fclose() value unchanged to the caller. For reference, the migrate_fd_cleanup() callers are the following: - migrate_fd_completed(): any negative value is considered an error, so the change is OK. - migrate_fd_error(): doesn't check the migrate_fd_cleanup() return value - migrate_fd_cancel(): doesn't check the migrate_fd_cleanup() return value Signed-off-by: NEduardo Habkost <ehabkost@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 06 12月, 2011 3 次提交
-
-
由 Luiz Capitulino 提交于
Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
-
由 Luiz Capitulino 提交于
Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
-
由 Luiz Capitulino 提交于
Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
-
- 22 11月, 2011 2 次提交
-
-
由 Anthony Liguori 提交于
Image files have two types of data: immutable data that describes things like image size, backing files, etc. and mutable data that includes offset and reference count tables. Today, image formats aggressively cache mutable data to improve performance. In some cases, this happens before a guest even starts. When dealing with live migration, since a file is open on two machines, the caching of meta data can lead to data corruption. This patch addresses this by introducing a mechanism to invalidate any cached mutable data a block driver may have which is then used by the live migration code. NB, this still requires coherent shared storage. Addressing migration without coherent shared storage (i.e. NFS) requires additional work. Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Anthony Liguori 提交于
This lets different subsystems register an Error that is thrown whenever migration is attempted. This works nicely because it gracefully supports things like hotplug. Right now, if multiple errors are registered, only one of them is reported. I expect that for 1.1, we'll extend query-migrate to return all of the reasons why migration is disabled at any given point in time. Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 12 11月, 2011 1 次提交
-
-
由 Juan Quintela 提交于
Migration with fd uses s->mon to pass the fd. But we only assign the s->mon for !detached migration. Fix it. Once there add a comment indicating that s->mon has two uses. Bug reported by: Wen Congyang <wency@cn.fujitsu.com> Signed-off-by: NJuan Quintela <quintela@redhat.com> CC: Wen Congyang <wency@cn.fujitsu.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 02 11月, 2011 1 次提交
-
-
由 Luiz Capitulino 提交于
A simple migration reproduces it: 1. Start the source VM with: # qemu [...] -S 2. Start the destination VM with: # qemu <source VM cmd-line> -incoming tcp:0:4444 3. In the source VM: (qemu) migrate -d tcp:0:4444 4. The source VM will segfault as soon as migration completes (might not happen in the first try) What is happening here is that qemu_file_put_notify() can end up closing 's->file' (in which case it's also set to NULL). The call stack is rather complex, but Eduardo helped tracking it to: select loop -> migrate_fd_put_notify() -> qemu_file_put_notify() -> buffered_put_buffer() -> migrate_fd_put_ready() -> migrate_fd_completed() -> migrate_fd_cleanup(). To be honest, it's not completely clear to me in which cases 's->file' is not closed (on error maybe)? But I doubt this fix will make anything worse. Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com> Acked-by: NEduardo Habkost <ehabkost@redhat.com> Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 27 10月, 2011 1 次提交
-
-
由 Luiz Capitulino 提交于
Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com> Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
-
- 25 10月, 2011 1 次提交
-
-
由 Gerd Hoffmann 提交于
Add migration_is_active and migration_has_failed functions to query migration state. Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
-
- 20 10月, 2011 26 次提交
-
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
This will allow us to hide the state values. Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
Now that current_migration always exist, there is no reason for max_throotle variable. Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
This means we can remove the two forward declarations. Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
It is used only in one place Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
It is only used inside migration.c, and fields on that struct are accessed all around the place on that file. Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
We called it from a single place, and always with state != MIG_STATE_ACTIVE. Just remove the whole callback. For users of the notifier, notice that this is exactly the case where they don't care, we are just freeing the state from previous failed migration (it can't be a sucessful one, otherwise we would not be running on that machine in the first place). Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
This function is a bit different of the others that change the state, in the sense that if migrate_fd_cleanup() returns an error, it set the status to error, not completed. Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Use MIG_STATE_ACTIVE only when migration has really started. Use this new state to setup migration parameters. Change defines for an anonymous struct. Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
Once there, remove all parameters that don't need to be passed to *start_outgoing_migration() functions Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
I have to move two functions postions to avoid forward declarations Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Now the function returned errno, so it is better the new name. Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
make functions propagate errno, instead of just using -EIO. Add a comment about what are the return value of qemu_savevm_state_iterate(). Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
We normally already have an errno value. When not, abuse EIO. Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
If migration is not active, just ignore writes. Signed-off-by: NJuan Quintela <quintela@redhat.com>
-
由 Yoshiaki Tamura 提交于
Although migrate_fd_put_buffer() sets MIG_STATE_ERROR if it failed, since migrate_fd_put_notify() isn't checking error of underlying QEMUFile, those resources are kept open. This patch checks it and calls migrate_fd_error() in case of error. Signed-off-by: NYoshiaki Tamura <tamura.yoshiaki@lab.ntt.co.jp> Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Juan Quintela 提交于
Signed-off-by: NJuan Quintela <quintela@redhat.com> Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
-