Microsoft KB Archive/318751

= HOW TO: Remove Administrative Shares in Windows 2000 or Windows NT 4.0 =

PSS ID Number: 318751

Article Last Modified on 9/22/2003

-

The information in this article applies to:


 * Microsoft Windows 2000 Server
 * Microsoft Windows 2000 Advanced Server
 * Microsoft Windows 2000 Datacenter Server
 * Microsoft Windows NT Server 4.0
 * Microsoft Windows NT Server 4.0 Terminal Server Edition
 * Microsoft Windows NT Server, Enterprise Edition 4.0

-



This article was previously published under Q318751



For a Microsoft Windows XP Professional, Windows 2000 Professional, and Windows NT 4.0 Workstation version of this article, see 314984.IMPORTANT: This article contains information about modifying the registry. Before you modify the registry, make sure to back it up and make sure that you understand how to restore the registry if a problem occurs. For information about how to back up, restore, and edit the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows Registry

IN THIS TASK

 * SUMMARY
 * Remove Administrative Shares by Using Poledit
 * Remove Administrative Shares by Using Registry Editor
 * REFERENCES



SUMMARY
This step-by-step article describes how to remove the default administrative shares, and prevent them from being automatically created.

The default administration shares are designated by the logical drive names that you have on the computer, for example, the root folder of drive C is C$. You can turn off the automatic creation of the administrative shares by using either Registry Editor or Poledit.exe. Note that these methods do not remove the IPC$ share or existing shares that have been manually created.

CAUTION: Do not remove the Administrative Shares if your organization is using Microsoft Systems Management Server (SMS), or Microsoft Operations Manager (MOM).

SMS and MOM both rely on access to all default administrative shares on client and server computers to function correctly. For additional information about the security requirements for SMS and MOM, click the article numbers below to view the articles in the Microsoft Knowledge Base:

304685 Description of Security Rights for Microsoft Operations Manager 2000

122988 SMS Installation Incomplete with Missing Admin Drive Share

168518 SMS: Troubleshooting SMS Windows NT Client Services Installation

back to the top

Remove Administrative Shares by Using Poledit

 * 1) Click Start, click Run, type poledit in the Open box, and then click OK.
 * 2) On the File menu, click Open Registry.
 * 3) Double-click Local Computer.
 * 4) Expand Windows NT Network, and then expand Sharing (Server).
 * 5) Click to clear the Create Hidden Drive Shares (Server) check box, and then click OK.
 * 6) On the File menu, click Save.

NOTE: Poledit.exe is provided with the Windows 2000 Administration Tools. To install the Windows 2000 Administration Tools (including Poledit.exe), open the I386 folder on the applicable Windows 2000 Server CD-ROM, and then double-click the Adminpak.msi file. Follow the instructions that appear in the Windows 2000 Administration Tools Setup Wizard.

back to the top

Remove Administrative Shares by Using Registry Editor
WARNING: If you use Registry Editor incorrectly, you may cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that you can solve problems that result from using Registry Editor incorrectly. Use Registry Editor at your own risk.

You can remove automatic creation of the administrative shares by using Registry Editor. By using this method, you must make sure that the Group Policy does not restore this entry after you set it. For more information, see the &quot;Remove Administrative Shares by Using Poledit&quot; section of this article.

To remove automatic creation of the administrative shares by using Registry Editor:  Start Registry Editor (Regedt32.exe). Locate and then click the following key in the registry:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters\AutoShareServer

 Change the value of the AutoShareServer key to zero (0).

NOTE: A setting of zero (0) prevents the administrative shares, such as C$, D$, and Admin$ from being created automatically. Quit Registry Editor.

NOTE: If the AutoShareServer key does not exist, create the AutoShareServer key by using the following steps:  Locate and then click the following key in the registry:

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanServer\Parameters

 On the Edit menu, click Add Value.</li> Type AutoShareServer, click REG_DWORD, and then click OK.</li> Type 0, and then click OK.</li> Quit Registry Editor, and then restart the computer.</li></ol>

You can easily complete this process through a policy. For more information, see the &quot;Remove Administrative Shares by Using Poledit&quot; section of this article.

back to the top

<div class="references_section">