Bug 1979292

Summary: Do not attempt to authenticate using rh_cloud_token when token is not set
Product: Red Hat Satellite Reporter: Stephen Wadeley <swadeley>
Component: RH Cloud - InsightsAssignee: Shimon Shtein <sshtein>
Status: CLOSED ERRATA QA Contact: Stephen Wadeley <swadeley>
Severity: high Docs Contact:
Priority: high    
Version: 6.9.0CC: ahumbe, aruzicka, ktordeur, sshtein, zhunting
Target Milestone: 6.10.0Keywords: Triaged, UserExperience
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 4.0.26 Doc Type: Known Issue
Doc Text:
Cause: Red Hat Insights is enabled by default and an inventory upload will be attempted before the user has configured the authentication token. Consequence: "Inventory scheduled sync" will be listed as a paused task, connection errors will be logged when registering new hosts when using the global registration method with Red Hat Insights (which is enabled by default on the Advanced tab). Workaround (if any): Navigate to Configure > Insights and follow the instructions to configure a Red Hat Cloud token. Alternatively, Navigate to Configure > Inventory Upload and disable Automatic inventory upload If the customer does not intend to have the toke set up, the option to disable automatic uploads is presented on manifest import page too.
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-11-16 14:12:23 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Stephen Wadeley 2021-07-05 13:51:56 UTC
Description of problem:

On a new system:

Monitor > Tasks shows:
Inventory scheduled sync	paused	error

~]# satellite-installer --help | grep -i cloud
    --[no-]enable-foreman-plugin-rh-cloud Enable 'foreman_plugin_rh_cloud' puppet module (default: true)

its enabled by default, so its bad user experience to have this error

Version-Release number of selected component (if applicable):
6.9
6.10

How reproducible:
Every time

Steps to Reproduce:
1. Install a Satellite
2. Check tasks for "Inventory scheduled sync"


Actual results:
Inventory scheduled sync	paused	error

Expected results:
System should not attempt to authenticate using rh_cloud_token when token is not set.
A nicer error could be given to warn no token is set.
Perhaps its best to prevent enabling tasks such as Inventory upload until token is set.



Additional info:
Bug 1976904 - Inventory scheduled sync fails on new system

Comment 2 Kenny Tordeurs 2021-08-14 09:46:32 UTC
This causes foreman-maintain with a FAILED step so it's a really bad experience.

~~~
--------------------------------------------------------------------------------
Rerunning the check after fix procedure
Check for paused tasks:                                               [FAIL]
There are currently 1 paused tasks in the system
--------------------------------------------------------------------------------
~~~

I'd consider moving this to a bug over an RFE.

Comment 11 errata-xmlrpc 2021-11-16 14:12:23 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: Satellite 6.10 Release), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2021:4702

Comment 12 Red Hat Bugzilla 2023-09-15 01:10:59 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 500 days