Bug 1694598

Summary: Scenario tests do not always log the serial console in case of ssh error
Product: Red Hat OpenStack Reporter: Attila Fazekas <afazekas>
Component: openstack-tempestAssignee: Chandan Kumar <chkumar>
Status: CLOSED ERRATA QA Contact: Martin Kopec <mkopec>
Severity: medium Docs Contact:
Priority: medium    
Version: 13.0 (Queens)CC: apevec, lhh, shdunne, slinaber, udesale
Target Milestone: z7Keywords: Triaged, ZStream
Target Release: 13.0 (Queens)   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: openstack-tempest-18.0.0-8.el7ost Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-07-10 13:06:00 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
verification output none

Description Attila Fazekas 2019-04-01 08:34:27 UTC
Description of problem:
In the Newton(osp10) ages the get_remote_client() method called
self._log_console_output()  for getting the serial console log output
in case of ssh or boot issue, but this feature missing in the osp13 version of tempest.

 
[compute-feature-enabled]
console_output = True

Version-Release number of selected component (if applicable):
openstack-tempest.noarch          1:18.0.0-6.el7ost     @rhelosp-13.0-puddle 

How reproducible:
alwyas

Steps to Reproduce:
Have a broken image and try to run scenario tests


Actual results:
Test fails with failing to ssh .


Expected results:
When an SSH failure happen, I must be able to see is the 
- root fs properly mounted
- got ip over dhcp
- metadata received (ssh pub key)

In case of a well bahaving cloud image,
just the serial console log can tell these.

Comment 1 Martin Kopec 2019-04-15 16:49:27 UTC
Last time _log_console_output was called from get_remote_client method was in openstack-tempest-16.*, since then that part of the code is omitted and I don't understand why. I'm gonna look into it.

Comment 2 Martin Kopec 2019-04-16 12:31:40 UTC
The mentioned code was removed by this review:
https://review.openstack.org/#/c/467905/

Comment 12 Martin Kopec 2019-06-17 09:17:13 UTC
Created attachment 1581372 [details]
verification output

The openstack-tempest-18.0.0-8.el7ost package contains the fix of this issue. The fixed in version package is already available via the latest symlink in RHOS-13 repository.

I verified it by running tempest.scenario.test_volume_boot_pattern.TestVolumeBootPattern.test_volume_boot_pattern test and using a wrong image_ssh_user in order to get a failing console output.

Comment 15 errata-xmlrpc 2019-07-10 13:06:00 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:1739