Performance: Increase database buffer pools for Nextcloud and Zabbix
- Nextcloud MariaDB: 128MB → 4GB buffer pool - Zabbix MariaDB: 128MB → 3GB buffer pool - Added innodb-log-file-size=512M for better write performance - Added max-connections=200 for better concurrency - Created performance.cnf for Zabbix with additional optimizations Expected improvement: 3-6x faster database queries Impact: Better responsiveness for Nextcloud and Zabbix web UI
This commit is contained in:
@@ -15,6 +15,7 @@ services:
|
|||||||
#options:
|
#options:
|
||||||
#loki-url: "http://localhost:3100/loki/api/v1/push"
|
#loki-url: "http://localhost:3100/loki/api/v1/push"
|
||||||
image: mariadb:10.5
|
image: mariadb:10.5
|
||||||
|
command: --innodb-buffer-pool-size=4G --innodb-log-file-size=512M --max-connections=200
|
||||||
volumes:
|
volumes:
|
||||||
- /home/icke/mariadb-nextcloud/db:/var/lib/mysql
|
- /home/icke/mariadb-nextcloud/db:/var/lib/mysql
|
||||||
- /etc/localtime:/etc/localtime:ro
|
- /etc/localtime:/etc/localtime:ro
|
||||||
|
|||||||
@@ -103,7 +103,7 @@ services:
|
|||||||
- MYSQL_PASSWORD=eccmts42*
|
- MYSQL_PASSWORD=eccmts42*
|
||||||
volumes:
|
volumes:
|
||||||
- /home/icke/mysql-zabbix/var:/var/lib/mysql
|
- /home/icke/mysql-zabbix/var:/var/lib/mysql
|
||||||
- /home/icke/mysql-zabbix/custom.cnf:/etc/mysql/conf.d/custom.cnf
|
- /home/icke/mysql-zabbix/performance.cnf:/etc/mysql/conf.d/performance.cnf:ro
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
networks:
|
networks:
|
||||||
zabbix:
|
zabbix:
|
||||||
|
|||||||
@@ -143,7 +143,7 @@ services:
|
|||||||
# ------------------------------------------------
|
# ------------------------------------------------
|
||||||
mysql-zabbix:
|
mysql-zabbix:
|
||||||
image: mariadb:10.6
|
image: mariadb:10.6
|
||||||
command: ['mysqld', '--collation_server=utf8_bin', '--character_set_server=utf8']
|
command: ['mysqld', '--collation_server=utf8_bin', '--character_set_server=utf8', '--innodb-buffer-pool-size=3G', '--innodb-log-file-size=512M', '--max-connections=200']
|
||||||
container_name: mysql-zabbix
|
container_name: mysql-zabbix
|
||||||
restart: always
|
restart: always
|
||||||
volumes:
|
volumes:
|
||||||
|
|||||||
Reference in New Issue
Block a user