Files
cloud/press/playbooks/mariadb_memory_allocator.yml
Aditya Hase 885471318e feat: Allow switching MariaDB memory allocator
Supports TCMalloc (google-perftools) and jemalloc (libjemalloc20.

Finds the shared library using
`find /usr/lib -name "libtcmalloc.so.*` or
`find /usr/lib -name "libjemalloc.so.*`

Sets LD_PRELOAD environment variable using the SystemD drop-in

Setting alloctor to "System" removes the LD_PRELOAD variable (falls back to glibc malloc).

Call update_memory_allocator(memory_allocator). Restarts MariaDB.
2024-06-21 14:56:30 +05:30

7 lines
136 B
YAML

---
- name: Update MariaDB Memory Allocator
hosts: all
become: yes
become_user: root
roles:
- role: mariadb_memory_allocator