hi.i made a service that point to a usb directory which is fat32, when i copy a big file (2G B) into this service, i found the samba will generate a sparse file which is 2GB size ,then copy files from net into disk. it means linux cpu will write fat32 disk twice.(one sparse,one real write) and if the file is too big, samba will not response to smbclient, so smbclient will print out "no such service" and connection will break. if i look up the sparse file in linux shell , the file still generating to 2GB. is it right?
It is right,we must compile the module with the option samba "D_FILE_OFFSET_BITS=64"
This isn't a Samba bug, just a reality of large files, obsolete filesystems and USB storage. Modern versions of Samba will however keep responding to an echo in a thread handler to help the client know it is still alive. There isn't anything more for Samba to do here, it has nothing to do with 64-bit file offsets, that is the default anyway.