Bug 1150697 - Satellite5.6: spacewalk-export --org fails for system-profile
Summary: Satellite5.6: spacewalk-export --org fails for system-profile
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Client
Version: 560
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
Assignee: Grant Gainey
QA Contact: Radovan Drazny
URL:
Whiteboard:
: 1275207 (view as bug list)
Depends On:
Blocks: sat560-triage
TreeView+ depends on / blocked
 
Reported: 2014-10-08 17:45 UTC by Grant Gainey
Modified: 2020-03-11 14:51 UTC (History)
4 users (show)

Fixed In Version: spacewalk-utils-2.0.2-28
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1151121 (view as bug list)
Environment:
Last Closed: 2016-09-14 12:04:50 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1866 0 normal SHIPPED_LIVE Satellite 5.6 bug fix update 2016-09-14 16:01:09 UTC

Description Grant Gainey 2014-10-08 17:45:08 UTC
Description of problem:

Specifying --org <org-id> for spacewalk-export fails to export system-profiles

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

spacewalk-utils-2.0.2-16.el6sat.noarch

How reproducible:

Try "spacewalk-export --org 1"

Actual results:

===
~ $ spacewalk-export --org 1
INFO: Processing users...
INFO: Processing system-groups...
INFO: Processing config-files...
INFO: Processing repositories...
INFO: Processing channels...
Processing organization: RED HAT SATELLITE ENGINEERING
INFO: Processing activation-keys...
INFO: Processing kickstart-scripts...
INFO: Processing system-profiles...
Unknown column [org_id] in report [system-profiles].
INFO: Export-file created at /root/spacewalk-export-dir/spacewalk_export.tar.gz
===

Expected results:

===
~ $ spacewalk-export --org 1
INFO: Processing users...
INFO: Processing system-groups...
INFO: Processing config-files...
INFO: Processing repositories...
INFO: Processing channels...
Processing organization: RED HAT SATELLITE ENGINEERING
INFO: Processing activation-keys...
INFO: Processing kickstart-scripts...
INFO: Processing system-profiles...
INFO: Export-file created at /root/spacewalk-export-dir/spacewalk_export.tar.gz
===

Additional info:

spacewalk-report system-profiles calls it 'organization_id'

Workaround:

  Export system-profiles directly:

  # spacewalk-report --where-organization-id <ID> system-profiles > ~/spacewalk-export-dir/exports/system-profiles.csv

Comment 1 Grant Gainey 2014-10-08 17:49:16 UTC
spacewalk commit 0310f02553ed4475ccedf93746631b2b832fe4a6

Comment 6 Radovan Drazny 2016-08-29 09:56:28 UTC
Reproduced with spacewalk-utils-2.0.2-27 using the reproducer in the initial report. 

# spacewalk-export --org 1
INFO: Processing users...
INFO: Processing system-groups...
INFO: Processing config-files...
INFO: Processing repositories... 
INFO: Processing channels...
Processing organization: Red Hat SatTeam QA
INFO: Processing activation-keys...
INFO: Processing kickstart-scripts...
INFO: Processing system-profiles...
Unknown column [org_id] in report [system-profiles].
INFO: Export-file created at /root/spacewalk-export-dir/spacewalk_export.tar.gz

The file /root/spacewalk-export-dir/exports/system-profiles.csv is empty, and the same file in the /root/spacewalk-export-dir/spacewalk_export.tar.gz archive is empty as well (naturally). 

Updated to spacewalk-utils-2.0.2-28

# spacewalk-export --org 1
INFO: Processing users...
INFO: Processing system-groups...
INFO: Processing config-files...
INFO: Processing repositories...
INFO: Processing channels...
Processing organization: Red Hat SatTeam QA
INFO: Processing activation-keys...
INFO: Processing kickstart-scripts...
INFO: Processing system-profiles...
INFO: Export-file created at /root/spacewalk-export-dir/spacewalk_export.tar.gz

There is no error in the output. Checking the /root/spacewalk-export-dir/exports/system-profiles.csv shows correctly exported csv file, and the /root/spacewalk-export-dir/spacewalk_export.tar.gz archive contains correctly exported file as well. 

VERIFIED

Comment 8 errata-xmlrpc 2016-09-14 12:04:50 UTC
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.

https://rhn.redhat.com/errata/RHBA-2016-1866.html

Comment 9 Tomas Lestach 2017-02-17 08:06:12 UTC
*** Bug 1275207 has been marked as a duplicate of this bug. ***


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