-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement a receive / send buffer on zfs send | zfs receive #4281
Comments
referencing: #1161 Implement zfs recv buffer , ryao@3530cf2 Increase Linux pipe buffer size on zfs recv to the maximum system size in addition to behlendorf's comment (#1112 (comment)) Illumos 5694 - traverse_prefetcher does not prefetch enough there were also changes to prefetch itself: 7f60329 Illumos 5987 - zfs prefetch code needs work options you have for buffering (mostly on the receiving side appears to be advantageous, mentioned in the issues): lz4, lz4hc |
@RubenKelevra As @kernelOfTruth mentioned, an increased buffer size has already been implemented in zfs recv. It just is not configurable via the commandline tool and instead opts to use the value of I had only touched That being said, I would prefer not to duplicate the functionality of |
I'm still importing from one machine while importing several hundert snapshots as diff (via send -I a@1 a@800 ). On the second import the import just stall several dozend seconds, than he imports the full buffer and stall again after some seconds ... The 6 disks are only avg 6% busy... the z_wr_iss processes seem to block here ... what are the purpose of these processes? |
They issue write IOs to disk. |
My issue seem to be the same at this: https://serverfault.com/questions/507587/zfs-send-i-receive-stalling |
So is mbuffer still needed at all with all the latest changes to send and receive? |
The question is, is this feature worthwhile enough to make it part of send/recv directly? I gave my opinion in the other issues. |
In that case, does it help only on the receive side or on both send and receive? |
While it helps either side, if you could only have one side implement the buffer or have the larger buffer then the right choice is the receiver. |
If you use current master. It does use |
switch to lz4. I had an old dataset using gz9 and I went crazy trying to find out why is my cpu burning on receive. switched to lz4 and transfer went back to expected speed. and I hope you have a very particular case to justify dedup. |
Old open issue. Let me leave my opinion: I think zfs send/recv should have a minimum buffer. Enough for most critical operations, but not more than that. Maybe something like block size (128k?) times number of simultaneous physical I/O permitted on the pool in question. Maybe, also, this same sized buffer on both sides, send and recv. Obviously more buffer may mean more performance, but Unix Philosophy is to create small programs to do small things, and pipe them through. So, IFF the user wants, let the user add mbuffer or whatever to his pipe. |
I found this article, which shows an issue on zfs send | zfs receive.
http://everycity.co.uk/alasdair/2010/07/using-mbuffer-to-speed-up-slow-zfs-send-zfs-receive/
This is especially an issue when receiving over a slow network, like dsl. First at all, when the disks are able to receive they got to less data and when they stall no data is transferred at all.
Secondly I use a tcp session to transfer the data over ssh, so I think the issue is increased because the tcp is constantly running it's slow start to avoid congestion, with bursty data transfers the bandwidth ist further wasted.
With mbuffer with 1 GB size on both sending systems and 2x 1 GB on receiving side I reduced my backup-time massively because my dsl is now constantly filled up with data.
So it would be nice if it's possible to implement a similar function in zfs send | zfs receive. A progress graph would be also nice, as optional feature.
The text was updated successfully, but these errors were encountered: