Here is the code for chord/sos.  To run on a machine, run sosctl.pl as 
follows:
./sosctl <BootStrap IP ADDR> <BootStrap Port> <targets file|empty file> <Node name e.g sos30.cs.columbia,edu> <Node Port>.

Please be carefull to give the bootstrap IP Address not the name.
For the first node joining the P2P network give its own ip address as
<BootStrap IP ADDR>
Also targets contains the IP Addresses of the hosts we are the secret servlet
where chord_port can be any unused port, bootstrap should be the ip of the 
Chord bootstrap node (i.e. the first node up; use itself for the first 
one) and targets should be a list of targets for which that node is the 
servlet.  All else should happen automatically.

Example for the first host:

root@sos30:[~/soscode/deploy_sc]>./sosctl.pl 128.59.23.204 10000 notargets
sos30.cs.columbia.edu 10000

And for the another host on the P2P network:

/sosctl.pl 128.59.23.204 10000 notargets <new host IP ADDR> <PORT> 

Remember that one of machines should be configured to be the secret servlet:
/sosctl.pl 128.59.23.204 10000 targets <new host IP ADDR> <PORT>
			        ^^^^^^
Where as we mentioned targets is a file with the IP Addresses of the hosts we
protect. The file we provide has the IP addresses for the site web.mit.edu.

If everything goes OK you should be able to see in the file output.chord
something like:

root@sos30:[~/soscode/deploy_sc]>more output.chord
Connect to: 128.59.23.204:10000
18.7.21.70
18.7.22.69
18.7.21.69
212.58.240.111
212.58.240.120
18.7.21.116
woke up
18.7.21.70
received announcement for 128.59.23.204
18.7.22.69
received announcement for 128.59.23.204
18.7.21.69
received announcement for 128.59.23.204
212.58.240.111
received announcement for 128.59.23.204
212.58.240.120
received announcement for 128.59.23.204
18.7.21.116
received announcement for 128.59.23.204

To stop the Overlay Network we issue:
./sosctrl stop


