Hi,
My FSD mounts its filesystem on a My Computer volume. This volume can then
be unmounted by clicking a button on a controlling GUI program. This works
fine.
The volume can also be shared as usual (right-click the volume in Explorer
and select “share”). Doing so, other PCs on the LAN can access data on the
volume.
My problem is with unmounting the volume. Turns out that the first time a
remote client on the network access the share, a directory handle is opened
by the FS. Even when the remote PC closes the share window in Explorer,
one directory handle remains opened on the FS. My question is, how to I
unmount in this case? Is there an NT or Win32 call that tells the LAN
manager than a volume is unmounting? Alternatively, can I simply unmount
the FS and leave the opened directory handle opened (yuck)?
BTW, I solved a similar problem on the machine running the FSD by calling
the Win32
SHChangeNotify(SHCNE_MEDIAREMOVED, SHCNF_PATH, vol, NULL)
before unmounting the volume. This closes all the Explorer windows opened
on the volume, thus closing all the dir handles opened by Explorer. I
tried a similar
SHChangeNotify(SHCNE_NETUNSHARE , SHCNF_PATH, vol, NULL)
hoping that it will tell the LAN manager to close the share, but it did not
help.
Thanks
Chuck Shavit
You are currently subscribed to ntfsd as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntfsd-$subst(‘Recip.MemberIDChar’)@lists.osr.com