Bug 985346 - Share the engine's os info with DWH through a translation table
Share the engine's os info with DWH through a translation table
Status: CLOSED ERRATA
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine-dwh (Show other bugs)
3.3.0
Unspecified Unspecified
unspecified Severity unspecified
: ---
: 3.3.0
Assigned To: Yaniv Lavi
Barak Dagan
infra
:
Depends On: 977440
Blocks: 1019461
  Show dependency treegraph
 
Reported: 2013-07-17 06:30 EDT by Roy Golan
Modified: 2016-02-10 14:15 EST (History)
11 users (show)

See Also:
Fixed In Version: rhevm-dwh-3.3.0-12.el6ev.noarch.rpm
Doc Type: Enhancement
Doc Text:
Custom virtual machine operating system information is now automatically synced to history database.
Story Points: ---
Clone Of: 977440
Environment:
Last Closed: 2014-01-21 09:59:23 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: Infra
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
half-sql (2.37 KB, text/plain)
2013-10-01 06:53 EDT, David Botzer
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
oVirt gerrit 19330 None None None Never

  None (edit)
Description Roy Golan 2013-07-17 06:30:19 EDT
+++ This bug was initially created as a clone of Bug #977440 +++

Description of problem:
in 3.3 we adding the ability to add user-defined OSs to the engine.
Reports on vm os type will end with up with new entries without the actual name of the OS, as kept in the engine.

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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:
DWH keeps its own translation based on the VmOsType enum and won't have any info
on new OSs

Expected results:
DWH will be able to read the mapping from the engine db. The data will relay in 
a dedicated dwh_osinfo table.

Additional info:

--- Additional comment from Yaniv Dary on 2013-06-25 08:59:58 EDT ---

This is a documentation bug. We need to add a guide to adding new OSs to the history database. Zac, which component to move this to? 



Yaniv
Comment 1 Itamar Heim 2013-07-17 08:56:53 EDT
its not clear if this is a documentation bug or coding is needed.
you need to remember the enums in dwh are also per locale for example.
I think a procedure to adding them by customer to dwh if adding OSs to OsInfo is good enough for now
Comment 6 David Botzer 2013-09-30 06:29:26 EDT
What to test - 
documentation, 
dwh history DB enum_translator table 
or reports ?
Comment 7 Yaniv Lavi 2013-09-30 06:34:24 EDT
(In reply to David Botzer from comment #6)
> What to test - 
> documentation, 
> dwh history DB enum_translator table 
> or reports ?

history DB enum_translator table after adding custom os to rhevm.



Yaniv
Comment 8 David Botzer 2013-09-30 07:36:50 EDT
Engine side is ok
Adding new custom OS is shown in both
Engine DB - TABLE dwh_osinfo
Webadmin  - Create new VM OS 
how to test in dwh/reports side
Comment 9 Yaniv Lavi 2013-09-30 07:39:33 EDT
(In reply to Yaniv Dary from comment #7)
> (In reply to David Botzer from comment #6)
> > What to test - 
> > documentation, 
> > dwh history DB enum_translator table 
> > or reports ?
> 
> history DB enum_translator table after adding custom os to rhevm.
> 
> 
> 
> Yaniv
Comment 10 Yaniv Lavi 2013-09-30 07:40:29 EDT
(In reply to Yaniv Dary from comment #9)
> (In reply to Yaniv Dary from comment #7)
> > (In reply to David Botzer from comment #6)
> > > What to test - 
> > > documentation, 
> > > dwh history DB enum_translator table 
> > > or reports ?
> > 
> > history DB enum_translator table after adding custom os to rhevm.
> > 
> > 
> > 
> > Yaniv

Should be added to en_US OS_TYPE.
Comment 11 David Botzer 2013-09-30 07:57:59 EDT
I cannot login to dwh history db, there is a problem with rhevm-dwh-setup

rhevm-dwh-setup gives error when creating a user or not:

2013-09-30 14:49:19::DEBUG::common_utils::777::root:: output = 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:1a:4a:16:97:df brd ff:ff:ff:ff:ff:ff
    inet 10.35.161.223/24 brd 10.35.161.255 scope global eth0
    inet6 fe80::21a:4aff:fe16:97df/64 scope link
       valid_lft forever preferred_lft forever

2013-09-30 14:49:19::DEBUG::common_utils::778::root:: stderr =
2013-09-30 14:49:19::DEBUG::common_utils::779::root:: retcode = 0
2013-09-30 14:49:19::DEBUG::common_utils::589::root:: Found IP Address: 10.35.161.223
2013-09-30 14:49:19::DEBUG::common_utils::735::root:: Executing command --> '/bin/su -l postgres -c /usr/bin/psql -U postgres -c "DROP ROLE if exists engine_history;"' in working directory '/etc/ovirt-engine/notifier'
2013-09-30 14:49:19::DEBUG::common_utils::777::root:: output =
2013-09-30 14:49:19::DEBUG::common_utils::778::root:: stderr = ERROR:  role "engine_history" cannot be dropped because some objects depend on it
DETAIL:  owner of database ovirt_engine_history
287 objects in database ovirt_engine_history

2013-09-30 14:49:19::DEBUG::common_utils::779::root:: retcode = 129
2013-09-30 14:49:19::ERROR::rhevm-dwh-setup::506::root:: Exception caught!
2013-09-30 14:49:19::ERROR::rhevm-dwh-setup::507::root:: Traceback (most recent call last):
  File "/usr/bin/rhevm-dwh-setup", line 410, in main
    option='createdb',
  File "/usr/share/ovirt-engine-dwh/common_utils.py", line 998, in createUser
    failOnError=True
  File "/usr/share/ovirt-engine-dwh/common_utils.py", line 782, in execCmd
    raise Exception(msg)
Exception: Return Code is not zero
Comment 12 David Botzer 2013-09-30 09:50:18 EDT
history db enum_translator is not updated
Yaniv: please advise on the correct build
Comment 13 David Botzer 2013-10-01 03:54:45 EDT
When is this due to be fix ?
if not current build, please move it to assign (or let me know and I will)
Comment 14 David Botzer 2013-10-01 06:53:05 EDT
3.3/is16 This bug is fixed,
dwh history db - enum_translator table includes all OS_TYPES

Need to examine the following before I verify:

1. postgresql.conf is incomplete (Half) missing the connection config params
2. What build is this fix included in order to test it fully.
Comment 15 David Botzer 2013-10-01 06:53:31 EDT
Created attachment 805838 [details]
half-sql
Comment 16 David Botzer 2013-10-02 07:31:54 EDT
3.3/is17.1
DWH install successfully,
history DB enum_translator has the following only in English:
"OS_TYPE";1193;"en_US";"SUSE Linux Enterprise Server 11"
"OS_TYPE";1252;"en_US";"Ubuntu Precise Pangolin LTS"
"OS_TYPE";1253;"en_US";"Ubuntu Quantal Quetzal"
"OS_TYPE";1254;"en_US";"Ubuntu Raring Ringtails"
"OS_TYPE";1255;"en_US";"Ubuntu Saucy Salamander"

Should they include in all languages ?
Please advise,
Comment 17 David Botzer 2013-10-03 00:28:34 EDT
Fixed, 3.3/is17.1
Comment 18 Charlie 2013-11-27 19:54:49 EST
This bug is currently attached to errata RHEA-2013:15116. If this change is not to be documented in the text for this errata please either remove it from the errata, set the requires_doc_text flag to 
minus (-), or leave a "Doc Text" value of "--no tech note required" if you do not have permission to alter the flag.

Otherwise to aid in the development of relevant and accurate release documentation, please fill out the "Doc Text" field above with these four (4) pieces of information:

* Cause: What actions or circumstances cause this bug to present.
* Consequence: What happens when the bug presents.
* Fix: What was done to fix the bug.
* Result: What now happens when the actions or circumstances above occur. (NB: this is not the same as 'the bug doesn't present anymore')

Once filled out, please set the "Doc Type" field to the appropriate value for the type of change made and submit your edits to the bug.

For further details on the Cause, Consequence, Fix, Result format please refer to:

https://bugzilla.redhat.com/page.cgi?id=fields.html#cf_release_notes 

Thanks in advance.
Comment 20 errata-xmlrpc 2014-01-21 09:59:23 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/RHBA-2014-0036.html

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