Chaged MaxScale default installation directory to /usr/local/mariadb/maxscale and MaxAdmin password to 'mariadb'.
This commit is contained in:
@ -136,5 +136,5 @@ Both RPM and Debian packages are available for MaxScale in addition to the tar b
|
||||
|
||||
# MaxScale Home Default Value
|
||||
|
||||
The installation assumes that the default value for the environment variable MAXSCALE_HOME is set to /usr/local/skysql/maxscale. This is hard coded in the service startup file that is placed in /etc/init.d/maxscale by the installation process.
|
||||
The installation assumes that the default value for the environment variable MAXSCALE_HOME is set to /usr/local/mariadb/maxscale. This is hard coded in the service startup file that is placed in /etc/init.d/maxscale by the installation process.
|
||||
|
||||
|
@ -1,25 +1,25 @@
|
||||
Installation and startup
|
||||
|
||||
Untar the binary distribution in the desired location,
|
||||
e.g. /usr/local/skysql
|
||||
e.g. /usr/local/mariadb
|
||||
|
||||
Alternatively build from the source code using the instructions
|
||||
in the README file and execute make install.
|
||||
|
||||
Simply set the environment variable MAXSCALE_HOME to point to the
|
||||
MaxScale directory, found inside the path into which the files have been copied,
|
||||
e.g. MAXSCALE_HOME=/usr/local/skysql/maxscale/MaxScale
|
||||
e.g. MAXSCALE_HOME=/usr/local/mariadb/maxscale
|
||||
|
||||
Also you will need to optionaly set LD_LIBRARY_PATH to include the 'lib' folder,
|
||||
found inside the path into which the files have been copied,
|
||||
e.g. LD_LIBRARY_PATH=/usr/local/skysql/maxscale/lib
|
||||
e.g. LD_LIBRARY_PATH=/usr/local/mariadb/maxscale/lib
|
||||
|
||||
Because we need the libmysqld library for parsing we must create a
|
||||
valid my.cnf file to enable the library to be used. Copy the my.cnf
|
||||
to $MAXSCALE_HOME/mysql/my.cnf.
|
||||
|
||||
To start MaxScale execute the command 'maxscale' from the bin folder,
|
||||
e.g. /usr/local/skysql/maxscale/bin/maxscale
|
||||
e.g. /usr/local/mariadb/maxscale/bin/maxscale
|
||||
|
||||
Configuration
|
||||
|
||||
@ -30,8 +30,8 @@ various services.
|
||||
|
||||
In order to view the internal activity of the gateway you can telnet to
|
||||
the port defined for the telnet listener. Initially you may login with
|
||||
the user name of "admin" and the password "skysql". Once connected type
|
||||
the user name of "admin" and the password "mariadb". Once connected type
|
||||
help for an overview of the commands and help <command> for the more
|
||||
detailed help on commands. Use the add user command to add a new user,
|
||||
this will also remove the admin/skysql user.
|
||||
this will also remove the admin/mariadb user.
|
||||
|
||||
|
@ -171,7 +171,7 @@ After the completion of the make process the installation can be achieved by run
|
||||
|
||||
This will result in an installation being created which is identical to that which would be achieved by installing the binary package. The only difference is that init.d scripts aren't installed and the RabbitMQ components are not built.
|
||||
|
||||
By default, MaxScale installs to '/usr/local/skysql/maxscale' and places init.d scripts and ldconfig files into their folders. Change the CMAKE_INSTALL_PREFIX variable to your desired installation directory and set INSTALL_SYSTEM_FILES=N to prevent the init.d script and ldconfig file installation.
|
||||
By default, MaxScale installs to '/usr/local/mariadb/maxscale' and places init.d scripts and ldconfig files into their folders. Change the CMAKE_INSTALL_PREFIX variable to your desired installation directory and set INSTALL_SYSTEM_FILES=N to prevent the init.d script and ldconfig file installation.
|
||||
|
||||
Other useful targets for Make are `documentation`, which generates the Doxygen documentation, and `uninstall` which uninstall MaxScale binaries after an install.
|
||||
|
||||
|
@ -514,7 +514,7 @@ Default value is `2`. Write Timeout is the timeout in seconds for each attempt t
|
||||
|
||||
# Protocol Modules
|
||||
|
||||
The protocols supported by MaxScale are implemented as external modules that are loaded dynamically into the MaxScale core. These modules reside in the directory `$MAXSCALE_HOME/modules`, if the environment variable `$MAXSCALE_HOME` is not set it defaults to `/usr/local/skysql/MaxScale`. It may also be set by passing the `-c` option on the MaxScale command line.
|
||||
The protocols supported by MaxScale are implemented as external modules that are loaded dynamically into the MaxScale core. These modules reside in the directory `$MAXSCALE_HOME/modules`, if the environment variable `$MAXSCALE_HOME` is not set it defaults to `/usr/local/mariadb/MaxScale`. It may also be set by passing the `-c` option on the MaxScale command line.
|
||||
|
||||
## MySQLClient
|
||||
|
||||
@ -905,7 +905,7 @@ protocol=telnetd
|
||||
port=4442
|
||||
```
|
||||
|
||||
Connections using the telnet protocol to port 4442 of the MaxScale host will result in a new debug CLI session. A default username and password are used for this module, new users may be created using the add user command. As soon as any users are explicitly created the default username will no longer continue to work. The default username is admin with a password of skysql.
|
||||
Connections using the telnet protocol to port 4442 of the MaxScale host will result in a new debug CLI session. A default username and password are used for this module, new users may be created using the add user command. As soon as any users are explicitly created the default username will no longer continue to work. The default username is admin with a password of mariadb.
|
||||
|
||||
The debugcli supports two modes of operation, `developer` and `user`. The mode is set via the `router_options` parameter. The user mode is more suited to end-users and administrators, whilst the develop mode is explicitly targeted to software developing adding or maintaining the MaxScale code base. Details of the differences between the modes can be found in the debugging guide for MaxScale. The default is `user` mode. The following service definition would enable a developer version of the debugcli.
|
||||
|
||||
|
@ -65,7 +65,7 @@ modules it will search using a predescribed search path. The rules are:
|
||||
|
||||
1. Look in the current directory for the module
|
||||
2. Look in $MAXSCALE_HOME/modules
|
||||
3. Look in /usr/local/skysql/maxscale/modules
|
||||
3. Look in /usr/local/mariadb/maxscale/modules
|
||||
|
||||
Configuration is read by default from the file \$MAXSCALE_HOME/etc/MaxScale.cnf, /etc/MaxScale.cnf. An example file is included in in the installation and can be found in the etc/ folder within the MaxScale installation. The default value of MAXSCALE_HOME can be overriden by using the -c flag on the command line. This should be immediately followed by the path to the MaxScale home directory. The -f flag can be used on the command line to set the name and the location of the configuration file. Without path expression the file is read from \$MAXSCALE_HOME/etc directory.
|
||||
|
||||
|
@ -354,7 +354,7 @@ Connected to localhost.
|
||||
|
||||
Escape character is '^]'.
|
||||
|
||||
Welcome the SkySQL MaxScale Debug Interface (V1.1.0).
|
||||
Welcome the Mariadb MaxScale Debug Interface (V1.1.0).
|
||||
|
||||
Type help for a list of available commands.
|
||||
|
||||
@ -364,7 +364,7 @@ Password:
|
||||
|
||||
MaxScale>
|
||||
|
||||
As delivered MaxScale uses a default login name of admin with the password of skysql for connections to the debug interface. Users may be added to the CLI by use of the add user command.
|
||||
As delivered MaxScale uses a default login name of admin with the password of mariadb for connections to the debug interface. Users may be added to the CLI by use of the add user command.
|
||||
|
||||
This places you in the debug command line interface of MaxScale, there is a help system that will display the commands available to you
|
||||
|
||||
@ -1691,7 +1691,7 @@ Note, not all configuration elements can be changed dynamically currently. This
|
||||
|
||||
## Add user
|
||||
|
||||
The add user command is used to add new users to the debug CLI of MaxScale. The default behaviour of the CLI for MaxScale is to have a login name of admin and a fixed password of skysql. Adding new users will disable this default behaviour and limit the login access to the users that are added.
|
||||
The add user command is used to add new users to the debug CLI of MaxScale. The default behaviour of the CLI for MaxScale is to have a login name of admin and a fixed password of mariadb. Adding new users will disable this default behaviour and limit the login access to the users that are added.
|
||||
|
||||
**MaxScale>** add user admin july2013
|
||||
|
||||
@ -1711,7 +1711,7 @@ User admin already exists.
|
||||
|
||||
**MaxScale>**** **
|
||||
|
||||
If you should forget or lose the the account details you may simply remove the passwd file in $MAXSCALE_HOME/etc and the system will revert to the default behaviour with admin/skysql as the account.
|
||||
If you should forget or lose the the account details you may simply remove the passwd file in $MAXSCALE_HOME/etc and the system will revert to the default behaviour with admin/mariadb as the account.
|
||||
|
||||
## Enable/disable log
|
||||
|
||||
|
@ -650,7 +650,7 @@ A monitor that has been shutdown may be restarted using the restart monitor comm
|
||||
|
||||
# Working With Administration Interface Users
|
||||
|
||||
A default installation of MaxScale allows connection to the administration interface using the username of admin and the password skysql. This username and password stay in effect as long as no other users have been created for the administration interface. As soon as the first user is added the use of admin/skysql as login credentials will be disabled.
|
||||
A default installation of MaxScale allows connection to the administration interface using the username of admin and the password mariadb. This username and password stay in effect as long as no other users have been created for the administration interface. As soon as the first user is added the use of admin/mariadb as login credentials will be disabled.
|
||||
|
||||
## What Users Have Been Defined?
|
||||
|
||||
@ -666,7 +666,7 @@ In order to see the current users that have been defined for the administration
|
||||
User names: vilho, root, dba, massi, mark
|
||||
MaxScale>
|
||||
|
||||
Please note that if no users have been configured the default admin/skysql user will not be shown.
|
||||
Please note that if no users have been configured the default admin/mariadb user will not be shown.
|
||||
|
||||
MaxScale> show users
|
||||
Administration interface users:
|
||||
|
@ -80,7 +80,7 @@ A number of bug fixes have been applied between the 1.0.5 GA and this RC release
|
||||
</tr>
|
||||
<tr>
|
||||
<td>709</td>
|
||||
<td>"COPYRIGHT LICENSE README SETUP" files go to /usr/local/skysql/maxscale/ after 'make package'</td>
|
||||
<td>"COPYRIGHT LICENSE README SETUP" files go to /usr/local/mariadb/maxscale/ after 'make package'</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>704</td>
|
||||
|
@ -22,7 +22,7 @@ or
|
||||
|
||||
$ /etc/init.d/maxscale start
|
||||
|
||||
It is also possible to start MaxScale by executing the maxscale command itself, in this case you must ensure that the environment is correctly setup or command line options are passed. The major elements to consider are the correct setting of the MAXSCALE\_HOME directory and to ensure that LD\_LIBRARY\_PATH. The LD\_LIBRARY\_PATH should include the lib directory that was installed as part of the MaxScale installation, the MAXSCALE\_HOME should point to /usr/local/skysql/maxscale if a default installation has been created or to the directory this was relocated to. Running the executable $MAXSCALE\_HOME/bin/maxscale will result in MaxScale running as a daemon process, unattached to the terminal in which it was started and using configuration files that it finds in the $MAXSCALE\_HOME directory.
|
||||
It is also possible to start MaxScale by executing the maxscale command itself, in this case you must ensure that the environment is correctly setup or command line options are passed. The major elements to consider are the correct setting of the MAXSCALE\_HOME directory and to ensure that LD\_LIBRARY\_PATH. The LD\_LIBRARY\_PATH should include the lib directory that was installed as part of the MaxScale installation, the MAXSCALE\_HOME should point to /usr/local/mariadb/maxscale if a default installation has been created or to the directory this was relocated to. Running the executable $MAXSCALE\_HOME/bin/maxscale will result in MaxScale running as a daemon process, unattached to the terminal in which it was started and using configuration files that it finds in the $MAXSCALE\_HOME directory.
|
||||
|
||||
Options may be passed to the MaxScale binary that alter this default behaviour, this options are documented in the table below.
|
||||
|
||||
@ -83,14 +83,14 @@ MaxScale will also stop gracefully if it received a hangup signal, to find the p
|
||||
|
||||
In order to shutdown MaxScale using the maxadmin command you may either connect with maxadmin in interactive mode or pass the "shutdown maxscale" command you wish to execute as an argument to maxadmin.
|
||||
|
||||
$ maxadmin -pskysql shutdown maxscale
|
||||
$ maxadmin -pmariadb shutdown maxscale
|
||||
|
||||
<a name="checking"></a>
|
||||
### Checking The Status Of The MaxScale Services
|
||||
|
||||
It is possible to use the maxadmin command to obtain statistics regarding the services that are configured within your MaxScale configuration file. The maxadmin command "list services" will give very basic information regarding the services that are define. This command may be either run in interactive mode or passed on the maxadmin command line.
|
||||
|
||||
$ maxadmin -pskysql
|
||||
$ maxadmin -pmariadb
|
||||
MaxScale> list services
|
||||
|
||||
Services.
|
||||
@ -118,7 +118,7 @@ It should be noted that network listeners count as a user of the service, theref
|
||||
|
||||
To determine what client are currently connected to MaxScale you can use the "list clients" command within maxadmin. This will give you IP address and the ID’s of the DCB and session for that connection. As with any maxadmin command this can be passed on the command line or typed interactively in maxadmin.
|
||||
|
||||
$ maxadmin -pskysql list clients
|
||||
$ maxadmin -pmariadb list clients
|
||||
|
||||
Client Connections
|
||||
|
||||
@ -141,11 +141,11 @@ MaxScale write log data into four log files with varying degrees of detail. With
|
||||
|
||||
It is possible to rotate either a single log file or all the log files with a single command. When the logfile is rotated, the current log file is closed and a new log file, with an increased sequence number in its name, is created. Log file rotation is achieved by use of the "flush log" or “flush logs” command in maxadmin.
|
||||
|
||||
$ maxadmin -pskysql flush logs
|
||||
$ maxadmin -pmariadb flush logs
|
||||
|
||||
Flushes all of the logs, whereas an individual log may be flushed with the "flush log" command.
|
||||
|
||||
$ maxadmin -pskysql
|
||||
$ maxadmin -pmariadb
|
||||
MaxScale> flush log error
|
||||
MaxScale> flush log trace
|
||||
MaxScale>
|
||||
@ -154,7 +154,7 @@ This may be integrated into the Linux logrotate mechanism by adding a configurat
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>/usr/local/skysql/maxscale/log/*.log {
|
||||
<td>/usr/local/mariadb/maxscale/log/*.log {
|
||||
monthly
|
||||
rotate 5
|
||||
missingok
|
||||
@ -163,7 +163,7 @@ sharedscripts
|
||||
postrotate
|
||||
\# run if maxscale is running
|
||||
if test -n "`ps acx|grep maxscale`"; then
|
||||
/usr/local/skysql/maxscale/bin/maxadmin -pskysql flush logs
|
||||
/usr/local/mariadb/maxscale/bin/maxadmin -pmariadb flush logs
|
||||
fi
|
||||
endscript
|
||||
}</td>
|
||||
@ -175,14 +175,14 @@ One disadvantage with this is that the password used for the maxadmin command ha
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>/usr/local/skysql/maxscale/log/*.log {
|
||||
<td>/usr/local/mariadb/maxscale/log/*.log {
|
||||
monthly
|
||||
rotate 5
|
||||
missingok
|
||||
nocompress
|
||||
sharedscripts
|
||||
postrotate
|
||||
kill -USR1 `cat /usr/local/skysql/maxscale/log/maxscale.pid`
|
||||
kill -USR1 `cat /usr/local/mariadb/maxscale/log/maxscale.pid`
|
||||
endscript
|
||||
}</td>
|
||||
</tr>
|
||||
|
@ -60,7 +60,7 @@ If you wish to use two different usernames for the two different roles of monito
|
||||
|
||||
### Creating Your MaxScale Configuration
|
||||
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/skysql/maxscale/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/mariadb/maxscale/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
|
||||
A global, maxscale, section is included within every MaxScale configuration file; this is used to set the values of various MaxScale wide parameters, perhaps the most important of these is the number of threads that MaxScale will use to execute the code that forwards requests and handles responses for clients.
|
||||
|
||||
@ -89,7 +89,7 @@ In order to instruct the router to which servers it should route we must add rou
|
||||
|
||||
The final step in the service section is to add the username and password that will be used to populate the user data from the database cluster. There are two options for representing the password, either plain text or encrypted passwords may be used. In order to use encrypted passwords a set of keys must be generated that will be used by the encryption and decryption process. To generate the keys use the maxkeys command and pass the name of the secrets file in which the keys are stored.
|
||||
|
||||
% maxkeys /usr/local/skysql/maxscale/etc/.secrets
|
||||
% maxkeys /usr/local/mariadb/maxscale/etc/.secrets
|
||||
%
|
||||
|
||||
Once the keys have been created the maxpasswd command can be used to generate the encrypted password.
|
||||
@ -178,9 +178,9 @@ or
|
||||
|
||||
% service maxscale start
|
||||
|
||||
Check the error log in /usr/local/skysql/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
Check the error log in /usr/local/mariadb/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
|
||||
% maxadmin -pskysql list services
|
||||
% maxadmin -pmariadb list services
|
||||
|
||||
Services.
|
||||
--------------------------+----------------------+--------+---------------
|
||||
@ -189,7 +189,7 @@ Check the error log in /usr/local/skysql/maxscale/log to see if any errors are d
|
||||
Galera Service | readconnroute | 1 | 1
|
||||
CLI | cli | 2 | 2
|
||||
--------------------------+----------------------+--------+---------------
|
||||
% maxadmin -pskysql list servers
|
||||
% maxadmin -pmariadb list servers
|
||||
Servers.
|
||||
-------------------+-----------------+-------+-------------+-------------------
|
||||
Server | Address | Port | Connections | Status
|
||||
@ -201,7 +201,7 @@ Check the error log in /usr/local/skysql/maxscale/log to see if any errors are d
|
||||
|
||||
A Galera Cluster is a multi-master clustering technology, however the monitor is able to impose false notions of master and slave roles within a Galera Cluster in order to facilitate the use of Galera as if it were a standard MySQL Replication setup. This is merely an internal MaxScale convenience and has no impact on the behaviour of the cluster.
|
||||
|
||||
% maxadmin -pskysql list listeners
|
||||
% maxadmin -pmariadb list listeners
|
||||
|
||||
Listeners.
|
||||
---------------------+--------------------+-----------------+-------+--------
|
||||
|
@ -62,7 +62,7 @@ If you wish to use two different usernames for the two different roles of monito
|
||||
|
||||
### Creating Your MaxScale Configuration
|
||||
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/skysql/maxscale/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/mariadb/maxscale/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
|
||||
A global, maxscale, section is included within every MaxScale configuration file; this is used to set the values of various MaxScale wide parameters, perhaps the most important of these is the number of threads that MaxScale will use to execute the code that forwards requests and handles responses for clients.
|
||||
|
||||
@ -83,7 +83,7 @@ The router for we need to use for this configuration is the readwritesplit modul
|
||||
|
||||
The final step in the service sections is to add the username and password that will be used to populate the user data from the database cluster. There are two options for representing the password, either plain text or encrypted passwords may be used. In order to use encrypted passwords a set of keys must be generated that will be used by the encryption and decryption process. To generate the keys use the maxkeys command and pass the name of the secrets file in which the keys are stored.
|
||||
|
||||
% maxkeys /usr/local/skysql/maxscale/etc/.secrets
|
||||
% maxkeys /usr/local/mariadb/maxscale/etc/.secrets
|
||||
%
|
||||
|
||||
Once the keys have been created the maxpasswd command can be used to generate the encrypted password.
|
||||
@ -183,9 +183,9 @@ or
|
||||
|
||||
% service maxscale start
|
||||
|
||||
Check the error log in /usr/local/skysql/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
Check the error log in /usr/local/mariadb/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
|
||||
% maxadmin -pskysql list services
|
||||
% maxadmin -pmariadb list services
|
||||
|
||||
Services.
|
||||
--------------------------+----------------------+--------+---------------
|
||||
@ -195,7 +195,7 @@ Check the error log in /usr/local/skysql/maxscale/log to see if any errors are d
|
||||
CLI | cli | 2 | 2
|
||||
--------------------------+----------------------+--------+---------------
|
||||
|
||||
% maxadmin -pskysql list servers
|
||||
% maxadmin -pmariadb list servers
|
||||
Servers.
|
||||
-------------------+-----------------+-------+-------------+--------------------
|
||||
Server | Address | Port | Connections | Status
|
||||
@ -207,7 +207,7 @@ Check the error log in /usr/local/skysql/maxscale/log to see if any errors are d
|
||||
|
||||
A Galera Cluster is a multi-master clustering technology, however the monitor is able to impose false notions of master and slave roles within a Galera Cluster in order to facilitate the use of Galera as if it were a standard MySQL Replication setup. This is merely an internal MaxScale convenience and has no impact on the behaviour of the cluster but does allow the monitor to create these pseudo roles which are utilised by the Read/Write Splitter.
|
||||
|
||||
% maxadmin -pskysql list listeners
|
||||
% maxadmin -pmariadb list listeners
|
||||
|
||||
Listeners.
|
||||
---------------------+--------------------+-----------------+-------+--------
|
||||
|
@ -249,7 +249,7 @@ Add these sections in MaxScale.cnf config file:
|
||||
|
||||
Assuming MaxScale is installed in server1, start it
|
||||
|
||||
[root@server1 ~]# cd /usr/local/skysql/maxscale/bin
|
||||
[root@server1 ~]# cd /usr/local/mariadb/maxscale/bin
|
||||
|
||||
[root@server1 bin]# ./maxscale -c ../
|
||||
|
||||
|
@ -70,7 +70,7 @@ If you wish to use two different usernames for the two different roles of monito
|
||||
|
||||
## Creating Your MaxScale Configuration
|
||||
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/skysql/maxscle/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/mariadb/maxscle/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
|
||||
A global, maxscale, section is included within every MaxScale configuration file; this is used to set the values of various MaxScale wide parameters, perhaps the most important of these is the number of threads that MaxScale will use to execute the code that forwards requests and handles responses for clients.
|
||||
|
||||
@ -130,7 +130,7 @@ servers=dbserv1, dbserv2, dbserv3
|
||||
|
||||
The final step in the service sections is to add the username and password that will be used to populate the user data from the database cluster. There are two options for representing the password, either plain text or encrypted passwords may be used. In order to use encrypted passwords a set of keys must be generated that will be used by the encryption and decryption process. To generate the keys use the maxkeys command and pass the name of the secrets file in which the keys are stored.
|
||||
|
||||
% maxkeys /usr/local/skysql/maxscale/etc/.secrets
|
||||
% maxkeys /usr/local/mariadb/maxscale/etc/.secrets
|
||||
|
||||
%
|
||||
|
||||
@ -292,9 +292,9 @@ or
|
||||
|
||||
% service maxscale start
|
||||
|
||||
Check the error log in /usr/local/skysql/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
Check the error log in /usr/local/mariadb/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
|
||||
% maxadmin -pskysql list services
|
||||
% maxadmin -pmariadb list services
|
||||
|
||||
Services.
|
||||
|
||||
@ -312,7 +312,7 @@ CLI | cli | 2 | 2
|
||||
|
||||
--------------------------+----------------------+--------+---------------
|
||||
|
||||
% maxadmin -pskysql list servers
|
||||
% maxadmin -pmariadb list servers
|
||||
|
||||
Servers.
|
||||
|
||||
@ -330,7 +330,7 @@ dbserv3 | 192.168.2.3 | 3306 | 0 | Running, Slave
|
||||
|
||||
-------------------+-----------------+-------+-------------+--------------------
|
||||
|
||||
% maxadmin -pskysql list listeners
|
||||
% maxadmin -pmariadb list listeners
|
||||
|
||||
Listeners.
|
||||
|
||||
|
@ -70,7 +70,7 @@ If you wish to use two different usernames for the two different roles of monito
|
||||
|
||||
## Creating Your MaxScale Configuration
|
||||
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/skysql/maxscale/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
MaxScale configuration is held in an ini file that is located in the file MaxScale.cnf in the directory $MAXSCALE_HOME/etc, if you have installed in the default location then this file is available in /usr/local/mariadb/maxscale/etc/MaxScale.cnf. This is not created as part of the installation process and must be manually created. A template file does exist within this directory that may be use as a basis for your configuration.
|
||||
|
||||
A global, maxscale, section is included within every MaxScale configuration file; this is used to set the values of various MaxScale wide parameters, perhaps the most important of these is the number of threads that MaxScale will use to execute the code that forwards requests and handles responses for clients.
|
||||
|
||||
@ -96,7 +96,7 @@ servers=dbserv1, dbserv2, dbserv3
|
||||
|
||||
The final step in the service sections is to add the username and password that will be used to populate the user data from the database cluster. There are two options for representing the password, either plain text or encrypted passwords may be used. In order to use encrypted passwords a set of keys must be generated that will be used by the encryption and decryption process. To generate the keys use the maxkeys command and pass the name of the secrets file in which the keys are stored.
|
||||
|
||||
% maxkeys /usr/local/skysql/maxscale/etc/.secrets
|
||||
% maxkeys /usr/local/mariadb/maxscale/etc/.secrets
|
||||
|
||||
%
|
||||
|
||||
@ -226,9 +226,9 @@ or
|
||||
|
||||
% service maxscale start
|
||||
|
||||
Check the error log in /usr/local/skysql/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
Check the error log in /usr/local/mariadb/maxscale/log to see if any errors are detected in the configuration file and to confirm MaxScale has been started. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
|
||||
% maxadmin -pskysql list services
|
||||
% maxadmin -pmariadb list services
|
||||
|
||||
Services.
|
||||
|
||||
@ -244,7 +244,7 @@ CLI | cli | 2 | 2
|
||||
|
||||
--------------------------+----------------------+--------+---------------
|
||||
|
||||
% maxadmin -pskysql list servers
|
||||
% maxadmin -pmariadb list servers
|
||||
|
||||
Servers.
|
||||
|
||||
@ -262,7 +262,7 @@ dbserv3 | 192.168.2.3 | 3306 | 0 | Running, Slave
|
||||
|
||||
-------------------+-----------------+-------+-------------+--------------------
|
||||
|
||||
% maxadmin -pskysql list listeners
|
||||
% maxadmin -pmariadb list listeners
|
||||
|
||||
Listeners.
|
||||
|
||||
|
@ -73,9 +73,9 @@ and add (just after localhost.cfg or commnads.cfg)
|
||||
- modify server IP address in server1.cfg, pointing to MaxScale server
|
||||
- maxadmin executable must be in the nagios server
|
||||
- default MaxScale AdminInterface port is 6603
|
||||
- default maxadmin executable path is /usr/local/skysql/maxscale/bin/maxadmin
|
||||
- default maxadmin executable path is /usr/local/mariadb/maxscale/bin/maxadmin
|
||||
It can be changed by -m option
|
||||
- maxadmin executable could be copied from an existing maxscale installation (default location is /usr/local/skysql/maxscale/bin/maxadmin)
|
||||
- maxadmin executable could be copied from an existing maxscale installation (default location is /usr/local/mariadb/maxscale/bin/maxadmin)
|
||||
|
||||
This example shows configuration that needs to be done on Nagios server in order to communicate to MaxScale server that is running on host server1.
|
||||
In this example we are using the check_maxscale_resource as the check command
|
||||
@ -85,7 +85,7 @@ In this example we are using the check_maxscale_resource as the check command
|
||||
use local-service
|
||||
host_name server1
|
||||
service_description MaxScale_sessions
|
||||
check_command check_maxscale_resource!6603!admin!skysql!sessions!/path_to/maxadmin
|
||||
check_command check_maxscale_resource!6603!admin!mariadb!sessions!/path_to/maxadmin
|
||||
notifications_enabled 0
|
||||
}
|
||||
|
||||
|
@ -92,7 +92,7 @@ After this we have a fully working configuration and we can move on to starting
|
||||
|
||||
Upon completion of the configuration process MaxScale is ready to be started . This may either be done manually by running the maxscale command or via the service interface. The service scripts are located in the `/etc/init.d/` folder and are accessible through both the `service` and `systemctl` commands.
|
||||
|
||||
After starting MaxScale check the error log in /usr/local/skysql/maxscale/log to see if any errors are detected in the configuration file. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
After starting MaxScale check the error log in /usr/local/mariadb/maxscale/log to see if any errors are detected in the configuration file. Also the maxadmin command may be used to confirm that MaxScale is running and the services, listeners etc have been correctly configured.
|
||||
|
||||
MaxScale is now ready to start accepting client connections and routing them. Queries are routed to the right servers based on the database they target and switching between the shards is semaless since MaxScale keeps the session state intact between servers.
|
||||
|
||||
|
Reference in New Issue
Block a user