cifsd-team / ksmbd

ksmbd kernel server(SMB/CIFS server)
151 stars 23 forks source link

cifsd does not work with OpenZFS #506

Open FellTarsier opened 3 years ago

FellTarsier commented 3 years ago

I'm currently using OpenZFS 2.0.4 as the filesystem for my archival data. Reading from the archive works as expected. However when I attempt to write to the archive from a Windows machine, Windows throws an access denied error. With debugging enabled on the server I get this error when I attempt to create a folder:

[3774800.084558] ksmbd: smb2_open:2775: can not get linux path for /archive/New folder, rc = -2
[3774800.084559] ksmbd: smb2_open:2865: User does not have write permission
[3774800.084629] ksmbd: smb2_open:3350: Error response: c0000022

It does not matter if it's a folder or a file, the error is the same. I have verified that the user account does have write permissions to /archive. If I use samba the share works as expected from the windows machine.

Here is my smb.conf:

   comment = Long Term Archival Storage
   path = /archive
   public = no
   writable = yes
   printable = yes
   create mask = 0765

Currently using the latest tools and module checked out from git as of 3/22/2021.

namjaejeon commented 3 years ago

Hi, You need to change "writable = yes" to "writeable = yes" or "read only = no".

namjaejeon commented 3 years ago

@FellTarsier ping ?

pfactum commented 2 years ago

@namjaejeon with Samba writable works, but with ksmbd it doesn't (have to use writeable). Is this on purpose?

namjaejeon commented 2 years ago

@pfactum No reason, ksmbd doesn't support all parameters of samba. They are too many, So we are adding them as needed.

namjaejeon commented 2 years ago

@pfactum we list up supported parameters in https://github.com/cifsd-team/ksmbd-tools/blob/master/Documentation/configuration.txt . If you want to add writable parameter, Please request it to us.

pfactum commented 2 years ago

@namjaejeon I'm good with this explanation, thanks, there's no reason to breed multiple synonyms just to satisfy my 3-share configuration ☺. Feel free to close this request.