Enable the Exporter Process min read


The memsql-exporter process (or simply “the exporter”) collects data about a running cluster. The user that starts the exporter must have the following permissions at a minimum:

SHOW METADATA on *.*.
SELECT on *.*

Stop the Existing Exporter Process

If you are currently using MemSQL’s former monitoring solution and are migrating to MemSQL’s new monitoring solution, stop the existing MemSQL exporter process by running the following commands on your Source cluster’s Master Aggregator host. Otherwise, skip to Start the New Exporter Process.

Note: Perform the following steps on the Source cluster Master Aggregator.

  1. Obtain the MemSQL exporter process PID.

    ps aux | grep memsql_exporter
    
  2. Kill the MemSQL exporter process.

    kill  <PID>
    

Start the New Exporter Process

Note: Perform the following steps on the Source cluster Master Aggregator.

MemSQL Toolbox

Run the following command to start the exporter. This command will start the exporter using the MemSQL root user and default port (9104). The exporter username and password are used to access the Source cluster. Refer to memsql-admin configure-monitoring for more information.

memsql-admin configure-monitoring \
--exporter-user root \
--exporter-password <secure-password>

SQL

You may start the exporter in the MemSQL engine by passing a user, port, and password to the exporter. The following example shows the the exporter being started with the MemSQL root user:

SET GLOBAL exporter_user = root;
SET GLOBAL exporter_password = '<secure-password>';
SET GLOBAL exporter_port= 9104;

How to Stop the Exporter Process

You may stop the exporter at any time by performing either of the following commands on the Source cluster Master Aggregator.

MemSQL Toolbox

memsql-admin configure-monitoring --stop-exporter

SQL

Use an engine variable to stop the exporter process by setting the port to 0.

SET GLOBAL exporter_port = 0;