{"id":18408379,"url":"https://github.com/pingcap/kdt","last_synced_at":"2026-03-06T12:32:45.565Z","repository":{"id":88352273,"uuid":"176096896","full_name":"pingcap/kdt","owner":"pingcap","description":"Kernel Debug Toolkit","archived":false,"fork":false,"pushed_at":"2019-03-21T04:24:44.000Z","size":34,"stargazers_count":20,"open_issues_count":1,"forks_count":4,"subscribers_count":16,"default_branch":"master","last_synced_at":"2025-10-09T21:37:38.799Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Shell","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/pingcap.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-17T12:19:19.000Z","updated_at":"2021-12-27T08:09:08.000Z","dependencies_parsed_at":null,"dependency_job_id":"0eff4683-a0a0-4de7-8171-3787e1c17248","html_url":"https://github.com/pingcap/kdt","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/pingcap/kdt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fkdt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fkdt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fkdt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fkdt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pingcap","download_url":"https://codeload.github.com/pingcap/kdt/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fkdt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30176249,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-06T11:48:51.886Z","status":"ssl_error","status_checked_at":"2026-03-06T11:48:51.460Z","response_time":250,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2024-11-06T03:18:52.316Z","updated_at":"2026-03-06T12:32:45.541Z","avatar_url":"https://github.com/pingcap.png","language":"Shell","readme":"# Kernel Debug Toolkit (KDT)\n\nKDT is a toolkit for efficient kernel tracing and hotfix. It makes use of\nextended BPF (Berkeley Packet Filters), formally known as eBPF, a new feature\nthat was first added to Linux 3.15. Much of what BCC uses requires Linux 4.1 and\nabove. Fortunately RHEL/CENTOS 7.6 has already supported a plenty of eBPF\nfeatures which seems keep up with Linux 4.13:\n\n``` c\nenum bpf_prog_type {\n    BPF_PROG_TYPE_UNSPEC,\n    BPF_PROG_TYPE_SOCKET_FILTER,\n    BPF_PROG_TYPE_KPROBE,\n    BPF_PROG_TYPE_SCHED_CLS,\n    BPF_PROG_TYPE_SCHED_ACT,\n    BPF_PROG_TYPE_TRACEPOINT,\n    BPF_PROG_TYPE_XDP,\n    BPF_PROG_TYPE_PERF_EVENT,\n    BPF_PROG_TYPE_CGROUP_SKB,\n    BPF_PROG_TYPE_CGROUP_SOCK,\n    BPF_PROG_TYPE_LWT_IN,\n    BPF_PROG_TYPE_LWT_OUT,\n    BPF_PROG_TYPE_LWT_XMIT,\n    BPF_PROG_TYPE_SOCK_OPS,\n};\n```\n\nSo we may create and use lots of efficient tools on RHEL/CENTOS 7.6.\n\neBPF was [described by](https://lkml.org/lkml/2015/4/14/232) Ingo Molnár as:\n\n\u003e One of the more interesting features in this cycle is the ability to attach eBPF programs (user-defined, sandboxed bytecode executed by the kernel) to kprobes. This allows user-defined instrumentation on a live kernel image that can never crash, hang or interfere with the kernel negatively.\n\nWe use [bcc](https://github.com/iovisor/bcc) to increase development efficiency,\nso for the changes of the bcc's framework code, we will submit them to it's\nrepo directly.\n\nKDT also uses [kpatch](https://github.com/dynup/kpatch) to hotfix a running\nkernel without rebooting or restarting any processes. It's relatively easy to\nuse than RHEL's livepatch, it's an automatic patches generation and has less\nlimitations. One limitation we know is that sometimes it maybe failed to patch a\nfunction with a gcc's inter-procedural optimization. (in the future gcc 9.1 with\na new -flive-patching= flag will help with scenarios like live Linux kernel\npatching.)\n\nThere are several old ftrace tools for old kernel. Some needs to install a\nkernel module [ktc](https://github.com/ethercflow/ktc) to create dynamic event\ntraces. So in the future we may create a generic-ebpf to instead of it to\nunify the frontend.\n\nOther components such as\n[PSI](https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/accounting/psi.txt)\nwill keep coming more.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpingcap%2Fkdt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpingcap%2Fkdt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpingcap%2Fkdt/lists"}