Thread: News M3 server issue
View Single Post
Old 08-07-2020, 11:35 AM  
k33n
Confirmed User
 
Join Date: Feb 2009
Posts: 201
I am no expert but here is my opinion.

You say that you have 4 cam sites and 3 tubes, all on wordpress with plugins, however,in your screenshot, database usage is only 40MB. I don't know how you do it because on my website, the models table is bigger than this. Maybe you are using a local xml file, which would explain the low database disk usage, i think i saw the option in a demo script for cams, to use xml instead of tables. The two ways are nothing alike, working with databases is not the same as reading a xml file.

In your other screenshot, i can see 3% mysql connections so it is obvious that you are using databases. Now depending on the connection limit, this could be a high number, as a database connection should be closed as soon as whatever opened it finished its job. This can be a hint that the job is not completing in time or at all.

Because we all know cams needs to be updated via a cron, lets assume that you set your cron to run every 5 minutes, but the script takes 7 minutes to complete (or more). When a table is updated, depending on the table engine, the second cron would find a table lock and it would have to wait 2 minutes until the first cron finishes and release the table. The second cron, will take 7 minutes to complete from the moment it had access to the table, 3 minutes later a third cron finds the table lock and will have to wait 4 minutes until the second cron releases the table, and so on. As you can see, each delay causes a bigger delay. Each job will reserve an amount of memory to complete and i think will use the max memory allowed, set in php.ini, therefore at some point your vps will run out of memory and the db will refuse new connections.Again, this is only a scenario, my opinion on what i think is happening with your website, based on the little information you provided.
  • If you restart the vps and the website comes back online, your problem is not the host.
  • If your resource usage after restart is low but increases in time, your problem is not the host.
k33n is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote