Bug 1165766 - satellite-upgrade-estimates: psycopg2.ProgrammingError: relation "user_segments" does not exist at character 44
Summary: satellite-upgrade-estimates: psycopg2.ProgrammingError: relation "user_segmen...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Upgrades
Version: 570
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Stephen Herr
QA Contact: Jan Hutař
URL:
Whiteboard:
Depends On:
Blocks: sat570-upgrades
TreeView+ depends on / blocked
 
Reported: 2014-11-19 16:12 UTC by Jan Hutař
Modified: 2015-01-13 10:25 UTC (History)
2 users (show)

Fixed In Version: rhn-upgrade-5.7.0.6-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-01-13 10:25:29 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Jan Hutař 2014-11-19 16:12:52 UTC
Description of problem:
satellite-upgrade-estimates on Satellite 5.6.0 tracebacks with:

psycopg2.ProgrammingError: relation "user_segments" does not exist at character 44


Version-Release number of selected component (if applicable):
Upgraded Satellite 5.6.0 on RHEL5
rhn-upgrade-5.7.0.5-1.el5sat
python-psycopg2-2.0.14-3.el5sat


How reproducible:
always


Steps to Reproduce:
1. Run satellite-upgrade-estimates and answer just "Enter"
   to first two questions


Actual results:
# /etc/sysconfig/rhn/satellite-upgrade/scripts/satellite-upgrade-estimates
Will you be upgrading both the operating system and Red Hat Satellite? [N] 
Will you be migrating your Red Hat Satellite database from Oracle to PostgreSQL? [N] 

Computing ...
Traceback (most recent call last):
  File "/etc/sysconfig/rhn/satellite-upgrade/scripts/satellite-upgrade-estimates", line 223, in ?
    oracle_db_size = get_oracle_db_size()
  File "/etc/sysconfig/rhn/satellite-upgrade/scripts/satellite-upgrade-estimates", line 126, in get_oracle_db_size
    h.execute()
  File "/usr/lib/python2.4/site-packages/spacewalk/server/rhnSQL/sql_base.py", line 163, in execute
    return apply(self._execute_wrapper, (self._execute, ) + p, kw)
  File "/usr/lib/python2.4/site-packages/spacewalk/server/rhnSQL/driver_postgresql.py", line 273, in _execute_wrapper
    retval = apply(function, p, kw)
  File "/usr/lib/python2.4/site-packages/spacewalk/server/rhnSQL/sql_base.py", line 217, in _execute
    return self._execute_(args, kwargs)
  File "/usr/lib/python2.4/site-packages/spacewalk/server/rhnSQL/driver_postgresql.py", line 287, in _execute_
    self._real_cursor.execute(self.sql, params)
psycopg2.ProgrammingError: relation "user_segments" does not exist at character 44


Expected results:
Should show estimates

Comment 2 Jan Hutař 2014-11-19 21:10:07 UTC
Same problem for recognize_guests.py script:


# /etc/sysconfig/rhn/satellite-upgrade/scripts/recognize_guests.py
Traceback (most recent call last):
  File "/etc/sysconfig/rhn/satellite-upgrade/scripts/recognize_guests.py", line 229, in ?
    main()
  File "/etc/sysconfig/rhn/satellite-upgrade/scripts/recognize_guests.py", line 102, in main
    db = options.db or CFG.DEFAULT_DB
  File "/usr/lib/python2.4/site-packages/spacewalk/common/rhnConfig.py", line 222, in __getattr__
    raise AttributeError(key)
AttributeError: DEFAULT_DB


When you add:


    print 'options.db = ', options.db
    print 'CFG.DEFAULT_DB = ', CFG.DEFAULT_DB


you get:


# /etc/sysconfig/rhn/satellite-upgrade/scripts/recognize_guests.py
options.db =  None
CFG.DEFAULT_DB = 
Traceback (most recent call last):
  File "/etc/sysconfig/rhn/satellite-upgrade/scripts/recognize_guests.py", line 231, in ?
    main()
  File "/etc/sysconfig/rhn/satellite-upgrade/scripts/recognize_guests.py", line 103, in main
    print 'CFG.DEFAULT_DB = ', CFG.DEFAULT_DB
  File "/usr/lib/python2.4/site-packages/spacewalk/common/rhnConfig.py", line 222, in __getattr__
    raise AttributeError(key)
AttributeError: DEFAULT_DB

Comment 3 Stephen Herr 2014-11-21 15:53:14 UTC
I think comment 2 was supposed to be added to bug 1165852. Copying...

Comment 4 Stephen Herr 2014-11-21 16:58:48 UTC
(In reply to Jan Hutař from comment #0)
> How reproducible:
> always

Specifically I think this is always reproducable on a Postgresql Sat 5.6. user_segments is an Oracle-ism.

Comment 9 Clifford Perry 2015-01-13 10:25:29 UTC
With the release of Red Hat Satellite 5.7 on January 12th 2015 this bug is
being moved to a Closed Current Release state. 

The Satellite 5.7 GA Errata:
 - https://rhn.redhat.com/errata/RHSA-2015-0033.html 

Satellite 5.7 Release Notes:
 -
https://access.redhat.com/documentation/en-US/Red_Hat_Satellite/5.7/html-single/Release_Notes/index.html

Satellite Customer Portal Blog announcement for release:
 - https://access.redhat.com/blogs/1169563/posts/1315743 

Cliff

NOTE: This bug has not been re-verified (moved to RELEASE_PENDING) prior to release. We assume that the bug has indeed been fixed and not regressed since we initially verified it. Please re-open in the future if needed.


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