* CPU processing time between using TCP and UDP
@ 2012-02-07 14:53 Srinidhi M
2012-02-07 15:30 ` James Carlson
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Srinidhi M @ 2012-02-07 14:53 UTC (permalink / raw)
To: linux-ppp
Hi All,
We have an application which uses the TCP/UDP packets. The packet
processing time between application and session layers is same for TCP
as well as UDP. However, there is a packet processing time difference
after sending it to layer 4 either TCP or UDP. Generally, we are
calling the socket() API for transmitting the packet. We are seeing
the difference in Linux Network Stack.
Could you please let me know, which module in TCP/IP is consuming more
time than UDP? How can we reduce packet processing time when sending
through TCP stack? Please let me know your thoughts.
Please let me know, the appropriate mailing list name for this type of
questions.
Thanks in advance.
Regards,
Srinidhi M.
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: CPU processing time between using TCP and UDP
2012-02-07 14:53 CPU processing time between using TCP and UDP Srinidhi M
@ 2012-02-07 15:30 ` James Carlson
2012-02-07 18:55 ` terry white
2012-02-08 11:55 ` Srinidhi M
2 siblings, 0 replies; 5+ messages in thread
From: James Carlson @ 2012-02-07 15:30 UTC (permalink / raw)
To: linux-ppp
Srinidhi M wrote:
> Could you please let me know, which module in TCP/IP is consuming more
> time than UDP? How can we reduce packet processing time when sending
> through TCP stack? Please let me know your thoughts.
Are you sure you wanted to post this message on the Linux PPP mailing list?
Anyway, without knowing a lot about your application, how you're
measuring things, and what environment you're running in, it's a little
hard to guess at what sort of change you might require. But I'll give
it a try.
Have you tried setting the TCP_NODELAY option and/or redesigning around
TCP_CORK? If your application does a lot of tiny write(2) calls, you
will sometimes see RTT delays in delivery. This is normal, and it's
something that the stack does in order to protect the network against
misbehaving (or just inefficient) applications. You can disable it in
order to force a write(2) to result in a transmission ... but be careful
if you do this, because doing so can result in a flood of tiny packets
if you (say) write a byte at a time.
Have you considered SCTP instead? If you have a message-oriented
protocol (rather than a stream-oriented one), and you need reliable
delivery, SCTP may be a better option for you than TCP.
--
James Carlson 42.703N 71.076W <carlsonj@workingcode.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: CPU processing time between using TCP and UDP
2012-02-07 14:53 CPU processing time between using TCP and UDP Srinidhi M
2012-02-07 15:30 ` James Carlson
@ 2012-02-07 18:55 ` terry white
2012-02-08 11:55 ` Srinidhi M
2 siblings, 0 replies; 5+ messages in thread
From: terry white @ 2012-02-07 18:55 UTC (permalink / raw)
To: linux-ppp
: on "2-7-2012" "Srinidhi M" writ:
: Could you please let me know, which module in TCP/IP is consuming more
: time than UDP? How can we reduce packet processing time when sending
: through TCP stack? Please let me know your thoughts.
... ciao:
i could be "WAY" off base here, but, i would 'expect' there to be a
difference. a connectionless protocol, udp, suggests a "no-wait" interval,
while 'tcp' demands it.
i think a more meaningful investigation would compare the linux stack
vis-a-vis another implementation ...
--
... it's not what you see ,
but in stead , notice ...
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: CPU processing time between using TCP and UDP
2012-02-07 14:53 CPU processing time between using TCP and UDP Srinidhi M
2012-02-07 15:30 ` James Carlson
2012-02-07 18:55 ` terry white
@ 2012-02-08 11:55 ` Srinidhi M
2 siblings, 0 replies; 5+ messages in thread
From: Srinidhi M @ 2012-02-08 11:55 UTC (permalink / raw)
To: linux-ppp
On Tue, Feb 7, 2012 at 9:00 PM, James Carlson <carlsonj@workingcode.com> wrote:
> Srinidhi M wrote:
>> Could you please let me know, which module in TCP/IP is consuming more
>> time than UDP? How can we reduce packet processing time when sending
>> through TCP stack? Please let me know your thoughts.
>
> Are you sure you wanted to post this message on the Linux PPP mailing list?
No. I do not know the exact mailing list name for these type of
questions. First, I mailed to main kernel, but, I did not get any
response. So, I mailed to this group. Please let me know the mailing
list name for posting these type of questions.
> Anyway, without knowing a lot about your application, how you're
> measuring things, and what environment you're running in, it's a little
> hard to guess at what sort of change you might require. But I'll give
> it a try.
Just using "top" command. No other commands.
> Have you tried setting the TCP_NODELAY option and/or redesigning around
> TCP_CORK?
No. We are not using these options. We will try to change the options
for setsockopt call.
> If your application does a lot of tiny write(2) calls, you
> will sometimes see RTT delays in delivery. This is normal, and it's
> something that the stack does in order to protect the network against
> misbehaving (or just inefficient) applications. You can disable it in
> order to force a write(2) to result in a transmission ... but be careful
> if you do this, because doing so can result in a flood of tiny packets
> if you (say) write a byte at a time.
>
> Have you considered SCTP instead? If you have a message-oriented
> protocol (rather than a stream-oriented one), and you need reliable
> delivery, SCTP may be a better option for you than TCP.
We will think about these, later.
Thank you very much for your reply.
Regards,
Srinidhi M.
> --
> James Carlson 42.703N 71.076W <carlsonj@workingcode.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* CPU processing time between using TCP and UDP
@ 2012-02-07 10:25 Srinidhi M
0 siblings, 0 replies; 5+ messages in thread
From: Srinidhi M @ 2012-02-07 10:25 UTC (permalink / raw)
To: linux-kernel
Hi All,
We have an application which uses the TCP/UDP packets. The packet
processing time between application and session layers is same for TCP
as well as UDP. However, there is a packet processing time difference
after sending it to layer 4 either TCP or UDP. Generally, we are
calling the socket() API for transmitting the packet. We are seeing
the difference in Linux Network Stack.
Could you please let me know, which module in TCP/IP is consuming more
time than UDP? How can we reduce packet processing time when sending
through TCP stack? Please let me know your thoughts.
Please let me know, the appropriate mailing list name for this type of
questions.
Thanks in advance.
Regards,
Srinidhi M.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-02-08 11:55 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-07 14:53 CPU processing time between using TCP and UDP Srinidhi M
2012-02-07 15:30 ` James Carlson
2012-02-07 18:55 ` terry white
2012-02-08 11:55 ` Srinidhi M
-- strict thread matches above, loose matches on Subject: below --
2012-02-07 10:25 Srinidhi M
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.