Bug 1299925

Summary: HTTPS Error 502 - Bad Gateway(client), Unexpected response code from candlepin: 400(sam)
Product: [Retired] Subscription Asset Manager Reporter: martin <bigsow>
Component: candlepinAssignee: Katello Bug Bin <katello-bugs>
Status: CLOSED WORKSFORME QA Contact: SAM QE List <sam-qe-list>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 1.4.3   
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-01-29 14:48:01 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:

Description martin 2016-01-19 14:57:29 UTC
Description of problem:
During yum update on the client side (kvm guest) via yum, there is an error [Errno 14] HTTPS Error 502 - Bad Gateway].
This situation happens only with Red Hat Enterprise Linux with Smart Virtualization, Standard (2-socket) on kvm guest. WHen the another subscription is binded everything is ok.


Version-Release number of selected component (if applicable):
Ruby 	1.9.3
Version 1.4.3.26-1.el6sam_splice


Additional info:

On the SAM there are errors in files:

FILE: /var/log/thumbslug/error.log

Jan 19 14:16:36 [New I/O client worker #1-1] ERROR org.candlepin.thumbslug.HttpRequestHandler - Unexpected response code from candlepin: 400

FILE: /var/log/candlepin/candlepin.log

2016-01-19 14:55:57,500 [req=beb63089-5870-4dc5-a707-c27ad56488d3, org=] INFO  org.candlepin.servlet.filter.logging.LoggingFilter - Request: verb=GET, uri=/candlepin/consumers/5ecb2f6c-6682-4276-91cd-b67a4d56b3b1/release
2016-01-19 14:55:57,552 [req=beb63089-5870-4dc5-a707-c27ad56488d3, org=Aegon_PL] INFO  org.candlepin.servlet.filter.logging.LoggingFilter - Response: status=200, content-type="application/json", time=53ms
2016-01-19 14:55:58,332 [req=29d2a63a-36b5-48ed-8088-398d5c27b014, org=] INFO  org.candlepin.servlet.filter.logging.LoggingFilter - Request: verb=GET, uri=/candlepin/entitlements/8ac08dad52553d6e015259fc0d2602cc/upstream_cert
2016-01-19 14:55:58,405 [req=29d2a63a-36b5-48ed-8088-398d5c27b014, org=] INFO  org.candlepin.servlet.filter.logging.LoggingFilter - Response: status=400, content-type="text/plain", time=73ms
2016-01-19 14:55:59,326 [req=849f03d4-b923-461d-b234-7aaed70952ed, org=] INFO  org.candlepin.servlet.filter.logging.LoggingFilter - Request: verb=GET, uri=/candlepin/entitlements/8ac08dad52553d6e015259fc0d2602cc/upstream_cert
2016-01-19 14:55:59,400 [req=849f03d4-b923-461d-b234-7aaed70952ed, org=] INFO  org.candlepin.servlet.filter.logging.LoggingFilter - Response: status=400, content-type="text/plain", time=75ms

At first I thought that problem is with proxy, but how to explain that ic case of bind another license everything is ok,
mabye problem is with Response code 400, what thas it mean?

Comment 1 martin 2016-01-29 14:48:01 UTC
OK, I found solution in 
https://access.redhat.com/solutions/518613

So it is worth to say, that when you install SAM from iso:
sam-1.4-20140512-rhel-6-x86_64.iso, as I did.

It is necessary to turn on SAM reposiory:
"subscription-manager repos --enable rhel-6-server-sam-rpms",
and then execute:
"yum update"

After that, guest machine downloads packages without errors :)