New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Comments
Google. Find out how to edit the ram usage and number of threads of php-fpm and also edit the mysql config. There's lots of tutorials around for these. If all else fails, buy more ram.
If you are using myisam as storage engine,
vim /etc/mysql/conf.d/leb.cnf
[mysqld]
skip-innodb
default-storage-engine = myisam
If your site is small,
vim /etc/php5/fpm/pool.d/www.conf
pm = static
pm.max_children = 2
i tried other my.cnf configs, but when i load them, my wordpress site cannot find the database anymore for some reason?
`
[client]
port = 3306
socket = /var/run/mysqld/mysqld.sock
[mysqld_safe]
socket = /var/run/mysqld/mysqld.sock
nice = 0
[mysqld]
user = mysql
pid-file = /var/run/mysqld/mysqld.pid
socket = /var/run/mysqld/mysqld.sock
port = 3306
basedir = /usr
datadir = /var/lib/mysql
tmpdir = /tmp
lc-messages-dir = /usr/share/mysql
skip-external-locking
bind-address = 127.0.0.1
default-storage-engine = myisam
key_buffer = 1M
query_cache_size = 1M
query_cache_limit = 128k
max_connections=25
thread_cache=1
skip-innodb
query_cache_min_res_unit=0
tmp_table_size = 1M
max_heap_table_size = 1M
table_cache=256
concurrent_insert=2
max_allowed_packet = 1M
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 64K
expire_logs_days = 10
max_binlog_size = 100M
[mysqldump]
quick
quote-names
max_allowed_packet = 16M
[mysql]
[isamchk]
key_buffer = 16M
`
this is the new one i tried. I used tuxlite to setup the vps
When i change the mycnf to the above, wordpress starts with the default install
The amount of memory used by PHP is determined by the app (Wordpress) and the number of simultaneous visitors.
You might look at your Wordpress config (plugins) for something that is abusing memory.
I have wordpress site on my dedicated server. Using nginx, php-fpm, mysql, apc, & memcached. With 3000+ uv per hour only use ~ 2 GB of 16 GB memory.
Server spec maybe seems overkill, but previously while still using the DO vps, the cpu load is too high. Wordpress is cpu hogging when faced with many concurrent request
So basically you might look at your active plugins for something that using to much memory.
Also you might be intersted in using CloudFlare and WP Super Cache plugin for wordpress That should speed up your website and save on the resources.
May be a stupid question, but have you thought of using a Turnkey Linux distribution?
There's one already configured with nginx, php5-fpm and mysql already configured. A simple apt-get update & upgrade and you'd be up-to-date and running within minutes.
OP want to tune for LEB, not just deploying.
Anyway, I have active WP website which have more than 1,000 concurrent visitors at certain time. Its in 256MB box. I set it up few years ago using this as basic guide. The trick with WP is to always minimize php & sql call.
anyone know why this happens?
Anyone have a nice nginx/php5-fpm installer for debian?
@linuxthefish
Yes, it's called dotdeb repo.
I'm going to guess it happens because you're changing datadir.
Do you having caching like quickcache installed on your wordpress installs?
throw varnish into your mix for some really impressive improvements. @bigcat already linked one of the best guides out there for supercharging wordpress.
This, Varnish will by far make the biggest difference. Even when you setup a cache plugin in WP, and tune nginx etc, it will still hog your CPU.
Make sure you disable WP-cron as that will completely kill your server once you get heaps of traffic: http://www.inmotionhosting.com/support/website/wordpress/disabling-the-wp-cronphp-in-wordpress
You can get varnish to run on a fairly low ram VPS (I have it running on 512mb DO VPS with a site that gets about 500 uniques a day).
i don't see any difference in the config regarding datadir
Other applications that use mysql still work