New DS built-in tools for Windows Server 2003
You really are spoilt for choice when it comes to scripting tools for creating
Active Directory objects. In addition to CSVDE, LDIFDE and VBScript, we
now have the following DS commands:
The DS family of built-in utilities
Adding objects is great, but there are times in Windows 2003 when you need
to change the Active Directory properties.
Scenario, you wish to quickly change a user's password. This is task
you are going to have to do regularly, and you would like to able to do it
quickly from the command line. Let us now modify the the user's password with DSmod
Preparation:
Example 1 Modify Password
Logon to your domain controller. Check which users you have, if
necessary create an ou called guyds and user called guyt.
See DSadd
Examine the script below. Decide how cn= or ou= or dc= need editing.
Run, CMD then copy your script and paste into the command window.
Alternatively type it starting with dsmod user .........
dsmod user "cn=guyt, ou=guyds, dc=cp, dc=com" -pwd a1yC24kg
Example 2 Create user WITH password
Note 1: We could have created the password at the same time
we created the user. For ease of learning I introduce one variable at a time.
However, here is the complete command to add a user with a password.
dsadd user "cn=pault, ou=guyds, dc=cp, dc=com" -pwd a1yC24kg
Example 3 Modify Groups
Another use of DSmod is to add members to a group.
In this instance you need the full distinguished name (DN) of the group then
the -addmbr switch followed by the DN of the users. Tricky method!
Try dsmod group /? for more help.
Problems contact Guy Thomas see below for email address
See Also
|