mysqlstat−setup − sets up mysqlstat Net−SNMP module
mysqlstat-setup [−f] [−u USER ] [−p PASSWORD ] [−C CONFDIR ] [−L LIBDIR ] [−−defaults−file= FILE ] [−−force] [−−host= HOST ] [−−user= USER ] [−−password= PASSWORD ] [−−snmp−user= USER ] [−−snmp−password= PASSWORD ] [−−snmp−host= HOSTNAME ] [−−confdir CONFDIR ] [−−libdir LIBDIR ]
mysqlstat-setup [−h] [−−help] [−−usage]
By default the user snmp
is created with empty password. This can be controlled using
the following command line options:
Sets the MySQL user name to use.
Sets the MySQL password.
Sets the source host name or IP address to use. Default is localhost.
Credentials for connecting the MySQL server are read from file ~/.my.cnf, if such file exists. Another file may be given using the −−defaults−file option. Credentials can also be given from command line, using the options −−user, −−password and −−host, although such usage is not recommended for security reasons.
2. Creates the /etc/snmp/mysqlstat.cnf file.
This file defines the MySQL credentials to use when connecting to the mysqld server. If that file already exists, mysqlstat-setup assumes the module has already been configured and refuses to run (unless given the −−force option).
3. Edits the /etc/snmp/snmpd.conf file.
The dlmod statement is inserted, which instructs snmpd to load the module.
In most cases,
it suffices to run the utility without any special options.
Nevertheless, the following options are provided that alter
Force operation even if it is detected that the mysqlstat module has already been set up.
−u, −−user= USER
Connect to MySQL using USER as user name. This user must have GRANT privileges.
Note: it is not the user that will be used by the mysqlstat module. For that, see −−snmp−user, below.
−p, −−password= PASSWORD
Connect to MySQL using the supplied password.
Note: it is not the password that the mysqlstat module will be using. For that, see −−snmp−password, below.
Connect to MySQL server running at HOST (hostname or IP address). This will also be stored in /etc/snmp/mysqlstat.cnf for use by the mysqlstat module.
Read MySQL access credentials from FILE . By default ~/.my.cnf is read if it exists. This way of supplying access credentials is preferred over the command line options.
MySQL user to be used by the mysqlstat module. Default is snmp.
MySQL password to be used by the mysqlstat module. Default is empty password.
Hostname or IP address the mysqlstat module will connect from. This is used when granting MySQL user privileges.
−C, −−confdir= DIR
Assume DIR instead of /etc/snmp.
−L, −−libdir= LIBDIR
Net-snmp modules are installed to LIBDIR .
The following options provide informational output:
Print short help summary.
Print the manpage.
Show a terse command line usage summary.
Manpage server at Ulysses.gnu.org.ua.
Powered by mansrv 1.0