Error during write operation when packets dropped in vfswrap_pwrite()

sandeep nag sandeepnagamalli at gmail.com
Fri Jul 24 17:48:31 UTC 2015


To check the performance of samba, I am trying to drop packets in samba vfs
write() entry function before writing to the disk.
I have tried updating write function in vfs_default.c

ssize_t vfswrap_pwrite((vfs_handle_struct *handle, files_struct *fsp, const
void *data, size_t n)
{
  .
  .
 //result = SMB_VFS_WRITE(fsp, data, n);     <-- done this change
 result =n;
 return result;
}


Error seen on windows client :
Writing 8594128896 binary bytes sequentially to Z:\file_10 (direct)
  MS-DOS style path detected: Z:\file_10
write error: No such file or directory.
Also taking more time to finish the file copy.


Apart from above change do I need to do any changes in reply message or any
other place??


Thanks,
Sandeep


More information about the samba-technical mailing list