Audit Logging Configuration Variables

The configuration variables associated with audit logging are described in the following table.

Setting Name



Specifies the audit logging level. By default, this value is set to OFF. Ten other levels are available — see Audit Logging Levels for more information.


Specifies whether every audit log record is synchronously written and persisted to the disk. By default, this value is set to OFF and audit log disk syncs are delayed.


Indicates the retention period (in days) for audit log files. Setting this to 0 (the default) means that log files will be kept on the server indefinitely.


Specifies the maximum size per log file in bytes. By default, this value is set to 128MB, or 134217728 bytes.


Specifies the maximum time duration to write to a single log file in seconds. The log rotation check happens when SingleStore DB writes audit entries to the log. Therefore, in some rare cases (and especially on leaf nodes) where there are not a lot of entries written to the log, it is possible that the log is not rotated for greater periods of time than configured in auditlog_rotation_time. By default, this value is set to 1 hour, or 3600 seconds.


Specifies the local or network directory to write log files. By default, this value is set to the auditlogs directory in your node’s SingleStore DB directory. For example: /var/lib/memsql/<node-type>-<port>/auditlogs

To enable audit logging, set auditlog_level to a value other than OFF. The other variables described in the table above have default values that can be overridden, if desired.