跨平台进程监控工具 — macOS / Linux / Windows
Project description
pmon — 跨平台进程监控工具
跨平台进程资源监控命令行工具,支持 macOS / Linux / Windows。
安装
pip install psutil
pip install .
或直接从 PyPI 安装(发布后):
pip install pmon
用法
pmon # 进程列表(按 CPU 降序,top 30)
pmon -n 50 # 显示 top 50
pmon -f chrome # 按名称/PID/用户过滤
pmon -s mem # 排序: cpu|mem|rss|pid|name|threads|fds
pmon -w # watch 模式,每 3 秒刷新
pmon -w -i 5 # 自定义刷新间隔(秒)
pmon -p 1234 # 查看指定 PID 的详细信息
pmon -p 1234 --tree # 显示进程树(含子进程)
pmon -p 1234 --ancestry # 只显示祖先链
pmon -p 1234 --json # JSON 输出
pmon -p 1234 --warnings # 只显示告警
pmon --port 8080 # 按端口反查进程
pmon --file /tmp/x.lock # 按文件路径反查持有进程
pmon --kill 1234 # 发送 SIGTERM
pmon --kill 1234 -9 # 发送 SIGKILL
pmon --pause 1234 # 暂停进程 (SIGSTOP)
pmon --resume 1234 # 恢复进程 (SIGCONT)
pmon --renice 1234 10 # 调整优先级 (-20~19)
pmon --no-color # 禁用颜色输出
显示信息
进程列表
PID、进程名、用户、状态、CPU%、内存%、RSS(MB)、线程数、FD数、启动时间
详情页(-p <PID>)
- 概览:进程名、PID、父进程 ID/路径、可执行路径、工作目录、启动命令、启动用户、状态、启动时间、已运行时长、优先级、终端
- 祖先链 & 起源:完整启动链路 + 自动检测起源类型(shell/ssh/launchd/systemd/cron/container)
- 告警:僵尸进程、高内存/CPU、root 运行、可疑目录、环境变量注入、公网绑定等
- 资源占用:CPU/内存/磁盘 I/O/上下文切换
- 内存详情:macOS 显示 memory_full_info,Linux 显示内存映射表
- 打开的文件、网络连接/端口、线程、环境变量
依赖
- Python >= 3.8
- psutil >= 5.9
许可证
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
marmon-1.0.0.tar.gz
(13.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
marmon-1.0.0-py3-none-any.whl
(14.8 kB
view details)
File details
Details for the file marmon-1.0.0.tar.gz.
File metadata
- Download URL: marmon-1.0.0.tar.gz
- Upload date:
- Size: 13.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c91a4a5d3a564280da22b0ad48edc6bb7aa064bff575ac5d7c73b40c9846e2c8
|
|
| MD5 |
34f2a39fc08f93232fb1efb429d1bedb
|
|
| BLAKE2b-256 |
da2ccb18d9b933e60f4d998b912ee867cd1c4b04bfae98265ae5ef319c807097
|
File details
Details for the file marmon-1.0.0-py3-none-any.whl.
File metadata
- Download URL: marmon-1.0.0-py3-none-any.whl
- Upload date:
- Size: 14.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7de9c0c67eadc517f7b7894ff135f8030307ed0a2d38b81daf83dc4b98ef24f9
|
|
| MD5 |
9d34929f5c4b422732985b22978b73a6
|
|
| BLAKE2b-256 |
a3f355de6b95098a4467b1c60e828bd567b8f4d977089c28468d5c9c6d3955a0
|