透過您的圖書館登入
IP:3.145.143.239
  • 學位論文

改善Linux網路儲存系統上Samba伺服器檔案讀取之效能

Performance Optimization of the Samba Read Service on Linux-based Network-Attached Storage Systems

指導教授 : 洪士灝

摘要


近年來,網路儲存系統(network-attached storage,NAS)廣泛應用於公司或住家內,用來提供檔案、印表機等資源的分享。然而,大多數低階的網路儲存系統處理器為了節省成本,使用了低成本的控制器(controller),這些控制器的運算速度不快,不足夠去處理網路協定與I/O操作,以致於無法有效處理1Gbps乙太(Ethernet)網路甚至10Gbps乙太網路,而產生了效能的瓶頸。 為了減少處理器的負擔,過去有RDMA(Remote Direct Memory Access)的研究,欲減少處理器花費在資料搬移的時間;也有TCP卸載引擎(TCP offload engine)的研究,透過硬體來分擔處理器處理TCP網路協定的運算。雖然能夠有效減輕處理器的負擔,但缺點是耗費的成本很高、增加系統的複雜度以及軟體必須對應卸載引擎作更改,對於低階的網路儲存系統並不適用。 本論文對Linux網路儲存系統上Samba伺服器的效能做評估與測試,找出其效能瓶頸,探討如何以較低成本的方式,改善Samba伺服器的檔案讀取效能,以應用在低階的網路儲存系統。我們成功將Samba處理資料的主要功能遷移到Linux作業系統核心(kernel),以減輕對處理器在資料搬移的負擔。由於軟體架構的改變,我們得到5.5% ~ 27.9%的讀取效能增益。

並列摘要


In recent years, Network-Attached Storage (NAS) has become a popular choice for storing and sharing in a workgroup or at home. For low-end NAS servers, the tradeoffs between performance and cost is an important issue. Many low-end NAS servers failed to fully utilize the bandwidth of 1Gbps Ethernet network, because the processor embedded in those servers do not have sufficient computation power to process the network protocols and I/O operations. Several solutions were proposed: RDMA (Remote Direct Memory Access) supports zero-copy networking by enabling the network adapter to transfer data directly to or from application memory; TCP offload engine (TOE) shifts TCP/IP processing tasks to the network adapter or storage device. However, even with these solutions, hardware-software co-design is a key issue and software modifications are needed to take advantage from the offload engines. In this thesis, we present a study which uses performance evaluation tools and methodologies to guide software modifications and hardware-software co-design. In this case study, we evaluated the performance of read operations on a Samba server. Then, the performance was improved by porting the application into kernel space after identifying the performance bottleneck by tracing tools. Furthermore, we removed one unnecessary data copy operation for each read request. Our results showed that the performance was improved by 5.5% ~ 27.9% compared to original code. In addition, we compare the performance results with an existing method, the sendfile system call, which removes two major data copy operations while handling read requests in the Samba service.

參考文獻


[2] Dalessandro, D., and Wyckoff, P., "Memory Management Strategies for Data Serving with Rdma", in 15th IEEE Symposium on High-Performance Interconnects, 2007, pp. 135-142.
[3] Yoon, I.-S., and Chung, S.-H., "Implementation and Analysis of Tcp/Ip Offload Engine and Rdma Transfer Mechanisms on an Embedded System", in Asia-Pacific Computer Systems Architecture Conference, 2005, pp. 818-830.
[8] Kang, D.-J., Kim, K.-H., Jung, S.-I., and Bae, H.-Y., "Tcp/Ip Offload Engine Module Supporting Binary Compatibility for Standard Socket Interfaces", in Grid and Cooperative Computing, 2005, pp. 357-369.
[10] Li, Y.-C., and Chiang, M.-L., "A Zero-Copy Tcp/Ip Protocol Stack for Embedded Operating Systems", in Embedded and Real-Time Computing Systems and Applications, 2005, pp. 123-128.
[11] Oh, S.-C., and Kim, S.-W., "An Efficient Linux Kernel Module Supporting Tcp/Ip Offload Engine on Grid", in Fifth International Conference on Grid and Cooperative Computing, 2006, pp. 228-235.

延伸閱讀