跨平台进程监控工具 — 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.1.tar.gz
(13.3 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.1-py3-none-any.whl
(14.8 kB
view details)
File details
Details for the file marmon-1.0.1.tar.gz.
File metadata
- Download URL: marmon-1.0.1.tar.gz
- Upload date:
- Size: 13.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
54868c50d9a8495117db03add037598b3be87f43931122ba81fa0332ea390317
|
|
| MD5 |
afb44549a528171265e39379165fa0b8
|
|
| BLAKE2b-256 |
13596cc014ae7128d5f4cb99f065a2ed6a32b36cbe4b068520b74f2417ee7696
|
File details
Details for the file marmon-1.0.1-py3-none-any.whl.
File metadata
- Download URL: marmon-1.0.1-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 |
fba1359e49002da59fcc77935bf55d1a9c0978a48da4bd45efaa3d06d9d4c1a0
|
|
| MD5 |
e8854493def1c8f759a2d7061079a02b
|
|
| BLAKE2b-256 |
4e3c4d80e25d40a10f94058f2bfd0828541a44756233062dc0aaa35100cb700f
|