跳转到主内容

为什么小文件与大文件的文件传输速度可能不同

Views:
602
Visibility:
Public
Votes:
0
Category:
ontap-9
Specialty:
nas
Last Updated:

适用场景

  • ONTAP 9
  • 7-模式 Data ONTAP

问题解答

  • 对于所有主要操作系统、尝试读取或写入大量小文件会产生大量操作系统开销。
    • 这是因为在操作系统级别上花费了更多的时间对客户端正在处理的每个文件执行find()、open()和Close()操作。
    • 示例:在SMB2中查找并打开文件几乎需要一秒钟的时间、以下元数据调用可查找父文件夹、子文件夹、查找文件是否存在、然后打开(SMB2创建调用)文件、关闭文件、再次打开、最后读取文件。
    • 小型文件的屏幕截图cii removed.png
  • SMB2/3具有比NFS更多的元数据工作负载。
    • Linux客户端还可以缓存某些属性、以避免不必要的其他I/O调用。
  • 当安全硬件/软件扫描客户端与ONTAP之间网络上的每个文件时、或者在客户端级别、可能会发生额外的延迟。
  • 由于大型文件是连续操作、因此可以快速进行传输、并可利用以下功能:
    • n在NFS上连接
    • 适用于NFS的64 KB到1 MB rsize/wsize挂载选项。
    • SMB3大型MTU:与巨型帧不同、此功能可启用1 MB的读/写操作大小。
    • SMB3多通道:允许并行TCP流在TCP级别通过更多逻辑连接传输文件。
    • TCP拥塞Windows:自Windows Vista日(21世纪中期)以来、TCP的窗口大小会滑动到MB、并允许大型文件传输利用单个TCP流的更多带宽。
    • 这些功能不适用于小型文件、因为它们通常可以容纳在一个TCP流上、并且小于默认读写大小(通常为64k)。
      • 元数据调用不会并行执行、而是按顺序进行处理。

追加信息

 

 

NetApp provides no representations or warranties regarding the accuracy or reliability or serviceability of any information or recommendations provided in this publication or with respect to any results that may be obtained by the use of the information or observance of any recommendations provided herein. The information in this document is distributed AS IS and the use of this information or the implementation of any recommendations or techniques herein is a customer's responsibility and depends on the customer's ability to evaluate and integrate them into the customer's operational environment. This document and the information contained herein may be used solely in connection with the NetApp products discussed in this document.