← 返回命令列表

Linux command

duc 命令

文件

复制后可按需替换文件名、目录或参数。

常用示例

Index a directory

duc index [/path/to/directory]

List directory sizes

duc ls [/path]

Interactive console UI

duc ui [/path]

Graphical sunburst view

duc gui [/path]

Show database info

duc info

Export to JSON

duc json [/path]

说明

duc (Disk Usage Calculator) indexes filesystem usage into a database for fast repeated queries and provides multiple visualization interfaces. Unlike tools that scan filesystems on every invocation, duc performs an initial scan to build an index, then allows instant queries and visualizations from the cached data. The workflow involves two phases: first, use duc index to scan directories and build the database; second, query the database using various interfaces (ls, ui, gui, graph). This approach is particularly effective for large filesystems where repeated full scans would be prohibitively slow. duc offers four main visualization modes: ls (command-line listing), ui (interactive ncurses interface), gui (graphical X11 window with sunburst charts), and graph (generate static images). The graphical modes provide intuitive visual representations of disk usage, making it easy to identify large directories at a glance. The database stores complete size information including file counts and sizes at all directory levels. Multiple filesystem scans can be stored in a single database, and duc tracks timestamps to show when data was last updated. The tool supports incremental updates but requires manual reindexing when filesystem contents change significantly.

FAQ

What is the duc command used for?

duc (Disk Usage Calculator) indexes filesystem usage into a database for fast repeated queries and provides multiple visualization interfaces. Unlike tools that scan filesystems on every invocation, duc performs an initial scan to build an index, then allows instant queries and visualizations from the cached data. The workflow involves two phases: first, use duc index to scan directories and build the database; second, query the database using various interfaces (ls, ui, gui, graph). This approach is particularly effective for large filesystems where repeated full scans would be prohibitively slow. duc offers four main visualization modes: ls (command-line listing), ui (interactive ncurses interface), gui (graphical X11 window with sunburst charts), and graph (generate static images). The graphical modes provide intuitive visual representations of disk usage, making it easy to identify large directories at a glance. The database stores complete size information including file counts and sizes at all directory levels. Multiple filesystem scans can be stored in a single database, and duc tracks timestamps to show when data was last updated. The tool supports incremental updates but requires manual reindexing when filesystem contents change significantly.

How do I run a basic duc example?

Run `duc index [/path/to/directory]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

Where can I find more duc examples?

This page includes 6 examples for duc, plus related commands for nearby Linux tasks.