Bug 735793
Summary: | virt-who got exception when connecting to candlepin (stage env) | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | Keqin Hong <khong> | ||||
Component: | virt-who | Assignee: | Radek Novacek <rnovacek> | ||||
Status: | CLOSED ERRATA | QA Contact: | |||||
Severity: | high | Docs Contact: | |||||
Priority: | high | ||||||
Version: | 6.2 | CC: | bkearney, jomara, ndai, ovasik, rvokal, syeghiay | ||||
Target Milestone: | beta | Keywords: | TestBlocker | ||||
Target Release: | 6.2 | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | virt-who-0.3-2.el6 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2011-12-06 18:56:27 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Bug Depends On: | |||||||
Bug Blocks: | 682238 | ||||||
Attachments: |
|
Description
Keqin Hong
2011-09-05 12:23:43 UTC
Are you sure that your rhsm configuration is correct? Do you have your system registered? Can you show your rhsm configuration? Maybe change prefix=/subscription to prefix=/candlepin in /etc/rhsm/rhsm.conf can help. Created attachment 521498 [details]
rhsm.conf
(In reply to comment #2) > Are you sure that your rhsm configuration is correct? Do you have your system > registered? Can you show your rhsm configuration? Maybe change > prefix=/subscription to prefix=/candlepin in /etc/rhsm/rhsm.conf can help. It should be correct. For stage env, we use /subscription instead of /candlepin. I can register/subscribe using subscription-manager. rhsm.conf is attached https://bugzilla.redhat.com/attachment.cgi?id=521498. GET /candlepin/status/ {'content': '<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">\n<html><head>\n<title>404 Not Found</title>\n</head><body>\n<h1>Not Found</h1>\n<p>The requested URL /candlepin/status/ was not found on this server.</p>\n<hr>\n<address>Apache Server at subscription.rhn.stage.redhat.com Port 443</address>\n</body></html>\n', 'status': 404} My system is registered. Otherwise, I couldn't use virt-who. subscription-manger has exception handling which catches the exception when getting /subscription/status/. That's why I could use subscription-manager to register/subscribe. > subscription-manger has exception handling which catches the exception when
getting /subscription/status/
Where do you get this information? I can't find it in subscription-manager code.
(In reply to comment #7) > > subscription-manger has exception handling which catches the exception when > getting /subscription/status/ > > Where do you get this information? I can't find it in subscription-manager > code. You are right, it has no exception handling for GET /subscription/status/ (the ping cmd). Sorry, I meant to say it had for GET /subscription/. #connection.py def _load_supported_resources(self): """ Load the list of supported resources by doing a GET on the root of the web application we're configured to use. Need to handle exceptions here because sometimes UEPConnections are created in a state where they can't actually be used. (they get replaced later) If something goes wrong making this request, just leave the list of supported resources empty. """ self.resources = {} try: resources_list = self.conn.request_get("/") for r in resources_list: self.resources[r['rel']] = r['href'] log.debug("Server supports the following resources:") log.debug(self.resources) # Handle situations where the UEPConnection isn't actually usable: except Exception, e: log.warn("Error fetching supported resources, this " "UEPConnection is likely not usable:") log.exception(e) Since the /status/ might not be implemented sometimes, I'll put the ping command to exception block to avoid virt-who to fail. Fixed in virt-who-0.3-2.el6. Verified on virt-who-0.3-2.el6. PASS Steps: 1. enable virt-who debug option in /etc/sysconfig/ VIRTWHO_DEBUG=1 2. # service virt-who restart virt-who exited normally. 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. http://rhn.redhat.com/errata/RHEA-2011-1757.html |