{"id":13586751,"url":"https://github.com/ianmiell/autotrace","last_synced_at":"2025-04-30T09:15:50.265Z","repository":{"id":142014897,"uuid":"132368418","full_name":"ianmiell/autotrace","owner":"ianmiell","description":" Runs a process, and gives you the output along with other telemetry on the process, all in one terminal window.","archived":false,"fork":false,"pushed_at":"2018-05-25T17:47:18.000Z","size":6299,"stargazers_count":71,"open_issues_count":2,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-30T09:15:34.325Z","etag":null,"topics":["automation","debugging-tool"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ianmiell.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2018-05-06T19:14:31.000Z","updated_at":"2024-04-14T00:51:30.000Z","dependencies_parsed_at":"2023-07-07T07:32:08.313Z","dependency_job_id":null,"html_url":"https://github.com/ianmiell/autotrace","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianmiell%2Fautotrace","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianmiell%2Fautotrace/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianmiell%2Fautotrace/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ianmiell%2Fautotrace/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ianmiell","download_url":"https://codeload.github.com/ianmiell/autotrace/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251674586,"owners_count":21625645,"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":["automation","debugging-tool"],"created_at":"2024-08-01T15:05:47.219Z","updated_at":"2025-04-30T09:15:50.226Z","avatar_url":"https://github.com/ianmiell.png","language":"Python","funding_links":[],"categories":["Python","\u003ca name=\"performance\"\u003e\u003c/a\u003eperformance"],"sub_categories":[],"readme":"# autotrace\n\nRuns a process, and gives you the output along with other telemetry on the\nprocess, all in one terminal window.\n\nHere's me seeing what `ping google.com` (after 'forgetting' to run it under `autotrace`) does by looking at strace and tcpdump, with the command:\n\n```\nautotrace\n```\n\nYou can also run:\n\n```\nautotrace 'ping google.com' 'strace -p PID' 'any other commands' ...\n```\n\n![Demo](https://raw.githubusercontent.com/ianmiell/autotrace/master/demo.gif)\n\nSee [here](https://zwischenzugs.com/2018/05/21/autotrace-debug-on-steroids/) for more.\n\n## Features:\n\n- Pause program in-flight to see what's going on\n\n- Supply PID to pane's command and it gets the main pid sub'd in (see strace in the example above)\n\n- Colorised, multi-pane output\n\n- Output of all commands captured to files (in `/tmp/tmpautotrace/PID/*`)\n\n- Raise PR if you want other features\n\n\n## Install\n\n```\n# Requires:\n# python (2 or 3)\n# pip\npip install autotrace\n```\n\n\n## Examples\n\nMac example:\n\n```\n$ sudo autotrace \\\n    'find /' \\\n    'dtruss -f -p PID' \\\n    'iostat 1'\n```\n\nPID is replaced with the PID of the main (-c) command\n\n\nLinux example with strace and vmstat:\n\n```\n$ sudo autotrace \\\n    'find /' \\\n    'strace -p PID' \\\n    'vmstat 1'\n```\n\nLinux example with strace and tcpdump:\n\n```\n$ sudo autotrace \\\n     'nmap localhost' \\\n     'strace -p PID' \\\n     'tcpdump -XXs 20000'\n```\n\nExample with `while true` script to iterate output:\n\n```\n$ sudo autotrace \\\n    'nmap localhost' \\\n    'strace -p PID' \\\n    'tcpdump -XXs 20000' \\\n    'bash -c \"while true; do free; sleep 5; done\"'\n```\n\nLinux example with more than four panes that can be cycled through by hitting\n'm':\n\n```\n$ sudo autotrace \\\n    'nmap localhost' \\\n    'strace -p PID' \\\n    'tcpdump -XXs 20000' \\\n    'bash -c \"while true; do free; sleep 5; done\"' \\\n    'bash -c \"while true; do lsof -p PID | tail -5; sleep 5; done\"' \\\n```\n\nA (Linux) monster:\n\n```\n$ sudo autotrace \\\n    'nmap localhost' \\\n    'strace -p PID' \\\n    'tcpdump -XXs 20000' \\\n    'bash -c \"while true; do free; sleep 5; done\"' \\\n    'bash -c \"while true; do lsof -p PID | tail -5; sleep 5; done\"' \\\n    'bash -c \"while true; do pstree -p PID | tail -5; sleep 5; done\"' \\\n    'bash -c \"while true; do cat /proc/interrupts; sleep 1; done\"'\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fianmiell%2Fautotrace","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fianmiell%2Fautotrace","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fianmiell%2Fautotrace/lists"}