oeqa: fix runtime testing using systemd-boot target
v3 cover oeqa: fix runtime testing using systemd-boot target
I'm sending this on behalf of Erik. Apart from adding the missing bug reference in patch 1/4, I also added a 'sync' call as part of the reboot operation to ensure that reboot (after extraction of big rootfs) of target doesn't take much longer than expected by testimage.
PATCH v3 1/4 masterimage.py: fix issue with calling reboot on masterimage/DUT
From: Erik Botö <[email protected]>
On systemd systems calling reboot over an ssh connection doesn't return as expected causing an exception, therefore wrap the call to reboot in order to avoid this issue.
Also sync the filesystems before rebooting cause otherwise, it will be done as part of the reboot and could take a very long time and testimage will fail to access the machine. This issue was observed consistently with one of our rootfs at Pelagicore.
[YOCTO #11524]
--- meta/lib/oeqa/controllers/masterimage.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/lib/oeqa/controllers/masterimage.py +1 -1
@@ -108,7 +108,7 @@ class MasterImageHardwareTarget(oeqa.targetcontrol.BaseTarget, metaclass=ABCMeta time.sleep(10) self.power_ctl("cycle") else: - status, output = conn.run("reboot") + status, output = conn.run("sync; { sleep 1; reboot; } > /dev/null &") if status != 0: bb.error("Failed rebooting target and no power control command defined. You need to manually reset the device.\n%s" % output)
Signature · 1 line
2.9.4
PATCH v3 2/4 masterimage.py: rename parameter "params" in start() to "extra_bootparams"
In reply to Zeeshan AliFrom: Erik Botö <[email protected]>
This matches how it is called, and how it is named in qmeu target.
[YOCTO #11524]
--- meta/lib/oeqa/controllers/masterimage.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/lib/oeqa/controllers/masterimage.py +1 -1
@@ -143,7 +143,7 @@ class MasterImageHardwareTarget(oeqa.targetcontrol.BaseTarget, metaclass=ABCMeta def _deploy(self): pass - def start(self, params=None): + def start(self, extra_bootparams=None): bb.plain("%s - boot test image on target" % self.pn) self._start() # set the ssh object for the target/test image
Signature · 1 line
2.9.4
PATCH v3 3/4 masterimage.py: fix stop()
In reply to Zeeshan AliFrom: Erik Botö <[email protected]>
The stop() function is called in the context of the masterimage, so self.master should be used instead of self.connection which is undefined at that time.
[YOCTO #11524]
--- meta/lib/oeqa/controllers/masterimage.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/lib/oeqa/controllers/masterimage.py +1 -1
@@ -156,7 +156,7 @@ class MasterImageHardwareTarget(oeqa.targetcontrol.BaseTarget, metaclass=ABCMeta def stop(self): bb.plain("%s - reboot/powercycle target" % self.pn) - self.power_cycle(self.connection) + self.power_cycle(self.master) class GummibootTarget(MasterImageHardwareTarget):
Signature · 1 line
2.9.4
PATCH v3 4/4 sshcontrol.py: in copy_to() always use scp
In reply to Zeeshan AliFrom: Erik Botö <[email protected]>
The current implementation is broken when the localpath is a link. Then only a symlink would be created on the target, instead of copying the actual file.
[YOCTO #11524]
--- meta/lib/oeqa/utils/sshcontrol.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-)
meta/lib/oeqa/utils/sshcontrol.py +3 -6
@@ -150,12 +150,9 @@ class SSHControl(object): def copy_to(self, localpath, remotepath): if os.path.islink(localpath): - link = os.readlink(localpath) - dst_dir, dst_base = os.path.split(remotepath) - return self.run("cd %s; ln -s %s %s" % (dst_dir, link, dst_base)) - else: - command = self.scp + [localpath, '%s@%s:%s' % (self.user, self.ip, remotepath)] - return self._internal_run(command, ignore_status=False) + localpath = os.path.dirname(localpath) + "/" + os.readlink(localpath) + command = self.scp + [localpath, '%s@%s:%s' % (self.user, self.ip, remotepath)] + return self._internal_run(command, ignore_status=False) def copy_from(self, remotepath, localpath): command = self.scp + ['%s@%s:%s' % (self.user, self.ip, remotepath), localpath]
Signature · 1 line
2.9.4
✗ patchtest: failure for oeqa: fix runtime testing using systemd-boot target (rev2)
In reply to Zeeshan Ali== Series Details ==
Series: oeqa: fix runtime testing using systemd-boot target (rev2)
Revision: 2
URL : https://patchwork.openembedded.org/series/6953/
State : failure
== Summary ==
Thank you for submitting this patch series to OpenEmbedded Core. This is an automated response. Several tests have been executed on the proposed series by patchtest resulting in the following failures:
* Issue Series does not apply on top of target branch [test_series_merge_on_head]
Suggested fix Rebase your series on top of targeted branch
Targeted branch master (currently at 1d9a88f635)
If you believe any of these test results are incorrect, please reply to the mailing list ([email protected]) raising your concerns. Otherwise we would appreciate you correcting the issues and submitting a new version of the patchset if applicable. Please ensure you add/increment the version number when sending the new version (i.e. [PATCH] -> [PATCH v2] -> [PATCH v3] -> ...).
---
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe
Re: ✗ patchtest: failure for oeqa: fix runtime testing using systemd-boot target (rev2)
Hey Zeeshan,
Let me know if you need any help with this. This probably requires that you do a rebase with master and resubmit a V4.
Cheers,
Stephano
Quoted 38 lines · Patchwork
== Series Details ==
Series: oeqa: fix runtime testing using systemd-boot target (rev2)
Revision: 2
URL : https://patchwork.openembedded.org/series/6953/
State : failure== Summary ==
Thank you for submitting this patch series to OpenEmbedded Core. This is an automated response. Several tests have been executed on the proposed series by patchtest resulting in the following failures:
* Issue Series does not apply on top of target branch [
test_series_merge_on_head]
Suggested fix Rebase your series on top of targeted branch
Targeted branch master (currently at1d9a88f635)If you believe any of these test results are incorrect, please reply to the mailing list ([email protected]) raising your concerns. Otherwise we would appreciate you correcting the issues and submitting a new version of the patchset if applicable. Please ensure you add/increment the version number when sending the new version (i.e. [PATCH] -> [PATCH v2] -> [PATCH v3] -> ...).
---
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oeSignature · 4 lines
_______________________________________________ Openembedded-core mailing list [email protected] http://lists.openembedded.org/mailman/listinfo/openembedded-core
Re: ✗ patchtest: failure for oeqa: fix runtime testing using systemd-boot target (rev2)
Hi Stephano,
Thanks. I'm already on my 2 weeks vacation so if you could kindly rebase the patch series, that'd be very nice. Otherwise, I'll just do it after I return. Thanks.
Quoted 54 lines · On Tue, 20 Jun 2017, 23:34 Stephano Cetola, <[email protected]>…
Hey Zeeshan,
Let me know if you need any help with this. This probably requires that you do a rebase with master and resubmit a V4.
Cheers,
StephanoQuoted 10 lines · Patchwork
== Series Details ==
Series: oeqa: fix runtime testing using systemd-boot target (rev2)
Revision: 2
URL : https://patchwork.openembedded.org/series/6953/
State : failure== Summary ==
Quoted 7 lines
Thank you for submitting this patch series to OpenEmbedded Core. This is an automated response. Several tests have been executed on the proposed series by patchtest resulting in the following failures:
* Issue Series does not apply on top of target branch
[
test_series_merge_on_head]Quoted 6 lines
Suggested fix Rebase your series on top of targeted branch
Targeted branch master (currently at1d9a88f635)If you believe any of these test results are incorrect, please reply to
the
Quoted 1 line
mailing list ([email protected]) raising your
concerns.
Quoted 1 line
Otherwise we would appreciate you correcting the issues and submitting a
new
Quoted 1 line
version of the patchset if applicable. Please ensure you add/increment
the
Quoted 1 line
version number when sending the new version (i.e. [PATCH] -> [PATCH v2]
->
Quoted 11 lines
[PATCH v3] -> ...).
---
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core