Linux Tips

Duc – A Assortment Of Instruments To Examine And Visualize Disk Utilization

Duc is a set of instruments that can be utilized to index, examine and visualize disk utilization on Unix-like working methods. Don’t consider it as a easy CLI software that merely shows a elaborate graph of your disk utilization. It’s constructed to scale fairly nicely on large filesystems. Duc has been examined on methods that consisted of greater than 500 million information and a number of other petabytes of storage with none issues.

Duc is kind of quick and versatile software. It shops your disk utilization in an optimized database, so you’ll be able to rapidly discover the place your bytes are as quickly because the index is accomplished. As well as, it comes with varied consumer interfaces and back-ends to entry the database and draw the graphs.

Right here is the record of at the moment supported consumer interfaces (UI):

Command line interface (ls),
Ncurses console interface (ui),
X11 GUI (duc gui),
OpenGL GUI (duc gui).

Listing of supported database back-ends:

Tokyocabinet,
Leveldb,
Sqlite3.

Duc makes use of Tokyocabinet as default database backend.

Set up Duc

Duc is accessible within the default repositories of Debian and its derivatives comparable to Ubuntu. So putting in Duc on DEB-based methods is a bit of cake.

$ sudo apt-get set up duc

On different Linux distributions, you might have to manually compile and set up Duc from supply as proven beneath.

Obtain newest duc supply .tgz file from the releases web page on github. As of penning this information, the newest model was 1.four.four.

$ wget https://github.com/zevv/duc/releases/obtain/1.four.four/duc-1.four.four.tar.gz

Then run the next instructions one after the other to put in DUC.

$ tar -xzf duc-1.four.four.tar.gz
$ cd duc-1.four.four
$ ./configure
$ make
$ sudo make set up

Duc Utilization

The standard utilization of duc is:

$ duc

You’ll be able to view the record of normal choices and sub-commands by working the next command:

$ duc assist

You may as well know the the utilization of a selected subcommand as beneath.

$ duc assist

To view the in depth record of all instructions and their choices, merely run:

$ duc assist –all

Allow us to now se some sensible use circumstances of duc utility.

Create Index (database)

To start with, you have to create an index file (database) of your filesystem. To create an index file, use “duc index” command.

For instance, to create an index of your /residence listing, merely run:

$ duc index /residence

The above command will create the index of your /residence/ listing and put it aside in $HOME/.duc.db file. When you’ve got added new information/directories within the /residence listing in future, simply re-run the above command at any time later to rebuild the index.

Question Index

Duc has varied sub-commands to question and discover the index.

To view the record of accessible indexes, run:

$ duc data

Pattern output:

Date Time Information Dirs Dimension Path
2019-04-09 15:45:55 three.5K 305 654.6M /residence

As you see within the above output, I’ve already listed the /residence listing.

To record all information and directories within the present working listing, you are able to do:

$ duc ls

To record information/directories in a selected listing, for instance /residence/sk/Downloads, simply go the trail as argument like beneath.

$ duc ls /residence/sk/Downloads

Equally, run “duc ui” command to open a ncurses primarily based console consumer interface for exploring the file system utilization and run “duc gui” to start out a graphical (X11) interface to discover the file system.

To know extra a couple of sub-command utilization, merely refer the assistance part.

$ duc assist ls

The above command will show the assistance part of “ls” subcommand.

Visualize Disk Utilization

Within the earlier part, now we have seen the right way to record information and directories utilizing duc subcommands. As well as, you’ll be able to even present the file sizes in a elaborate graph.

To indicate the graph of a given path, use “ls” subcommand like beneath.

$ duc ls -Fg /residence/sk

Pattern output:

duc 1

Visualize disk utilization utilizing “duc ls” command

As you see within the above output, the “ls” subcommand queries the duc database and lists the inclusive dimension of all
information and directories of the given path i.e /residence/sk/ on this case.

Right here, the “-F” choice is used to append file sort indicator (one in every of */) to entries and the “-g” choice is used to attract graph with relative dimension for every entry.

Please observe that if no path is given, the present working listing is explored.

You need to use -R choice to view the disk utilization lead to tree construction.

$ duc ls -R /residence/sk
duc 2

Visualize disk utilization in tree construction

To question the duc database and open a ncurses primarily based console consumer interface for exploring the disk utilization of given path, use “ui” subcommand like beneath.

$ duc ui /residence/sk

duc 3

Equally, we use “gui” subcommand to question the duc database and begin a graphical (X11) interface to discover the disk utilization of the given path:

$ duc gui /residence/sk

duc 4

Like I already talked about earlier, we are able to be taught extra a couple of subcommand utilization like beneath.

$ duc assist

I coated the essential utilization half solely. Refer man pages for extra particulars about “duc” software.

$ man duc

Associated learn:

Conclusion

Duc is straightforward but helpful disk utilization viewer. If you wish to rapidly and simply know which information/directories are consuming up your disk area, Duc is perhaps a good selection. What are you ready for? Go get this software already, scan your filesystem and do away with unused information/directories.

And, that’s all for now. Hope this was helpful. Extra good stuffs to come back. Keep tuned!

Cheers!

Useful resource:

Thanks for stopping by!

Assist us that will help you:

Have a Good day!!

Source link

Related Articles

Back to top button