Bug 978539 - [RFE] Provide a way to log a reason when a service has been disabled [NEEDINFO]
[RFE] Provide a way to log a reason when a service has been disabled
Status: CLOSED ERRATA
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-nova (Show other bugs)
4.0
Unspecified Unspecified
medium Severity unspecified
: Upstream M2
: 4.0
Assigned To: David Ripton
Nir Magnezi
https://blueprints.launchpad.net/nova...
: FutureFeature
Depends On: 989721
Blocks: RHOS40RFE
  Show dependency treegraph
 
Reported: 2013-06-26 14:30 EDT by Russell Bryant
Modified: 2016-04-26 15:54 EDT (History)
10 users (show)

See Also:
Fixed In Version: openstack-nova-2013.2-0.23.rc1.el6
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-12-19 19:11:29 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
nmagnezi: needinfo-
mlopes: needinfo? (dripton)


Attachments (Terms of Use)

  None (edit)
Comment 1 Nir Magnezi 2013-07-03 08:12:15 EDT
This one looks quite straightforward, few questions due:
1. Is this going to be exposed only by API? or CLI as well?
2. I see the work on nova client marked as INPROGRESS, any implications regarding QE tests in your opinion?
3. I noticed they talk about a new services table, Is this a db table under nova db?

Any additional information is welcomed.
Comment 2 Russell Bryant 2013-07-03 09:56:57 EDT
(In reply to Nir Magnezi from comment #1)
> This one looks quite straightforward, few questions due:
> 1. Is this going to be exposed only by API? or CLI as well?

Ideally anything supported by the API should be supported in the CLI, as well.

> 2. I see the work on nova client marked as INPROGRESS, any implications
> regarding QE tests in your opinion?

You're right.  It's not in the client yet.  I need to follow up on that.

> 3. I noticed they talk about a new services table, Is this a db table under
> nova db?

It's not a new table.  It's just a new column, disabled_reason, in the existing services table.
Comment 3 Russell Bryant 2013-07-03 10:15:02 EDT
client support is in progress here: https://review.openstack.org/#/c/34964/
Comment 4 Nir Magnezi 2013-07-15 05:09:25 EDT
(In reply to Russell Bryant from comment #3)
> client support is in progress here: https://review.openstack.org/#/c/34964/

Russell,
I'm looking to the exact syntax of those new CLI commands.

Looking here: https://review.openstack.org/#/c/34964/5/novaclient/tests/v1_1/fakes.py

I get the impression that it will look something like:

service <host> <service-name> <text entered by the user as a reason>

I'm I correct?
Comment 5 Russell Bryant 2013-07-15 12:36:48 EDT
(In reply to Nir Magnezi from comment #4)
> (In reply to Russell Bryant from comment #3)
> > client support is in progress here: https://review.openstack.org/#/c/34964/
> 
> Russell,
> I'm looking to the exact syntax of those new CLI commands.
> 
> Looking here:
> https://review.openstack.org/#/c/34964/5/novaclient/tests/v1_1/fakes.py
> 
> I get the impression that it will look something like:
> 
> service <host> <service-name> <text entered by the user as a reason>
> 
> I'm I correct?

[rbryant@devstack python-novaclient]$ nova service-list
nova+------------------+----------+----------+---------+-------+----------------------------+-----------------+
| Binary           | Host     | Zone     | Status  | State | Updated_at                 | Disabled Reason |
+------------------+----------+----------+---------+-------+----------------------------+-----------------+
| nova-conductor   | devstack | internal | enabled | up    | 2013-07-15T16:35:01.000000 | None            |
| nova-cert        | devstack | internal | enabled | up    | 2013-07-15T16:34:58.000000 | None            |
| nova-compute     | devstack | nova     | enabled | up    | 2013-07-15T16:34:55.000000 | None            |
| nova-network     | devstack | internal | enabled | up    | 2013-07-15T16:34:53.000000 | None            |
| nova-scheduler   | devstack | internal | enabled | up    | 2013-07-15T16:35:03.000000 | None            |
| nova-consoleauth | devstack | internal | enabled | up    | 2013-07-15T16:34:57.000000 | None            |
+------------------+----------+----------+---------+-------+----------------------------+-----------------+
 [rbryant@devstack python-novaclient]$ nova service-disable devstack nova-compute --reason 'because i said s' 
+----------+--------------+----------+-------------------+
| Host     | Binary       | Status   | Disabled Reason   |
+----------+--------------+----------+-------------------+
| devstack | nova-compute | disabled | because i said so |
+----------+--------------+----------+-------------------+
[rbryant@devstack python-novaclient]$ nova service-list
+------------------+----------+----------+----------+-------+----------------------------+-------------------+
| Binary           | Host     | Zone     | Status   | State | Updated_at                 | Disabled Reason   |
+------------------+----------+----------+----------+-------+----------------------------+-------------------+
| nova-conductor   | devstack | internal | enabled  | up    | 2013-07-15T16:35:21.000000 | None              |
| nova-cert        | devstack | internal | enabled  | up    | 2013-07-15T16:35:18.000000 | None              |
| nova-compute     | devstack | nova     | disabled | up    | 2013-07-15T16:35:20.000000 | because i said so |
| nova-network     | devstack | internal | enabled  | up    | 2013-07-15T16:35:23.000000 | None              |
| nova-scheduler   | devstack | internal | enabled  | up    | 2013-07-15T16:35:23.000000 | None              |
| nova-consoleauth | devstack | internal | enabled  | up    | 2013-07-15T16:35:17.000000 | None              |
+------------------+----------+----------+----------+-------+----------------------------+-------------------+
[rbryant@devstack python-novaclient]$ nova service-enable devstack nova-compute
+----------+--------------+---------+
| Host     | Binary       | Status  |
+----------+--------------+---------+
| devstack | nova-compute | enabled |
+----------+--------------+---------+
[rbryant@devstack python-novaclient]$ nova service-list
+------------------+----------+----------+---------+-------+----------------------------+-------------------+
| Binary           | Host     | Zone     | Status  | State | Updated_at                 | Disabled Reason   |
+------------------+----------+----------+---------+-------+----------------------------+-------------------+
| nova-conductor   | devstack | internal | enabled | up    | 2013-07-15T16:35:41.000000 | None              |
| nova-cert        | devstack | internal | enabled | up    | 2013-07-15T16:35:38.000000 | None              |
| nova-compute     | devstack | nova     | enabled | up    | 2013-07-15T16:35:38.000000 | because i said so |
| nova-network     | devstack | internal | enabled | up    | 2013-07-15T16:35:33.000000 | None              |
| nova-scheduler   | devstack | internal | enabled | up    | 2013-07-15T16:35:33.000000 | None              |
| nova-consoleauth | devstack | internal | enabled | up    | 2013-07-15T16:35:37.000000 | None              |
+------------------+----------+----------+---------+-------+----------------------------+-------------------+


Minor bug here at the end.  The reason didn't get cleared out on enable.  The version I'm running is just a little old.  It was fixed here:

https://review.openstack.org/#q,I78c9e40c65e96fbc6eff0e3426cfd87b0810cd69,n,z
Comment 9 David Ripton 2013-08-13 11:53:12 EDT
Nir, your test plan looks great to me.  The upstream unit tests should cover proving that the migration that adds the column works.
Comment 10 Nir Magnezi 2013-08-14 02:57:05 EDT
(In reply to David Ripton from comment #9)
> Nir, your test plan looks great to me.  The upstream unit tests should cover
> proving that the migration that adds the column works.

Thank you for the feedback David.
Comment 14 Nir Magnezi 2013-11-12 04:47:35 EST
Verified NVR:
# rpm -qa | grep openstack-nova
openstack-nova-conductor-2013.2-4.el6ost.noarch
openstack-nova-cert-2013.2-4.el6ost.noarch
openstack-nova-common-2013.2-4.el6ost.noarch
openstack-nova-console-2013.2-4.el6ost.noarch
openstack-nova-compute-2013.2-4.el6ost.noarch
openstack-nova-scheduler-2013.2-4.el6ost.noarch
openstack-nova-api-2013.2-4.el6ost.noarch
openstack-nova-novncproxy-2013.2-4.el6ost.noarch


Passed all OE Sanity tests.
Comment 17 errata-xmlrpc 2013-12-19 19:11:29 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.

http://rhn.redhat.com/errata/RHEA-2013-1859.html

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