vethを介する通信をブリッジとNATで制御 • ホスト環境(docker: net=host)と比べて, ネットワークI/O性能が低下[1][2] ◦ パケット送受信時にデータパスが長くなる [3] eth0 コンテナ ブリッジ … eth0 veth コンテナ eth0 veth NAT(iptables) [1]Anderson, J., Hu, H., Agarwal, U., Lowery, C., Li, H. and Apon, A.: Performance considerations of network functions virtualization using containers, 2016 International Conference on Computing, Networking and Communications (ICNC), p 1-7 (2016). [2]Zhao, Y., Xia, N., Tian, C., Li, B., Tang, Y., Wang,Y., Zhang, G., Li, R. and Liu, A. X.: Performance of Container Networking Technologies, Proceedings of the Workshop on Hot Topics in Container Networking and Networked Systems, HotConNet '17, Association for Computing Machinery, pp. 1-6 (2017). [3]Nakamura, R., Sekiya, Y. and Tazaki, H.: Grafting Sockets for Fast Container Networking, Proceedings of the 2018 Symposium on Architectures for Networking and Communications Systems, Association for Computing Machinery, pp. 1 (2018). コンテナ ブリッジ NAT eth0 veth eth0 Ethernet Ethernet IP アプリ TCP IP Ethernet ソケット
2. I/O仮想化ハードウェアを使用した手法 e.g. SR-IOV[6] 3. OSカーネルをバイパスした手法 4. 軽量なOS・OS機能の実装手法 [4]Thomas, G.: KubeCon + CloudNativeCon Europe 2018,Cilium Accelerating Envoy with Linux Kernel, https://sched.co/EJAt ((Accessed on 08/26/2020)). [5]William, T.: Open vSwitch 2018 Fall Conference, Fast Userspace OVS with AF XDP, https://www.openvswitch.org/support/ovscon2018/ ((Accessed on 08/26/2020)). [6]Jun Nakajima,Building High-Performance NFV Solutions Using Containers,https://events.static.linuxfound.org/sites/events/files/slides/Jun_Nakajima_NFV_Container_final.pdf((Accessed on 11/23/2020)). LTなのでこっちを一部だけ
• AF_INETなどを使う既存のアプリケーションが AF_GRAFTを使用するために, socket()などをフックして変換 • https://github.com/upa/af-graft 軽量なOS・OS機能の実装手法:Socket-Grafting[8] 7 AF_GRAFTのデータパス[9] [8] Nakamura, R., Sekiya, Y. and Tazaki, H.: Grafting Sockets for Fast Container Networking, Proceedings of the2018 Symposium on Architectures for Networking and Communications Systems, Association for Computing Machinery, pp. 1 (2018). AF_GRAFTのデータパス(赤線) [8]