Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
Lenny Warren Posted May 4, 2016 Posted May 4, 2016 Hi there, I self host my forum on a VPS Intel(R) Xeon(R) CPU E5-2660 0 @ 2.20GHz 32 core(s) with 1Gb of RAM. My forum db is 57Mb, and I only have 565 members. All my images are stored on Amazon S3 http://www.militariacollectors.network Tonight MySQL was killed a few times due to out of memory. My host support gave me the following info: Quote The mysql service was killed due to running out of memory, see below: May 4 19:03:36 warren-server kernel: [34463392.872123] Out of memory in UB 10182: OOM killed process 1078 (mysqld) score 0 vm:1542400kB, rss:454264kB, swap:0kB May 4 19:03:36 warren-server kernel: [34463393.296922] Out of memory in UB 10182: OOM killed process 1124 (mysqld) score 0 vm:415112kB, rss:364300kB, swap:0kB May 4 19:16:18 warren-server kernel: [34464154.108012] Out of memory in UB 10182: OOM killed process 1611 (mysqld) score 0 vm:1612160kB, rss:464564kB, swap:0kB May 4 19:16:30 warren-server kernel: [34464166.430189] Out of memory in UB 10182: OOM killed process 2001 (mysqld) score 0 vm:1214200kB, rss:454928kB, swap:0kB May 4 19:16:31 warren-server kernel: [34464166.884519] Out of memory in UB 10182: OOM killed process 2042 (mysqld) score 0 vm:415112kB, rss:372336kB, swap:0kB Your database alone is using 470mb of memory, basically in idle. Your available free memory is fluctuating between a little over 100 to 250mb. I have enabled slow queries for your mysql to see we can find some queries that need and can be optimized. but they said that everything seemed optimized, all ok, but I should upgrade my server with more memory. They then came back with: Quote [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: PHP Fatal error: Uncaught exception 'ErrorException' with message 'mysqli::real_escape_string(): Couldn't fetch IPS\\Db' in /var/www/vhosts/militariacollectors.network/httpdocs/forums/system/Db/Db.php:1964, referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: Stack trace:, referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: #0 [internal function]: IPS\\IPS::errorHandler(2, 'mysqli::real_es...', '/var/www/vhosts...', 1964, Array), referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: #1 /var/www/vhosts/militariacollectors.network/httpdocs/forums/system/Db/Db.php(1964): mysqli->real_escape_string('cacheKeys'), referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: #2 /var/www/vhosts/militariacollectors.network/httpdocs/forums/system/Data/Store/Database.php(89): IPS\\_Db->in('store_key', Array), referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: #3 /var/www/vhosts/militariacollectors.network/httpdocs/forums/system/Data/Store/Database.php(105): IPS\\Data\\Store\\_Database->loadIntoMemory(Array), referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: #4 /var/www/vhosts/militariacollectors.network/httpdocs/forums/system/Data/Store/Database.php(152): IPS\\Data\\Store\\_Database->get('cacheKeys'), referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: #5 /var/www/vhosts/militariacollectors.network/httpdocs/forums/system/Data/AbstractData.php(121): IPS\\Data\\Store\\_Database->exists('cacheKeys'), referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ [Wed May 04 20:03:43 2016] [warn] [client 80.42.181.180] mod_fcgid: stderr: #6 /var/www/vhosts/milit in /var/www/vhosts/militariacollectors.network/httpdocs/forums/system/Db/Db.php on line 1964, referer: http://www.militariacollectors.network/forums/topic/1546-were-you-a-member-of-the-old-forum/ Mysql oom: May 4 20:03:47 warren-server kernel: [34467000.047688] Out of memory in UB 10182: OOM killed process 4959 (mysqld) score 0 vm:1082132kB, rss:451448kB, swap:0kB May 4 20:03:47 warren-server kernel: [34467000.578439] Out of memory in UB 10182: OOM killed process 5351 (mysqld) score 0 vm:620144kB, rss:429236kB, swap:0kB What could cause this? I thought my small forum would be ok with 1Gb of RAM? Are there any plugins or apps that could be causing issues with memory???
Lenny Warren Posted May 5, 2016 Author Posted May 5, 2016 Is there any way of checking what apps are maybe stressing the database????
RevengeFNF Posted May 5, 2016 Posted May 5, 2016 Can you run mysqltuner in your vps and return here the result?
Lenny Warren Posted May 6, 2016 Author Posted May 6, 2016 I'm not sure how to do this, my host support have said... Quote To reduce memory usage i tweaked a bit the default mysql variables and this should help with memory usage. This may affect performance but I don't think it will have a noticeable effect. Memory usage does seem less.... mmm....
tnn Posted May 6, 2016 Posted May 6, 2016 On 5/4/2016 at 4:29 PM, Lenny Warren said: Hi there, I self host my forum on a VPS Intel(R) Xeon(R) CPU E5-2660 0 @ 2.20GHz 32 core(s) with 1Gb of RAM. My forum db is 57Mb, and I only have 565 members. All my images are stored on Amazon S3 http://www.militariacollectors.network Tonight MySQL was killed a few times due to out of memory. My host support gave me the following info: but they said that everything seemed optimized, all ok, but I should upgrade my server with more memory. They then came back with: What could cause this? I thought my small forum would be ok with 1Gb of RAM? Are there any plugins or apps that could be causing issues with memory??? Lenny can you create a support ticket and ask them how much disk space you have and also if they can remove any old files that are not needed such as old log files, old kernels etc.? On your part, can you see where your rss feeds are being used for? Got to run but will be back.
Lenny Warren Posted May 6, 2016 Author Posted May 6, 2016 I'm fine for disk space, and memory usage seems better now....
Lenny Warren Posted May 6, 2016 Author Posted May 6, 2016 All seems to be fine now after support optimized it, cheers..
Tracy Perry Posted May 9, 2016 Posted May 9, 2016 If you were that close, then you may want to seriously consider going to a 2GB setup. 1GB for a "heavy" process like a forum and using any kind of real caching is on the low end. All it's going to take is a good scraper hit or bot hit and you will probably be running out of resources again.
Lenny Warren Posted May 9, 2016 Author Posted May 9, 2016 I had been thinking that @Tracy Perry, but can't justify the extra cost at the moment. Small forum with under 600 members, never get's that busy. Al seems fine now that host support have optimized things...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.