Example, limit port 8000
to 100KByte/s
limit_band 100 8000
Remove bandwidth limit
remove_limit
function limit_band() { | |
sudo ipfw pipe 1 config bw $1KByte/s | |
sudo ipfw add 1 pipe 1 src-port $2 | |
} | |
function remove_limit() { | |
sudo ipfw delete 1 | |
} |