Archive

Archive for April 9th, 2008

Windows 2003 Server Command line tools

April 9th, 2008 1 comment

[ad#ad-4]
The day-to-day routine maintenance in a Windows Server 2003 based network, can be made much easier by knowing which command line tools are available for you. Here is a list of which commands I find particularly helpful. Base OS Tools: These useful command line tools come with the base Windows 2003 server install:

  • DSadd: Quickly objects to AD, can be used to create User accounts, OUs, Computer accounts, Groups and Contacts
  • DSmod: Modify existing AD objects
  • DSrm: Delete AD objects
  • DSmove: Move an object from its current location to a new location
  • DSQuery: Query AD according to specified criteria
  • DCgpofix: Restore default domain policy and default domain controllers policy.
  • Read more…

Categories: Tutorial, Windows Server Tags:

Create User with VB Script

April 9th, 2008 No comments

[ad#ad-4]
This is a sample working code to create users in bulk by reading a text file
containing list of users (each line of text file contain name of a user):

It requires text file as command line argument.
‘———-
strComputer = “.” ‘local computer
set objArgs = wscript.arguments

if objArgs.count <> 1 then
wscript.echo “Usage: ” & wscript.scriptFullName & ”
<text_file_containing_user_names>”
wscript.quit
end if
strServerListFile=objArgs(0)
set fs = CreateObject(“Scripting.FileSystemObject”)
if NOT fs.fileExists(strServerListFile) then
wscript.echo “Text file containing User list not found.”
wscript.quit Read more…

Categories: Windows Server Tags: