Thanks all for your help! A few more questions:
(1) If I decided to add support for redirecting local disk requests
to another server or redirecting other server requests to the
local disk. Can I still use \Device\LanmanRedirector?? Doesn’t
the \Device\LanmanRedirector only handle network server??
(2) Is there a way I can use \Device\LanmanRedirector without
first mapping the server to a drive letter?? For example,
can I access the server share using something like:
\Device\LanmanRedirector\server\share
(3) I don’t think I can use STATUS_REPARSE. Reason being in some
cases after I redirected the request to one server, I want to
redirect the request again to another server if that first one
failed. If I use STATUS_REPARSE, I would never get the result
status of the first redirected request. Am I right??
Thanks,
Patrick
> I am trying to write a filter driver which redirect file requests
> from one server to another server. For example, if someone want to
> open file \server-A\share\file-A.txt , then I want to automatically
> redirect
> the request to server-B instead. What Target Device should
I attach my
> filter to?? I tried to get the device for \Device\Mup but
it failed with
> STATUS_SHARING_VIOLATION. What does that mean??This is the wrong way.
The command:
net use z: \server\share
- creates a symbolic link in the form of
\Device\LanmanRedirector\z:\server\share
So, accesing such a mapped drive letter will bypass MUP.Filter \Device\LanmanRedirector, update paths in the file
objects on CREATE
and return STATUS_REPARSE - this is a correct way.Max