Microsoft KB Archive/154760

= How to Use the DSMN Utility to Verify Synchronized Passwords =

Article ID: 154760

Article Last Modified on 11/1/2006

-

APPLIES TO


 * Microsoft Windows NT Workstation 3.51
 * Microsoft Windows NT Workstation 4.0 Developer Edition
 * Microsoft Windows NT Server 3.51
 * Microsoft Windows NT Server 4.0 Standard Edition

-



This article was previously published under Q154760



SUMMARY
The Directory Service Manager for NetWare (DSMN) compact disc includes Dsmchk.exe, a new utility for testing password synchronization. Dsmchk.exe checks one or more NetWare servers in the domain and compares the user's password on each NetWare server to the user's password on the primary domain controller. To automate the testing of each user's password, you can call Dsmchk.exe from the user's logon script. This article explains how to use Dsmchk.exe.

NOTE: To use Dsmchk.exe, the primary domain controller must be running Windows NT Server 4.0.



Syntax for Dsmchk.exe
The syntax for Dsmchk.exe is:

  dsmchk -d -u [-n ] [-r : ]

where

-d             Specifies the domain in which to verify password synchronization.

-u           Specifies the user account.

-n            Specifies the name of a NetWare server with which to verify password synchronization. If                           you don't specify a server, the default is all NetWare servers in the domain.

-r : Specifies a number of retries and the interval, in seconds, between retries.

Error Levels of Dsmchk.exe
Dsmchk.exe reports the user's password situation with the following error levels:

  0 The password is synchronized across the specified NetWare server(s) and the primary domain controller.

1 The password is not synchronized.

2 The NetWare server is unknown or not administered by DSMN.

3 The domain name is unknown.

4 The user account name is unknown or not administered by DSMN.

5 The user account name is not administered between the primary domain controller and the NetWare server.

Using Dsmchk.exe
You can run Dsmchk.exe with the Dsmchk files (Swclnt.dll and Msvcrt.dll; Msvcrt.dll is only needed by Windows NT 3.51 clients), based on either the server or the client computers.

To run Dsmchk.exe using files on the server:

  Create directories for each processor type (I386, Alpha, MIPS, and/or PPC) in the %Systemroot%\System32\Repl\Import\Scripts directory.

For example, if the %Systemroot% is C:\Winnt and you have clients with x86 and Alpha processors, create the following directories:

 c:\Winnt\System32\Repl\Import\Scripts\I386 c:\Winnt\System32\Repl\Import\Scripts\Alpha   Expand and copy the appropriate Dsmchk.exe and Swclnt.dll files from the FPNW/DSMN compact disc to each directory. Continuing the example from step 1, and assuming that the CD-ROM drive is drive D, type the following from a command prompt:

 expand d:\Dsmn\Nt40\I386\Dsmchk.ex_ c:\Winnt\System32\Repl\Import\Scripts\I386\Dsmchk.exe

expand d:\Dsmn\Nt40\I386\Swclnt.dl_ c:\Winnt\System32\Repl\Import\Scripts\I386\Swclnt.dll

expand d:\Dsmn\Nt40\Alpha\Dsmchk.ex_ c:\Winnt\System32\Repl\Import\Scripts\Alpha\Dsmchk.exe

expand d:\Dsmn\Nt40\Alpha\Swclnt.dl_ c:\Winnt\System32\Repl\Import\Scripts\Alpha\Swclnt.dll NOTE: Each of the indented lines in the example is a continuation of the line above; you should type the entire command on one line.   If any of the clients run Windows NT Workstation 3.51, copy Msvcrt.dll from the Windows NT Server 4.0 %Systemroot%\System32 directory to each Dsmchk directory. Continuing the example from the previous steps, type:

 copy c:\Winnt\System32\Msvcrt.dll c:\Winnt\System32\Repl\Import\Scripts\I386

copy c:\Winnt\System32\Msvcrt.dll c:\Winnt\System32\Repl\Import\Scripts\Alpha NOTE: Each of the indented lines in the example is a continuation of the line above; you should type the entire command on one line. </li></ol>

After you have copied these files, a Windows NT 4.0 client can run Dsmchk.exe simply by using the path of the Dsmchk.exe file on the server.

To run Dsmchk.exe using files on the client:

- Copy the Dsmchk.exe and Swclnt.dll files (and Msvcrt.dll if you are using a Windows NT 3.51 client) for the client's processor type to the client's %Systemroot%\System32 directory.

For example, from the client's command prompt, type:

copy \\server\netlogon\i386\*.* c:\winnt\system32

When you copy the files to the client, the client can use Dsmchk.exe without referencing a path on a server.

Using Dsmchk.exe in a Logon Script
You can use Dsmchk.exe in a logon script whether the files are installed on a server or on the client. For example, you can insert the following commands in a logon script to test the user's password synchronization:

<pre class="fixed_text">  :TEST_USER \\DSMNsrvr\netlogon\i386\dsmchk -d domain2 -u myname -n NWserver -r 4:30 @ECHO OFF

IF ERRORLEVEL 5 GOTO   USER_NOT_PROPED IF ERRORLEVEL 4 GOTO   USER_NOT_DSMN IF ERRORLEVEL 3 GOTO   DOMAIN_NOT_DSMN IF ERRORLEVEL 2 GOTO   SVR_NOT_IN_DSMN IF ERRORLEVEL 1 GOTO   SVR_NOT_IN_SYNC IF ERRORLEVEL 0 GOTO   ALL_IN_SYNC

ECHO The servers are synchronized. GOTO DONE

ECHO The servers are not synchronized. Rechecking. ..

sleep 30 \\DSMNsrvr\netlogon\i386\dsmchk -d domain2 -u myname -n NWserver -r 1:30 IF ERRORLEVEL 1 GOTO TEST_USER GOTO DONE

ECHO The NetWare server is unknown or not administered by DSMN. GOTO DONE

ECHO The domain name is unknown. GOTO DONE

ECHO The user account name is unknown or not administered by DSMN. GOTO DONE

ECHO The user account name is not administered between the primary ECHO Domain controller and the NetWare server. GOTO DONE



Additional query words: prodnt

Keywords: kb3rdparty kbhowto kbnetwork kbusage KB154760

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.