SMB write performance can be increased by Tuning the buffer cache.
The secret to good performance is to keep as much of the data in memory for as long as is possible. Writing to the disk is the slowest part of any filesystem. If you know that the filesystem will be heavily used, then you can tune this process for Linux Samba.
writing out dirty blocks to the disk until the filesystem buffer cache is 80 percent full (80). default is 40%, source = http://tldp.org/LDP/solrhe/Securing-Optimizing-Linux-RH-Edition-v1.3/chap29sec287.html
by writing
echo 80 > /proc/sys/vm/dirty_ratio
I am getting around 2MB increase while write operation, tested in Xp.
I have tried with this single option, as the ref source is for linux 2.2 and we are using 2.6 kernel.
we can try out Linux General Optimization suggested at http://tldp.org/LDP/solrhe/Securing-Optimizing-Linux-RH-Edition-v1.3/gen-optim.html
Tried with smb.conf, I am getting around 1MB gain while read and write.
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE
oplocks = yes
dead time = 15
read size = 32768
TCP socket options can be tested at run time using -O option of SMBD
/usr/local/samba/bin/smbd -O socket optios = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE
source.
http://us1.samba.org/samba/docs/man/Samba3-HOWTO/speed.html
socket level perf improvement also suggests for TCP_NODELAY
ref: http://www.ibm.com/developerworks/linux/library/l-hisock.html
http://www.stuartcheshire.org/papers/NagleDelayedAck/
SAMBA perf tuning ref.
http://oreilly.com/catalog/samba/chapter/book/appb.pdf
The secret to good performance is to keep as much of the data in memory for as long as is possible. Writing to the disk is the slowest part of any filesystem. If you know that the filesystem will be heavily used, then you can tune this process for Linux Samba.
writing out dirty blocks to the disk until the filesystem buffer cache is 80 percent full (80). default is 40%, source = http://tldp.org/LDP/solrhe/Securing-Optimizing-Linux-RH-Edition-v1.3/chap29sec287.html
by writing
echo 80 > /proc/sys/vm/dirty_ratio
I am getting around 2MB increase while write operation, tested in Xp.
I have tried with this single option, as the ref source is for linux 2.2 and we are using 2.6 kernel.
we can try out Linux General Optimization suggested at http://tldp.org/LDP/solrhe/Securing-Optimizing-Linux-RH-Edition-v1.3/gen-optim.html
Tried with smb.conf, I am getting around 1MB gain while read and write.
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE
oplocks = yes
dead time = 15
read size = 32768
TCP socket options can be tested at run time using -O option of SMBD
/usr/local/samba/bin/smbd -O socket optios = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE
source.
http://us1.samba.org/samba/docs/man/Samba3-HOWTO/speed.html
socket level perf improvement also suggests for TCP_NODELAY
ref: http://www.ibm.com/developerworks/linux/library/l-hisock.html
http://www.stuartcheshire.org/papers/NagleDelayedAck/
SAMBA perf tuning ref.
http://oreilly.com/catalog/samba/chapter/book/appb.pdf
Comments