ncdu-compare
Project description
ncdu-compare
Compare ncdu export files and shows differences to find out what consumes most space.
Installation
# from pypi
pip3 install ncdu-compare
# ... or from git
pip3 install git+https://github.com/yaroslaff/ncdu-compare.git
Example usage
# measure current /var/log
$ ncdu /var/log/ -0o /tmp/1
# create extra 1M file... and just wait
$ sudo dd if=/dev/zero of=/var/log/zzz.log bs=1M count=1
1+0 records in
1+0 records out
1048576 bytes (1.0 MB, 1.0 MiB) copied, 0.00229604 s, 457 MB/s
# measure /var/log again
$ ncdu /var/log/ -0o /tmp/2
# see top usage
$ ncdu-compare /tmp/1 /tmp/2 | sort -n | tail -n 5
155 /var/log/syslog (8673820 > 8673975)
343 /var/log/auth.log (45035 > 45378)
576 /var/log/minidlna.log (20389653 > 20390229)
1048576 /var/log/zzz.log (0 > 1048576)
1049894 /var/log (755103600 > 756153494)
Invalid unicode filenames
Sometimes ncdu can produce invalid JSON files (see https://dev.yorhel.nl/ncdu/jsonfmt). When loading ncdu files ncdu-compare uses (default) 'replace' mode to handle unicode errors. You can override it with -e
/--error
options, e.g. --error ignore
. More at python doc to open().
See also
My other project Plus Size to detect changes in short-time (e.g. fast growing log files)
ncdu-diff C + Python ncdu fork that can compare and diff results
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file ncdu-compare-0.0.6.tar.gz
.
File metadata
- Download URL: ncdu-compare-0.0.6.tar.gz
- Upload date:
- Size: 3.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9a7e9696e6850a93f943e1d52c446b0e7ff724b6f2a7c27e90597f5c8b758961 |
|
MD5 | 63451fb18d416354d8f672906acc18e0 |
|
BLAKE2b-256 | 00ad9ae7b7045398a2e78ebb82b5962ca974eb29352e274ceca0da6562babab3 |
File details
Details for the file ncdu_compare-0.0.6-py3-none-any.whl
.
File metadata
- Download URL: ncdu_compare-0.0.6-py3-none-any.whl
- Upload date:
- Size: 4.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 245689b9fe3e52af0dfef8a4774d63b639df0f4ea40e4ac7193f42d53629286a |
|
MD5 | c55285e5fc8243c79d875708037820b3 |
|
BLAKE2b-256 | 33ab720ea722f9c146d04795a4556c6940af1843ba193a02b8269c8ed812a4fb |