db.conf

The file /opt/mapr/conf/db.conf specifies configuration parameters for the Metrics database.

WARNING
Any time you make changes to the db.conf file, you must restart the hoststats service and Warden for those changes to take effect.

Field

Default

Description

db.url

localhost:3306

The URL and port for the MySQL server that stores Metrics data. This machine does not need to be a node in the cluster.

db.user

root

The MySQL user name.

db.passwd

mapr

The MySQL password. If the password contains the & character, it is replaced with the & string in the hibernate.cfg.xml file (following XML parsing standards).

db.schema

metrics

The name of the MySQL schema.

db.mode

mysql

Reserved for future use.

db.driverclass

com.mysql.jdbc.Driver

Reserved for future use.

db.joblastacessed.limit.hours

48

Task and task attempt data for a job are purged for jobs that have not been accessed in a number of hours equal to this parameter's value.

NOTE
Note that there is an error in this parameter's name. Instead of db.joblastaccessed.limit.hours, spelled as the English word accessed, the parameter is written db.joblastacessed.limit.hours.

db.partition.finest.count.days

3

Integer number of days for which the finest data granularity is kept. Finest granularity is a ten-second resolution.

db.partition.fine.count.days

15

Integer number of days for which fine data granularity is kept. Fine granularity is a five-minute average of the finest resolution.

db.partition.coarse.count.years

100

Integer number of years for which the coarse data granularity is kept. Coarse granularity is a 24-hour average of the fine resolution.

metric.file.rotate

365

Integer number of days for which metrics files are kept in the local volume for each node.

metric.file.cleanupthreshold 512 Specifies a size in GB. When the total size of the metrics files exceeds the value of this parameter, all data over 30 days old is cleaned up.
Example db.conf file
db.url=localhost:3306
db.user=root
db.passwd=mapr
db.schema=metrics
db.mode=mysql
db.driverclass=com.mysql.jdbc.Driver
db.joblastacessed.limit.hours=48
db.partition.finest.count.days=3
db.partition.fine.count.days=15
db.partition.coarse.count.years=100
### How many files with raw node metrics data to keep
metric.file.rotate=365