Microsoft KB Archive/295622

= How to Create a Share Remotely By Using the Windows Management Instrumentation Command-Line Tool =

Article ID: 295622

Article Last Modified on 12/3/2007

-

APPLIES TO


 * Microsoft Windows Server 2003, Standard Edition (32-bit x86)
 * Microsoft Windows Small Business Server 2003 Premium Edition
 * Microsoft Windows Small Business Server 2003 Standard Edition

-



This article was previously published under Q295622



SUMMARY
This article describes how to create a share on a remote computer by using the Windows Management Instrumentation Command-Line tool (WMIC).



MORE INFORMATION
Note: To use this feature, you must have administrative permissions, and the folder that you want to share must already exist on the target computer.

You can access Windows Management Instrumention (WMI) by using WMIC. Although you can share an existing folder, you cannot set the permissions on the share directly from WMIC.

To create a share on a remote computer by using WMIC:  At a command prompt, type wmic, and then press ENTER. Type /node: where  is the name of the target computer. If you want to pass administrator credentials, type /user:&quot;domain\username&quot;, to receive a prompt for a password. Type the following line where  is the path to the folder that you want to share:

share call create &quot;&quot;, &quot;this is the comments section&quot;, &quot;maximum number of connections&quot;, &quot;this is the share name&quot;, &quot;&quot;, &quot;C:\test&quot;, 0



For additional information, click the article numbers below to view the articles in the Microsoft Knowledge Base:

290216 A Description of the WMI Command-Line Utility

295292 How to Set WMI Namespace Security

