2004.09_Filelight-Easy to See Graphical Tool for Determining File Sizes.pdf

(2240 KB) Pobierz
Layout 1
LINUX USER
Filelight
Tidy Up Your Hard Disk with Filelight
Summer Cleaning
Sooner or later, your hard disk is bound to fill up. Filelight helps you to quickly
discover the space hogs without needing to pore over columns of numbers.
The neat diagram that the tool provides gives an at-a-glance overview of
where the space is being used allowing you to concentrate on whether the file
is deletable or not. BY JÖRG SCHUMANN
command can output
an overview of hard
disk usage. But if you prefer
to visualize those dry fig-
ures, Filelight [1] provides
the tools for the job, dis-
playing directories and
files as segments in a pie
diagram, with the segment size reflecting
the hard disk usage.
Results
Depending on the size of the directory,
the scan might take a while to complete.
After ascertaining the file sizes for all the
files in the directory, Filelight displays
the results in a circle in the center of the
pie diagram (see Figure 1).
The display shows a number of con-
centric rings that indicate the nesting
depth grouped around the central hub.
The innermost ring represents the direc-
tories in files in the original directory.
Any further rings represent the next level
down the directory tree.
Each of these rings is divided into dif-
ferent colored segments. Gray segments
represent files, and the other colors
directories. The segment size indicates
the disk usage, and the biggest disk hogs
are labeled.
On mouse over, each segment displays
a text frame with details for
the figures including the
exact size and, for directo-
ries, the number of files in
the directory (see Figure 2).
The box also provides details
for the areas below the
selected directory.
You can click a segment to
tell Filelight to create a new
diagram centered on the
selected directory. Just like
in a file manager, you can
press the left arrow key to go
back to the previous view.
The up arrow takes you one
level higher in the directory
address box, or navigate the filesystem
tree after selecting Scan | Scan Direc-
tory… (accelerator key [Ctrl-o]). You can
specify a directory option when launch-
ing the program to automatically scan
that directory when the program comes
up. For example:
Installation
Download the package from the projects
homepage. Change to the relevant direc-
tory, and enter rpm -Uvh followed by the
filename to install. Debian users (with
Sarge or later) and Gentoo users can fol-
low the typical steps for their distros:
apt-get install filelight or emerge filelight .
Users of other distros will need to build
Filelight from the source code.
After entering the filelight
command to launch the pro-
gram, go on to select a
directory for which you need
space information details. The
Scan menu will offer to scan
your own home directory,
Scan Home Directory , (key-
board shortcut [Ctrl-Home]),
or the whole filesystem, Scan
Root Directory . Of course, the
latter function will ignore
paths where you do not have
read permissions.
Alternatively, you can enter
a different directory into the
filelight /usr
will automatically scan the /usr/ direc-
tory.
Figure 1: Filelight provides a useful overview of your hard disk.
76
September 2004
www.linux-magazine.com
W e all know that the du
593079774.001.png
Filelight
LINUX USER
Figure 2: Checking out the details.
Figure 3: Filelight has file manager capabilities.
tree. To remove the need for Filelight to
check the disk space each time you
move, the program caches this data,
assuming that there have been no
changes. However, you can click Rescan
to do just that.
To avoid a cluttered display, Filelight
will not display smaller files by default.
You can select Settings – Configure File-
light… , click the Appearance tab, and
check Show small files to change this,
and display every single file in the dia-
gram.
Yo u can also use Filelight as a kind of
primitive file manager. Right click a
directory to pop up a context menu with
functions for opening files or directories
or deleting files (see Figure 3). Note that
you need to assign an application to each
file type before attempting to open a file
of that type in Filelight. The program
does not have a Open file with… dialog.
The program also inserts itself into the
Konqueror context menu, adding a File-
light item to the Open with entry, and
allowing users to open directories
directly in Filelight.
maxim that “everything is a file”. Unfor-
tunately, this is not immediately obvious
to a program like Filelight. To avoid trou-
ble, the system directories /dev/ , /proc/ ,
and /sys/ are not scanned by default.
Also, the tool will ignore any files below
/root/ .
Of course you can edit the list of direc-
tories to ignore. To review the current
settings, check Don’t scan these directo-
ries in the Settings | Configure Filelight…
dialog. You can use the Add and Remove
buttons to edit the list.
Note the Scan across filesystem bound-
aries checkbox below this area. If the
checkbox is selected, Filelight will access
other filesystems, providing information
on Windows partitions, for example – of
course, this again assumes that you have
read permissions.
You can restrict this by checking
Exclude remote filesytems to prevent
scanning your Samba or NFS network
directories. Scanning removable media,
such as CD-ROM drives, is not typically a
thing you would want to do with File-
light. Thus, you might prefer to Exclude
removable media .
In addition to the option for displaying
small files, the Appearance tab has three
different color schemes, allowing users to
customize the application if so desired.
Special Tool
Filelight closes a gap left open by Kon-
queror in the KDE desktop’s feature
scope. No other KDE tool allows users to
locate large files and directories as
quickly and easily as Filelight. The pro-
gram displays the underlying directory
tree, rather than just the top level direc-
tory.
Of course, there is always the com-
mand-line tool du , which may produce
the results more quickly, assuming some
level of console wizardry on the part of
the user, but in the GUI-based world,
Filelight is probably unique in its kind
and extremely useful when assessing
hard disk usage. After all, history shows
that seemingly inexhaustible hard disk
capacities are anything but that, if you
fail to tidy up once in a while.
INFO
[1] Filelight Homepage:
http://www.methylblue.com/filelight
Jörg Schumann origi-
nally studied music,
intending to become
a church musician,
but then switched to
mathematics and
computer science to
concentrate on programming. The
connections between music and com-
puter science is an area that Jörg still
spends quite a lot of time investigat-
ing. Whenever he has time to spare, he
enjoys tinkering with Linux computers
and exploiting their sound-making
capacity.
Fine Tuning
There are some special directories that
do not contain files in the traditional
sense of the word, despite the Unix
GLOSSARY
Samba: A protocol that allows Linux to sup-
port so-called Windows shares on a
heterogeneous network. Linux has both a
Samba server, which allows Windows PCs to
access Linux “shares”, and a client that allows
access to Windows shares on Linux.
NFS: The “Network Filesystem” is a protocol
that allows Linux and other Unix systems to
mount directories located on remote
machines,allowing users to access those
directories as if they were local.
www.linux-magazine.com September 2004
77
593079774.002.png 593079774.003.png
Zgłoś jeśli naruszono regulamin