Giter Site home page Giter Site logo

uwnetworkslab / meshinsight Goto Github PK

View Code? Open in Web Editor NEW
42.0 11.0 7.0 578 KB

MeshInsight: Dissecting Overheads of Service Mesh Sidecars

License: Apache License 2.0

Python 49.27% Dockerfile 0.06% Go 0.94% Shell 3.19% Lua 13.32% Perl 22.68% C 0.06% HTML 8.78% Rust 1.70%
envoy istio performance-analysis service-mesh

meshinsight's Introduction

MeshInsight

Overview

MeshInsight is a tool to systematically characterize the overhead of service meshes and to help developers quantify the latency and CPU overhead in deployment scenarios of interest. Read the paper for how MeshInsight works!

Note: MeshInsight currently only works on Istio. We plan to extend it to other service meshes (e.g., Cilium or Linkerd) in the future.

Installation

Requirements

  • Python (Version >= 3.7)
  • Kubernetes (Idealy version >=1.24)
    • Run . ./utils/k8s_setup.sh to install Kubernetes. (Note - this script is only tested on Ubuntu.)

Run the following script to install necessary tools for MeshInsight:

. ./install.sh

For details see INSTALL.md.

Run MeshInsight

workflow
MeshInsight Workflow

MeshInsight has an offline profiling phase and an online prediction phase. The offline phase generates performance profiles of individual service mesh components, and the online phase predicts overhead based on these profiles, service mesh configuration, and application workload. Optionally, MeshInsight can predict the performance of an optimization based on a speedup profile.

Step 1: Run offline profiler

# Run profiler for latency and cpu overhead profile. Root access is needed for BCC and perf
# Once it completes, the profile will be saved to meshinsight/profiles/
sudo -E python3 ./meshinsight/profiler/offline_profiler.py --latency --cpu

usage: offline_profiler.py [-h] [-v] [-c] [-l] [-d DURATION] 

optional arguments:
  -h, --help            show this help message and exit
  -v, --verbose
  -c, --cpu             run offline latency profiling
  -l, --latency         run offline cpu profiling
  -d DURATION, --duration DURATION
                        the duration for each measurement
                        default duration is 15s                    

Note:

  1. The profiler will delete all kubernetes deployments before it starts to minimize interference.
  2. We recommend running the offline profiler on a machine that has at least 16 cores.
  3. The offline profiling phase will take a few hours (~3 hours with duration of 15s)

Step 2: Run online predictor

# Run prediction based on an example call graph
python3 ./meshinsight/predictor/online_predictor.py -c ./meshinsight/predictor/config/example1.yml -p meshinsight/profiles/profile.pkl 

usage: online_predictor.py [-h] [-v] [-p PROFILE] -c CONFIG

optional arguments:
  -h, --help            show this help message and exit
  -v, --verbose
  -p PROFILE, --profile PROFILE
                        path to the profile
  -c CONFIG, --config CONFIG
                        path to config file

Please see PREDICTION.md for reference of configuration files.

Repo Structure

Repo Root
|---- benchmark   
|---- meshinsight   # MeshInsight source code
  |---- profiler    # Source code for offline profiler
    |---- benchmark   # Benchmarks used in the paper and their wrk scripts
  |---- predictor   # Source code for online predictor
|---- utils         # Some other tools for analyzing service mesh deployments
|---- samples       # Demo of service mesh performance analysis

Reference

Please consider citing our paper if you find MeshInsight related to your research.

@inproceedings{meshinsight,
  title={Dissecting Overheads of Service Mesh Sidecars},
  author={Zhu, Xiangfeng and She, Guozhen and Xue, Bowen and Zhang, Yu and Zhang, Yongsu and Zou, Xuan Kelvin and Duan, XiongChun and He, Peng and Krishnamurthy, Arvind and Lentz, Matthew and others},
  booktitle={Proceedings of the 2023 ACM Symposium on Cloud Computing},
  pages={142--157},
  year={2023}
}

Contact

If you have any questions or comments, please get in touch with Xiangfeng Zhu ([email protected]).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.