Microsoft KB Archive/125996

= Saving and restoring existing Windows shares =

Article ID: 125996

Article Last Modified on 2/20/2007

-

APPLIES TO


 * Microsoft Windows Server 2003, Datacenter Edition (32-bit x86)
 * Microsoft Windows Server 2003, Enterprise Edition (32-bit x86)
 * Microsoft Windows Server 2003, Standard Edition (32-bit x86)
 * Microsoft Windows Server 2003, Web Edition
 * Microsoft Windows 2000 Server
 * Microsoft Windows 2000 Advanced Server
 * Microsoft Windows 2000 Professional Edition
 * Microsoft Windows 2000 Datacenter Server
 * Microsoft Windows NT Advanced Server 3.1
 * Microsoft Windows NT Server 3.5
 * Microsoft Windows NT Server 3.51
 * Microsoft Windows NT Server 4.0 Standard Edition
 * Microsoft Windows NT Workstation 3.1
 * Microsoft Windows NT Workstation 3.5
 * Microsoft Windows NT Workstation 3.51
 * Microsoft Windows NT Workstation 4.0 Developer Edition
 * Microsoft Windows NT Advanced Server 3.1

-



This article was previously published under Q125996



Important This article contains information about how to modify the registry. Make sure to back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows registry



SUMMARY
If you need to complete any of the following procedures, you can save the share names that exist on the original Microsoft Windows installation, including any permissions assigned to those shares:
 * Reinstall Windows over an existing installation (a clean install, not an upgrade).
 * Move all of your data drives from one server to another.
 * Install Windows to another folder or drive on a computer that already has Windows installed.



MORE INFORMATION
Warning Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall your operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

To save only the existing share names and their permissions on Windows follow these steps.

Note This procedure applies only to NetBIOS shares and not to Macintosh volumes.  On the existing Windows installation that contains the share names and permissions that you want to save, start Registry Editor (Regedt32.exe). From the HKEY_LOCAL_MACHINE subtree, go to the following key:

SYSTEM\CurrentControlSet\Services\LanmanServer\Shares

 Save or export the registry key.  For Windows NT and Windows 2000, click Save Key on the Registry menu. For Windows Server 2003, click Export on the File menu. </li> Type a new file name (a file extension is not necessary), and then save the file to a floppy disk.</li> Reinstall Windows.</li> Run Registry Editor (Regedt32.exe).</li> From the HKEY_LOCAL_MACHINE subtree, go to the following key:

SYSTEM\CurrentControlSet\Services\LanmanServer\Shares

</li> Restore or import the registry key.  For Windows NT and Windows 2000, click Restore on the Registry menu.</li> For Windows Server 2003, click Import on the File menu.</li></ul> </li> Type the path and file name of the file that you saved in steps 3 and 4.

Caution This step overrides the shares that already exist on the Windows computer with the share names and permissions that exist in the file you are restoring. You are warned about this before you restore the key.</li> Restart the server.</li></ol>

Note After you complete this procedure, if you decide that you should not have restored the Shares key, restart the computer and press the SPACEBAR to use the last known good configuration. After you restore the shares key, the shares can be used by network clients. If you run the net shares command on the server, the server displays the shares; however, File Manager does not display the shares. To make File Manager aware of the newly restored shares, create any new share on the server. File Manager displays all of the other shares after you restart the server or stop and restart the Server service.

In Windows NT 3.5, if you click Stop Sharing in File Manager, the restored shares are still displayed, but they are dimmed.

Only permissions for domain users are restored. If a local user was created in the previous Windows NT installation, that local user's unique security identifier (SID) is lost. NTFS permissions on folders and files are not affected when you save and restore the shares key.

Additional query words: migrate

Keywords: kbinfo KB125996

-

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

© Microsoft Corporation. All rights reserved.