MacKuba

🍎 Kuba Suder's blog on Mac & iOS development

Bandwidth limiting in MacOSX

Categories: Mac Comments: 0 comments

I played a bit with bandwidth limiting tools in MacOSX recently. The reason was that I was uploading huge files to DivShare, and my Firefox took all the available upload bandwidth; and since upload bandwidth happens to be quite useful even when you’re not really uploading anything, everyone at home (including me) had serious problems with using the web at the time. So I thought I could try to force Firefox somehow to limit the maximum upload speed.

I’ve found a plugin which does exactly that, but it was only for Windows… (a plugin for a cross-platform browser which is not cross-platform? come on…). So I started looking for some system-wide solution. I found two pages that explained how to do this – it turns out it’s pretty easy, at least for someone that’s not afraid of the command line.

Everything is done using the ipfw command (IP FireWall?…). First you have to create one or more “pipes” with a constant share of bandwidth assigned:

sudo ipfw pipe <pipe_nr> config bw <amount>kbit/s

Read more »