Find the answer to your Linux question:
Results 1 to 7 of 7
Hi, If a client sends a message to the server using TCP and an ack is received then does it mean that the application (on the server) for which the ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Mar 2009
    Posts
    3

    Question TCP acknowledgement


    Hi,

    If a client sends a message to the server using TCP and an ack is received then does it mean that the application (on the server) for which the message was intended has received the message.

    The question is that when is the ack sent , on receipt of the message by the operating system or on the receipt of MSG by the application(on the server).


  2. #2
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    It should be the app that is responding unless you have something else setup.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  3. #3
    Just Joined!
    Join Date
    Mar 2009
    Posts
    3
    Is it confirmed that it is the application which sends the ACK after receiving the tcp packet??
    Or is it the operating system that sends the ACK when the tcp packet is received in the OS input buffer??
    Kindly confirm the situation.......Because as read the TCP protocol maintains the reliable connection in the Network Layer......

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Engineer Thrillhouse's Avatar
    Join Date
    Jun 2006
    Location
    Arlington, VA, USA
    Posts
    1,377
    The operating system has a TCP/IP stack which handles the receiving of incoming IP packets (TCP rides on top of IP). When the stack receives the packet, it strips off any TCP-related information and has other means (other protocols) by which it delivers the data up the stack to the intended, listening application specified by the destination port field in the TCP header. The stack is what is responsible for sending back an ACK.

    And strictly speaking, TCP does not reside at the Network layer. IP is at the Network layer and TCP rides on top of it at the Transport layer.

  6. #5
    Just Joined!
    Join Date
    Mar 2009
    Posts
    3
    When does the OS stack sends the ACK?? i.e. just after receiving the packet or after giving it to the listening application....

    Also, please elaborate on the protocols by which OS delivers the data up the stack to the intended, listening application specified by the destination port field in the TCP header.

  7. #6
    Linux Engineer Thrillhouse's Avatar
    Join Date
    Jun 2006
    Location
    Arlington, VA, USA
    Posts
    1,377
    Rather than asking me, why don't you google these questions? There is tons of information on TCP/IP on the net; most of which can give you much better answers than I can.

  8. #7
    Just Joined!
    Join Date
    Apr 2009
    Posts
    9
    Typically, a TCP stack would send the ACK when it gets data, regardless of whether the app is ready to receive the data (typically from a socket).

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •