The MySQL module collects the error and slow logs generated by MySQL server.

Setup & Configuration

The MySQL module is included with the Atatus Infra agent by default, please follow the below steps to enable.

  1. Add the following lines in the file /etc/atatus-infra-agent/atatus.yml.

    copy
    icon/buttons/copy
    logs_enabled: true
    
  2. Copy the mysql example configuration file.

    copy
    icon/buttons/copy
    cd /etc/atatus-infra-agent/conf.d/mysql.d/
    sudo cp mysql.yml.template mysql.yml
    
  3. Update the file /etc/atatus-infra-agent/conf.d/mysql.d/mysql.yml with below configurations.

    copy
    icon/buttons/copy
    #Log section
    logs:
    
      # - type : (mandatory) type of log input source (error / slowlog)
    
      - type: error
      - type: slowlog
    
  4. Restart the atatus infrastructure agent.

    copy
    icon/buttons/copy
    sudo service atatus-infra-agent restart