Issue while sending files with iperf3
Hello eveyone;
I want to send a file using iperf:(From client to server.)
I used below command at server side:
iperf3 -s -F lambo.jpg
And also at client side I used this command:
iperf3.exe -c <server_ip> -F lambo.jpg
But only a small portion of the original jpg can be send
You can see the transmitted and original files in the links:
https://prnt.sc/MGBKLs5MA9bA
https://prnt.sc/n_Zz7T2-1ljW
I tried the test on Windows 11 and the file transfer work o.k. Does iperf3 report that the transfer was successful (and the number of bytes transferred is about the file size)? If this is the case, you may be using and old version of iperf3 (3.1.3?) and you should probably try first a newer version.
Also, iperf3 isn't a real great file transfer tool, even if it does transfer the bytes correctly. If the point is to actually copy a file between machines, something like scp, sftp, or even netcat would probably be better suited to this.
Hello again; I want to give some setup details.
The server is a Toradex Apalis imx6 SoM. And client is my Windows 10 PC
At the client side it says: %163 of the file is transmitted
As davidBar-on said it might be older version of iperf; I bitbaked latest iperf3 ipk with yocto project. And used latest windows iperf3.exe
But the result is still the same
Scp or sftp is not suitable for me because the transfer must not be encrypted
I tried using netcat with udp but same problem occurred
Can you please add some more info:
- What is the Client and Server iperf3 versions? Can you send the output of
iperf3 -v(which also includes the version number)? (If the Windows client is 3.1.x ,you may get a newer version from here - note that this is not an official iperf3 site). - Can you run the Client using
-V -Joptions and send the Client's output? This may allow to better understand where the problem is. Sending the Server's output (using these options) may also help.
For the client you are using version 3.1.3 which is very old and may be the reason for the issue. E.g see the fix by PR #588 that was done for version 3.2.
For the Client under Windows you should get a newer version from here (note that this is not an official iperf3 site). Download iperf3.13_64.zip, unzip it and run iperf3 from the extracted folder.
Hello again;
I dowloaded latest version from the link.It is better now, but still problem continues:



One more question would be;
Is it possible to use iperf to send a pre known pattern instead of random data?
The reason I want to send a file is to do a binary comparison of the received data with the original file.
If I can send a pre known pattern, this would also be enough for me.
-
You can use the
--repeating-payloadto send per-defined patter - the sent packet will include repeated "01234567890123456789012...". However, if you need to store the sent data in a file on the server side using-F, functionality is not consistent. It seems that at least the first packet is stored, so you may user-l 1Mto send large packets. You can also use-kto send only limited number of packets (e.g. only one packet). -
I was able to create a similar problem to the problem you have, but using iperf3 version 3.9. It did not happen when using the official 3.11 version (your server's version), and it seems that the problem was fixed in 3.10 by PR #1115. You may try to build version 3.13 for the server yourself:
- Download iperf3 3.13
.tar.gzfile from here and unzip/untar it. - Change directory to the
iperf-3.13folder. - Run
./bootstrap.sh- If it fails because of "Autoconf version 2.71 or higher is required", get the version of autoconf by running
autoconf -Vand change "2.71" in line 27 ofconfigure.acto that version. Then run./bootstrap.shagain.
- If it fails because of "Autoconf version 2.71 or higher is required", get the version of autoconf by running
- Run
./configuration - Run
make - The generated iperf3 executable is
./src/iperf3
- Download iperf3 3.13
Hi everyone,
I'm having trouble saving a file using iperf version 2.1.0. The logs indicate that the file was transmitted successfully, but I'm not sure how to save it on the server side.
Can anyone help me with this?
Thank you!
@chandusurisetty, note that this is an iperf3 forum/issue, not iperf2 (iperf) that you are using. As far as I understand (but I am not 100% sure), iperf2 support only sending from a file but not writing the received data to a file.
iperf3 does support writing the received data to a file, but note that this is regardless of whether the sent data is from a file or not.