-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ubuntu 22.04 (ksmbd v3.4.2) , mount.cifs is ok, but some simple file io ops are failed? #602
Comments
ksmbd in linux-5.15 kernel seems to be unstable. Please use ksmbd in the latest kernel(6.5 or 6.6) or use github ksmbd(https://github.com/cifsd-team/ksmbd). Let me know if you find same issue on the latest ones. |
@namjaejeon It works now, thanks. |
@tojoyccnu I don't have all kinds of RDMA NICs. I have tested only ConnectX-3 Mellanox and a Chelsio NIC. There will not be some problem. |
@tojoyccnu And you need to add "server multi channel support = yes" parameter in [global] section of ksmbd.conf. Without this, RDMA will not work with windows client. |
@namjaejeon Has the latest version of ksmbd (git master) been tested for compatibility with Linux kernel 6.6.0? compile occors errors, like below: ./include/linux/fs.h:3016:43: note: expected ‘u32’ {aka ‘unsigned int’} but argument is of type ‘struct inode *’ fs/smb/server/smb2pdu.c: In function ‘find_file_posix_info’: ... |
Looks like the fix to this will be to use inode_get_ctime(i), and the appropriate setter function, for all of these places we have been accessing i->i_ctime directly。 linux 6.6.0 has changed arguments to function ‘generic_fillattr’. |
@tojoyccnu Yes, there is a change in vfs. I will call you after updating it tonight or tomorrow. |
@tojoyccnu Please check git clone https://github.com/namjaejeon/ksmbd |
@namjaejeon Is there a configuration to configure the number of cpu cores used? |
@tojoyccnu No, there is no such configuration in ksmbd. nfs or samba has such options ? |
Issue
See title, how can I get it correctly when using ksmbd. Just simple file ops would not be successful. ANY SUGGESTION or docs to follow。
Setup
linux version: ubuntu 22.04 kernel 5.15.0-87-generic
Version of kmod: ksmd ksmbd version : 3.4.2
Version of tools: git master
Expected behaviour
Files copy normally
I follow the ksmbs_tools 's step to share dictory, like below:
`
mkdir -vp $HOME/MyShare
sudo ksmbd.addshare --add
--option "path = $HOME/MyShare"
--option 'read only = no'
MyShare
sudo ksmbd.addshare --update MyShare
sudo ksmbd.adduser --add ubuntu
sudo ksmbd.addshare --update
--option "force user = $USER"
--option "force group = $USER"
MyShare
`
next, mount it normally.
sudo mount -o user=ubuntu //127.0.0.1/MyShare /mnt/smb
then, some file ops in the mountpoint /mnt/smb
sudo su root vim /mnt/smb/testfile01.txt // E667: Fsync failed echo "test" > /mnt/smb/testfile02.txt // no error occors, but file lenth is zero.
Why? How can I edit the ksmbd.conf, or update ksmbd version to newest version?
ksmbd.conf
`
[global]
; global parameters
bind interfaces only = no
deadtime = 0
guest account = nobody
ipc timeout = 0
map to guest = never
max active sessions = 1024
max connections = 128
max open files = 10000
netbios name = KSMBD SERVER
restrict anonymous = 0
server max protocol = SMB3_11
server min protocol = SMB2_10
server multi channel support = no
server signing = disabled
server string = SMB SERVER
share:fake_fscaps = 64
smb2 leases = no
smb2 max credits = 8192
smb2 max read = 4MB
smb2 max trans = 1MB
smb2 max write = 4MB
smb3 encryption = auto
smbd max io size = 8MB
tcp port = 445
workgroup = WORKGROUP
browseable = yes
create mask = 0744
crossmnt = yes
directory mask = 0755
force create mode = 0000
force directory mode = 0000
guest ok = no
hide dot files = yes
inherit owner = no
oplocks = yes
[public]
comment = share folder
browseable = yes
path = /home/ubuntu/MyShare
valid users = ubuntu
force user = ubuntu
public=yes
writeable=yes
available=yes
`
The text was updated successfully, but these errors were encountered: