Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1357930 - QCI 1.2: At end of RHEV deployment received error "getaddrinfo: Name or service not known" without listing the name
Summary: QCI 1.2: At end of RHEV deployment received error "getaddrinfo: Name or servi...
Keywords:
Status: NEW
Alias: None
Product: Red Hat Quickstart Cloud Installer
Classification: Red Hat
Component: Installation - RHEV
Version: 1.0
Hardware: Unspecified
OS: Linux
unspecified
low
Target Milestone: ---
: ---
Assignee: John Matthews
QA Contact: Dave Johnson
Dan Macpherson
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-07-19 15:33 UTC by James Olin Oden
Modified: 2016-09-23 18:50 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:


Attachments (Terms of Use)

Description James Olin Oden 2016-07-19 15:33:38 UTC
Description of problem:
This happened at the tail end of a RHEV deployment.   The resolv.conf was 
not correct such that none of the DNS entries for the RHEV hosts could be resolved.   The getaddrinfo error pointed in the right right direction, but having the extra bit of information concerning which host it could not resolve would have been helpful.

Version-Release number of selected component (if applicable):
QCI-1.2-RHEL-7-20160713.t.1

How reproducible:


Steps to Reproduce:
1. Mess up the resolve.conf
2. Start a RHEV deployment

Actual results:
Towards the end of the deployment you will get an error concerning a
getaddrinfo() failure that does not contain the name trying to be resolved.

Expected results:
The same error but with the name trying to be resolved.

Comment 1 John Matthews 2016-07-19 15:44:06 UTC
This is the area of code James is referring to:

https://github.com/fusor/fusor/blob/master/server/app/lib/actions/fusor/deployment/rhev/create_cr.rb#L41

            deployment = ::Fusor::Deployment.find(input[:deployment_id])
            rhevm = ::Host.find(deployment.rhev_engine_host_id).name
            rhev = { "name" => "#{deployment.label}-RHEV",
                     "location_ids" => ["", Location.where(:name => "Default Location").first.id],
                     "url" => "https://#{rhevm}/api",
                     "provider" => "Foreman::Model::Ovirt", "user" => 'admin@internal',
                     "password" => deployment.rhev_root_password,
                     "organization_ids" => [deployment.organization_id],
                     "public_key" => "#{Net::HTTP.get(URI.parse("http://#{rhevm}/ca.crt"))}" }



Specifically this line:
 "public_key" => "#{Net::HTTP.get(URI.parse("http://#{rhevm}/ca.crt"))}" }


We can break this out and do the fetch separately, if it fails rescue the exception and raise a better error message.

Note...the rhev4 beta work is likely to change how we fetch the ca cert, I think the path will be different.


Note You need to log in before you can comment on or make changes to this bug.