Creates a new stand-alone Distributed File System (DFS) namespace.
Syntax
NET_API_STATUS NetDfsAddStdRoot(
__in LPWSTR ServerName,
__in LPWSTR RootShare,
__in_opt LPWSTR Comment,
__in DWORD Flags
);
Parameters
- ServerName [in]
-
Pointer to a string that specifies the name of the server that will host the new stand-alone DFS namespace. This parameter is required.
- RootShare [in]
-
Pointer to a string that specifies the name of the shared folder for the new stand-alone DFS namespace on the server that will host the namespace. This parameter is required.
- Comment [in, optional]
-
Pointer to a string that contains an optional comment associated with the DFS namespace.
- Flags [in]
-
This parameter is reserved and must be zero.
Return Value
If the function succeeds, the return value is NERR_Success.
If the function fails, the return value is a system error code. For a list of error codes, see
System Error Codes.
Remarks
The share specified by the RootShare parameter must already exist on the server that will host the new DFS root target. This function does not create a new share.
The caller must have Administrator privilege on the DFS server. For more information about calling functions that require administrator privileges, see
Running with Special Privileges.
Requirements
| Minimum supported client | Windows 2000 Professional |
| Minimum supported server | Windows 2000 Server |
| Header | LmDfs.h (include LmDfs.h or Lm.h) |
| Library | Netapi32.lib |
| DLL | Netapi32.dll |
See Also
- Network Management
Overview
- Network
Management Functions
- Distributed File System (DFS) Functions
- NetDfsAddFtRoot
- NetDfsAddRootTarget
- NetDfsRemoveStdRoot
Send comments about this topic to Microsoft
Build date: 11/12/2009