4:15pm, Friday 3 January 2003
Some quick statistics on backing up a Linux machine remotely.
I have one machine with a DLT tape drive, and another without - but needing to be backed up, and the wrong side of the firewall. The basic solution is
ssh root@target "/sbin/dump 0f - /" | buffer >/dev/st0I fiddled with various block size settings, buffer thresholds and timings, and whether or not to use
dd
in the pipeline to set the output block size. Here are the results.
dump block size | pipeline | output block size | buffer -p | buffer -u | speed |
---|---|---|---|---|---|
(KB) | from buffer or dd (KB) | (KB/s) | |||
64 | dd | 10 | n/a | n/a | 83 |
64 | dd | 64 | n/a | n/a | 221 |
64 | buffer+dd | 64 | n | n | 212 |
64 | buffer | 64 | n | n | 3210 |
64 | buffer | 64 | 75 | n | 3165 |
10 | buffer | 10 | n | n | 2103 |
64 | buffer | 10 | n | n | 2135 |
64 | buffer | 64 | n | 100 | 2268 |
Conclusions:
- Using dd in the pipeline (to set the output block size) is unnecessary and a bottleneck.
- Buffering produces a large performance increase.
- Increasing the block size throughout the pipeline from the default 10KB up to MAXBSIZE (64KB) gives better performance.
- In this situation, adjusting the buffer threshold has no effect, and increasing the tape write delay gives a 30% slowdown.