mfdbtool
The mfdbtool
utility manages mailfromd
databases.
• Invoking mfdbtool | ||
• Configuring mfdbtool |
Next: Configuring mfdbtool, Up: mfdbtool [Contents][Index]
mfdbtool
The following options request the operation to be performed on the database. Exactly one of them must be specified. Each of them implied the --stderr option (see --stderr).
List the database. By default, ‘cache’ database is assumed. To list another database, use --format option (see --format).
Delete given entries from the database (see deleting from databases). By default, ‘cache’ database is assumed. To specify another database, use --format option (see --format).
Delete all expired entries from the database (see Database Maintenance). By default, ‘cache’ database is assumed. To specify another database, use --format option (see --format). Full database name can be given in the command line (see --file option below), if it differs from the one specified in the script file.
Use with the option --all (see --all) to expire all databases.
See Database Maintenance.
Compact database (see compaction). By default, ‘cache’ database is compacted. To specify another database, use --format option (see --format). Full database name can be given in the command line (see --file option below), if it differs from the one specified in the script file.
Use with the option --all (see --all) to compact all databases.
See compaction.
The following options modify the behavior of mfdbtool
:
When used with --compact or --expire option, applies the action to all available databases. See compact cronjob.
Sets debugging level. The string argument must be a valid mailfromd debug level specification, as described in debugging level specification.
Set expiration intervals for all databases to the specified interval.
See time interval specification, for a description of
interval format. The option overrides the
expire-interval
configuration statement
(see expire-interval-conf), which you are advised to use instead.
Set the name of the database to operate upon (for --compact,
--delete, --expire, and --list options).
Useful if, for some reason, you need to operate on a database whose
file name does not match the one mfdbtool
is configured to
use.
Use database of the given format, instead of the default ‘cache’. See Basic Database Operations.
Ignore records that cannot be retrieved while compacting the
database. Without this option, mfdbtool
will abort the
compaction if any such error is encountered.
Used with --list enables printing of the estimated times of sending along with the ‘rate’ database dump. Implies --list --format=rate. See estimated time of sending.
Sets program state directory. See Local state directory, for
the description of this directory and its purposes. This option
overrides the state-directory
configuration statement,
described in state-directory.
Set format to be used for timestamps in listings, produced by
--list. The format is any valid strftime
format
string, see Time and Date Formats, for a detailed description.
The default format is ‘%c’ (see %c time format). To
analyze mfdbtool --list output using text tools, such as
awk
or grep
, the following format might be useful:
‘%s’ (see %s time format). Another format I find useful is
‘%Y-%m-%d_%H:%M:%S’.
Previous: Invoking mfdbtool, Up: mfdbtool [Contents][Index]
mfdbtool
Configuration settings are read from the /etc/mailfromd.conf file (see Mailfromd Configuration). The following statements are understood:
Statement | Reference |
---|---|
database | See conf-database. |
database-mode | See database-mode. |
database-type | See database-type. |
debug | See conf-calloutd-log. |
lock-retry-count | See lock-retry-count. |
lock-retry-timeout | See lock-retry-timeout. |
state-directory | See state-directory. |
Previous: Invoking mfdbtool, Up: mfdbtool [Contents][Index]