Linux: Limiting data throughput (pipe) in bytes per second?
Posted
by
sdaau
on Super User
See other posts from Super User
or by sdaau
Published on 2011-03-18T10:11:37Z
Indexed on
2011/03/20
8:11 UTC
Read the original article
Hit count: 225
Hi all,
I was wandering if there is a Linux program that can limit data throughput of a pipe - in actual bytes per second?.
From what I gather, applicable for the purposes would be
bfr
, however, it has been removed from Debian (Removal candidate: bfr)cpipe
, however, it seems the lowest resolution it will support is kB/s, meaning that buffer writes can still reach MB/s ([SOLVED] Is there a program to limit terminal pipe speed? - Page 2 - Ubuntu Forums)
What I'd want is to be able to specify something like
cat example.txt | ratelimit -Bps 100 > /dev/ttyUSB0
... and actually have a single byte from example.txt sent each 1/100 = 0.01 sec (or 10 ms) to 'output'..
Thanks in advance for any suggestions,
Cheers!
© Super User or respective owner