# Mininet 2 /setting Node/link [TOC] ## 改Node 清空 node info ``` ifconfig h1-eth0 0 ``` 設定 Node ip ``` ip addr add 192.168.1.1/24 brd + dev h1-eth0 ``` brd == boradcast Node 1 ``` ip addr add 192.168.1.2/24 brd + dev h2-eth0 ``` Node 2 ``` ip addr add 192.168.1.1/24 brd + dev h1-eth0 ```  ## Analysis Tools Server ``` iperf -s -i 1 -u -p 8080 ``` Client ``` iperf -c 192.168.1.2 -t 10 -b 10M -u -p 8080 ```  ## Configure Link ### Link Loss Rate 設定 packet loss 的機率 ``` mn --link=tc,loss=5 ``` tc -> 內建tools loss rate = 5%  #### Test ``` h1 ping -c 1000 -i 0.01 h2 ```   ### Link Bandwidth  ``` mn --link=tc,loss=0,bw=5 ``` loss Rate = 0% bandwidth = 5MB/s #### Test Client 以10MB/s Send UDP packets client ``` iperf -c 10.0.0.2 -u -b 10M -t 10 ``` listener ``` iperf -s -u -i 1 ```  --- TCP client ``` iperf -c 10.0.0.2 -t 10 ``` Listener ``` iperf -s -u -i 1 ```  ### Link Delay (Latency)   
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up