Katello 3.16.1-1.el7 subscription-manager doesn't create rhsm repos for ubuntu

Problem:
root@xxxxxxxxxxxx:/# subscription-manager refresh
All local data refreshed
root@xxxxxxxxxxxx:/# subscription-manager repos
This system has no repositories available through subscriptions.
root@xxxxxxxxxxxx:/# subscription-manager list --consumed
±------------------------------------------+
Consumed Subscriptions
±------------------------------------------+
Subscription Name: ub18_repos
Provides: ub18_repos
SKU: 117303501592
Contract:
Account:
Serial: 1513275188278959336
Pool ID: 8a789ece744cf61501744d0998d50010
Provides Management: No
Active: True
Quantity Used: 1
Service Type:
Roles:
Service Level:
Usage:
Add-ons:
Status Details: Subscription is current
Subscription Type: Standard
Starts: 02/09/20
Ends: 01/12/49
Entitlement Type: Physical

Expected outcome:

/etc/apt/sources.list.d/rhsm.sources has content from its subscription

Foreman and Proxy versions:
foreman-2.1.4-1.el7.noarch
foreman-proxy-2.1.4-1.el7.noarch
katello-3.16.1-1.el7.noarch

Foreman and Proxy plugin versions:

Distribution and version:
centos 7.8.2003
Other relevant data:

subscription-manager repos --list (if it not showing then try to un register and register again)

I hope you add repos to content view and promote that content to prod or dev and then add that view to activation key.

subscription-manager unregister

subscription-manager register with activation key (as mention in Foreman UI when you create key)

Try to register again with Activation key and share result

root@xxxxxxxxxxxxx:/# subscription-manager unregister
Unregistering from: bss01.orch.vocus.net:443/rhsm
System has been unregistered.
root@xxxxxxxxxxxxx:/# subscription-manager register --org=“Default_Organization” --activationkey=‘ub18-key’
‘NoneType’ object is not callable
root@xxxxxxxxxxxx:/# subscription-manager refresh
All local data refreshed
root@syd01ddev06:/# subscription-manager repos
This system has no repositories available through subscriptions.

go to foreman and type

hammer repository list --organization “Default_Organization”

it showing any repos ?

well that’s interesting

hammer repository list --organization “Default_Organization”
Error: organization not found.

hammer organization list
—|-------|-------|-------------|---------------------

ID TITLE NAME DESCRIPTION LABEL
1 VOCUS VOCUS Default_Organization
------- ------- ------------- ---------------------

I think there may be some parts that use LABEL as register org must be LABEL or it won’t register.

It works for Centos 7 creating repos

hammer repository list --organization “VOCUS”
----|-------------------------------|------------|--------------|-------------------------------------------------------------------------------

ID NAME PRODUCT CONTENT TYPE URL
45 alpine docker docker https://registry-1.docker.io/
67 appstream_x86_64 el8_repos yum http://mirror.ventraip.net.au/CentOS/8/AppStream/x86_64/os
66 base_x86_64 el8_repos yum http://mirror.ventraip.net.au/CentOS/8/BaseOS/x86_64/os/
7 base_x86_64 el7_repos yum http://mirror.ventraip.net.au/CentOS/7/os/x86_64/
1 base_x86_64 el6_repos yum http://mirror.ventraip.net.au/CentOS/6/os/x86_64/
65 bionic ub18_repos deb http://mirror.waia.asn.au/ubuntu
32 bionic-security ub18_repos deb http://mirror.waia.asn.au/ubuntu
31 bionic-updates ub18_repos deb http://mirror.waia.asn.au/ubuntu
55 calico/cni docker docker https://registry-1.docker.io/
54 calico/ctl docker docker https://registry-1.docker.io/
59 calico/k8s-policy-agent docker docker https://registry-1.docker.io/
51 calico/kube-controllers docker docker https://registry-1.docker.io/
58 calico/kube-policy-controller docker docker https://registry-1.docker.io/
50 calico/node docker docker https://registry-1.docker.io/
53 calico/pod2daemon-flexvol docker docker https://registry-1.docker.io/
57 calico/ttfp docker docker https://registry-1.docker.io/
52 calico/typha docker docker https://registry-1.docker.io/
56 calico/upgrade docker docker https://registry-1.docker.io/
15 docker_ce_stable_7_x86_64 el7_repos yum https://download.docker.com/linux/centos/7/x86_64/stable
43 docker_ce_stable_x86_64 ub20_repos deb https://download.docker.com/linux/ubuntu/
37 docker_ce_stable_x86_64 ub18_repos deb https://download.docker.com/linux/ubuntu/
29 docker_ce_stable_x86_64 ub16_repos deb https://download.docker.com/linux/ubuntu/
49 ebiwd/alpine-ssh docker docker https://registry-1.docker.io/
73 elastic_6_x86_64 el8_repos yum h

etc etc

Please make a key with organization and add content view and repos and register properly with VOCUS

example

subscription-manager register --org=“Abc_Airo” --activationkey=“Airo_Centos7_key”

That won’t work as the register org is using the label not the name. centos 7 subscription is working as expected - it is only Ubuntu (debian) failing

subscription-manager register --org=“Default_Organization” --activationkey=‘test.key’
‘NoneType’ object is not callable
root@xxxxxxxxxxxx:/# subscription-manager refresh
All local data refreshed
root@xxxxxxxxxxxx:/# subscription-manager repos
This system has no repositories available through subscriptions.


click on details and share

show subscriptions and details

I am going to sleep , I will check tomorrow but you need to run everything under VOCUS not default as all repos are there.

you can change organisation from top menu and what’s inside VOCUS.

thanks I’ll keep going for a while and the orgainisation is set as VOCUS

I’m having the same issue.
On the client, I installed the new ATIX subscription-manager on a ubuntu-18.04.
I updated to the latest foreman 2.1.4

# subscription-manager register --org="" --activationkey=“AK_Ubuntu_18.04_ACC”
The system has been registered with ID: 3abb6648-1d04-40f8-b108-77c9e2b6e806
The registered system name is: ubuntu-t03
No products installed.

# subscription-manager refresh
1 local certificate has been deleted.
All local data refreshed
# subscription-manager repos --list
This system has no repositories available through subscriptions.

It does register the server in foreman, but no products are assigned.

Can you try to run Run auto-attach on <foreman_fqdn>/content_hosts/<host_id>/subscriptions?

1 Like

nope, same result

show subscriptions and details full page