WordPress Posting Slowdown
-
Hello to All!
I have a Python script that generates an array of posts to publish on a WordPress site. Posts are stored in memory in a form of array in JSON format for uploading to the WordPress via the REST API using Python requests.post function.
First 300-400 posts work great and a posting speed is about several posts per second. Htop shows several mariadb instances working, memory is not overloaded and uses 1-2Gb from 12Gb total.
But after that everything starts to slow down dramatically. After a while only 2 mariadb processes remain consuming about 90-100% of one CPU core jumping from one core to another. Other cores are almost free.
The speed of posting drops to 1-2 posts per 10-15 seconds and gradualy almost dies in time. But I need to record several thousands of posts so it is not acceptable. I did not tweak database settings much, so what I have im /etc/mysql/my.conf:
[mariadb]
performance_schema=ON
skip-name-resolve=1
innodb_buffer_pool_size=2G
innodb_log_file_size=512M
slow_query_log=1
tmp_table_size=64M
max_heap_table_size=64M
thread_handling=pool-of-threads
query_cache_size=0I have tried Redis, WP-Cache, WP-Optimize but it’s all for reading, they don’t work for writing.
Maybe someone could direct me where though to dig?
Thank you in advance!
- The topic ‘WordPress Posting Slowdown’ is closed to new replies.