Solved

Change Default LDAP CN on Active Directory users

Posted on 2009-05-07
5
2,022 Views
Last Modified: 2012-06-27
We moved from a Novell NetWare server to a MS Windows Server 2003 AD server recently... users were migrated using a utility by Quest software and everything worked out great - until now.

When the migration utility copied over the users, the CN in an LDAP query was the same as our usernames (FirstInitialLastname) - this is what we wanted because one of the applications we use query via LDAP but does not let us specify which field to query (So we can't force the program to pull sAMAccountName - it only pulls the CN). Again, this has been working fine since the CN is the same as the username... except - all new users... users that weren't on the Novell server, the CN is FirstName LastName.

I looked around on Google and found Adsiedit and it mentioned:
# In the right-hand pane, open the properties for "CN=user-Display".
# Scroll to the createDialog optional property.
# Set the attribute to %<sn>.%<givenName>. Make sure that you click Set.
Note The only tokens that can be formatted in the dislayName are %<sn>, %<givenName>, and %<initials>.

It doesn't let me use %<sAMAccountName > or %<userPrincipalName>.

So how can I do this? How can I make the default CN be the same as the username?

I've seen ADAM mentioned but I haven't looked into it too much. If I made an ADAM server and tied it into our AD database could I "re-arrange" the fields a bit?

Thank you for your time.
0
Comment
Question by:sbrown_cesd
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 15

Expert Comment

by:zelron22
ID: 24329105
When you look at the General tab of a migrated user's properties in AD Users and Computers, what does it show for First Name and Last Name?
0
 
LVL 30

Accepted Solution

by:
LauraEHunterMVP earned 250 total points
ID: 24329107
To my knowledge, you cannot enforce this using only native AD tools like ADSI Edit or AD Users & Computers. You'll need to use either a home-grown or paid provisioning script or tool (roll your own user creation VBScript, Powershell or web page) that will populate CN automatically using the same value as sAMAccountName. Unfortunately, native string validation functionality within AD is somewhat limited, as you're discovering.
0
 

Author Comment

by:sbrown_cesd
ID: 24329230
zelron22:
Username: sbrown
First Name: Scott
Last Name: Brown
Display Name: Scott Brown
CN= sbrown

LauraEHunterMVP:
I was afraid of that... I saw some scripts online - I might have to play with those on a test domain controller (don't want to accidentally wipe out my server :-) )
0
 
LVL 30

Expert Comment

by:LauraEHunterMVP
ID: 24329271
Thing with AD is that it's really good at publishing information and replicating it everywhere. It's really not good at (nor was it intended to be good at) enforcing "business rules" such as the proper way to format a telephone number or the name of a city, etc.
0
 
LVL 15

Expert Comment

by:zelron22
ID: 24329608
Holy moly Ms. Hunter, you've got more credentials than I've got [insert lame joke here].
0

Featured Post

Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A project that enables an administrator to perform actions within a user session context not just at the time of login but any time later on day(s) or week(s) later.
Auditing domain password hashes is a commonly overlooked but critical requirement to ensuring secure passwords practices are followed. Methods exist to extract hashes directly for a live domain however this article describes a process to extract u…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…

624 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question