pure-ftpd 要能支援 smbfs 這些比較特殊的 File System,必須在 configure 的時候加入 “–without-sendfile” 這個參數,讓它不使用 sendfile 這個 System Call,在 FreeBSD ports 裡,只需要將預設的 Option “SENDFILE Support for the sendfile syscall” 取消即可。下面是官方的說明:
--without-sendfile: on Linux, Solaris, HPUX and FreeBSD kernels, Pure-FTPd tries to reduce the CPU/memory usage by using a special system call (sendfile) . It works very well with most filesystems. However, this optimization is not implemented for all filesystems in current kernels. Users reported that downloading files with Pure-FTPd failed with SMBFS (Samba) on FreeBSD and TmpFS and NTFS on Linux (the error reported by the server is "broken pipe" or "Error during write to data connection") . If you are planning to serve files from these filesystems, you have to use the --without-sendfile switch to enable a workaround. It was also reported that PA-Risc Linux systems need this flag.
0 Response to “讓 pure-ftpd 支援 smbfs”