wordpress on fly.io super fast last night, today its got 15s page load times.

MySQL can be quite memory hungry if you let it. Here are some config options you can use to get the memory use down.

# Performance optimisations
# http://www.tocker.ca/2014/03/10/configuring-mysql-to-use-minimal-memory.html
# https://www.woktron.com/secure/knowledgebase/272/How-to-optimize-MySQL-performance.html
performance_schema = OFF

key_buffer_size = 16M
tmp_table_size = 1M

read_buffer_size = 256K
read_rnd_buffer_size = 1M
net_buffer_length = 2K
sort_buffer_size = 256K
join_buffer_size = 1M

innodb_buffer_pool_size = 8M
innodb_log_buffer_size = 256k
innodb_sort_buffer_size = 125k

max_connections = 25
max_user_connections = 25

table_open_cache = 12
table_open_cache_instances = 1

We are running a complete LAMP stack on a 1GB shared cpu instance. Works really well. You can find our stack here: GitHub - joomlatools/joomlatools-server: Cloud native dev evironment for Joomla CMS, Wordpress and Joomlatools Pages in case you wanna poke around to see it’s config. It’s tailored for Wordpress and Joomla, if you turn MySQL off you get a generic PHP server.

6 Likes