Given the following command:
gunzip -c /mnt/mysmbshare/mybackup.gz | dd of=/dev/sdb bs=1M
Why would the machine go through cycles of a really long phase of reading data from the network (with no disk activity), THEN writing all of that to disk (while not reading from the network drive), repeatedly?
Only 1.7GB of the 8GB of RAM is being consumed - I would have thought it could be smarter about streaming the data to disk.
In other words, the disk
/dev/sdb is surely the bottleneck (
/mnt/mysmbshare can saturate the gigabit ethernet easily) - so why does the command above leave it idle for ages while reading from the network into RAM?
In the case where actually the CPU is the bottleneck (dealing with gunzip), why is it left idle for ages in each cycle?