Skip to content

Instantly share code, notes, and snippets.

@mccun934
Forked from jlsherrill/debugging_errata.md
Created November 8, 2017 14:38
Show Gist options
  • Save mccun934/5060a79a4e9e8a36ccada48abc1eb8b1 to your computer and use it in GitHub Desktop.
Save mccun934/5060a79a4e9e8a36ccada48abc1eb8b1 to your computer and use it in GitHub Desktop.
debugging errata issues

Run all of these in 'foreman-rake console'

Check the event queue:

Katello::Event.count

Check 'bound repositories' known to katello

Host.find_by(:name => "dev.example.com").content_facet.bound_repositories.pluck(:name)

Check installed package profile known to katello:

Host.find_by(:name => "dev.example.com").installed_packages.count

Check 'bound repositories' known to pulp:

Katello::Pulp::Consumer.new(Host.find_by(:name => "dev.example.com").content_facet.uuid).bound_yum_repositories.count

Check errata ids known to pulp:

Katello::Pulp::Consumer.new(Host.find_by(:name => "dev.example.com").content_facet.uuid).applicable_errata_ids.count

Check errata ids known to katello:

Host.find_by(:name => "dev.example.com").content_facet.applicable_erratum_ids
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment