Archive for the ‘TCP/IP’ Category

TCP/IP and Offload   4 comments

CHECKSUM OFFLOAD
Checksum Offload is a property of some network adapters that allows the TCP/IP/UDP checksums for send and receive traffic to be calculated by the adapter hardware rather than by the host CPU. In high-traffic situations, this can allow a system to handle more connections more efficiently than if the host CPU were forced to calculate the checksums. This property is inherently a hardware property and would not benefit from a software-only implementation. An adapter that supports Checksum Offload advertises this capability to the operating system so that the checksum does not need to be calculated in the protocol stack.

LARGE SEND OFFLOAD
Large Send Offload (LSO) is a feature provided by some network adapters that prevents an upper level protocol such  as TCP from breaking a large data packet into a series of smaller packets with headers appended to them. The protocol stack need only generate a single header for a data packet as large as 64 KB, and the adapter hardware breaks the data buffer into appropriately-sized Ethernet frames with the correctly sequenced header (based on the single header originally provided).

TCP OFFLOAD ENGINE (TOE)
The TCP/IP protocol suite is used to provide transport services for a wide range of applications for the Internet, LAN, and for file transfer. Without the TCP Offload Engine, the TCP/IP protocol suite runs on the host CPU, consuming a very high percentage of its resources and leaving little resources for the applications. With the use of this feature on the hardware adapters that support it, the TCP/IP processing can be moved to the hardware, freeing the CPU for more important tasks such as application processing. The TCP Offload Engine functionality (TOE) allows simultaneous operation of up to 1024 fully offloaded TCP connections for 1-Gbps network adapters and 1880 fully offloaded TCP connections for 10-Gbps network adapters. The TOE support on the adapter significantly reduces the host CPU utilization while preserving the implementation of the operating system stack

In Windows 2003, you can query/disable/enable some of the TCP Offload settings. The following settings are those suggested by the ISA BPA. These could help resolve performance issues on servers with relatively high traffic like ISA and EXCHANGE 2003.

reg query "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnablePMTUDiscovery
reg query "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnableRSS
reg query "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnableTCPA
reg query "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v DisableTaskOffload
reg query "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnableTCPChimney

reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnablePMTUDiscovery /t REG_DWORD /d 0x1 /f
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnableRSS /t REG_DWORD /d 0x0 /f
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnableTCPA /t REG_DWORD /d 0x0 /f
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v DisableTaskOffload /t REG_DWORD /d 0x1 /f
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters" /v EnableTCPChimney /t REG_DWORD /d 0x0 /f

Large Send Offload (LSO) stopped working since the release of the 32-bit Windows XP/2003 operating system to Service Pack 2. Microsoft’s implementation of the Windows Firewall feature included in Service Pack 2 appears to cause Large Send Offload (LSO) to stop working correctly. They provide the solution to this problem in Knowledge Base article 842264. If the problem persists, you may need to run the latest Windows update in order for this feature to begin working again. Specifically, the security update available at the following link should re-activate the LSO capability of the adapter: http://www.microsoft.com/technet/security/bulletin/ms05-019.mspx

Normally the TCP segmentation is done by the protocol stack. By enabling the Large Send Offload value, the TCP segmentation can be done by the Gigabit Ethernet Adapter. You can configure Large Send Offload following these steps:

  1. In Microsoft Windows, right-click the Network Adapter in Network Connections and then click Properties.
  2. Click the Configure button and then the General tab.
  3. Set the "Large Send Offload" parameter to Disable or Enable.

What is Jumbo MTU?
"Jumbo MTU" is a parameter that allows the adapter to transmit and receive oversized Ethernet frames that are greater than 1514 bytes but less than 9000 bytes in length. Note that this parameter requires a switch that is able to process large frames. To configure the Jumbo MTU, follow these steps:

  1. In Microsoft Windows, right-click the Network Adapter in Network Connections, and then click Properties.
    Click the Configure button and then the General tab. Jumbo MTU is set at 1500 bytes by default.
    To increase the size of the received frames, increase the byte quantity in 500-byte increments up to 9000 bytes.
  2. Netware: Jumbo Frame is configured by adding the "Jumbo=XXXX" parameter to the driver load command line in the AUTOEXEC.NCF file, where XXXX is a value between 1514 and 9000 bytes.
  3. Linux: The MTU can be changed on the device in which support this feature using the following command: "ifconfig eth<X> mtu <Value>". <Value> can be between 1500 and 9000, <X> is the device ID.

Not all networking devices support Jumbo-frame. Consult the respective product documentation to confirm that your device supports this feature.

What is Checksum Offload?
Normally the TCP Checksum is computed by the protocol stack. By selecting one of the "Checksum Offload" parameters, the checksum can be computed by the Gigabit Ethernet Adapter. You can configure Checksum Offload following these steps:

  1. In Microsoft Windows, right-click the Network Adapter in Network Connections and then click Properties.
    Click the Configure button and then the General tab.
    Set the Checksum Offload parameter to None, Rx TCP/IP Checksum, Tx TCP/IP Checksum, or Tx/Rx TCP/IP Checksum.
  2. Netware: Checksum Offload is configured by adding the "CHECKSUM=ON" parameter to the driver load command line in the AUTOEXEC.NCF file. To disable, change the value to OFF or do not include the parameter, since the default is set to disable.
  3. Linux: The can be done using the "ethtool -K" command. Please refer to the respective man page for command syntax.

Posted 20/10/2010 by Mike Wasowsky in TCP Offload, TCP/IP