[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Savannah-hackers-public] disk-usage monitoring on vcs.sv.gnu.org
From: |
Assaf Gordon |
Subject: |
Re: [Savannah-hackers-public] disk-usage monitoring on vcs.sv.gnu.org |
Date: |
Sun, 1 Feb 2015 15:22:46 -0500 |
Hello Karl,
On Jan 25, 2015, at 17:00, Karl Berry <address@hidden> wrote:
> As long as you're doing a du of everything -- when looking for disk hogs
> (wasn't that what we were talking about initially?),
Yes, that's the goal.
> you need to know
> the exact directory. I find GNU du's --separate-dirs option the most
> useful approach.
Do you mean each repository directory and other 'important' directories on the
disk, or literally every directory on the disk separately (as --separate-dirs
does)?
For example, each git repository directory contains several sub-directories
(e.g. "hooks", "objects", "refs", etc.) - wouldn't it be more helpful to treat
it as one item (the repository directory + its sub-directories) ?
If we want to track individual repositories, how about something like this (not
tested):
for SRC in /srv/git /srv/hg /srv/bzr /source /web ; do
find "$SRC" -maxdepth 1 -type d -print0 \
| LC_ALL=C sort -z \
| sed -z 1d \
| xargs -0 du --bytes --human --summarize
done
> On another diskfull front: frontend's disk has been 100% full for a
> while, for the same reason as before. I'm wasting my time dealing with
> it again. Can nagios be configured to send a report, say, hourly when
> any partition is, say, >98% (= requires action)? If not, a trivial
> shell script that just runs df would do the job.
I'm not well familiar with Nagios, but I'll give it a try.
- Assaf
- Re: [Savannah-hackers-public] disk-usage monitoring on vcs.sv.gnu.org,
Assaf Gordon <=