Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Recently, I use lftp as a ftp client to upload some files to ftp server on wireless network(dial with WCDMA/GSM modem),
I find the upload rate graph is different from other ftp client ,such as filezilla.
When wireless network signal is not very good, lftp rate graph look like a jaggies zigzag line, while filezilla
rate graph look like smoothly.
After I catching uploading wireshark log, I find the reason as below:
1)After tcp connection is created, lftp send lots of tcp packets to wireless modem and wait response, but now, wireless modem need much time to transfer these packets to ftp server, so lftp wait a lot of time to send next serial packets.
when I look rate graph on PC, its look like a jaggies zigzag line.
2) But filezilla send packets according the the real network environment, that is , when network signal is bad, its send
lftp is a pretty simple client, and relies on the TCP subsystem in the TCP/IP stack to throttle the connection by adjusting the TCP window size and so on. The Linux kernel supports a number of different TCP congestion control algorithms, at perhaps the one used by your kernel isn't very well-suited for this particular scenario.
I don't know anything about FileZilla, but it may very well be "holding back" packets and do its own congestion control by, say, using a smaller TCP window size. That would explain why the transfer appears to go smoother. I wouldn't expect this to dramatically affect transfer times, but it would make the connection appear much less congested as the buffer in the modem isn't filled to capacity.
You could try switching to another TCP algorithm, if your kernel supports it. If you have a file called /proc/config.gz on your system, the command
Code:
zcat /proc/config.gz | grep TCP_CONG_
should produce a list of supported TCP congestion algorithms, and whether they're compiled as modules or directly into the kernel. You switch algorithms by echoing the name of the desired algorithm (for instance, "Vegas") to the /proc/sys/net/ipv4/tcp_congestion_control file. See this article for more details.
The real problem here is actually the buffer in the modem, which from what you're saying is way too large. Congested connections should be dropping packets, not putting them in a huge queue.
Like most TCP applications, lftp doesn't use a specific algorithm. It just feeds data to a TCP connection, and leaves it to the IP stack of the operating system to adjust window sizes and throttle transfer speed.
Since the host OS is in fact Windows, there is (AFAIK) little you can do to change the behaviour of the TCP subsystem in the IP stack. A different and more advanced client that overrides the local IP stack and performs its own queuing and throttling would be one solution.
Another approach would be to install an application that can queue, prioritize and throttle all IP traffic from a Windows host, such as NetLimiter. Yet another would be to get a decent modem.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.