📄 mmstatd.conf.5
字号:
.\" $Id: mmstatd.conf.5,v 1.2 2003/01/01 14:54:11 mmondor Exp $.\".\" Copyright (C) 2002-2003, Matthew Mondor.\" All rights reserved..\".\" Redistribution and use in source and binary forms, with or without.\" modification, are permitted provided that the following conditions.\" are met:.\" 1. Redistributions of source code must retain the above copyright.\" notice, this list of conditions and the following disclaimer..\" 2. Redistributions in binary form must reproduce the above copyright.\" notice, this list of conditions and the following disclaimer in the.\" documentation and/or other materials provided with the distribution..\" 3. All advertising materials mentioning features or use of this software.\" must display the following acknowledgement:.\" This product includes software written by Matthew Mondor..\" 4. The name of Matthew Mondor may not be used to endorse or promote.\" products derived from this software without specific prior written.\" permission..\".\" THIS SOFTWARE IS PROVIDED BY MATTHEW MONDOR ``AS IS'' AND ANY EXPRESS OR.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. .\" IN NO EVENT SHALL MATTHEW MONDOR BE LIABLE FOR ANY DIRECT, INDIRECT,.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,.\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF.\" USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE..\".Dd 11 Dec, 2002.Dt MMSTATD.CONF 5.Os.Sh NAME.Nm mmstatd.conf.Nd.Xr mmstatd.conf 5configuration file for mmstatd and mmstat.Sh DESCRIPTIONThe.Nm /etc/mmstatd.conffile may contain one or more keyword/value pairs per line, empty lines orcomments. A ';' or '#' character causes all other characters to be consideredas a comment, and to be ignored, until the end of the current line. It isvery important to enclose the value for a keyword in double quotes ('"'characters) if the following characters are found in it: ';', '#', space andtab. Here are documented the various possible keywords and theirallowed values, as well as their defaults, and mmstatd/mmstat relation..Pp.Nm These are both used by mmstatd and mmstat:.Pp.Bl -tag -width XXXXXXXX -offset indent -compact.It Nm LOG_SOCKET Ar "file"Location of statistics update request socket, to which the logger processof.Nm mmstatdlistens to..Pp.It Nm STAT_SOCKET Ar "file"Location of statistics report request socket, to which the librarian processof.Nm mmstatd listens to..El.Pp.Nm These are only used by mmstatd:.Pp.Bl -tag -width XXXXXXXX -offset indent -compact.It Nm USER Ar "user"Unprivileged user service should run as..Pp.It Nm GROUPS Ar "group ..."Groups mmstatd should be part of, separated by spaces. The groups specifiedfor.Ar LOG_GROUPand.Ar STAT_GROUPshould also be specified here. Do not forget to enclose the value of thiskeyword in double quotes as more than one space separated entries mayexist..Pp.It Nm LOG_FACILITY Ar "facility"Syslog facility which should be used for error logging. Should normally beone of.Sy LOG_AUTH LOG_AUTHPRIV LOG_CRON LOG_DAEMON LOG_FTP LOG_KERN LOG_LPR.Sy LOG_MAIL LOG_NEWS LOG_SYSLOG LOG_USER LOG_UUCP, see.Xr syslog 3man page for more information..Pp.It Nm PID_FILE Ar "file"Location where mmstatd writes it's pid file. This consists of a small fileholding the process ID of.Nm mmstatdwhich can be used by scripts or the administrator to kill the daemon properly..Pp.It Nm LOCK_FILE Ar "file"Location of mmstatd lock file, this is only used to make sure that onlyone copy of the service is running, otherwise this could lead to databasecorruption..Pp.It Nm ENV_DIR Ar "directory"Location where database and recovery logs are internally, automatically storedand managed by.Nm mmstatddaemon..Pp.It Nm LOG_GROUP Ar "group".Ar LOG_SOCKETis created with permission mode 220. This permits users of the specifiedgroup to perform statistic update requests, using the.Xr mmstat 3library interface. Don't forget to also specify this group name into.Ar GROUPSvariable..Pp.It Nm STAT_GROUP Ar "group".Ar STAT_SOCKETis created with permission mode 660. This permits users of the specifiedgroup to obtain statistic reports or to rotate statistics using the.Xr mmstat 3library interface, or.Xr mmstat 8utility. Don't forget to also specify this group name into.Ar GROUPS variable..Pp.It Nm SYNC_INTERVAL Ar "seconds"Specifies the interval in seconds at which the statistics db will besynchronized to disk. This delay can be long enough, as a good log-basedrecovery technique is used in case system crashed between two sync events..Pp.It Nm SYNC_BYTES Ar "bytes"Maximum number of bytes to write to recovery logs before forcing a syncwith physical media (using fdatasync()). 0 Can be specified to force a syncafter every new entry; Higher values may cause some of the last updaterequests before a crash to be lost but will be more efficient..Pp.It Nm MAX_LOGSIZE Ar "bytes"Maximum size of a recovery log file, in bytes. When reaching that sizeinternal rotation to other files is performed. Logs are internally maintainedand cleaned up as necessary by mmstatd and are not user serviceable..Pp.It Nm STATS_RATE Ar "times"Maximum number of times Unix stream connections to.Ar STAT_SOCKETcan be performed within.Ar STATS_TIMEperiod. This prevents an application from requesting a large number of fullreports thus potentially preventing the librarian part of.Nm mmstatdto peform its vital tasks. As a general rule reports are not requestedfrequently. If necessary, 0 can be specified for no limit, and care should betaken to choose an adequate.Ar STAT_GROUPto restrict access..Pp.It Nm STATS_TIME Ar "seconds"Period in seconds during which a maximum of.Ar STATS_RATEconnections are allowed to occur..El.Sh DEFAULTSThe following defaults are used:.Pp.Bd -literal -offset indent -compactUSER mmstatdGROUPS "mmstat staff"LOG_FACILITY LOG_AUTHPRIVPID_FILE "/var/mmstatd/mmstatd.pid"LOCK_FILE "/var/mmstatd/mmstatd.lock"LOG_SOCKET "/var/mmstatd/mmstatd_log.sock"STAT_SOCKET "/var/mmstatd/mmstatd_stat.sock"ENV_DIR "/var/mmstatd"LOG_GROUP mmstatSTAT_GROUP staffSYNC_INTERVAL 1800SYNC_BYTES 4096MAX_LOGSIZE 1048576STATS_RATE 5STATS_TIME 10.Ed.Sh AUTHORmmstat and related daemon and library were written by Matthew Mondor,and are Copyright (c) 2002-2003, Matthew Mondor, All rights reserved.It originally was written for the mmftpd and mmmail suite of daemons by thesame author..Sh FILES.Bl -tag -width XXXXXXXXXXXXXXXXXXXX -compact.It Pa <mmstat.h>Headerfile used both by.Nm mmstatddaemon and.Nm mmstatutility, defining related.Ar MAX_TRANSACTvariable..Pp.It Pa /etc/mmstatd.confConfiguration file for both.Nm mmstatddaemon and.Nm mmstatutility. (This file).El.Sh SEE ALSO.Xr mmstat 3 ,.Xr mmstat 8 ,.Xr mmstatd 8 ,.Xr syslog 3 ,.Xr fdatasync 2 ,.Xr fsync 2 ..Sh BUGSPlease report any bug to mmondor@gobot.ca
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -