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 605734 - initscript actions
Summary: initscript actions
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: edac-utils
Version: 6.0
Hardware: All
OS: Linux
high
medium
Target Milestone: rc
: ---
Assignee: Mauro Carvalho Chehab
QA Contact: Alex Sersen
URL:
Whiteboard:
Depends On:
Blocks: 579073 632665 633349
TreeView+ depends on / blocked
 
Reported: 2010-06-18 16:15 UTC by Karel Volný
Modified: 2013-11-01 01:33 UTC (History)
8 users (show)

Fixed In Version: edac-utils-0.9-11.2.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 632665 (view as bug list)
Environment:
Last Closed: 2010-11-10 20:20:55 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
New EDAC SysV script (1.14 KB, application/octet-stream)
2010-06-23 00:18 UTC, Mauro Carvalho Chehab
no flags Details

Description Karel Volný 2010-06-18 16:15:50 UTC
the initscript does not implement some mandatory actions, it does not implement some actions correctly, and does not report correct status

please see https://fedoraproject.org/wiki/Packaging/SysVInitScript

1) the initscript does not implement 'condrestart'

2) the initscript does not implement 'try-restart'

3) the initscript does not implement 'force-reload'

4) running "service edac status" after "service edac stop" returns 0 instead of 3

5) running "service edac reload" on a stopped service returns 0 instead of 7 and restarts the service

6) for invalid arguments, instead of returning error message and status code 2, the initscript prints usage message and returns 0 - but usage message should be printed only if run without arguments or with "usage" argument

7) running the initscript as non-root user does not return error and status code 4 (except for usage and status, it should be allowed), but it tries to perform the actions which leads to permission denial errors

Comment 2 RHEL Program Management 2010-06-18 16:43:29 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.

Comment 3 Mauro Carvalho Chehab 2010-06-22 23:39:10 UTC
(In reply to comment #0)

> 4) running "service edac status" after "service edac stop" returns 0 instead of
> 3
> 
> 5) running "service edac reload" on a stopped service returns 0 instead of 7
> and restarts the service

Such return codes wouldn't make any sense on this case. This script should not
be different than the one provided for bluetooth, where only a start method is
defined:

start()
{
	echo -n $"Enabling Bluetooth devices:"
	udevadm trigger --subsystem-match=bluetooth
	echo ""
	return 0
}

stop()
{
	# FIXME If somebody figures out how to disable the K* script
	echo -n "Stopping Bluetooth services:"
	echo ""
	return 0
}

It is just the same case: we just need to run edac-ctl during start method,
in order to load some parameters at the corresponding kernel driver. This script doesn't start any deamon that needs to be stopped. I think I'll rewrite
the init script to look more like the above, adding some fake methods for all
those restart methods that will just call edac-ctl whatever argument provided,
except for stop and usage.

Comment 4 Mauro Carvalho Chehab 2010-06-23 00:18:37 UTC
Created attachment 426119 [details]
New EDAC SysV script

New script that fulfills all requirements stated at:
https://fedoraproject.org/wiki/Packaging/SysVInitScript#Initscripts_on_the_filesystem

Since this script just sends some data to EDAC kernel driver, there's no stop action, nor there is a "daemon status". So, all actions that asks for reload will just do the same action as "start": send the new memory labels table to the Kernel driver. "stop" and "status" will just return 0, as there's no way (nor make sense) to stop a non-daemon process.

Comment 6 Mauro Carvalho Chehab 2010-06-30 04:13:24 UTC
New SysV script added at: edac-utils-0.9-11.2.el6.src.rpm

Comment 15 releng-rhel@redhat.com 2010-11-10 20:20:55 UTC
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.


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