RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2107323 - Insights failed to register/connect during installation
Summary: Insights failed to register/connect during installation
Keywords:
Status: CLOSED DUPLICATE of bug 2117686
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: insights-client
Version: 9.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: rc
: ---
Assignee: Nobody
QA Contact: Nobody
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-07-14 18:24 UTC by Marek Haicman
Modified: 2022-11-09 04:51 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-10-20 12:37:20 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-127772 0 None None None 2022-07-14 18:26:37 UTC

Description Marek Haicman 2022-07-14 18:24:49 UTC
Description of problem:
I have installed RHEL 9.0 from the Boot ISO downloaded from access.redhat.com. Subscribed the system, (I have Red Hat Developer Subscription), requested to connect it right away with Red Hat Insights (because it's awesome). WiFi worked, installation proceeded until dialog popped up telling me Register to Insights failed. I had option to either end the installation or continue. I continued and installation successfully finished.

Insights were not connected.

Version-Release number of selected component (if applicable):
main: /sbin/anaconda 34.25.0.29-1.el9_0

How reproducible:
dunno, probably not always

Steps to Reproduce:
1. install system with subscription and Insights requested
2. after reboot start rhcd service `sudo systemctl start rhcd`
3. sudo rhc status

Actual results:
* got a pop-up about failure to connect to Insights
* Red Hat Insights were not connected

Expected results:
* installation proceeds without error dialogs
* rhc status shows three green dots:
** Connected to RH Subscription Management
** Connected to RH Insights
** RH connector daemon is running


Additional info:
I believe there was no option to "retry" the Insights connection attempt. That would be a possible workaround if the service is somewhat flaky. But it would definitely be better if it just works without user intervention.

Comment 5 Jan Stodola 2022-10-04 13:58:53 UTC
The --retry option indeed doesn't work for registration:

[root@localhost ~]# rpm -q insights-client
insights-client-3.1.7-8.el9.noarch
[root@localhost ~]# time insights-client --retry=10 --register
Fatal error
Traceback (most recent call last):
  File "/usr/lib/python3.9/site-packages/urllib3/connection.py", line 169, in _new_conn
    conn = connection.create_connection(
  File "/usr/lib/python3.9/site-packages/urllib3/util/connection.py", line 96, in create_connection
    raise err
  File "/usr/lib/python3.9/site-packages/urllib3/util/connection.py", line 86, in create_connection
    sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused
.
.
.

real    0m2.087s
user    0m1.917s
sys     0m0.156s
[root@localhost ~]#

From insights-client man page:
       --retry=RETRIES
              Number of times to retry uploading. 180 seconds between tries.

Comment 6 Martin Kolman 2022-10-14 14:30:02 UTC
(In reply to Jan Stodola from comment #5)
> The --retry option indeed doesn't work for registration:
> 
> [root@localhost ~]# rpm -q insights-client
> insights-client-3.1.7-8.el9.noarch
> [root@localhost ~]# time insights-client --retry=10 --register
> Fatal error
> Traceback (most recent call last):
>   File "/usr/lib/python3.9/site-packages/urllib3/connection.py", line 169,
> in _new_conn
>     conn = connection.create_connection(
>   File "/usr/lib/python3.9/site-packages/urllib3/util/connection.py", line
> 96, in create_connection
>     raise err
>   File "/usr/lib/python3.9/site-packages/urllib3/util/connection.py", line
> 86, in create_connection
>     sock.connect(sa)
> ConnectionRefusedError: [Errno 111] Connection refused
> .
> .
> .
> 
> real    0m2.087s
> user    0m1.917s
> sys     0m0.156s
> [root@localhost ~]#
> 
> From insights-client man page:
>        --retry=RETRIES
>               Number of times to retry uploading. 180 seconds between tries.

Interesting - thanks for looking into this. But I still think registration retries is something that should be addressed on the insights client side - either by default or via (another ?) command line option. 

I really don't think running insights-client registration multiple times from our end is a good solution:
- I'm sure insights client could do it much more efficiently
- it would only help during installation, while a solution in insights-client will help any time users try to register a system to insights
- what if the registration fails in some non-atomic way ? can't really tell from our end easily

So reassigning to Red Hat Insights to implement the registration retry functionality.


Note You need to log in before you can comment on or make changes to this bug.