Bug 1266139 - CFME needs to subscribe to neutron rabbit exchange for Openstack cloud provider events
Summary: CFME needs to subscribe to neutron rabbit exchange for Openstack cloud provid...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Providers
Version: 5.4.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: GA
: 5.6.0
Assignee: Ladislav Smola
QA Contact: Dave Johnson
URL:
Whiteboard: provider:openstack
Depends On:
Blocks: 1347701
TreeView+ depends on / blocked
 
Reported: 2015-09-24 15:06 UTC by Marius Cornea
Modified: 2019-01-24 14:21 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1347701 (view as bug list)
Environment:
Last Closed: 2019-01-24 14:21:03 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:
rrasouli: needinfo-


Attachments (Terms of Use)
cfme timelines (69.14 KB, image/png)
2016-06-16 03:45 UTC, Ronnie Rasouli
no flags Details
evm log (3.12 MB, application/x-xz)
2016-06-16 03:53 UTC, Ronnie Rasouli
no flags Details
events (17.55 KB, text/plain)
2016-06-21 08:29 UTC, Marius Cornea
no flags Details

Description Marius Cornea 2015-09-24 15:06:35 UTC
Description of problem:
CFME currently uses the quantum exchange for the Openstack cloud provider events. 

In OSP7 the exchange name is neutron:
[root@overcloud-controller-0 neutron]# grep control_exchange neutron.conf 
# control_exchange=openstack
control_exchange=neutron 

https://github.com/ManageIQ/manageiq/blob/master/config/vmdb.tmpl.yml#L291

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

How reproducible:
100%

Steps to Reproduce:
1. Activate neutron notifications on the Openstack controllers
2. Check Timelines for neutron events

Actual results:
No neutron events show up.

Expected results:
Neutron events show up.

Comment 2 Marius Cornea 2015-11-13 11:02:02 UTC
We should make sure that we don't get duplicate events if using neutron and quantum.

Comment 3 Ladislav Smola 2015-11-13 12:58:28 UTC
https://github.com/ManageIQ/manageiq/pull/5426 only floating ip related events should appear in the timelines

Comment 4 CFME Bot 2015-11-13 16:21:08 UTC
New commit detected on ManageIQ/manageiq/master:
https://github.com/ManageIQ/manageiq/commit/7131a22745c255f1bc2f9c714c0b5749ca7d7675

commit 7131a22745c255f1bc2f9c714c0b5749ca7d7675
Author:     Ladislav Smola <lsmola>
AuthorDate: Fri Nov 13 13:55:40 2015 +0100
Commit:     Ladislav Smola <lsmola>
CommitDate: Fri Nov 13 13:55:40 2015 +0100

    OpenStack catch Neutron events
    
    OpenStack catch Neutron events
    
    Implements BZ:
    https://bugzilla.redhat.com/show_bug.cgi?id=1266139

 config/vmdb.tmpl.yml | 1 +
 1 file changed, 1 insertion(+)

Comment 5 Ronnie Rasouli 2016-06-16 03:45:57 UTC
Created attachment 1168557 [details]
cfme timelines

Comment 6 Ronnie Rasouli 2016-06-16 03:49:35 UTC
tested on 5.6.0.10-rc2.1
Created floating-ip and networks

[stack@instack ~]$ ceilometer event-type-list
+-----------------------+
| Event Type            |
+-----------------------+
| identity.authenticate |
| network.create.end    |
| network.create.start  |
| subnet.create.end     |
| subnet.create.start   |
+-----------------------+

The network events did not show up

Comment 7 Ronnie Rasouli 2016-06-16 03:53:32 UTC
Created attachment 1168558 [details]
evm log

Comment 8 Marek Aufart 2016-06-16 08:08:13 UTC
Network related events should be visible in Network Provider (instead of Cloud Provider).

Comment 9 Ronnie Rasouli 2016-06-16 13:12:59 UTC
nova floating-ip-associate quatInstance 172.16.23.141
nova floating-ip-disassociate quatInstance 172.16.23.141

events showing:
[stack@undercloud ~]$ ceilometer event-type-list
+-------------------------------------+
| Event Type                          |
+-------------------------------------+
| compute.instance.create.end         |
| compute.instance.create.start       |
| compute.instance.delete.end         |
| compute.instance.delete.start       |
| compute.instance.exists             |
| compute.instance.shutdown.end       |
| compute.instance.shutdown.start     |
| compute.instance.update             |
| floatingip.create.end               |
| floatingip.create.start             |
| floatingip.update.end               |
| floatingip.update.start             |
| identity.authenticate               |
| port.create.end                     |
| port.create.start                   |
| port.delete.end                     |
| port.delete.start                   |
| scheduler.select_destinations.end   |
| scheduler.select_destinations.start |
+-------------------------------------+

Very strange why the openstack doesn't report network.floating_ip.deallocate network.floating_ip.allocate

Comment 15 Marius Cornea 2016-06-21 08:28:31 UTC
During the floating ip association operations I noticed the following events received by miq using this script[1]: floatingip.update.start, floatingip.update.end, floatingip.create.start, floatingip.create.end so I believe we don't capture those. According to [2] we're capturing floating_ip.allocate, floating_ip.deallocate, floating_ip.associate, floating_ip.disassociate

CLI commands that I run:

neutron floatingip-associate 548af7f5-57ac-455a-a0b0-0e3ee1ce0a30 8d50f69b-a770-497c-aacb-3960c2a08ad9
neutron floatingip-disassociate 548af7f5-57ac-455a-a0b0-0e3ee1ce0a30 8d50f69b-a770-497c-aacb-3960c2a08ad9
neutron floatingip-create 8e12b1bd-325e-40d7-8af1-81f36f6c7da0

Attaching events captured with the script.

[1] https://raw.githubusercontent.com/ManageIQ/manageiq/master/gems/pending/openstack/test/event_monitor_example.rb
[2] https://github.com/ManageIQ/manageiq/blob/master/config/settings.yml#L580-L583

Comment 16 Marius Cornea 2016-06-21 08:29:00 UTC
Created attachment 1170147 [details]
events

Comment 17 Ladislav Smola 2016-08-02 16:25:41 UTC
@Marius you should see all the events in MIQ DB, all events are being captured

The settings.yaml holds only definition for which ones you want to display in Timelines. Which is user configurable, so you can test with listing the events you are interested in, by typing them in settings.

We should open an RFE for expanding the default settings.yaml, with more default events.

Comment 18 Marius Cornea 2016-08-04 14:04:27 UTC
(In reply to Ladislav Smola from comment #17)
> @Marius you should see all the events in MIQ DB, all events are being
> captured
> 
> The settings.yaml holds only definition for which ones you want to display
> in Timelines. Which is user configurable, so you can test with listing the
> events you are interested in, by typing them in settings.
> 
> We should open an RFE for expanding the default settings.yaml, with more
> default events.

Could you please provide the steps on how to see the events in the MIQ DB?

Comment 19 Ladislav Smola 2016-08-05 10:26:35 UTC
In rails c, is't either MiqEvent or EmsEvent. Optionally you can specify the wanted events in the settings.yaml and they should show up in the timeline.

Comment 20 Ladislav Smola 2016-08-24 14:06:18 UTC
The additional check is adding the event into config/settings.yml (you can do it through UI), e.g. the same as compute.instance.create.end. And then the events should be visible in provider's timeline.

If there is a network manager, it should be under network manager timelines.

Comment 21 Ronnie Rasouli 2016-09-25 12:41:27 UTC
added under:
   :network:
      :critical:
      - network.floating_ip.allocate
      - network.floating_ip.deallocate
      - network.floating_ip.associate
      - network.floating_ip.disassociate
      - network.create.end
      - network.create.start
      - port.create.end
      - port.create.start
      - port.update.start
      - subnet.create.end
      - subnet.create.start
      - subnet.delete.end
      - subnet.delete.start
I can see in timelines network events.
verified on 5.6.2.0


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