winfsp / cgofuse

Cross-platform FUSE library for Go - Works on Windows, macOS, Linux, FreeBSD, NetBSD, OpenBSD
https://winfsp.dev
MIT License
514 stars 82 forks source link

Not able to mount Fuse Drive on a Mapped Network Drive in Windows #33

Closed mohankumarv2005 closed 4 years ago

mohankumarv2005 commented 5 years ago

I have a mapped network drive (R:) which is pointing one of the folder on the network E.g. "\server-share\files". When I try to mount FUSE drive to let's say "R:\Fuse" I get below error "Cannot set WinFsp-FUSE file system mount point".

However, I am able to mount Fuse to Local Drive like "C:\Fuse". I have ensured "Fuse" folder is not present.

Any idea on this issue?

billziss-gh commented 5 years ago

Can you please post the full FUSE command line that you use to mount the file system (i.e. the arguments to host.Mount)?

Keep in mind you cannot mount a "network" file system to a directory. Only "disk" file systems can be mounted on directories.

mohankumarv2005 commented 5 years ago

Sure, here it is:

options := []string{"-o", "volname=Altair", "-o", "uid=-1", "-o", "gid=-1"} host.Mount("R:\Fuse", options)

Note: The directory "Fuse" do not exist on R:

billziss-gh commented 5 years ago

In order to mount on a directory, WinFsp must be able to set a "reparse point" on the (newly created) directory.

This is done in the WinFsp internal call FspFileSystemSetMountPoint_Directory. There are a few reasons why this may fail, but I am suspecting that the problem is that the "reparse point" fails on the network drive.

Is the network drive on a Windows server? For example, I believe there are some issues with reparse points on Samba shares.

mohankumarv2005 commented 5 years ago

Sorry for delayed response. The Network Server Setup is on Linux (OneFS). So, it is expected to work?

billziss-gh commented 5 years ago

If the server properly supports reparse points (e.g. a Windows server) I believe that it should work.