Bug 649706

Summary: Several database tables have row movement disabled
Product: Red Hat Satellite 5 Reporter: Milan Zázrivec <mzazrivec>
Component: ServerAssignee: Michael Mráka <mmraka>
Status: CLOSED ERRATA QA Contact: Jiri Kastner <jkastner>
Severity: high Docs Contact:
Priority: high    
Version: 540CC: cperry, jkastner, mmraka
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: spacewalk-web-1.2.7-11 Doc Type: Bug Fix
Doc Text:
Prior to this update, running the "db-control shrink-segments" command on certain database tables could fail with an error. This happened when the database did not have row movement enabled. To prevent this, the db-control utility has been updated to enable the row movement automatically when the "shrink-segments" command is used.
Story Points: ---
Clone Of:
: 661662 (view as bug list) Environment:
Last Closed: 2010-12-21 12:25:19 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 646488, 661662    

Description Milan Zázrivec 2010-11-04 11:09:25 UTC
Description of problem:
Several database tables in Satellite 5.4 are created with row movement
disabled.

This status will cause

    db-control shrink-segments

to fail with an ORA- error.

In particular, this is a problem with rhnPackageRepoData (rather large table,
a good candidate for shrink).

Version-Release number of selected component (if applicable):
spacewalk-schema-1.2.21-9

How reproducible:
Always


Steps to Reproduce:
1. Satellite 5.4, synced channels, lot of packages
2. su - oracle
3. db-control shrink-segments
  
Actual results:
shrink-segments fails with an ORA- error telling row movement is not
enabled for rhnPackageRepoData.

Expected results:
db-control shrink-segments succeeds.

Additional info:

SQL> select table_name, row_movement from user_tables where row_movement = 'DISABLED' and TEMPORARY = 'N' and table_name not in ('PLAN_TABLE');
RHNPACKAGEREPODATA             DISABLED
RHNPACKAGEKEYTYPE              DISABLED
RHNPACKAGEPROVIDER             DISABLED
RHNPACKAGEKEY                  DISABLED
RHNPACKAGEKEYASSOCIATION       DISABLED
RHNREPOREGENQUEUE              DISABLED
RHNSSMOPERATION                DISABLED
RHNSSMOPERATIONSERVER          DISABLED
VALID_COUNTRIES_TL             DISABLED
RHNTASKOBUNCH                  DISABLED
RHNTASKOTASK                   DISABLED
RHNTASKOTEMPLATE               DISABLED
RHNTASKOSCHEDULE               DISABLED
RHNTASKORUN                    DISABLED
QRTZ_JOB_DETAILS               DISABLED
QRTZ_JOB_LISTENERS             DISABLED
QRTZ_TRIGGERS                  DISABLED
QRTZ_SIMPLE_TRIGGERS           DISABLED
QRTZ_CRON_TRIGGERS             DISABLED
QRTZ_BLOB_TRIGGERS             DISABLED
QRTZ_TRIGGER_LISTENERS         DISABLED
QRTZ_CALENDARS                 DISABLED
QRTZ_PAUSED_TRIGGER_GRPS       DISABLED
QRTZ_FIRED_TRIGGERS            DISABLED
QRTZ_SCHEDULER_STATE           DISABLED
QRTZ_LOCKS                     DISABLED

Comment 2 Michael Mráka 2010-11-27 12:32:13 UTC
As suggested by Jan we are going to fix db-control shrink-segments to enable row movement automaticaly on table it wants to shrink.

Implemented in spacewalk git:
commit b77e7e61560fd74db600c879a59ca8c2928275a8
    649706 - execute all recomendations from segment advisor
    incl. enable row movement if necessary

Comment 3 Michael Mráka 2010-12-09 15:42:18 UTC
Backported to satellite git as
commit 1a48ddf99db99e04dc693a9c79de300dd449ad35
    649706 - execute all recomendations from segment advisor
    incl. enable row movement if necessary

Comment 8 Jaromir Hradilek 2010-12-16 10:44:12 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Prior to this update, running the "db-control shrink-segments" command on certain database tables could fail with an error. This happened when the database did not have row movement enabled. To prevent this, the db-control utility has been updated to enable the row movement automatically when the "shrink-segments" command is used.

Comment 12 errata-xmlrpc 2010-12-21 12:25:19 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2010-1001.html