Project

General

Profile

Actions

Bug #16698

open

[Katello 3.1] Client subscription-manager out of sync with server repos

Added by Prasun Gera over 7 years ago. Updated over 5 years ago.

Status:
Needs design
Priority:
Normal
Category:
-
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Copying text from https://groups.google.com/forum/#!topic/foreman-users/Shzh4CAkG8M

I am using Katello 3.1 on a RHEL 7 system to manage RHEL 7 clients. I disabled a RH repository from the main RH subscriptions. However, the client still thinks that it is subscribed to that repo, and it eventually gives a 404 not found error on yum commands. Calling subscription-manger refresh or un-regestering and re-registering the client didn't help. This happened once earlier too for a different repo, but enabling and disabling the repo again in Katello brought the client in sync. For this particular repo though, it doesn't help. I saw the following error message in server's /var/log/messages for the repo in question

```
Sep 19 12:50:39 example pulp: pulp.server.event.http:INFO: (32572-85248) {"call_report": {"exception": null, "task_type": "pulp.server.managers.repo.sync.sync", "_href": "/pulp/api/v2/tasks/198fc8b0-fc25-41ad-841c-d65b97241385/", "task_id": "198fc8b0-fc25-41ad-841c-d65b97241385", "tags": ["pulp:repository:Org-Red_Hat_Enterprise_Linux_Server-Red_Hat_Satellite_Tools_6_2_for_RHEL_7_Server_RPMs_x86_64", "pulp:action:sync"], "finish_time": null, "_ns": "task_status", "start_time": "2016-09-19T16:50:23Z", "traceback": null, "spawned_tasks": [], "progress_report": {"yum_importer": {"content": {"items_total": 56, "state": "FINISHED", "error_details": [], "details": {"rpm_total": 56, "rpm_done": 56, "drpm_total": 0, "drpm_done": 0}, "size_total": 7035408, "size_left": 0, "items_left": 0}, "comps": {"state": "FINISHED"}, "purge_duplicates": {"state": "FINISHED"}, "distribution": {"items_total": 0, "state": "FINISHED", "error_details": [], "items_left": 0}, "errata": {"state": "FINISHED"}, "metadata": {"state": "FINISHED"}}}, "state": "running", "worker_name": "", "result": null, "error": null, "_id": {"$oid": "57e015984d0e0969d1034ff6"}, "id": "57e015984d0e0969d1034ff6"}, "event_type": "repo.sync.finish", "payload": {"importer_id": "yum_importer", "exception": null, "repo_id": "Org-Red_Hat_Enterprise_Linux_Server-Red_Hat_Satellite_Tools_6_2_for_RHEL_7_Server_RPMs_x86_64", "traceback": null, "started": "2016-09-19T16:50:23Z", "_ns": "repo_sync_results", "completed": "2016-09-19T16:50:39Z", "importer_type_id": "yum_importer", "error_message": null, "summary": {"content": {"state": "FINISHED"}, "comps": {"state": "FINISHED"}, "purge_duplicates": {"state": "FINISHED"}, "distribution": {"state": "FINISHED"}, "errata": {"state": "FINISHED"}, "metadata": {"state": "FINISHED"}}, "added_count": 63, "result": "success", "updated_count": 0, "details": {"content": {"size_total": 7035408, "items_left": 0, "items_total": 56, "state": "FINISHED", "size_left": 0, "details": {"rpm_total": 56, "rpm_
Sep 19 12:50:39 example pulp: pulp.server.event.http:INFO: (32572-85248) done": 56, "drpm_total": 0, "drpm_done": 0}, "error_details": []}, "comps": {"state": "FINISHED"}, "purge_duplicates": {"state": "FINISHED"}, "distribution": {"items_total": 0, "state": "FINISHED", "error_details": [], "items_left": 0}, "errata": {"state": "FINISHED"}, "metadata": {"state": "FINISHED"}}, "id": "57e0175f589b907f3cf535ee", "removed_count": 0}}
```


Related issues 1 (0 open1 closed)

Has duplicate Katello - Bug #17391: [Katello 3.1] Client subscription-manager out of sync with server reposDuplicateJustin Sherrill09/26/2016Actions
Actions #1

Updated by Justin Sherrill over 7 years ago

  • Category set to 78
  • Status changed from New to Need more information
  • Assignee set to Justin Sherrill

I believe this was resolved by http://projects.theforeman.org/issues/15482

Would you be able to re-test on Katello 3.2 RC1

Actions #2

Updated by Prasun Gera over 7 years ago

Justin Sherrill wrote:

I believe this was resolved by http://projects.theforeman.org/issues/15482

Would you be able to re-test on Katello 3.2 RC1

Thanks. I'll give it a shot on 3.2 RC1 and report back.

Actions #3

Updated by Prasun Gera over 7 years ago

Would you be able to re-test on Katello 3.2 RC1

I think it's fixed on 3.2. Right after upgrading to 3.2, the client was still listing the channel in subscription-manager repos --list. However, I enabled and disabled it on the server, and now the client doesn't show it any more.

Actions #4

Updated by Prasun Gera over 7 years ago

I think it's fixed on 3.2.

I'm still seeing issues with 3.2 server. I again deleted a repository from a product, and now the client gives 404 errors, and the repo is still listed under subscription-manager repos --list

Actions #5

Updated by Prasun Gera over 7 years ago

FYI, still see this on Katello 3.2 RC2. Any help with debugging this ? Pretty easy to reproduce for me. Steps: Add a repo to a product and enable it for a client; call yum repolist on the client; delete the repo; call yum repolist again on the client.

Actions #6

Updated by Justin Sherrill over 7 years ago

Hi Prasun,

I'm still not able to reproduce this. One thing to note is that you have to run 'subscription-manager refresh' after the repo is disabled for the client to pick that up. This happens automatically ever 4 hours via the rhsmcertd command.

If you run subscription-manager refresh before the yum repolist command, does that resolve the issue?

-Justin

Actions #7

Updated by Prasun Gera over 7 years ago

Justin Sherrill wrote:

Hi Prasun,

I'm still not able to reproduce this. One thing to note is that you have to run 'subscription-manager refresh' after the repo is disabled for the client to pick that up. This happens automatically ever 4 hours via the rhsmcertd command.

If you run subscription-manager refresh before the yum repolist command, does that resolve the issue?

-Justin

Hi Justin,
No, running subscription-manger refresh doesn't resolve it. I'm happy to post logs if there is any way to provide additional information. Is there a way to tie the client error back to some candlepin logs on the server ?

Actions #8

Updated by Justin Sherrill over 7 years ago

Prasun,

Were these Red Hat repositories? or Custom Repositories? Can you give an example of one such repository?

There are some cases regarding Release version where this will occur, such as if you enable RHEL 7Server RPMs, and RHEL 7.2 RPMS. If a client has his release version set to 7.2, he will get content from the 7.2 repo. If you disable the 7.2 repo but leave the 7Server repo enabled, subscription manager has no way to differentiate and will continue to populate the redhat.repo file with a repo that does not exist. Does that sound like what is happening (Note that none of this applies to custom repos)?

Actions #9

Updated by Prasun Gera over 7 years ago

Justin Sherrill wrote:

Prasun,

Were these Red Hat repositories? or Custom Repositories? Can you give an example of one such repository?

I've seen this with both RHEL repos as well as custom repos. I'm currently seeing this issue with a custom repo right now. Incidentally, I'm seeing this for the katello client repo. I enabled the katello 3.2 RC client repo since the server was updated to 3.2 RC. However, since the client packages aren't signed by the gpg key until GA, the clients were getting errors on yum update. So I tried to remove the client repo on the server. The client would still try to fetch from the repo (even after a subscription-manager refresh), and error out. Currently, the only fix is to disable the repo on the client manually with subscription-manager repos --disable.

Output of
sudo subscription-manager repos --list | grep Katello
Repo ID: Org_Katello_Client_Katello_Client_3_2_Sources
Repo Name: Katello Client 3.2 Sources
Repo URL: https://example.com/pulp/repos/Org/Library/custom/Katello_Client/Katello_Client_3_2_Sources
Repo ID: Org_Katello_Client_Katello_Client_3_1_Source
Repo Name: Katello Client 3.1 Source
Repo URL: https://example.com/pulp/repos/Org/Library/custom/Katello_Client/Katello_Client_3_1_Source
Repo ID: Org_Katello_Client_Katello_Client_3_1
Repo Name: Katello Client 3.1
Repo URL: https://example.com/pulp/repos/Org/Library/custom/Katello_Client/Katello_Client_3_1
Repo ID: Org_Katello_Client_Katello_Client_3_2
Repo Name: Katello Client 3.2
Repo URL: https://example.com/pulp/repos/Org/Library/custom/Katello_Client/Katello_Client_3_2

3.2 client repo has been deleted from the server, but subscription-manager still reports it.

Actions #10

Updated by Prasun Gera over 7 years ago

  • Copied to Bug #17391: [Katello 3.1] Client subscription-manager out of sync with server repos added
Actions #11

Updated by Eric Helms over 7 years ago

  • Copied to deleted (Bug #17391: [Katello 3.1] Client subscription-manager out of sync with server repos)
Actions #12

Updated by Eric Helms over 7 years ago

  • Has duplicate Bug #17391: [Katello 3.1] Client subscription-manager out of sync with server repos added
Actions #13

Updated by Eric Helms about 7 years ago

  • Status changed from Need more information to Needs design
Actions #14

Updated by John Mitsch almost 7 years ago

  • translation missing: en.field_release set to 114
Actions

Also available in: Atom PDF