The Win32 Network Management APIs 3

 

 

 

 

 

Distributed File System (DFS) Functions

 

The Distributed File System (DFS) functions provide the ability to logically group shares on multiple servers and to transparently link shares into a single hierarchical namespace. DFS organizes shared resources on a network in a treelike structure. DFS supports stand-alone DFS namespaces, those with one host server, and domain-based namespaces that have multiple host servers and high availability. The DFS topology data for domain-based namespaces is stored in Active Directory. The data includes the DFS root, DFS links, and DFS targets. Each DFS tree structure has one or more root targets. The root target is a host server that runs the DFS service. A DFS tree structure can contain one or more DFS links. Each DFS link points to one or more shared folders on the network. You can add, modify and delete DFS links from a DFS namespace. When you remove the last target associated with a DFS link, DFS deletes the DFS link in the DFS namespace. (In earlier documentation, DFS links were called junction points.)

A DFS link can point to one or more shared folders; the folders are called targets. When users access a DFS link, the DFS server selects a set of targets based on a client's site information. The client accesses the first available target in the set. This helps to distribute client requests across the possible targets and can provide continued accessibility for users even when some servers fail. An application can use the DFS functions to:

 

  1. Add a DFS link to a DFS root.
  2. Create or remove stand-alone and domain-based DFS namespaces.
  3. Add targets to an existing DFS link.
  4. Remove a DFS link from a DFS root.
  5. Remove a target from a DFS link.
  6. View and configure information about DFS roots and links.

 

Targets on computers that are running Microsoft Windows can be published in a DFS namespace. You can also publish any non-Microsoft shares for which client redirectors are available in a DFS namespace. However, unlike a share that is published on a server that is running Windows Server, they cannot host a DFS root or provide referrals to other DFS targets. DFS uses the Windows Server file replication service to copy changes between replicated targets. Users can modify files stored on one target, and the file replication service propagates the changes to the other designated targets. The service preserves the most recent change to a document or files.

 

DFS Functions List

 

The following are the Distributed File System (DFS) functions.

 

Function

Description

NetDfsAdd()

Creates a DFS link or adds targets to an existing link in a DFS namespace.

NetDfsAddFtRoot()

Creates a domain-based DFS namespace. If the namespace already exists, the function adds the specified root target to it.

NetDfsAddRootTarget()

Creates a domain-based or stand-alone DFS namespace or adds a new root target to an existing domain-based namespace.

NetDfsAddStdRoot()

Creates a stand-alone DFS namespace.

NetDfsEnum()

Enumerates the DFS namespaces hosted on a server or DFS links of a namespace hosted by a server.

NetDfsGetClientInfo()

Retrieves information about a DFS root or link from the cache maintained by the DFS client.

NetDfsGetInfo()

Retrieves information about a specified DFS root or link in a DFS namespace.

NetDfsGetFtContainerSecurity()

Retrieves the security descriptor of the container object for the domain-based DFS namespaces in the specified Active Directory domain.

NetDfsGetSecurity()

Retrieves the security descriptor for the root object of the specified DFS namespace.

NetDfsGetStdContainerSecurity()

Retrieves the security descriptor for the container object of the specified stand-alone DFS namespace.

NetDfsGetSupportedNamespaceVersion()

Determines the supported metadata version number.

NetDfsMove()

Renames or moves a DFS link.

NetDfsRemove()

Removes a target from a DFS link; removes the DFS link if the target is the last associated with the specified link.

NetDfsRemoveFtRoot()

Removes a root target from a domain-based DFS namespace; deletes the DFS root if there are no more associated targets.

NetDfsRemoveFtRootForced()

Removes the specified root target from a domain-based DFS namespace, even if the server is offline.

NetDfsRemoveRootTarget()

Removes a DFS root target from a domain-based DFS namespace. If the root target is the last root target in the DFS namespace, this function removes the DFS namespace. This function can also be used to remove a stand-alone DFS namespace.

NetDfsRemoveStdRoot()

Deletes the root of a stand-alone DFS namespace.

NetDfsSetClientInfo()

Modifies cached information about a DFS link on a client computer.

NetDfsSetInfo()

Sets or modifies the information associated with a DFS link in the named DFS root, or with the DFS root itself.

NetDfsSetFtContainerSecurity()

Sets the security descriptor of the container object for the domain-based DFS namespaces in the specified Active Directory domain.

NetDfsSetSecurity()

Sets the security descriptor for the root object of the specified DFS namespace.

NetDfsSetStdContainerSecurity()

Sets the security descriptor for the container object of the specified stand-alone DFS namespace.

 

Obsolete Functions

 

The following functions are obsolete:

 

  1. NetDfsAddStdRootForced().
  2. NetDfsManagerInitialize().

 

Distributed File System Structures

 

The following are the Distributed File System (DFS) structures:

 

  1. DFS_INFO_1
  2. DFS_INFO_2
  3. DFS_INFO_3
  4. DFS_INFO_4
  5. DFS_INFO_5
  6. DFS_INFO_6
  7. DFS_INFO_7
  8. DFS_INFO_8
  9. DFS_INFO_9
  10. DFS_INFO_50
  11. DFS_INFO_100
  12. DFS_INFO_101
  13. DFS_INFO_102
  14. DFS_INFO_103
  15. DFS_INFO_104
  16. DFS_INFO_105
  17. DFS_INFO_106
  18. DFS_INFO_107
  19. DFS_INFO_150
  20. DFS_INFO_200
  21. DFS_INFO_300
  22. DFS_STORAGE_INFO
  23. DFS_STORAGE_INFO_1
  24. DFS_SUPPORTED_NAMESPACE_VERSION_INFO
  25. DFS_TARGET_PRIORITY

 

 

 

 

< Win32 Network Management APIs 2 | Win32 Network Management APIs | Win32 Programming | Win32 Network Management APIs 4 >