Bug 882682

Summary: engine-notifierd service active & rhevm-manage-domains add/delete cause DB connection limit exceed
Product: Red Hat Enterprise Virtualization Manager Reporter: Ilanit Stein <istein>
Component: ovirt-engine-notification-serviceAssignee: Yair Zaslavsky <yzaslavs>
Status: CLOSED DUPLICATE QA Contact: Ilanit Stein <istein>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 3.1.0CC: bazulay, dyasny, iheim, oourfali, Rhev-m-bugs, ykaul
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: infra
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-12-09 11:36:56 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Infra RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
notifier.conf
none
notifier log
none
engine.log none

Description Ilanit Stein 2012-12-02 16:26:07 UTC
Description of problem:

Activating event notifification, along with trying to add/delete domain
by rhevm-manage-domains cause DB related commands to fail on database access.

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

How reproducible:
always (tried on 2 clean install setups)

Steps to Reproduce:
1. Define the /etc/ovirt-engine/notifier/notifier.conf for sending notifications
(My conf attached as example)
2. Activate engine-notifierd service. 
(/etc/rc.d/init.d/engine-notifierd start)
3. Attach event notification to a user 
(I added a user from AD, attached to it event notification for ovirt-engine stop)
4. rhevm-manage-domains delete or add domain fail to access DB.
(I run: 
rhevm-manage-domains  -action=delete -addPermissions -domain=qa.lab.tlv.redhat.com -user=dafna  -interactive -provider=activeDirectory
Failure while connecting to database. Details: FATAL: connection limit exceeded for non-superusers)
  
Actual results:
Commands related to database DB connection fail on limit exceeded error:
Examples:
--------
1.
rhevm-manage-domains  -action=delete -addPermissions -domain=qa.lab.tlv.redhat.com -user=dafna  -interactive -provider=activeDirectory

Failure while connecting to database. Details: FATAL: connection limit exceeded for non-superusers

2.
rhevm-config -l
Connection to the Database failed. Please check that the hostname and port number are correct and that the Database service is up and running.

Expected results:
Event notification should not interfere DB access.

Additional info:
Stop engine-notifierd release the DB.

Comment 1 Ilanit Stein 2012-12-02 16:30:14 UTC
Created attachment 656124 [details]
notifier.conf

Comment 2 Ilanit Stein 2012-12-02 16:32:18 UTC
Created attachment 656125 [details]
notifier log

Comment 3 Ilanit Stein 2012-12-02 16:34:15 UTC
Created attachment 656126 [details]
engine.log

Comment 4 Yair Zaslavsky 2012-12-09 11:36:56 UTC
Duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=882847
Connection handling at notifier was vastly improved at this bug.
Since notifierd does not work connection pool, each time a connection is obtained in its code a new connection is opened towards the DB, and the DB has a limit of open connections.
The above bug fix reduced the time the connection is begin opened.

*** This bug has been marked as a duplicate of bug 882847 ***