簡易檢索 / 詳目顯示

研究生: 盧逸恆
Yi-Heng Lu
論文名稱: 透過行程間通訊中之共享記憶體在容器間進行資料傳輸
Data Transmission Between Containers Using IPC with Shared Memory
指導教授: 沈上翔
Shan-Hsiang Shen
口試委員: 沈上翔
Shan-Hsiang Shen
金台齡
Tai-Lin Chin
沈中安
Chung-An Shen
黃琴雅
CHIN-YA HUANG
學位類別: 碩士
Master
系所名稱: 電資學院 - 資訊工程系
Department of Computer Science and Information Engineering
論文出版年: 2022
畢業學年度: 110
語文別: 英文
論文頁數: 34
中文關鍵詞: 容器行程間通訊共享記憶體DockerDocker Compose
外文關鍵詞: Container, Inter-Process Communication, Shared Memory, Docker, Docker Compose
相關次數: 點閱:108下載:0
分享至:
查詢本校圖書館目錄 查詢臺灣博碩士論文知識加值系統 勘誤回報
  • 容器是一種作業系統虛擬化的形式,它們輕巧、快速且易攜帶,它們可以在不同
    環境執行,比如筆電、虛擬機器、雲端供應商等等。愈來愈多業者因容器的快捷
    性將他們的應用程式或服務放到容器裡執行。在5G網路的時代,網路走向虛擬
    化,在高速網路中,傳輸速度很重要,所以能加快封包通過網路功能是一件很重
    要的事。因為容器的特性與網路功能的想法非常吻合,研究人員開始利用容器來
    實作網路功能,比如說服務功能鏈(Service Function Chaining)。雖然有容器管理工
    具的幫助,可以串聯兩個以上的容器並進行傳輸,但目前主流的實現方法會拉高延遲。

    在本文中,我們提出一種在容器與容器間資料的傳輸方法,我們的方法使用
    了行程間通訊中的共享記憶體來改善延遲問題,共享記憶體被視為其中一種傳輸
    資料最快速的方法。在共享記憶體中,同步化是一項重要的課題,我們實作了簡
    單的鎖,不僅解決同步問題也只些微地影響延遲。我們也有用鑰匙技術,用來保
    證傳送的順序且防止容器讀到不屬於他們的信息。藉由上述的幫助,我們的方法
    優於目前主流使用socket的傳輸方式。


    Containers are a form of operating system virtualization. They are lightweight, fast, and portable. They can be running on different environments, including laptops, virtual machines, cloud providers, etc. More and more enterprises put their applications or services into a container due to its agility. In the era of 5G networks, networks tend to be virtualized. In the high-speed network, the transmission speed is critical. It is important to speed up packet processing in the network functions. Because the light-weight features of the container well fit the idea of network function, researchers start to implement network functions with container, for instance, Service Function Chaining (SFC). Although container management tools can chain two or more containers to transmit data, the main
    method to implement SFC currently increases the latency.

    In this article, we propose a transmission method between containers. Our method
    uses inter-process communication (IPC) with shared memory, which has been known as
    one of the fastest methods to transmit data to improve the latency problem. Synchronization is an important issue in shared memory. We implement a simple lock not only solve the problem but merely affect latency. We also use a key to guarantee the order of the transmission and to prevent a container from reading messages not belonging to it. With the above assistance, our method outperforms the recent method using sockets.

    論文口試委員審定書 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . i 論文口試委員審定書 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ii 中文摘要 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii Abstract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iv Acknowledgment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . v Table of contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vi List of Figures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . viii 1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 2 Related Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 2.1 Docker Container . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 2.2 POSIX/SysV IPC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 2.3 Network Function Implement by Container . . . . . . . . . . . . . . . . 7 3 Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 3.1 Data transmission . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 3.2 Synchronization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 3.3 Privacy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 4 Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 4.1 Experiment environment . . . . . . . . . . . . . . . . . . . . . . . . . . 13 4.2 Evaluation results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 4.2.1 Latency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 4.2.2 Throughput . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 4.2.3 Stability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 5 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

    [1] Gartner, “Forecast analysis: Container management (software and services), worldwide.” https://www.gartner.com/en/documents/3985796, 2020.
    [2] Q. Zhang, L. Liu, C. Pu, Q. Dou, L. Wu, and W. Zhou, “A comparative study of
    containers and virtual machines in big data environment,” in 2018 IEEE 11th International Conference on Cloud Computing (CLOUD), pp. 178–185, IEEE, 2018.
    [3] O. Al-Debagy and P. Martinek, “A comparative review of microservices and monolithic architectures,” in 2018 IEEE 18th International Symposium on Computational
    Intelligence and Informatics (CINTI), pp. 000149–000154, IEEE, 2018.
    [4] Amazon, “Breaking a monolithic application into microservices.” https://aws.
    amazon.com/microservices/?nc1=h_ls.
    [5] Kubernetes, “Kubernetes main page.” https://kubernetes.io/.
    [6] R. Hat, “Red hat openshift main page.” https://www.redhat.com/en/
    technologies/cloud-computing/openshift.
    [7] DockerDocs, “Docker swarm docs.” https://docs.docker.com/engine/
    swarm/.
    [8] B. Milas, “Docker compose github.” https://github.com/docker/
    compose, 2022.
    [9] A. M. Medhat, T. Taleb, A. Elmangoush, G. A. Carella, S. Covaci, and T. Magedanz,
    “Service function chaining in next generation networks: State of the art and research
    challenges,” IEEE Communications Magazine, vol. 55, no. 2, pp. 216–223, 2016.
    [10] R. Mijumbi, J. Serrat, J.-L. Gorricho, N. Bouten, F. De Turck, and R. Boutaba,
    “Network function virtualization: State-of-the-art and research challenges,” IEEE
    Communications surveys & tutorials, vol. 18, no. 1, pp. 236–262, 2015.
    [11] A. Hakiri, A. Gokhale, P. Berthou, D. C. Schmidt, and T. Gayraud, “Softwaredefined networking: Challenges and research opportunities for future internet,”
    Computer Networks, vol. 75, pp. 453–471, 2014.
    [12] K. Kaur, V. Mangat, and K. Kumar, “A comprehensive survey of service function
    chain provisioning approaches in sdn and nfv architecture,” Computer Science Review, vol. 38, p. 100298, 2020.
    [13] SDXCentral, “How sfc is set up and operate.” https://citelab.github.
    io/gini5/features/service-function-chaining/.
    [14] B. Krzysztof, “Sfc implemented by docker compose.” https://github.com/
    kbijakowski/docker_sfc_blueprint, 2019.
    [15] Oracle, “System v ipc.” https://docs.oracle.com/cd/E19455-01/
    806-4750/6jdqdfltg/index.html.
    [16] X. ZHANG, “The analysis and comparison of inter-process communication performance between computer nodes,” Management Science and Engineering, vol. 5,
    no. 3, pp. 162–164, 2011.
    [17] S. Krishnaveni and D. Ruby, “Comparing and evaluating the performance of inter process communication models in linux environment,” International Journal of
    Trend in Research and Development, pp. 51–55, 2016.
    [18] S. Smith, A. Madhavapeddy, C. Smowton, M. Schwarzkopf, R. Mortier, S. Hand,
    and R. M. Watson, “Draft: Have you checked your ipc performance lately?,” Publ.
    Citeseer.
    [19] Docker, “Docker architecture.” https://docs.docker.com/
    get-started/overview/.
    [20] IBM, “Introduction to message queuing.” https://www.ibm.com/docs/en/
    ibm-mq/9.1?topic=overview-introduction-message-queuing.
    [21] Oracle, “System v semaphores.” https://docs.oracle.com/cd/
    E19683-01/816-5042/auto32/index.html.
    [22] IBM, “Overview of shared memory.” https://www.ibm.com/docs/en/
    power8?topic=memory-overview-shared.
    [23] F. Sandakly, J. Garcia, P. Ferreira, and P. Poyet, “Distributed shared memory infrastructure for virtual enterprise in building and construction,” Journal of Intelligent
    manufacturing, vol. 12, no. 2, pp. 199–212, 2001.
    [24] S. Livi, Q. Jacquemart, D. L. Pacheco, and G. Urvoy-Keller, “Container-based service chaining: A performance perspective,” in 2016 5th IEEE International Conference on Cloud Networking (Cloudnet), pp. 176–181, IEEE, 2016.
    [25] S. Martin, “Container service chaining.” http://events17.
    linuxfoundation.org/sites/events/files/slides/
    ContainerServiceChaining_MartinSunal.pdf, 2017.
    [26] N. Siasi, M. Jasim, J. Crichigno, and N. Ghani, “Container-based service function
    chain mapping,” in 2019 SoutheastCon, pp. 1–6, IEEE, 2019.
    [27] R. Morabito and N. Beijar, “A framework based on sdn and containers for dynamic
    service chains on iot gateways,” in Proceedings of the Workshop on Hot Topics in
    Container Networking and Networked Systems, pp. 42–47, 2017.
    [28] Docker, “Ipc settings.” https://docs.docker.com/engine/
    reference/run/.
    [29] Beej’s, “Shared memory segments.” https://beej.us/guide/bgipc/
    html/multi/shm.html.
    [30] NLM, “Standard deviation definition.” https://www.nlm.nih.gov/
    nichsr/stats_tutorial/section2/mod8_sd.html.
    [31] C. Guo, H. Wu, Z. Deng, G. Soni, J. Ye, J. Padhye, and M. Lipshteyn, “Rdma
    over commodity ethernet at scale,” in Proceedings of the 2016 ACM SIGCOMM
    Conference, pp. 202–215, 2016.

    無法下載圖示 全文公開日期 2026/09/20 (校內網路)
    全文公開日期 2026/09/20 (校外網路)
    全文公開日期 2026/09/20 (國家圖書館:臺灣博碩士論文系統)
    QR CODE