Increase Samba Server’s performance

April 17

There are numbers of socket options in smb.conf that can be tuned to enhance/optimize the performance of a Samba  server.  Socket options are configurable controls on the networking layer of an operating systems that allow the connection to be tuned.

The single configuration line below when added to the global section of your smb.conf  can give you up to 200% throughput increase compared to the smb.conf’s default settings.

socket options = TCP_NODELAY IPTOS_LOWDELAY SO_RCVBUF=65536 SO_SNDBUF=65536

TCP_NODELAY tells the samba server to send as many packets as necessary to keep delay low. Setting this option can increase the speed up to 30 to 50% and in Samba 2.0.4, became the default value for that option.

SO_SNDBUF and SO_RCVBUF The send and receive buffers can often be the reset to a value higher than that of the operating system. This yields a marginal increase of speed until it reaches a point of diminishing returns. A modern Linux Systems serving Samba shares to Windows systems, setting the  SO_SNDBUF and SO_RCVBUF to 65536 can give you an additional 20% throughput.

IPTOS_LOWDELAY is an option that trades off throughput for lower delay, but which affects routers and other systems, not the server. All the IPTOS options are new; they’re not supported by all operating systems and routers. If they are supported, set whenever you set . If supported, this setting accounts for another 20% speed increase.

SO_KEEPALIVE initiates a periodic check every four hours to see if the client has closed connection or not. This setting will close dead connections and return unused memory and process-table entries back to the operating system.

Popularity: unranked [?]

Comments
Advertisements
Zimbio Entertainment
Copyright © 2012 - Zimbio, Inc. Some rights reserved. Coming soon: Livingly
Share
. . .
Follow
. . .