How to Disable LMHOSTS Lookup During an Unattended Installation

Last reviewed: December 10, 1997
Article ID: Q177932
The information in this article applies to:
  • Microsoft Windows NT Workstation version 4.0
  • Microsoft Windows NT Server version 4.0
  • Microsoft Windows NT Server Enterprise Edition version 4.0

SUMMARY

NetBIOS name resolution using the LMHOSTS file is enabled by default during Windows NT installation. You may want to configure Windows NT unattended Setup so that LMHOSTS lookup is disabled. This article describes how to disable LMHOSTS lookup during a Windows NT 4.0 unattended Setup.

MORE INFORMATION

To disable LMHOSTS lookup during unattended Setup, follow these steps:

  1. Create a new share on a network server and then copy the I386 folder (or appropriate platform folder) from the Windows NT 4.0 CD-ROM to the new share.

  2. Using any text editor (such as Notepad), add the following entry to the [Unattended] section of the Unattend.txt file:

          OEMPreinstall = Yes
    

  3. Save and then close the Unattend.txt file.

  4. Create a new folder named $OEM$ in the share you created in step 1.

  5. In the $OEM$ folder, create a file with the following entries. Save the file as <filename>.reg, where <filename> is your choice of names (for example, Mychange.reg):

          REGEDIT4
    

          [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\NetBT\
    
             Parameters]
          "EnableLMHOSTS"=dword:00000000
    
       NOTE: These lines should be continuous. They are wrapped and indented
       for ease of readability.
    
    

  6. In the $OEM$ folder, create a file named Cmdlines.txt. This file should contain the following entries, including the quotation marks surrounding the entry

          [Commands]
          "Regedit.exe /s .\<filename>.reg"
    

    where <filename> is the name of the registry file you created in the previous step.

  7. Copy the Regedit.exe file from the share you created in step 1 to the $OEM$ folder.

  8. Run Windows NT 4.0 Setup in Unattended mode using the Unattend.txt file. For example, use the following command

          winnt /u:unattend.txt /s:<sourcefiles>
    

    where <sourcefiles> is the location of the shared folder you created in step 1.

For additional information about parameters for the Unattend.txt file, please see the following article in the Microsoft Knowledge Base:

   ARTICLE-ID: Q155197
   TITLE     : Unattended Setup Parameters for Unattend.txt File


Additional query words: unc tcpip wins 4.00
Keywords : ntsetup NTSrvWkst
Version : WINNT:4.0
Platform : winnt
Issue type : kbhowto


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: December 10, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.