Katello Client and Content Host

I’m trying to understand the concept of content hosts and how it relates to a client. This is my first time using and testing the product and I’m using Katello 3.8.

I’ve installed my server and synced my first repo and now I’m attempting to add a client. Both are running CentOS 7.5

I’ve done:

yum install -y http://fedorapeople.org/groups/katello/releases/yum/3.8/client/el7/x86_64/katello-client-repos-latest.rpm

yum -y install http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm

yum install katello-agent

Now I’m unsure what to do for my next steps. Is a content host the Katello verbage for client? Should I now follow the instructions under Content Hosts in the documentation to add my ‘client’?

Thanks.

Yup! Give that a try and let us know if that helped, left you with more questions or if you run into any errors.

Thank you very much! I’ve successfully added my content host, however, I have the following status warning:

Could not calculate errata status, ensure host is registered and the katello-host-tools package is installed

On my client…
[root@katelloclient ~]# rpm -qa |grep katello-host
katello-host-tools-fact-plugin-3.3.5-1.el7.noarch
katello-host-tools-3.3.5-1.el7.noarch

Check the installed packages for the content host within the UI, does it show katello-host-tools?

Yep, it looks like it updated the status of itself between my message and now :slight_smile:. All looks good! Thanks for your help.

Ah – spoke to soon. In the “All hosts” dashboard it still displays that error and I do see the package installed on the gui.

I tried restarting goferd and doing a katello-package-upload -f. Still no luck.

does the host have at least one repo enabled that shows up in the katello ui? If Katello does not know about any of the repos that the host has, it will show that message.

Hi Chris,

Is that the act of subscribing my content host to my repos? Host -> Content hosts -> manage subscriptions -> add?

Here’s the Repository sets section also. Sorry, learning as I go so if I provide wrong info, I apologize.

ya exactly, you should be able to add a subscription to the host. If you don’t have any products, you’ll need to create one and then create a repo under the product. Once the product is created, you can then assign the product’s subscription to the host.

Hi Chris,

I have some repos attached :frowning: and the issue is still there.

Can you check that /etc/yum.repos.d/redhat.repo on the host has repos in it? This confirms that everything is working as far as the host knowing its repos.

Hi Chris,

On my client server (CentOS 7.5) here’s the repos that we have:

[root@katelloclient ~]# ls -alh /etc/yum.repos.d/
total 56K
drwxr-xr-x. 2 root root 256 Oct 3 17:24 .
drwxr-xr-x. 88 root root 8.0K Oct 4 09:46 …
-rw-r–r-- 1 root root 1.7K Aug 13 10:34 CentOS-Base.repo
-rw-r–r-- 1 root root 1.3K Aug 13 10:34 CentOS-CR.repo
-rw-r–r-- 1 root root 649 Aug 13 10:34 CentOS-Debuginfo.repo
-rw-r–r-- 1 root root 314 Aug 13 10:34 CentOS-fasttrack.repo
-rw-r–r-- 1 root root 630 Aug 13 10:34 CentOS-Media.repo
-rw-r–r-- 1 root root 1.3K Aug 13 10:34 CentOS-Sources.repo
-rw-r–r-- 1 root root 4.7K Aug 13 10:34 CentOS-Vault.repo
-rw-r–r--. 1 root root 951 Oct 2 2017 epel.repo
-rw-r–r--. 1 root root 1.1K Oct 2 2017 epel-testing.repo
-rw-r–r-- 1 root root 491 Sep 5 07:52 katello-client.repo

Can you grab the output of “subscription-manager list --consumed”?

Sure:

[root@katelloclient ~]# subscription-manager list --consumed
±------------------------------------------+
Consumed Subscriptions
±------------------------------------------+
Subscription Name: x-centos
Provides: x-centos
SKU: 133092954328
Contract:
Account:
Serial: 8046521489164601904
Pool ID: 4028dd4066365f2401663b5258250023
Provides Management: No
Active: True
Quantity Used: 1
Service Level:
Service Type:
Status Details: Subscription is current
Subscription Type: Standard
Starts: 10/03/2018
Ends: 09/25/2048
System Type: Physical

Subscription Name: epel
Provides: epel
SKU: 508966444484
Contract:
Account:
Serial: 7743122078349391617
Pool ID: 4028dd4066365f24016636a052d1000d
Provides Management: No
Active: True
Quantity Used: 1
Service Level:
Service Type:
Status Details: Subscription is current
Subscription Type: Standard
Starts: 10/02/2018
Ends: 09/24/2048
System Type: Physical

Subscription Name: base-7.5.1804
Provides: base-7.5.1804
SKU: 685552104653
Contract:
Account:
Serial: 3433284986234075349
Pool ID: 4028dd4066365f2401663b19ee90001c
Provides Management: No
Active: True
Quantity Used: 1
Service Level:
Service Type:
Status Details: Subscription is current
Subscription Type: Standard
Starts: 10/03/2018
Ends: 09/25/2048
System Type: Physical

Using x-centos as an example, can you confirm that product has repos in Katello?

Also, can you do a “subscription-manager refresh” and “yum repolist”, then check for redhat.repo file? usually you should get a redhat.repo file even if it’s empty.

Well Chris, that fixed it!

I performed the refresh and everything worked afterwards. Thanks much!

Side question - I noticed that my local repos are still present. If I want Katello to be the end-all be-all for repo management for a client, should I empty out my /etc/yum.repos.d/ (effectively leaving redhat.repo)?

Thank you again!!

I’m glad to hear it worked!

Ya, you should be able to recreate all of the repos in Katello. Once the system is subscribed to the right products, you should be able to rm everything in /etc/yum.repos.d and “subscription-manager refresh” will recreate redhat.repo for you.

You can use "yum repolist -v " to get a before/after snapshot which can be helpful

Thanks a lot for your help, Chris!!