I have a VPS Debian running a nginx webserver and 2 node.js servers, one with socket.io for suplying data for my website and another one for a bot. The socket server runs a lot of queries but I try to keep them as low as possible, the bot runs some queries but not too many, the website is an ordinary website, its taking good amount of traffic, like 400 ppl on it very often. My VPS specs: CPU: 4.8Ghz(2 cores of 2.4) RAM: 2Gb HDD: 40Gb Bandwidth: 2000Gb
The website is running very slow, but its not memory or CPU usage cause those values stay between 40~60%
But when i type service mysql status
this is what I get:
Threads: 2 Questions: 122488 Slow queries: 0 Opens: 172 Flush tables: 1 Open tables: 113 Queries per second avg: 935.022.
And this numbers get a lot bigger when the site is crowded. I haven't changed the my.conf neither nginx.conf(only changed the root) since I'm a completely newbie at this. What Am I doing wrong? How can I log the queries to check where are all those coming from?