82 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			82 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
| # MaxScale documentation:
 | |
| # https://mariadb.com/kb/en/mariadb-enterprise/mariadb-maxscale-23/
 | |
| 
 | |
| # Global parameters
 | |
| #
 | |
| # Complete list of configuration options:
 | |
| # https://mariadb.com/kb/en/mariadb-maxscale-23-mariadb-maxscale-configuration-usage-scenarios/
 | |
| 
 | |
| [maxscale]
 | |
| threads=auto
 | |
| 
 | |
| # Server definitions
 | |
| #
 | |
| # Set the address of the server to the network
 | |
| # address of a MariaDB server.
 | |
| #
 | |
| 
 | |
| [server1]
 | |
| type=server
 | |
| address=127.0.0.1
 | |
| 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-23-mariadb-monitor/
 | |
| 
 | |
| [MariaDB-Monitor]
 | |
| type=monitor
 | |
| module=mariadbmon
 | |
| servers=server1
 | |
| user=myuser
 | |
| password=mypwd
 | |
| 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-23-readconnroute/
 | |
| 
 | |
| [Read-Only-Service]
 | |
| type=service
 | |
| router=readconnroute
 | |
| servers=server1
 | |
| user=myuser
 | |
| password=mypwd
 | |
| router_options=slave
 | |
| 
 | |
| # ReadWriteSplit documentation:
 | |
| # https://mariadb.com/kb/en/mariadb-maxscale-23-readwritesplit/
 | |
| 
 | |
| [Read-Write-Service]
 | |
| type=service
 | |
| router=readwritesplit
 | |
| servers=server1
 | |
| user=myuser
 | |
| password=mypwd
 | |
| 
 | |
| # 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
 | 
