Skip to content
KimJeongChul edited this page Apr 26, 2019 · 6 revisions

Network - iperf3

Library : subprocess

EC2 Setting

  1. Start your EC2 instance, Configure EC2 Network and Subnet(same Lambda functions) image
  2. Configure your Security Group image
  3. Check your EC2 internal-ip (ex : 172.31.XX.XX)
  4. Install iperf3
sudo yum -y install iperf3
  1. Start iperf3 server default port : 5201
sudo iperf3 -s -p [PORT]
  1. Check your Lambda VPC Permission AWSLambdaVPCAccessExecutionRole image

  2. Config your Lambda Network image

Lambda payload(test-event) example:

iperf3 doc

server_ip : EC2 internal ip

server_port : iperf3 server port

reverse options : True or False

  • We can let a client(Lambda) work as either a data uploader(default / False) or downloader(with -R options / True).
  • True : downloader
  • False : uploader

test_time : Sets the interval time in seconds between periodic bandwidth, jitter, and loss reports.

{
    "server_ip": [SERVER_IP],
    "server_port": [SERVER_PORT],
    "test_time": [NUMBER_OF_TEST_TIME],
    "reverse" : [REVERSE_OPTION] 

Lambda Output : network sender and recevier bandwidth