[DFS] Moveing a file across DFS

M

Michael B Allen

What would happen if you tried to "MoveFile" a file using across a DFS
volume? For example:

server1:
file1
file2
foo --> referral to server2\bar

server2:
bar

and you call:

MoveFile(file1,foo\file1)

Does this fail? Are there instances in which API functions behave
differently if DFS is involved? The MoveFile API documentation has this to
day:

"The one caveat is that the MoveFile function will fail on directory moves
when the destination is on a different volume.

If a file is moved across volumes, MoveFile does not move the security
descriptor with the file. The file will be assigned the default security
descriptor in the destination directory.

The MoveFile function coordinates its operation with the link tracking
service, so link sources can be tracked as they are moved."

Thanks,
Mike
 
M

Mukul Gupta [MSFT]

This comment is talking about 'directory' in particular. It is not talking
specific to DFS. It is talking that if you try to move a 'directory' across
different volumes (i.e. even from C: to E:), it will fail.
So in your case, MoveFile(file1, foo\file1) should succeed as long as it is
a file.

--
Thanks
Mukul [MSFT]

PS: Please post DFS related queries in newsgroup
microsoft.public.win2000.file_system. Please use "DFS" in subject to make it
immediately noticeable.

PS: Please find latest dfsutil.exe (updated) at
http://www.microsoft.com/downloads/...C3-C7A3-4B5B-9FF1-FD01B0203DC1&displaylang=en

Disclaimer: This posting is provided "AS IS" with no warranties, and confers
no rights
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top