From: Dan Smith Subject: [PATCH][XM-TEST] Some adjustments to the restore tests Date: Tue, 29 Nov 2005 14:43:25 -0800 Message-ID: <87zmnnhy7m.fsf@theine.beaverton.ibm.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Xen Developers List-Id: xen-devel@lists.xenproject.org --=-=-= After inspecting the restore and migrate failures on x86_64, I realized that the DomUs are oops-ing. This patch turns on console debug dumping for the restored-domain consoles so that we can see the oops messages, as shown here: http://xmtest.dague.org/cgi-bin/display?view=single&testid=778#log_restore01_basic_pos Signed-off-by: Dan Smith --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=restore_tweaks.patch # HG changeset patch # User dan@guaranine.beaverton.ibm.com # Node ID dea4045294359ebfecc8161474b14c904e350432 # Parent 151ce96c7cb03ce3981ecdb849bf281af03eeade Some tweaks to the restore and migrate tests to expose the consoles of the restored DomUs, since they currently Oops on x86_64. diff -r 151ce96c7cb0 -r dea404529435 tools/xm-test/tests/migrate/01_migrate_localhost_pos.py --- a/tools/xm-test/tests/migrate/01_migrate_localhost_pos.py Tue Nov 29 18:27:18 2005 +++ b/tools/xm-test/tests/migrate/01_migrate_localhost_pos.py Tue Nov 29 22:35:20 2005 @@ -38,8 +38,8 @@ try: # Activate the console console.sendInput("foo") - # Make sure a command succeeds - run = console.runCmd("ls /bin") + # Set a variable to check on the other side + run = console.runCmd("foo=bar") except ConsoleError, e: FAIL(str(e)) @@ -66,18 +66,21 @@ # Attach a console to it try: console = XmConsole(domain.getName(), historySaveCmds=True) + console.debugMe = True except ConsoleError, e: pass + +console.sendInput("ls") # Run 'ls' try: # Check the dmesg output on the domU - run = console.runCmd("ls /bin") + run = console.runCmd("echo xx$foo") except ConsoleError, e: FAIL(str(e)) - -if not re.search("chmod", run["output"]): - FAIL("invalid console output from ls after migration") + +if not re.search("bar", run["output"]): + FAIL("Migrated domain has been reset") # Close the console console.closeConsole() diff -r 151ce96c7cb0 -r dea404529435 tools/xm-test/tests/restore/01_restore_basic_pos.py --- a/tools/xm-test/tests/restore/01_restore_basic_pos.py Tue Nov 29 18:27:18 2005 +++ b/tools/xm-test/tests/restore/01_restore_basic_pos.py Tue Nov 29 22:35:20 2005 @@ -25,6 +25,8 @@ # Make sure the domain isn't DOA try: console = XmConsole(domain.getName()) + console.sendInput("input") + console.runCmd("foo=bar") except ConsoleError, e: FAIL(str(e)) @@ -63,9 +65,12 @@ # Make sure it's alive try: newConsole = XmConsole(domain.getName()) - run = newConsole.runCmd("ls") - if run["return"] != 0: - FAIL("Unable to read from restored domain") + # Enable debug dumping because this generates a Oops on x86_64 + newConsole.debugMe = True + newConsole.sendInput("ls") + run = newConsole.runCmd("echo xx$foo") + if not re.search("bar", run["output"]): + FAIL("Restored domain has been reset") except ConsoleError, e: FAIL("Restored domain is dead (%s)" % str(e)) diff -r 151ce96c7cb0 -r dea404529435 tools/xm-test/tests/restore/04_restore_withdevices_pos.py --- a/tools/xm-test/tests/restore/04_restore_withdevices_pos.py Tue Nov 29 18:27:18 2005 +++ b/tools/xm-test/tests/restore/04_restore_withdevices_pos.py Tue Nov 29 22:35:20 2005 @@ -90,6 +90,11 @@ try: console = XmConsole(domain.getName()) + # Enable debug dumping, as this causes an Oops on x86_64 + console.debugMe = True + + # In case the domain is rebooted + console.sendInput("ls") run = console.runCmd("ls | grep proc") if run["return"] != 0: --=-=-= -- Dan Smith IBM Linux Technology Center Open Hypervisor Team email: danms@us.ibm.com --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --=-=-=--