Skip to main content
13-Aquamarine
September 22, 2015
Solved

Unable to Load Users to Group with LoadFromFile

  • September 22, 2015
  • 1 reply
  • 7457 views

10.1 M040

I am trying to load EnterpriseLDAP users to an existing Org level group.  The group DN is "cn=steelcase external,cn=public,o=steelcase
inc.,ou=people,cn=administrativeldap,cn=windchill_9.1,o=steelcase inc." and am using the command UserGroup.  However I keep getting the below error.  How can I get UserGroup to search higher up the tree in the local LDAP?

2015-09-22 08:20:18,284 INFO  [RMI TCP
Connection(342)-10.80.96.61] wt.system.out wcadmin - Error detected in
createUserGroup <ABURGESS/Steelcase External>

2015-09-22 08:20:18,285 ERROR [RMI TCP
Connection(342)-10.80.96.61] wt.org.LoadPrincipal wcadmin -

  1. wt.util.WTException: No principal was found for the dn:
    cn=Steelcase
    External,ou=people,cn=AdministrativeLdap,cn=Windchill_9.1,o=Steelcase Inc.

              
at wt.org.LoadPrincipal.validatePrincipalFoundByDN(LoadPrincipal.java:1254)

              
at wt.org.LoadPrincipal.addMemberByDN(LoadPrincipal.java:1245)

Best answer by LoriSood

Hi Patrick,

I worked on C12755759 with Mike Genovese today and I think we may have figured out the problem in this case. The full MS log you provided for the case yielded some clues.

Your MS log shows the following:

2015-09-22 07:02:43,500 INFO  [RMI TCP Connection(165)-10.80.96.61] wt.system.out  - Getting container path= ''

2015-09-22 07:02:43,500 INFO  [RMI TCP Connection(165)-10.80.96.61] wt.system.out  - ERROR: Container path not set for this file, contact the author of the loadFile

2015-09-22 07:02:43,500 INFO  [RMI TCP Connection(165)-10.80.96.61] wt.system.out  - FIX THE LOAD FILE SET!

2015-09-22 07:02:43,500 INFO  [RMI TCP Connection(165)-10.80.96.61] wt.system.out  - Using the Windchill PDM container. If it doesn't exist will use the exchange instead.

2015-09-22 07:02:43,500 INFO  [RMI TCP Connection(165)-10.80.96.61] wt.system.out  - Could not find Windchill PDM container, using exchange instead

2015-09-22 07:02:43,501 INFO  [RMI TCP Connection(165)-10.80.96.61] wt.system.out wcadmin - Using container with path= '/'

The lines in red indicate that the file is getting loaded into the Site level context. Since the Steelcase External group is an org-level group it can't find the group and is erroring out. You need to specify a CONT_PATH value pointing to the organization where the group exists in the LoadFromFile command.

We tested this out in-house with a group that is also defined in the AdministrativeLdap under the cn=Public... area and got similar results to what you were seeing when CONT_PATH was not specified. It worked if CONT_PATH pointed to the organization where the group existed:

9-29-2015 5-15-24 PM.png

We used the following XML:

<?xml version="1.0" ?><!DOCTYPE NmLoader SYSTEM "standardX20.dtd">

<NmLoader>

<csvUserGroup handler="wt.load.LoadUser.createUserGroup" >

    <csvuser></csvuser>

    <csvgroupName>AAAA</csvgroupName>

    <csvgroupNameDirectoryService></csvgroupNameDirectoryService>

    <csvuserName>ptcuser</csvuserName>

    <csvuserNameDirectoryService></csvuserNameDirectoryService>

    <csvDirectoryService></csvDirectoryService>

</csvUserGroup>

</NmLoader>

Also tried this with the same result:

<?xml version="1.0" ?><!DOCTYPE NmLoader SYSTEM "standardX20.dtd">

<NmLoader>

<csvUserGroup handler="wt.load.LoadUser.createUserGroup" >

    <csvuser></csvuser>

    <csvgroupName>AAAA</csvgroupName>

    <csvgroupNameDirectoryService>com.ptcts.Ldap</csvgroupNameDirectoryService>

    <csvuserName>wcadmin</csvuserName>

    <csvuserNameDirectoryService></csvuserNameDirectoryService>

    <csvDirectoryService></csvDirectoryService>

</csvUserGroup>

</NmLoader>

We then used the following command to successfully load the file:

windchill wt.load.LoadFromFile -d Add_Group_Principals.xml -u wcadmin -p wcadmin -CONT_PATH \"/wt.inf.container.OrgContainer=PTC\"


I think if you update your loadFromFile command to specify the CONT_PATH to point to your organization then the load will be successful.

1 reply

17-Peridot
September 22, 2015

Could you add the xml or the csv?

13-Aquamarine
September 22, 2015
UserGroupSteelcase
  External
ABURGESS
13-Aquamarine
September 22, 2015

sorry this is the one I tried.

UserGroup,,Steelcase External,com.steelcase.Ldap,ABURGESS,com.steelcase.EnterpriseLdap,