Skip to contentSkip to conversation

tools: handle xl migrate --debug in legacy stream

PATCH Applied Olaf Hering 4 participants 6 messages Apr 7, 2016 – May 9, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tools: handle xl migrate --debug in legacy stream

Doing a 'xl migrate --debug domU host' on xen-4.5 adds a XC_SAVE_ID_ENABLE_VERIFY_MODE marker, which is not handled. Since using --debug is valid usage, handle it by logging the fact instead of aborting the migration.

---
 tools/python/scripts/convert-legacy-stream | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
tools/python/scripts/convert-legacy-stream +1 -2
index 41fee10..5f80f13 100755
@@ -389,8 +389,7 @@ def read_chunks(vm):
             write_page_data(pfns, pages)
 
         elif marker == legacy.CHUNK_enable_verify_mode:
-            # For debugging purposes only.  Will not be seen in real migration
-            raise RuntimeError("Unable to convert a debug stream")
+            info("This is a debug stream")
 
         elif marker == legacy.CHUNK_vcpu_info:
             max_id, = unpack_exact("i")

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

Reviewed-by on v1 1/1
#1 lore raw
Quoted 8 lines · Olaf Hering

Doing a 'xl migrate --debug domU host' on xen-4.5 adds a XC_SAVE_ID_ENABLE_VERIFY_MODE marker, which is not handled. Since using --debug is valid usage, handle it by logging the fact instead of aborting the migration.

Hmm - I had never considered someone doing that. Debug mode for legacy migration was sufficiently broken (in a falling over wild pointers kind of way) that I assumed noone ever used it.

But yes - not needlessly killing the migration is an improvement.

Ian: This is also a backport candidate for 4.6

Quoted 9 lines
---
 tools/python/scripts/convert-legacy-stream | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
tools/python/scripts/convert-legacy-stream +0 -0
index 41fee10..5f80f13 100755

tools/python/scripts/convert-legacy-stream def read_chunks(vm): · line 395

Quoted 9 lines
tools/python/scripts/convert-legacy-stream +1 -2
@@ -389,8 +389,7 @@ def read_chunks(vm):
             write_page_data(pfns, pages)
 
         elif marker == legacy.CHUNK_enable_verify_mode:
-            # For debugging purposes only.  Will not be seen in real migration
-            raise RuntimeError("Unable to convert a debug stream")
+            info("This is a debug stream")
 
         elif marker == legacy.CHUNK_vcpu_info:
             max_id, = unpack_exact("i")

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#2 lore raw

Andrew Cooper writes ("Re: [PATCH] tools: handle xl migrate --debug in legacy stream"):

Quoted 14 lines · Olaf Hering
Quoted 8 lines

Doing a 'xl migrate --debug domU host' on xen-4.5 adds a XC_SAVE_ID_ENABLE_VERIFY_MODE marker, which is not handled. Since using --debug is valid usage, handle it by logging the fact instead of aborting the migration.

Hmm - I had never considered someone doing that. Debug mode for legacy migration was sufficiently broken (in a falling over wild pointers kind of way) that I assumed noone ever used it.

Quoted 5 lines

But yes - not needlessly killing the migration is an improvement.

Ian: This is also a backport candidate for 4.6

Queued for backport.

Ian.

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

Applied
#3 lore raw

Ian Jackson writes ("Re: [PATCH] tools: handle xl migrate --debug in legacy stream"):

Quoted 4 lines

Andrew Cooper writes ("Re: [PATCH] tools: handle xl migrate --debug in legacy stream"):

Quoted 1 line

Ian: This is also a backport candidate for 4.6

Queued for backport.

Pushed to 4.6.

Ian.

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

Acked-by on v1 1/1
#4 lore raw
In reply to Olaf Hering
Quoted 8 lines · Olaf Hering

Doing a 'xl migrate --debug domU host' on xen-4.5 adds a XC_SAVE_ID_ENABLE_VERIFY_MODE marker, which is not handled. Since using --debug is valid usage, handle it by logging the fact instead of aborting the migration.

Quoted 9 lines
---
 tools/python/scripts/convert-legacy-stream | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
tools/python/scripts/convert-legacy-stream +0 -0
index 41fee10..5f80f13 100755

tools/python/scripts/convert-legacy-stream def read_chunks(vm): · line 395

Quoted 9 lines
tools/python/scripts/convert-legacy-stream +1 -2
@@ -389,8 +389,7 @@ def read_chunks(vm):
             write_page_data(pfns, pages)
 
         elif marker == legacy.CHUNK_enable_verify_mode:
-            # For debugging purposes only.  Will not be seen in real migration
-            raise RuntimeError("Unable to convert a debug stream")
+            info("This is a debug stream")
 
         elif marker == legacy.CHUNK_vcpu_info:
             max_id, = unpack_exact("i")

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#5 lore raw

Wei Liu writes ("Re: [PATCH] tools: handle xl migrate --debug in legacy stream"):

Quoted 11 lines · Olaf Hering
Quoted 8 lines

Doing a 'xl migrate --debug domU host' on xen-4.5 adds a XC_SAVE_ID_ENABLE_VERIFY_MODE marker, which is not handled. Since using --debug is valid usage, handle it by logging the fact instead of aborting the migration.

Thanks, and thanks to Andrew for the review. Queued for 4.7.

Ian.

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel