{"id":24626569,"url":"https://github.com/iogbole/ebpf-network-viz","last_synced_at":"2025-05-07T18:50:17.699Z","repository":{"id":199377792,"uuid":"692765226","full_name":"iogbole/ebpf-network-viz","owner":"iogbole","description":"Getting Started with eBPF","archived":false,"fork":false,"pushed_at":"2023-11-04T21:22:56.000Z","size":866,"stargazers_count":9,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-01-25T21:45:40.715Z","etag":null,"topics":["ebpf","go","golang","prometheus","tcp"],"latest_commit_sha":null,"homepage":"https://www.israelo.io/blog/ebpf-net-viz/","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/iogbole.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-09-17T14:16:20.000Z","updated_at":"2023-12-18T02:21:48.000Z","dependencies_parsed_at":null,"dependency_job_id":"4fc1931f-a0f2-4d5d-87c7-132bf2807b1e","html_url":"https://github.com/iogbole/ebpf-network-viz","commit_stats":{"total_commits":16,"total_committers":1,"mean_commits":16.0,"dds":0.0,"last_synced_commit":"10fbdffa19a910404d7e678265d636cb8691bea2"},"previous_names":["iogbole/ebpf-network-viz"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iogbole%2Febpf-network-viz","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iogbole%2Febpf-network-viz/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iogbole%2Febpf-network-viz/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iogbole%2Febpf-network-viz/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iogbole","download_url":"https://codeload.github.com/iogbole/ebpf-network-viz/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235538068,"owners_count":19006075,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ebpf","go","golang","prometheus","tcp"],"created_at":"2025-01-25T04:49:09.684Z","updated_at":"2025-01-25T04:49:10.168Z","avatar_url":"https://github.com/iogbole.png","language":"C","funding_links":[],"categories":["C"],"sub_categories":[],"readme":"\n#  Getting Started with eBPF: Monitoring TCP Retransmissions with eBPF, Go and Prometheus \n\n\u003e [!IMPORTANT]  \n\u003e Refer to this blog post for details on the background and motivation behind this experiment -  **[https://www.israelo.io/blog/ebpf-net-viz/](https://www.israelo.io/blog/ebpf-net-viz/)**\n\n\n\n## Usage \n\n1. `Make` : To compile the eBPF code and run main.go \n2. `./run_prom.sh` : To start Prometheus\n3. `./create_tcp_chaos.sh` : To start `tc` and generate TCP requests. \n\n\n## How it works \n\nThe diagram below depicts the solution.  \n\nRead the blog post for details [https://www.israelo.io/blog/ebpf-net-viz/](https://www.israelo.io/blog/ebpf-net-viz/)\n\n\n\n\u003cp align=\"center\"\u003e\n\u003cimg width=\"1510\" alt=\"the solution\" \nsrc=\"https://user-images.githubusercontent.com/2548160/274510771-99bb4583-c7be-4e3e-83fc-283ea99d0195.png\"\u003e\n\u003c/p\u003e\n\n\n\n## Observe \n\nHead over to your Prometheus interface and type `tcp_retransmissions_total` into the query bar. Switch to the graph view and marvel at the results of your hard work.\n\n\u003cp align=\"center\"\u003e\n\u003cimg width=\"1510\"  src=\"https://user-images.githubusercontent.com/2548160/274725653-9b2ac550-01cc-4015-befb-9539a9b38d03.gif\"\u003e\n\u003c/p\u003e\n\n\n### **Using Lima on MacOS**\nIf you're a MacOS user like me, Lima is an excellent way to emulate a Linux environment. To kick things off with Lima, follow these steps:\n\n1. Install Lima and launch it with the [ebpf-vm.yaml](https://github.com/iogbole/ebpf-network-viz/blob/main/ebpf-vm.yaml) file:\n\n    ```bash\n    limactl start ebpf-vm.yaml\n    limactl shell ebpf-vm\n    ```\n2. If use use Visual Studio Code, you can connect to the Lima VM via SSH:\n\n    ```bash\n    limactl show-ssh ebpf-vm\n    ```\n\n    Subsequently, use the SSH command to link up with the remote server through Visual Studio Code.\n\n3. After establishing the connection, clone the required repository:\n\n    ```bash\n    git clone https://github.com/iogbole/ebpf-network-viz.git\n    ```\n\n### **Manual Setup on Linux**\n\nIf you’re opting for a manual setup on Linux, refer to the script section in the [ebpf-vm.yaml](https://github.com/iogbole/ebpf-network-viz/blob/main/ebpf-vm.yaml#L18) file.\n\nWith your environment now primed, you’re all set to delve into the fascinating world of eBPF!\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiogbole%2Febpf-network-viz","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiogbole%2Febpf-network-viz","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiogbole%2Febpf-network-viz/lists"}