[170] in 6.033-lab

home help back first fref pref prev next nref lref last post

tcp proxy

daemon@ATHENA.MIT.EDU (Benjie Chen)
Sat Feb 19 21:11:22 2000

From: Benjie Chen <benjie@cag.lcs.mit.edu>
Message-Id: <200002200211.VAA13184@amsterdam.lcs.mit.edu>
To: 6.033-lab@MIT.EDU
Date: Sat, 19 Feb 2000 21:11:12 -0500 (EST)
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hi
  
First of all, if you are no longer in 6.906/6.033 lab, let me know if you
want to be removed from the mailing list.

A couple of things:

  - The following code segment will allow you to terminate your proxy
    server and restart it again w/o your system complaining that the server
    is trying to reuse a port number. Here, s is the descriptor you got 
    from socket.

    { 
      int v = 1; 
      setsockopt(s, SOL_SOCKET, SO_REUSEADDR, (char*)&v, sizeof(v));
    }

    Include this code before call to bind. It tells the kernel that you
    are allowed to reuse an address with this socket.

  - If you are still uncertain about what you are suppose to do with your 
    tcp proxy, please let me know.

  - I will have office hours on Tues (virtual Monday), so please come and 
    see me if you have questions.

Benjie

-- 
Benjie Chen
benjie@lcs.mit.edu

home help back first fref pref prev next nref lref last post