Bug 1315820 - Provide separate puppet module for Insights to use on Capsules
Provide separate puppet module for Insights to use on Capsules
Status: CLOSED ERRATA
Product: Red Hat Satellite 6
Classification: Red Hat
Component: rubygem-foreman-redhat_access (Show other bugs)
Unspecified
Unspecified Unspecified
medium Severity high (vote)
: 6.2.7
: 6.X
Assigned To: Lindani Phiri
jcallaha
: Triaged
: 1332672 (view as bug list)
Depends On:
Blocks: 1315844 1405511
  Show dependency treegraph
 
Reported: 2016-03-08 12:03 EST by Lindani Phiri
Modified: 2017-12-14 09:30 EST (History)
14 users (show)

See Also:
Fixed In Version: redhat-access-insights-puppet-0.0.8-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1315844 1405511 (view as bug list)
Environment:
Last Closed: 2017-01-26 05:48:21 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
verification screenshot (72.14 KB, image/png)
2017-01-20 18:03 EST, jcallaha
no flags Details

  None (edit)
Description Lindani Phiri 2016-03-08 12:03:23 EST
Customer SFDC case number 01583479

Clients registered to Capsules fail to apply the "access_insights" puppet class used to register to Insights :

puppet agent -t
Info: Retrieving plugin
Info: Loading facts in /var/lib/puppet/lib/facter/pe_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/package_provider.rb
Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb
Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb
Info: Loading facts in /var/lib/puppet/lib/facter/ssh_server_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/service_provider.rb
Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb
Info: Loading facts in /var/lib/puppet/lib/facter/ssh_client_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/rh_certificates.rb
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not find class access_insights_client for 

This is because the Insights puppet module is bundled with the Red Hat Access plugin and is installed on the main Satellite server only, and does not exist in the Capsule environment.

A separate puppet module already exists [1,2] but was never officially released.
Since the Red Hat Insights Plugin is installed by default on the main server,
it would be ideal to have the puppet rpm installed on capsule by default.


[1]http://pkgs.devel.redhat.com/cgit/rpms/redhat-access-insights-puppet
Comment 2 Daniele Palumbo 2016-04-19 07:30:19 EDT
Hi,

There is another related problem to availaibility of insights in the capsules.
The environment is not switched, as it is done instead in the clients attached to the capsule.

Taken from: 
https://groups.google.com/forum/#!topic/foreman-users/Oc9O3TqRX5E 

[root@capsule ~]# puppet master --configprint modulepath --environment production
[root@capsule ~]# puppet master --configprint modulepath --environment KT_V_TS_QA_RHEL7_Rolling_7 /etc/puppet/environments/KT_V_TS_QA_RHEL7_Rolling_7/modules:/etc/puppet/environments/common:/etc/puppet/modules:/usr/share/puppet/modules 
[root@capsule ~]# 

The modulepath is empty, and that is imo the problem. 

Is maybe the problem linked to: http://projects.theforeman.org/issues/7277 Even if the version of puppet seems not affected:
[root@capsule ~]# rpm -q puppet puppet-3.6.2-4.el7sat.noarch 
[root@capsule ~]#
Comment 3 Lindani Phiri 2016-05-04 15:15:23 EDT
*** Bug 1332672 has been marked as a duplicate of this bug. ***
Comment 4 Lindani Phiri 2016-11-11 08:52:49 EST
Builds for RPM are in brew:


https://brewweb.engineering.redhat.com/brew/packageinfo?packageID=53018
Comment 8 jcallaha 2017-01-20 18:01:55 EST
Verified in Satellite 6.2.7 Snap 2. 
The package redhat-access-insights-puppet is now provided by the Satellite Capsule repo. Below you can see it installed on the capsule as well as a successful registration to insights from a client that is registered to the capsule. Also see the attached screenshot of the client successfully showing up in the UI.

Capsule
-------
-bash-4.2# yum install redhat-access-insights-puppet
Loaded plugins: product-id, search-disabled-repos, subscription-manager
Default_Organization_627_rhel7_capsule                                                                                                                                 | 2.1 kB  00:00:00     
rhel-7-server-optional-rpms                                                                                                                                            | 2.0 kB  00:00:00     
rhel-7-server-rh-common-rpms                                                                                                                                           | 2.1 kB  00:00:00     
rhel-7-server-rpms                                                                                                                                                     | 2.0 kB  00:00:00     
Resolving Dependencies
--> Running transaction check
---> Package redhat-access-insights-puppet.noarch 0:0.0.8-1.el7sat will be installed
--> Finished Dependency Resolution

Dependencies Resolved

==============================================================================================================================================================================================
 Package                                              Arch                          Version                               Repository                                                     Size
==============================================================================================================================================================================================
Installing:
 redhat-access-insights-puppet                        noarch                        0.0.8-1.el7sat                        Default_Organization_627_rhel7_capsule                        5.9 k

Transaction Summary
==============================================================================================================================================================================================
Install  1 Package

Total download size: 5.9 k
Installed size: 7.9 k
Is this ok [y/d/N]: y
Downloading packages:
redhat-access-insights-puppet-0.0.8-1.el7sat.noarch.rpm                                                                                                                | 5.9 kB  00:00:02     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : redhat-access-insights-puppet-0.0.8-1.el7sat.noarch                                                                                                                        1/1 
  Verifying  : redhat-access-insights-puppet-0.0.8-1.el7sat.noarch                                                                                                                        1/1 

Installed:
  redhat-access-insights-puppet.noarch 0:0.0.8-1.el7sat                                                                                                                                       

Complete!



Client registered to capsule
----------------------------
[root@cloud-qe-20 ~]# redhat-access-insights --register
Successfully registered cloud-qe-20.idmqe.lab.eng.bos.redhat.com
Automatic daily scheduling for Insights has been enabled.
Starting to collect Insights data
Uploading Insights data, this may take a few minutes
Upload completed successfully!

[root@cloud-qe-20 ~]# cat /etc/rhsm/rhsm.conf | grep ytt
hostname = yttrium.idmqe.lab.eng.bos.redhat.com
baseurl= https://yttrium.idmqe.lab.eng.bos.redhat.com/pulp/repos
Comment 9 jcallaha 2017-01-20 18:03 EST
Created attachment 1243029 [details]
verification screenshot
Comment 11 errata-xmlrpc 2017-01-26 05:48:21 EST
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, 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/RHBA-2017:0197

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