list process' PSS sorted descendingly within their parent-child hierarchy. can also do same for disk-space usage
Project description
PSS-tree
# psstree --help
usage: psstree [-h] [--expand] [--full] [--shm] [--raw] [--du PATH] [--all]
gets process' PSS via /proc/<PID>/smaps(_rollup), sorts it descendingly within their parent-child hierarchy, and displays it in an interactive TUI with collapsible sections. alternatively can do the same for disk-space usage given a root-path
options:
-h, --help show this help message and exit
--expand [TUI only] expand all collapsible sections at start
--full show full description
--shm include tmpfs/ramfs filesystems in memory report
--raw disable TUI and dump formatted repr directly to stdout
--du PATH report disk space instead of memory, for given root-path
--all [du only] include content inside certain dirs: site-packages, and ones starting with '.' (like .git) [the dirs themselves are never omitted]
# psstree --raw
Proportional Set Size (PSS) "[<total-PSS-including-all-children>] command-name(pid): `<individual-PSS>` <full-cmdline-args>"
╭─[16.10MB] bash(291): `2.11MB`
│ ├─[13.37MB] psstree(614): `13.37MB`
│ ├─[0.31MB] sleep(607): `0.31MB`
│ ╰─[0.31MB] sleep(608): `0.31MB`
╰─[2.16MB] bash(1): `1.52MB`
├─[0.32MB] sleep(610): `0.32MB`
╰─[0.32MB] sleep(612): `0.32MB`
# psstree --raw --shm
Proportional Set Size (PSS) "[<total-PSS-including-all-children>] command-name(pid): `<individual-PSS>` <full-cmdline-args>"
╭─[16.13MB] bash(291): `2.12MB`
│ ├─[13.38MB] psstree(742): `13.38MB`
│ ├─[0.32MB] sleep(731): `0.32MB`
│ ╰─[0.31MB] sleep(732): `0.31MB`
├─[2.17MB] bash(1): `1.53MB`
│ ├─[0.32MB] sleep(728): `0.32MB`
│ ╰─[0.32MB] sleep(730): `0.32MB`
├─[0.004MB] /dev/shm/
│ ╰─[0.004MB] example
├─[0.000MB] /dev/
│ ├─[0.000MB] core
│ ├─[0.000MB] stderr
│ ├─[0.000MB] stdout
│ ├─[0.000MB] stdin
│ ├─[0.000MB] fd/
│ ├─[0.000MB] ptmx
│ ├─[0.000MB] urandom
│ ├─[0.000MB] zero
│ ├─[0.000MB] tty
│ ├─[0.000MB] full
│ ├─[0.000MB] random
│ ╰─[0.000MB] null
├─[0.000MB] /proc/interrupts
├─[0.000MB] /proc/kcore
├─[0.000MB] /proc/keys
├─[0.000MB] /proc/scsi/
├─[0.000MB] /proc/timer_list
╰─[0.000MB] /sys/firmware/
# psstree --raw --full
Proportional Set Size (PSS) "[<total-PSS-including-all-children>] command-name(pid): `<individual-PSS>` <full-cmdline-args>"
╭─[16.10MB] bash(291): `2.11MB` bash
│ ├─[13.37MB] psstree(633): `13.37MB` /usr/local/bin/python3.11 /usr/local/bin/psstree --raw --full
│ ├─[0.31MB] sleep(607): `0.31MB` sleep 100
│ ╰─[0.31MB] sleep(608): `0.31MB` sleep 100
╰─[2.16MB] bash(1): `1.52MB` bash
├─[0.32MB] sleep(610): `0.32MB` sleep 100
╰─[0.32MB] sleep(612): `0.32MB` sleep 100
# psstree --raw --du .
Disk-Space usage "[<total-space-including-subdirs-recursively>] <path>"
╶─[0.629MB] ./
├─[0.457MB] .git/*
├─[0.129MB] src/
│ ├─[0.102MB] psstree/
│ │ ├─[0.074MB] __pycache__/*
│ │ ├─[0.008MB] types.py
│ │ ├─[0.008MB] utils.py
│ │ ├─[0.004MB] cli.py
│ │ ├─[0.004MB] tui.py
│ │ ├─[0.004MB] __main__.py
│ │ ╰─[0.000MB] __init__.py
│ ╰─[0.027MB] psstree.egg-info/
│ ├─[0.008MB] PKG-INFO
│ ├─[0.004MB] SOURCES.txt
│ ├─[0.004MB] entry_points.txt
│ ├─[0.004MB] requires.txt
│ ├─[0.004MB] top_level.txt
│ ╰─[0.004MB] dependency_links.txt
├─[0.016MB] dist/
│ ├─[0.008MB] psstree-0.1.2.tar.gz
│ ╰─[0.008MB] psstree-0.1.2-py3-none-any.whl
├─[0.008MB] README.md
├─[0.004MB] LICENSE
├─[0.004MB] Makefile
├─[0.004MB] pyproject.toml
├─[0.004MB] .gitignore
├─[0.004MB] .github/*
╰─[0.000MB] images/
# psstree --raw --du . --full
Disk-Space usage "[<total-space-including-subdirs-recursively>] <path>"
╶─[0.629MB] ./
├─[0.457MB] ./.git/*
├─[0.129MB] ./src/
│ ├─[0.102MB] ./src/psstree/
│ │ ├─[0.074MB] ./src/psstree/__pycache__/*
│ │ ├─[0.008MB] ./src/psstree/types.py
│ │ ├─[0.008MB] ./src/psstree/utils.py
│ │ ├─[0.004MB] ./src/psstree/cli.py
│ │ ├─[0.004MB] ./src/psstree/tui.py
│ │ ├─[0.004MB] ./src/psstree/__main__.py
│ │ ╰─[0.000MB] ./src/psstree/__init__.py
│ ╰─[0.027MB] ./src/psstree.egg-info/
│ ├─[0.008MB] ./src/psstree.egg-info/PKG-INFO
│ ├─[0.004MB] ./src/psstree.egg-info/SOURCES.txt
│ ├─[0.004MB] ./src/psstree.egg-info/entry_points.txt
│ ├─[0.004MB] ./src/psstree.egg-info/requires.txt
│ ├─[0.004MB] ./src/psstree.egg-info/top_level.txt
│ ╰─[0.004MB] ./src/psstree.egg-info/dependency_links.txt
├─[0.016MB] ./dist/
│ ├─[0.008MB] ./dist/psstree-0.1.2.tar.gz
│ ╰─[0.008MB] ./dist/psstree-0.1.2-py3-none-any.whl
├─[0.008MB] ./README.md
├─[0.004MB] ./LICENSE
├─[0.004MB] ./Makefile
├─[0.004MB] ./pyproject.toml
├─[0.004MB] ./.gitignore
├─[0.004MB] ./.github/*
╰─[0.000MB] ./images/
# psstree --raw --du src/psstree
Disk-Space usage "[<total-space-including-subdirs-recursively>] <path>"
╶─[0.102MB] src/psstree/
├─[0.074MB] __pycache__/*
├─[0.008MB] types.py
├─[0.008MB] utils.py
├─[0.004MB] cli.py
├─[0.004MB] tui.py
├─[0.004MB] __main__.py
╰─[0.000MB] __init__.py
# psstree --raw --du src/psstree --all
Disk-Space usage "[<total-space-including-subdirs-recursively>] <path>"
╶─[0.102MB] src/psstree/
├─[0.074MB] __pycache__/
│ ├─[0.016MB] utils.cpython-311.pyc
│ ├─[0.012MB] utils.cpython-314.pyc
│ ├─[0.012MB] types.cpython-311.pyc
│ ├─[0.008MB] utils.cpython-39.pyc
│ ├─[0.004MB] cli.cpython-311.pyc
│ ├─[0.004MB] __main__.cpython-39.pyc
│ ├─[0.004MB] tui.cpython-39.pyc
│ ├─[0.004MB] __main__.cpython-314.pyc
│ ├─[0.004MB] tui.cpython-311.pyc
│ ├─[0.004MB] __init__.cpython-311.pyc
│ ╰─[0.004MB] __main__.cpython-311.pyc
├─[0.008MB] types.py
├─[0.008MB] utils.py
├─[0.004MB] cli.py
├─[0.004MB] tui.py
├─[0.004MB] __main__.py
╰─[0.000MB] __init__.py
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
psstree-0.4.0.tar.gz
(9.8 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
psstree-0.4.0-py3-none-any.whl
(10.5 kB
view details)
File details
Details for the file psstree-0.4.0.tar.gz.
File metadata
- Download URL: psstree-0.4.0.tar.gz
- Upload date:
- Size: 9.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d900c78bf6a7a5689b5e410e3cb4eb78339d8bcc6f04a1145a413afcc5814031
|
|
| MD5 |
3d237d588975cff53ef94e1cc17213be
|
|
| BLAKE2b-256 |
ff3e4dd208a03ea94636403663f3ab5d4a7a7f5a474a12cf551a524cd5136913
|
File details
Details for the file psstree-0.4.0-py3-none-any.whl.
File metadata
- Download URL: psstree-0.4.0-py3-none-any.whl
- Upload date:
- Size: 10.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e1d51f0ab9b4aae1560304fab6178e9ddeca5162efd6dc439c78ef2723f1c435
|
|
| MD5 |
8c5872a9767ad7c73660fc07b223bb13
|
|
| BLAKE2b-256 |
f18843f406b0a3edc0ef5b78fe06853cff1595bf4aa221239afaf4d18c6623c0
|