6

Title says it all. For a bit more info though:

Basically, I have Time Warner cable internet. My speeds maintain a stable 2Mbit/s upload and 20Mbit/s download with average ping times around 30ms.

This crazy thing happens though when I upload anything. I went to upload a 200M file to my server today through sftp and my internet completely choked up. I speed tested it during this upload and my ping time was around 800ms, download speeds of 0.2Mbit/s and Upload speeds of 0.3Mbit/s. Note, I wasn't downloading anything during this time either. It is just straight upload.

What is it that causes this phenomenon? My router is OpenBSD. Is there anything I could set up to fix this problem(by queues or some such), or is this a problem with cable internet?

Earlz
  • 4,484
  • 18
  • 59
  • 84
  • Latency is the problem. You'll need to speak to your ISP. –  Sep 10 '12 at 03:10
  • @RandolphWest but latency is only a problem when uploading? – Earlz Sep 10 '12 at 03:18
  • Yep, which is why you have to speak to your ISP. I'm currently facing a similar problem with my connection. –  Sep 10 '12 at 03:26
  • 1
    You may need to implement QoS somehow on your router, but how you do this with OpenBSD, I don't know. Basically, it sounds like your upload is hogging almost all the upstream bandwidth. Downloads and other activity still require some of that upstream bandwidth to work responsively. – jjlin Sep 10 '12 at 05:03
  • +1 for QoS. Also you should try with other protocol like plain FTP or HTTP. Maybe your router is prioritizing the sftp traffic. – Rufo El Magufo Sep 10 '12 at 22:25
  • @JuanFranciscoCanteroHurtado I can post my pf.conf if it'd help, but no, my router isn't prioritizing anything right now. I'm wondering if maybe it should (or de-prioritize) – Earlz Sep 11 '12 at 03:04

3 Answers3

4

You ran a speed test whilst uploading. The upload then showed 0.3 mbit/s. I assime your file upload speed to the server was somewhere near (2 mbit/s - 0.3 mbit/s), right? As jjlin saus: downloading also needs uploading. Limit the upload speed to your server (sftp -l) for example to 1.5 mbit/s and then see if your downloads run smoothly again when you are uploading.

Vincent
  • 1,132
  • 7
  • 16
3

I run OpenBSD on my egress device at home and have had this addressed for quite a while. I recommend you read about this well-known phenomenon at https://web.archive.org/web/20120923235002/http://www.benzedrine.cx/ackpri.html for more information on how to address this using pf (the author is the original developer of pf).

Bink
  • 145
  • 4
  • This looks very promising! I'll try this tomorrow – Earlz Sep 14 '12 at 05:51
  • I put that bit of queuing on to my OpenBSD router and now it works like a champ! Also I don't have such sporadic ping times in general now which helps with online games. Do you know if something like this should also be done with UDP or if it'd hurt? – Earlz Sep 17 '12 at 14:57
  • Glad to hear that did the trick for you. As for UDP traffic, you’ll want to prioritize any important traffic. For example, I prioritize my VoIP, which is UDP, over my TCK ACK traffic—because a clear phone call is more important than perfectly fast downloads! – Bink Sep 18 '12 at 16:33
  • 1
    @Bink Note that the link in your answer no longer points to the desired article. It seems the website was sold or something akin. The intended article can be found via the [Wayback Machine](https://web.archive.org/web/20120923235002/http://www.benzedrine.cx/ackpri.html) or on [pastebin](https://pastebin.com/07cEuXxh). – E.Nole Mar 14 '20 at 17:10
1

Another thing to keep in mind is that service providers use a number of techniques to keep residential users from operating commercial servers on their connections. One technique is to monitor the aggregate upload megabytes over a few minutes, and, if it's high, start to "choke" the connection.

So a medium-sized upload may run fairly fast, but a larger one will slow down and also slow down the download rate with it.

Daniel R Hicks
  • 6,143
  • 3
  • 27
  • 50