10 | | '''On TERMINAL 1''' |
| 12 | '''On TERMINAL 1 (H1 node)''' |
| 13 | |
| 14 | {{{ |
| 15 | sudo /root/choicenet/geni/start_server.sh |
| 16 | }}} |
| 17 | |
| 18 | |
| 19 | this will start both the marketplace and controller. |
| 20 | |
| 21 | Open up two ssh session terminals to the H2 Node. First run the Choicenet App. The Choicenet App will communicate with marketplace to request for path service and deal with payment. |
| 22 | |
| 23 | '''On TERMINAL 2 (H2 node)''' |
| 24 | |
| 25 | {{{ |
| 26 | sudo /root/choicenet/geni/start_app.sh |
| 27 | }}} |
| 28 | |
| 29 | When asked for username and password, please use the following account: |
| 30 | |
| 31 | Username: customer@choicenet.info |
| 32 | |
| 33 | Password: customer |
| 34 | |
| 35 | After login, the app will intercept any TCP SYN packets with destination IP 10.0.0.0/8 and destination port 8080 or 443. Once it intercepts a packet, it communicated with the marketplace and request for a path service with 3-minute duration. This means it is compatible with almost any existing network applications, here we will use wget and mplayer as two examples. |
| 36 | |
| 37 | First start a simple http server on H1: |
| 38 | |
| 39 | '''On TERMINAL 1 (H1 node)''' |
| 40 | |
| 41 | {{{ |
| 42 | sudo su |
| 43 | cd /root/ |
| 44 | python -m SimpleHTTPServer 8080 |
| 45 | }}} |
| 46 | |
| 47 | We then use wget on the other terminal of H2 |
| 48 | |
| 49 | '''On TERMINAL 3 (H2 node)''' |
| 50 | |
| 51 | {{{ |
| 52 | wget http://10.10.1.1:8080/sample.mp4 |
| 53 | }}} |
| 54 | |
| 55 | After executing this command, switch to TERMINAL 2, you will see the ChoiceNet App gives you several options about the forward and revert path. Select one for each, then you will be asked to pay for the path service on a webpage. |
| 56 | |
| 57 | '''Output on TERMINAL 2 (H2 node)''' |
14 | | cd ~/choicenet/source/bin |
| 61 | Forward recipe: |
| 62 | 0. Bandwidth: 10.000000 Mbps, Latency: 0.400000 ms, Price: 0.180000 dollars |
| 63 | 1. Bandwidth: 1.000000 Mbps, Latency: 0.400000 ms, Price: 0.160000 dollars |
| 64 | Enter selection: 1 |
| 65 | Return recipe: |
| 66 | 0. Bandwidth: 1.000000 Mbps, Latency: 0.400000 ms, Price: 0.160000 dollars |
| 67 | 1. Bandwidth: 10.000000 Mbps, Latency: 0.400000 ms, Price: 0.180000 dollars |
| 68 | Enter selection: 0 |
| 69 | Please pay for the services in the following webpage before you use them: |
| 70 | http://192.122.236.102/new/client/paypal/payment/service/69/2/1413512209097/39/ |
19 | | #!sh |
20 | | ./getool -f <MANIFEST FILENAME> -l <GENI USERNAME> -i ~/.ssh/id_rsa ssh h1 |
| 83 | root@h2:~# wget http://10.10.1.1:8080/sample.mp4 |
| 84 | --2014-10-16 23:02:16-- http://10.10.1.1:8080/sample.mp4 |
| 85 | Connecting to 10.10.1.1:8080... connected. |
| 86 | HTTP request sent, awaiting response... 200 OK |
| 87 | Length: 73516259 (70M) [video/mp4] |
| 88 | Saving to: `sample.mp4.4' |
| 89 | |
| 90 | 10% [========> ] 7,927,627 116K/s eta 9m 11s |
23 | | this will take you to H1 node (You can also directly ssh into H1 Node from your laptop if you prefer that way) |
24 | | |
25 | | on H1 Node |
26 | | |
27 | | {{{ |
28 | | #!sh |
29 | | cd choicenet/source/bin |
30 | | |
31 | | cp ../wrap . |
32 | | |
33 | | /sbin/ifconfig |
34 | | |
35 | | }}} |
36 | | |
37 | | Form the last command (ifconfig), please note down the IPV6 address of eth1. (This should begin with an fec0:: . This will be used the next terminal ) |
38 | | |
39 | | Choicenet is all about choices in the network. For our iperf test run, we currently have a set the network to use the High Bandwidth path "HB". If you like to take an alternate route based on your network preference , you can use any editor (vim, pico , nano) that you prefer to edit the ../config/config.txt and change HB to LB ( Low Bandwith) path or HBHL (High bandwidth High Latency) path as the last line. |
40 | | |
41 | | We then use a Choicenet wrapper app to convert an existing tcp application into a Choicenet application as shown below |
42 | | |
43 | | get ready to start the iperf Server here . Type the command and keep it ready . '''DO NOT RUN IT JUST YET''' |
44 | | |
45 | | {{{ |
46 | | #!sh |
47 | | sudo ./wrap /usr/bin/iperf -s -V |
48 | | }}} |
49 | | |
50 | | |
51 | | '''On TERMINAL 2''' |
52 | | |
53 | | {{{ |
54 | | #!sh |
55 | | cd ~/choicenet/source/bin |
56 | | }}} |
57 | | |
58 | | |
59 | | {{{ |
60 | | #!sh |
61 | | ./getool -f <MANIFEST FILENAME> -l <GENI USERNAME> -i ~/.ssh/id_rsa ssh h2 |
62 | | }}} |
63 | | |
64 | | this will take you to H2 node (You can also directly ssh into H2 Node from your laptop if you prefer that way) |
65 | | |
66 | | on H2 Node |
67 | | |
68 | | {{{ |
69 | | #!sh |
70 | | cd choicenet/source/bin |
71 | | |
72 | | cp ../wrap . |
73 | | |
74 | | }}} |
75 | | |
76 | | Choicenet is all about choices in the network. For our iperf test run, we currently have a set the network to use the High Bandwidth path "HB". If you like to take an alternate route based on your network preference , you can use any editor (vim, pico , nano) that you prefer to edit the ../config/config.txt and change HB to LB ( Low Bandwidth) path or HBHL (High bandwidth High Latency) path as the last line. |
77 | | We then use a Choicenet wrapper app to convert an existing tcp application into a Choicenet application as shown below |
78 | | |
79 | | get ready to start the iperf Client here . Type the command and keep it ready . '''DO NOT RUN IT JUST YET''' |
80 | | |
81 | | {{{ |
82 | | #!sh |
83 | | sudo ./wrap /usr/bin/iperf -c <IPv6 address of H1 > -V |
84 | | }}} |
85 | | |
86 | | (IPv6 address should be eth1 on H1 and starts with fec0) |
87 | | |
88 | | Now GOTO TERMINAL1 and run the iperf server command. Immediately then switch to TERMINAL2 and run the client command too. |
| 93 | The download speed should match the speed you select in the ChoiceNet App. |