Bug 876677
Summary: | Missing resource error in pulp.log if you deletes the consumer without re-registering it | ||
---|---|---|---|
Product: | [Retired] Pulp | Reporter: | Preethi Thomas <pthomas> |
Component: | consumers | Assignee: | pulp-bugs |
Status: | CLOSED UPSTREAM | QA Contact: | Preethi Thomas <pthomas> |
Severity: | low | Docs Contact: | |
Priority: | low | ||
Version: | Master | CC: | jason.dobies, rbarlow, skarmark |
Target Milestone: | --- | Keywords: | Triaged |
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | 876234 | Environment: | |
Last Closed: | 2015-02-28 21:51:34 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: | |||
Bug Depends On: | 876234 | ||
Bug Blocks: |
Description
Preethi Thomas
2012-11-14 17:20:38 UTC
Jeff - I'd like to know what's happening here. This is weird. It's a pretty annoying problem if a consumer disappearing (which she kinda simulated here, but I suspect the agent is still running so it's not exactly like the consumer box up and died) and the server continues to log errors like this. I'm aligning to 2.0 Beta to investigate. Ping me when you know what's happening. *** Bug 876234 has been marked as a duplicate of this bug. *** This bug describes a condition whereby the consumer is unregistered from pulp but a valid consumer certifiate still exists on the consumer. The agent is still installed and running and because valid consumer certificates still exist on the box, it continues to send profile updates as scheduled. The agent detects registration/unregistration based on the existance of a valid consumer certificate. Under normal circumstances, the certificate is deleted locally when the consumer is unregistered using pulp-consumer. If the consumer is unregistered using pulp-admin, notification of the unregistration is sent to the agent which deletes the certificate. There are a few abnormal scenerios that I can think of that can produce this condition. The condition being that the consumer not longer exists in the server but the agent thinks it's still registered. 1. The server is reinstalled or DB is manually cleared. 2. Consumer is unregistered using pulp-admin and connectivity between the server and qpid broker cannot be established. Short term, this causes a condition where the agent continues to report package profiles but the consumer no longer exits. Once the connection to the broken is established, the condition is resolved. However, if httpd is restarted before the connection is established, the message to the agent will never be sent and the condition will never be resolved. 3. Consumer is unregistered using pulp-admin and connectivity between the agent and qpid broker cannot be established. Short term, this causes a condition where the agent continues to report package profiles but the consumer no longer exits. Once the connection to the broken is established, the condition is resolved. 4. A deleted consumer certificate reappears as the result of a restored backup on the consumer. 5. User manually installs consumer certificate in some other way. Since interruptions in the communication path between the server and consumer are unavoidable, we need to assume that this condition can exist for at least short durations. Here are some possible solutions: 1. Don't raise ResourceMissing when reporting profiles. Bad idea. 2. Have agent query to see if consumer exists before sending the profile. This approach subject to race conditions so not very solid. 3. Implement CRLs on the server. When consumer is unregistered, revoke the consumer certificate and REST calls to report package profile are rejected at the front door and don't show up as ResourceMissing in the logs. Thinking of this solution raises the issue of unregistered consumers continuing to consume content from protected repos when this condition exists. 4. TBD Given this is an exceptional case she ran into, I'm punting this off of 2.0. There's not an easy solution so I'd rather take some time to step back and handle these sorts of consumer incongruities as its own story. Moved to https://pulp.plan.io/issues/340 |