Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 768510

Summary: migrate-ds : misleading error message when invalid objectclass defined
Product: Red Hat Enterprise Linux 6 Reporter: Jenny Severance <jgalipea>
Component: ipaAssignee: Rob Crittenden <rcritten>
Status: CLOSED ERRATA QA Contact: Namita Soman <nsoman>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.2CC: mkosek
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ipa-3.0.0-1.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-21 09:08:57 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:

Description Jenny Severance 2011-12-16 20:40:46 UTC
Description of problem:

If you define the correct user/group container but an invalid objectclass for the migrate-ds command, you get the following error ....

ipa: ERROR: Container for user not found  
  OR
ipa: ERROR: Container for group not found

This is confusing as the container is not the problem.

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ds-migration-cmd-004 Invalid User Object Class
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [15:32:55] ::  EXECUTING: ipa migrate-ds --user-container="ou=People" --group-container="ou=groups" --user-objectclass=badclass ldap://dhcp-185-164.testrelm:389
ipa: ERROR: Container for user not found
:: [   PASS   ] :: Check return code
:: [   FAIL   ] :: File '/tmp/error.out' should contain 'ipa: ERROR: Objectclass for user not found' 

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ds-migration-cmd-005 Invalid Group Object Class
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [15:32:59] ::  EXECUTING: ipa migrate-ds --user-container="ou=People" --group-container="ou=groups" --group-objectclass=badclass ldap://dhcp-185-164.testrelm:389
ipa: ERROR: Container for group not found
:: [   PASS   ] :: Check return code
:: [   FAIL   ] :: File '/tmp/error.out' should contain 'ipa: ERROR: Objectclass for group not found' 


Version-Release number of selected component (if applicable):
ipa-server-2.1.3-9

How reproducible:
always

Steps to Reproduce:
1.  These tests are automated and will be verified when tests are passing.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Dmitri Pal 2011-12-16 20:50:29 UTC
Upstream ticket:
https://fedorahosted.org/freeipa/ticket/2206

Comment 2 Martin Kosek 2012-06-05 06:54:46 UTC
Fixed upstream:
master: https://fedorahosted.org/freeipa/changeset/d31f0c2d330488e6b351f36d5a8f4f0affda935b

We cannot verify that the object class is right, user may use any custom object classes for the remote LDAP search.

What we did is that the error message now does not mention the container specifically, but is more general and includes the remote LDAP search attributes which should help user discover the error.

Comment 5 Jenny Severance 2013-01-14 17:47:53 UTC
verified ::

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ds-migration-cmd-004 Invalid User Object Class
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: EXECUTING: ipa migrate-ds --user-container="ou=People" --group-container="ou=groups" --user-objectclass=badclass ldap://qe-blade-13.testrelm.com:389
:: [   PASS   ] :: Check return code
:: [   PASS   ] :: File '/tmp/error.out' should contain 'ipa: ERROR: user LDAP search did not return any result (search base: ou=People,dc=example,dc=com, objectclass: badclass)'
:: [   LOG    ] :: Related Bugzilla :: https://bugzilla.redhat.com/show_bug.cgi?id=768510
:: [   LOG    ] :: Duration: 3s
:: [   LOG    ] :: Assertions: 2 good, 0 bad
:: [   PASS   ] :: RESULT: ds-migration-cmd-004 Invalid User Object Class

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ds-migration-cmd-005 Invalid Group Object Class
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: EXECUTING: ipa migrate-ds --user-container="ou=People" --group-container="ou=groups" --group-objectclass=badclass ldap://qe-blade-13.testrelm.com:389
:: [   PASS   ] :: Check return code
:: [   PASS   ] :: File '/tmp/error.out' should contain 'ipa: ERROR: group LDAP search did not return any result (search base: ou=groups,dc=example,dc=com, objectclass: badclass)'
:: [   LOG    ] :: Related Bugzilla :: https://bugzilla.redhat.com/show_bug.cgi?id=768510
:: [   LOG    ] :: Duration: 3s
:: [   LOG    ] :: Assertions: 2 good, 0 bad
:: [   PASS   ] :: RESULT: ds-migration-cmd-005 Invalid Group Object Class

version :: ipa-server-3.0.0-21.el6

Comment 7 errata-xmlrpc 2013-02-21 09:08:57 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.

http://rhn.redhat.com/errata/RHSA-2013-0528.html