Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1138939 - rhnsd should start correctly and then not do anything if the system is not registered to Satellite. It should not fail to start.
rhnsd should start correctly and then not do anything if the system is not re...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: rhnsd (Show other bugs)
7.0
All Linux
low Severity low
: rc
: ---
Assigned To: Jan Dobes
Jan Hutař
: Reopened
: 1189833 (view as bug list)
Depends On:
Blocks: 1118366 1133060
  Show dependency treegraph
 
Reported: 2014-09-06 10:36 EDT by John Fulton
Modified: 2016-02-12 10:15 EST (History)
11 users (show)

See Also:
Fixed In Version: rhnsd-5.0.13-5.el7
Doc Type: Bug Fix
Doc Text:
Previously, if the rhnsd service was unable to find a system ID file, the rhnsd.init script was exiting with an error. This update modifies rhnsd.init, which now exits gracefully.
Story Points: ---
Clone Of:
: 1139408 (view as bug list)
Environment:
Last Closed: 2015-11-19 07:13:36 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)
sosreport (6.96 MB, application/x-xz)
2015-04-15 10:11 EDT, IBM Bug Proxy
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
IBM Linux Technology Center 121374 None None None Never
Red Hat Product Errata RHBA-2015:2380 normal SHIPPED_LIVE rhnsd bug fix update 2015-11-19 05:50:19 EST

  None (edit)
Description John Fulton 2014-09-06 10:36:53 EDT
Description of problem:

rhnsd, a program for querying the Red Hat Network, is enabled by default in a minimal install of RHEL7. Instances of this image may have a short life so assuming they will be registered on each boot may not make sense. 

On a side note, it's enabled also on a minimal install of RHEL7. Given the move away from RHN (https://access.redhat.com/rhn-to-rhsm) should a separate bug be filed to have it not run by default there too? 

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

rhel-guest-image-7.0-20140618.1.x86_64.qcow2 with SHA-256 Checksum d3f6052b5b381f11a767d7918dfe2c75f68fb2d6508e0077ba9b70bc7941b522. 

How reproducible:

Deterministic. 

Steps to Reproduce:

* Download the image (https://access.redhat.com/downloads/content/69/ver=/rhel---7/7.0/x86_64/product-downloads) 
* Boot it on RHEL-OSP4 or RHEL-OSP4
* View full console log 

Actual results:

rhnsd is enabled so it fails to start since the system in question is not registered to RHN / RHN Satellite. Is it reasonable to assume the instance will be registered to RHN / RHN Satellite? 

Expected results:

rhnsd should not be enabled by default on an instance.
Comment 1 John Fulton 2014-09-06 10:46:56 EDT
Apologies for my typo above. The first sentence should read:

rhnsd, a program for querying the Red Hat Network, is enabled by default on *our KVM image* ...
Comment 3 Stephen Herr 2014-09-08 10:31:32 EDT
1) If you want a service to not be enabled by default on your KVM image then you need to let whoever built your KVM image know, not the component owner of the package in question.

2) RHEL 7 guests can be registered to Satellite, so it is reasonable to have rhnsd enabled by default to support that case. Is this causing any problems at all besides a "failed to start" message in the boot log? If not I will close this as notABug
Comment 4 Stephen Herr 2014-09-08 10:35:50 EDT
(In reply to Stephen Herr from comment #3)
> Is this causing any problems
> at all besides a "failed to start" message in the boot log? If not I will
> close this as notABug

Actually I'm going to assume the answer is "no" and close it now. Feel free to reopen if there is an actual bug here.
Comment 5 Stephen Herr 2014-09-08 10:51:01 EDT
I take it back: there is a bug here.

rhnsd should start correctly and then not do anything if the system is not registered to Satellite. It should not fail to start. Re-opening.
Comment 6 John Fulton 2014-09-08 17:03:07 EDT
(In reply to Stephen Herr from comment #3)
> 1) If you want a service to not be enabled by default on your KVM image then
> you need to let whoever built your KVM image know, not the component owner
> of the package in question.

OK. I will clone this bug into a bug report for the component rhel-guest-image. 

I see you're keeping this bug for the reasons stated in comment #5 so I'm just going to edit the title accordingly.
Comment 7 Matej Kollar 2015-04-15 09:36:59 EDT
*** Bug 1189833 has been marked as a duplicate of this bug. ***
Comment 8 IBM Bug Proxy 2015-04-15 10:11:44 EDT
Created attachment 1014798 [details]
sosreport
Comment 9 Jan Dobes 2015-05-25 11:35:24 EDT
this behaviour is not new in RHEL7, it's caused by rhnsd init script lines 43-44:

RHN_SYSTEMID_FILE=`awk -F '=[[:space:]]*' '/^[[:space:]]*systemIdPath[[:space:]]*=/ {print $2}' $RHN_UP2DATE_FILE`

[ -f $RHN_SYSTEMID_FILE ] || exit 6

it just exits if typically '/etc/sysconfig/rhn/systemid' does not exist
Comment 10 Jan Dobes 2015-05-25 12:32:24 EDT
rhnsd itself checks systemid file again before each action, so it should work without checking in init script
Comment 11 Jan Dobes 2015-06-23 08:13:53 EDT
fixed in spacewalk master:

62080bbcb37b74ee2a21e4e381ddf0d4e809cd96
Comment 18 errata-xmlrpc 2015-11-19 07:13:36 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://rhn.redhat.com/errata/RHBA-2015-2380.html

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