Soheil-ab / sage

Sage of Congestion Control (or How Computers Can Learn from Existing Schemes and Master Internet CC)
MIT License
38 stars 11 forks source link

Question about the relationship between iPerf and Sage Client/Server #13

Closed isZXY closed 3 months ago

isZXY commented 3 months ago

In Sage.cc, Line 237 and 238,

sprintf(tmp_cmd,"%s sudo -u `echo $USER` iperf3 -c $MAHIMAHI_BASE -p %d -R -i 0 -t %d &",tmp_cmd,client_port+i,duration);
sprintf(pre_cmd,"%s sudo -u `echo $USER` iperf3 -s -p %d -i 0 &",pre_cmd,client_port+i);

These lines create an iperf client and server for each flow (there will be serveral iperf) to measure bandwidth and network performance (is this correct?). They are then added to the container_cmd and final_cmd. Thus, when starting the Sage client and server (which sending and receiving "1"), iperf is also started for each flow.

What is the meaning and relationship between iPerf and the Sage Client/Server? From my understanding, iPerf is used for network performance benchmarking (e.g., bandwidth usage and latency), while the Sage Client/Server is responsible for the actual data transmission using Sage's congestion control. Is this correct? Additionally, will iperf and the Sage Client/Server influence each other, e.g., Bandwidth Occupation and compete?

Thank you for your help!

isZXY commented 3 months ago

I ignore the start of the loop is not 0 but 1. When flow_num > 1, the first flow will be sage flow, and other flows generated by iperf is working as background flow that compete with sage flows.