Bug 1488178

Summary: [Docs][DWH] Incomplete information while creating a read-only user to access the history DB
Product: Red Hat Enterprise Virtualization Manager Reporter: Javier Coscia <jcoscia>
Component: DocumentationAssignee: Avital Pinnick <apinnick>
Status: CLOSED CURRENTRELEASE QA Contact: Byron Gravenorst <bgraveno>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.1.0CC: aperotti, apinnick, jcoscia, lbopf, lsurette, rbalakri, srevivo, ykaul
Target Milestone: ovirt-4.1.8Flags: lsvaty: testing_plan_complete-
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-11-22 09:19:36 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Docs RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Javier Coscia 2017-09-04 14:50:20 UTC
Description of problem:

Need to add the following information into 2.6 section in DWH Guide

https://access.redhat.com/documentation/en-us/red_hat_virtualization/4.1/html/data_warehouse_guide/allowing_read_only_access_to_the_history_database


Before running the 'psql' command after step 6, customer still needs to configure the authentication method for the read-only user in ph_hba.conf file + reload postgresql service, also, the psql command, to test access to the ovirt_engine_history DB, has to include the host flag (-h localhost)

# /var/lib/pgsql/data/pg_hba.conf
~~~
# TYPE  DATABASE        USER            ADDRESS                 METHOD

# "local" is for Unix domain socket connections only
local   all             all                                     peer
host    ovirt_engine_history ovirt_engine_history 0.0.0.0/0               md5
host    ovirt_engine_history ovirt_engine_history ::0/0                   md5
host    ovirt_engine_history $RO_USER 0.0.0.0/0               md5
host    ovirt_engine_history $RO_USER ::0/0                   md5
host    engine          engine          0.0.0.0/0               md5
host    engine          engine          ::0/0                   md5
# IPv4 local connections:
host    all             all             127.0.0.1/32            ident
# IPv6 local connections:
host    all             all             ::1/128                 ident
~~~

Replace $RO_USER with correct value


# systemctl reload postgresql

Command to test DB access:

# psql -h localhost -U $RO_USER ovirt_engine_history

Comment 1 Andrea Perotti 2017-09-05 17:02:17 UTC
*** Bug 1488559 has been marked as a duplicate of this bug. ***