Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bypassing the TCP-IP stack

I realise this is a somewhat open ended question...

In the context of low latency applications I've heard references to by-passing the TCP-IP stack.

What does this really mean and assuming you have two processes on a network that need to exchange messages what are the various options (and associated trade-offs) for doing so?

like image 743
Joel Avatar asked Sep 08 '11 09:09

Joel


People also ask

Is there an alternative to TCP IP?

The most common alternative is UDP ("user datagram protocol"). UDP is designed for applications where you don't need to put sequences of datagrams together. It fits into the system much like TCP.

What does resetting the TCP IP stack do?

This will effectively replace the TCP/IP and DHCP configuration properties in the system registry, restoring them to their default values. This will remove static IP information for all network interfaces configured on the system.

What is meant by TCP IP stack?

(1) TCP/IP is frequently referred to as a "stack." This refers to the layers (TCP, IP, and sometimes others) through which all data passes at both client and server ends of a data exchange.

Why should I reset TCP IP stack?

"resetting the TCP stack" usually means resetting all IP protocol settings (IP, Subnetmask, DNS server entries, etc.) within Windows and can solve certain configuration errors.


2 Answers

Typically the first steps are using a TCP offload engine, ToE, or a user-space TCP/IP stack such as OpenOnload.

Completely skipping TCP/IP means usually looking at InfiniBand and using RDMA verbs or even implementing custom protocols above raw Ethernet.

Generally you have latency due to using anything in the kernel and so user-space mechanisms are ideal, and then the TCP/IP stack is an overhead itself consider all of the layers and the complexity that in can be arranged: IP families, sub-networking, VLANs, IPSEC, etc.

like image 147
Steve-o Avatar answered Sep 27 '22 17:09

Steve-o


You might want to check out zeromq.

like image 29
Robert S. Barnes Avatar answered Sep 27 '22 17:09

Robert S. Barnes