Diskspacemonitor, Diskspacemonitor 595 – Apple Mac OS X Server (version 10.2.3 or later) User Manual
Page 595

Tools for Advanced Administrators
595
There are several additional parameters you can specify. Refer to comments in the
configuration files for information about all the parameters and how to set them. The scripts
ignore all log files except those for which at least one threshold is present in the
configuration file.
To configure the scripts on a server from a remote Mac OS X computer, open a Terminal
window and log in to the remote server using ssh. Then open a text editor and edit the
scripts.
You can also use the diskspacemonitor command-line tool to reclaim disk space.
diskspacemonitor
When you need more vigilant monitoring of disk space than the log rolling scripts provide,
you can use the diskspacemonitor command-line tool. It lets you monitor disk space and
take action more frequently than once a day when disk space is critically low, and gives you
the opportunity to provide your own action scripts.
diskspacemonitor is disabled by default. You can enable diskspacemonitor by opening a
Terminal window and typing “sudo diskspacemonitor on”. You may be prompted for your
password. Type “man diskspacemonitor” for more information about the command-line
options.
When enabled, diskspacemonitor uses information in a configuration file to determine when
to execute alert and recovery scripts for reclaiming disk space:
m The configuration file is /etc/diskspacemonitor/diskspacemonitor.conf. It lets you specify
how often you want to monitor disk space and thresholds to use for determining when to
take the actions in the scripts. By default, disks are checked every 10 minutes, an alert
script executed when disks are 75% full, and a recovery script executed when disks are
85% full. To edit the configuration file, log in to the server as an administrator and use a
text editor to open the file. See the comments in the file for additional information.
m By default, two predefined action scripts are executed when the thresholds are reached.
The default alert script is /etc/diskspacemonitor/action/alert. It runs in accord with
instructions in configuration file /etc/diskspacemonitor/alert.conf. It sends email to
recipients you specify.
The default recovery script is /etc/diskspacemonitor/action/recover. It runs in accord with
instructions in configuration file /etc/diskspacemonitor/recover.conf.
See the comments in the script and configuration files for more information about these
files.
LL0395.Book Page 595 Wednesday, November 20, 2002 11:44 AM