Whilst I expect you want to use LDIFDE to import users into Active Directory,
I suggest that you start with LDIFDE export. My reasoning is this, LDIFDE
is a difficult command to master, however, the export switch is far easier to
learn than the import. In addition there is less scope for damaging Active Directory when you are exporting. Assuming then that you have some
experience - or you are a faster learner - let us master LDIFDE import.
The key switch is -i without this tiny -i switch (Lower case I), LDIFDE will just
export information or raise an error message. To master importing user
accounts, you must understand the LDAP attributes. Also you need 'Active Directory Users and Computer'
available for inspecting the users' properties.
Once you have written all the data in your .ldf file then
just import the data with a command like this:
ldifde -i -f accounts.ldf -s BigServer
1. Using
LDIFDE to Add a New User
In this example, you use LDIFDE to add a new user named Guy Thomas to the Training
organizational unit.
Start Notepad, and create a new file called Newuser.ldf. (Save the file as with
an .ldf extension.)
(Note you will need to substitute the information for your domain!)
Edit the LDIF file Newuser.ldf, and add the following text :
dn: CN=GuyThomas, OU=Training, DC=computerperformance, DC=com
changetype: add
cn: Guy Thomas
objectClass: user
samAccountName: Guy
givenName: Guy
sn: Thomas
Save the LDIF file.
Run LDIFDE to import the new user into Active Directory. Open a 'dos box',
start run, CMD, then type the following command, and then press Enter. ldifde -i -f newuser.ldf -s BigServer
To confirm that the new user has been created, check your Active Directory users
and computers snap-in.
Once you have mastered adding users, then experiment with modifying existing
attributes, this is the main advantage of LDIFDE over CSVDE.
The key is the 'changetype: ' command in the data file. The three possible
commands are add, modify, and delete.
Changing the password is very difficult. Below is an example but you
really need more details from your eBook to master the 'unicodePwd' syntax.
Import users from a spreadsheet. Just provide a list of the
users with their fields in the
top row, and save as .csv file. Then launch this FREE utility and match
your fields with AD's
attributes, click and import the users. Optionally, you can
provide the name of the OU where the new accounts will be born.
There are also two bonus tools in the free download, and all 3 have been approved by Microsoft:
Save hours of frustration and buy Guy's
eBook. The extra features include: detailed instructions on how to
add and modify user accounts. Worked LDIFDE examples on changetype:
and unicodePwd.
You get a printer friendly version with copy
enabled, and no expiry date.
*
Custom Search
Guy Recommends: WMI Monitor and It's Free!
Windows Management Instrumentation (WMI) is one of the hidden
treasures of Microsoft operating systems.
Fortunately, Solarwinds
have created the
Free WMI Monitor so that you can actually see and understand these gems of
performance information. Take the guess work out of which
WMI counters to use for applications like Microsoft Active Directory,
SQL or Exchange Server.