Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Help with adding new AD user via dsadd

Status
Not open for further replies.

chiefbootkncoker

IS-IT--Management
Aug 3, 2009
1
US
Hello,

I have created a BAT to add a new user to AD, and it works (somewhat) below is the contents of that BAT.


dsadd user cn=AidenWilson,ou=DomainUsers,dc=domain01,dc=ADC01 -upn awilson@domain01.ADC01 -display Aiden -fn Aiden -ln Wilson -pwd Password1 -mustchpwd yes -memberof cn=DomainUsers,ou=DomainUsers,dc=domain01,dc=ADC01
pause



The result of the BAT gives me the AD user AidenWilson, and I want that, but I want the user logon to be awilson. When I look at the account tab for Aiden's AD account is says awilson, but the Windows logon (pre-Windows 2000) says AidenWilson, and that is the user name that works for logon. I'm kinda pointed to the Windows logon (pre-Windows 2000)as being my problem as logins I have created manually have matching credentials, but I'm not sure what I need to do to fix my BAT....anyone that has ideas I would love to hear them. Thank You.
 
Add the following switch to the batch file:

-samid awilson

Joey
CCNA, MCSA 2003, MCP, A+, Network+, Wireless#
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top