SO_REUSEADDR

Discussion in 'Java' started by Srubys@gmail.com, Jul 2, 2008.

  1. Guest

    hiya

    1.
    a) I assume that if ServerSocket object is closed, local port and IP
    can be reused immediately ( assuming there is no active or closing
    connection to the same port) ?


    b) And even if there is active connection to the same port, if new
    ServerSocket object listens on same port, but different IP, then local
    port can be reused immediately ( even without setting SO_REUSEADDR
    option ) ?


    c) If on a client side a connection is in timeout state, can you
    immediately reuse this local port if new client socket listens on
    different local IP ( even without setting the SO_REUSEADDR option )?


    d) I gather that SO_REUSEADDR option enables new socket to bind to
    same local port while there is still closing connection to that port,
    but this new socket won’t be allowed to create connection with the
    same socket pair?



    2. If one server instance listens on port 2000 and on all local
    interfaces, then no other server instance can listen on same port.
    But if that server instance listens on just one local interface ( and
    on port 2000 ), then there can be some other server instance listening
    on same port and different local IP ?


    thank you
    , Jul 2, 2008
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. _mario.lat

    IPV6_V6ONLY and SO_REUSEADDR: why?

    _mario.lat, Jun 10, 2007, in forum: C Programming
    Replies:
    1
    Views:
    491
    Walter Roberson
    Jun 10, 2007
Loading...

Share This Page