Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the ad-inserter domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /var/www/vhosts/blog.webeats.it/httpdocs/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the cookie-law-info domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /var/www/vhosts/blog.webeats.it/httpdocs/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the wordpress-seo domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /var/www/vhosts/blog.webeats.it/httpdocs/wp-includes/functions.php on line 6114
Linux Performance Tuning per MySQL - Blog WebEats

Vediamo qualche piccolo impostazione per avere prestazioni migliori sul nostro server VPS o dedicato.

Filesystem

– ext4 (or xfs), mount with noatime
– Scheduler – use deadline or noop

# echo deadline >/sys/block/sda/queue/scheduler
add "elevator=deadline" to grub.conf

Memoria

Swappiness e NUMA:

# echo 0 > /proc/sys/vm/swappiness
add "vm.swappiness = 0" to /etc/sysctl.conf

Imposta numa interleave all
numactl --interleave=all

Se stai usando Percona Server puoi impostarlo nello script mysqld_safe, visto che Percona Server supporta il controllo NUMA.
Il blog di Jeremy Cole contiene una ottima panoramica su NUMA e su NUMA tools
(e non dimenticare innodb_flush_method=O_DIRECT)

CPU

Fai attenzione che non sia attiva la modalità “powersave”:
Controlla /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
e assicurati che non sia su “ondemand”
Controlla /proc/cpuinfo and compare cpu MHz number to what is listed under the “model name”
Disabilita “ondemand” se è attivo

Esempio: “ondemand” è attivo su tutte le CPU

$ ps ax| grep kondemand|wc -l
65
$ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
ondemand

abbiamo:

/proc/cpuinfo:
model name : Intel(R) Xeon(R) CPU E5-1620 v2 @ 3.70GHz
..
cpu MHz : 3700.000

In questo caso è necessario disabilitare “ondemand”.