Hello to all the specialists and geniuses who professionally use MySQL,
I have purchased a physical server and colocated it in a data center. This server is an HP G9 generation, with 128 GB of DDR4 RAM, 2 Xeon 2680V4 processors, and 8 PRO SSDs with 1 TB capacity each. On this server, I have installed an ESXi machine (one Windows Server 2019 with a dedicated application running on it, and one Linux machine, which I will explain in detail below).
Within this setup, an AlmaLinux 8 machine is installed, and on this Linux machine, cPanel/WHM is installed, with Litespeed Enterprise as the web server. I have dedicated an entire processor from one socket to this Linux machine, meaning 28 cores of the processor, 500 GB of hard disk, 64 GB of RAM, and 1 GB of dedicated internet. Given the hardware I have, I want to customize MySQL in the best and most professional way possible to support the website with high power.
On this Linux server, there is a WordPress/WooCommerce website with 2000 users logging in and placing orders daily. This dedicated server is solely for the WordPress/WooCommerce site. We want to optimize this server in the highest and best possible conditions to utilize all the dedicated hardware power.
I asked ChatGPT for MySQL optimization, and it responded with the following settings. Are these settings correct or not?
[mysqld]
# General settings
max_connections = 2000
table_open_cache = 8000
thread_cache_size = 100
# InnoDB settings
innodb_buffer_pool_size = 64G # (Can be increased as needed)
innodb_buffer_pool_instances = 8
innodb_log_file_size = 4G
innodb_flush_log_at_trx_commit = 2
innodb_flush_method = O_DIRECT
innodb_thread_concurrency = 56 # (2 times the number of cores)
innodb_read_io_threads = 32
innodb_write_io_threads = 32
innodb_io_capacity = 2000
# Query Cache (if needed)
query_cache_type = 1
query_cache_size = 256M
# Additional settings
tmp_table_size = 512M
max_heap_table_size = 512M
join_buffer_size = 16M
sort_buffer_size = 16M
read_buffer_size = 8M
read_rnd_buffer_size = 8M
Do we need to migrate from mysql to mariadb?
In linux command line I used this command htop
and it show me the process on the serve, the mysql process in higher than other things,
Also we are using PHP 8.1 and Almalinux and cPanel are update to last version. this it configuration of PHP if you need to know about it,
I asked from google Gemini and ChatGPT but I don’t think they are telling me the truth for this matters, I couldn’t find any website for mysql so I asked it here and hope some of you will help me in this case
Thank you all.