Memory alignment requirement for Direct/IO
Subsystems (2)
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hello,
I setup samba server in upstream and mount it in local with cache=none,vers=3.11. Then test the Direct/IO function like this:
fd=open(fname, O_DIRECT | O_RDWR | O_CREAT, 0666)) lseek(fd, 0, SEEK_SET);read(fd, buf, 1);
For local filesystem such as XFS, "read" will be failed because XFS has 512Byte memory aligment for Direct/IO. But it's success for cifs. I don't know if it's expected. Could anybody tell me more about Direct/IO for cifs?
Thanks.
Signature · 8 lines
Best regards! XiaoLi Feng 冯小丽 Red Hat Software (Beijing) Co.,Ltd filesystem-qe Team IRC:xifeng,#channel: fs-qe Tel:+86-10-8388112 9/F, Raycom
I would expect direct i/o to work with unaligned reads over SMB3 mounts.
Let me know if you see different behavior to any servers.
Quoted 25 lines · Xiaoli Feng
Hello,
I setup samba server in upstream and mount it in local with cache=none,vers=3.11. Then test the Direct/IO function like this:
fd=open(fname,
O_DIRECT|O_RDWR|O_CREAT, 0666))lseek(fd, 0, SEEK_SET);read(fd, buf, 1);For local filesystem such as XFS, "read" will be failed because XFS has 512Byte memory aligment for Direct/IO. But it's success for cifs. I don't know if it's expected. Could anybody tell me more about Direct/IO for cifs?
Thanks.
--
Best regards!
XiaoLi Feng 冯小丽Red Hat Software (Beijing) Co.,Ltd
filesystem-qe Team
IRC:xifeng,#channel: fs-qe
Tel:+86-10-8388112
9/F, Raycom
Signature · 3 lines
Thanks, Steve