FG
💻 Software

How to rate-limit a pipe under linux?

Fresh6 days ago
Mar 15, 202630231 views
Confidence Score1%
1%

Problem

Is there a filter which I could use to rate-limit a pipe on linux? If this exists, let call it rate-limit, I want to be able to type in a terminal something like in order to send a a stream of random bytes to foo's standard input at a rate (lower than) 3 kbytes/s.

Error Output

cat /dev/urandom | rate-limit 3 -k | foo

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Unverified Fix
New Fix – Awaiting Verification

Fix for: How to rate-limit a pipe under linux?

Low Risk

Pipe Viewer has this feature. From the man page: -L RATE, --rate-limit RATE Limit the transfer to a maximum of RATE bytes per second. A suffix of "k", "m", "g", or "t" can be added to denote kilobytes (*1024), megabytes, and so on.

Awaiting Verification

Be the first to verify this fix

Sign in to verify this fix

Environment