---
name: "writebuffer"
section: "1"
platform: "linux"
package: "chiark-rwbuffer"
version: "8.0.1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/writebuffer"
---

# writebuffer(1)

write output to devices which don't like constant stopping and starting

## NAME

writebuffer - write output to devices which don't like constant stopping and starting

## SYNOPSIS

**writebuffer** \[**--mlock**\] \[*size*\]

## DESCRIPTION

**writebuffer** reads data on standard input and writes it to standard output.  It will buffer internally up to *size* megabytes and will only write data when the buffer is at least 75% full or when there is no more input to fill the buffer.

*size* may also be suffixed with **m**, **k**, or **b** to indicate that it is in megabytes (2^20), kilobytes (2^10) or bytes.

It is intended for use in situations where many small writes are undesirable for performance reasons, e.g. tape drives.

## OPTIONS

- **--mlock**

  Calls [**mlock**(2)](/mlock/2.md) to lock the buffer into memory.

## SEE ALSO

[**readbuffer**(1)](/readbuffer/1.md), [**mlock**(2)](/mlock/2.md)
