# MaxScale documentation: # https://mariadb.com/kb/en/mariadb-maxscale-24/ # Global parameters # # Complete list of configuration options: # https://mariadb.com/kb/en/mariadb-maxscale-24-mariadb-maxscale-configuration-guide/ [maxscale] threads=auto admin_host=0.0.0.0 admin_secure_gui=false # Server definitions # # Set the address of the server to the network # address of a MariaDB server. # [server1] type=server address=10.10.1.10 port=3306 protocol=MariaDBBackend [server2] type = server address = 10.10.2.207 port = 3306 protocol = MariaDBBackend # Monitor for the servers # # This will keep MaxScale aware of the state of the servers. # MariaDB Monitor documentation: # https://mariadb.com/kb/en/mariadb-maxscale-24-mariadb-monitor/ [MariaDB-Monitor] type=monitor module=mariadbmon servers=server1,server2 user=repmaxscale password=M@xpa55! monitor_interval=2000 # Service definitions # # Service Definition for a read-only service and # a read/write splitting service. # # ReadConnRoute documentation: # https://mariadb.com/kb/en/mariadb-maxscale-24-readconnroute/ [Read-Only-Service] type=service router=readconnroute servers=server1 user=repmaxscale password=M@xpa55! router_options=slave # ReadWriteSplit documentation: # https://mariadb.com/kb/en/mariadb-maxscale-24-readwritesplit/ [Read-Write-Service] type=service router=readwritesplit #filters=split-router-cache servers=server1,server2 user=repmaxscale password=M@xpa55! #[split-router-cache] #type = filter #module = cache #hard_ttl = 30s #soft_ttl = 20s #storage = storage_redis #storage_options = server=datacheck.6ffefa.ng.0001.use1.cache.amazonaws.com:6379 # Listener definitions for the services # # These listeners represent the ports the # services will listen on. # [Read-Only-Listener] type=listener service=Read-Only-Service protocol=MariaDBClient port=4008 [Read-Write-Listener] type=listener service=Read-Write-Service protocol=MariaDBClient port=4006